Sync source

POST/sources/{sourceID}/sync

Start a sandbox source-sync simulation for all active policy rules; provisioned design-partner adapters may use the same result shape.

Auth:Bearer

Path parameters

sourceID

uuidrequired

Request body

sync_mode

Sync mode (default: full)

full | incremental

Response

id

Unique identifier for this resource.

uuid
source_id

Unique identifier (UUID) for the related resource.

uuid
sync_mode

One of: full, incremental, single_rule.

full | incremental | single_rule
trigger_type

What initiated the job (e.g. `manual`, `scheduled`, `policy_change`).

manual | auto | webhook | policy_change
status

Current lifecycle state of the resource.

pending | running | completed | failed | partial
rules_pushed

Number of rules the sandbox simulation or provisioned pilot adapter reported as applied.

integer
rules_skipped

Number of rules skipped because the target does not support that category.

integer
rules_failed

Number of rules that returned an error while being applied.

integer
error_message

Human-readable error detail when the operation failed; null on success.

stringnull
started_at

RFC 3339 timestamp of when the job started running.

datetime
completed_at

RFC 3339 timestamp of when the job finished.

datetime
created_at

RFC 3339 timestamp of when the resource was created.

datetime
Request
bash
curl -sS -X POST "https://phosra-api-sandbox-production.up.railway.app/api/v1/sources/5a5a5a5a-1111-4222-8333-444455556666/sync" \
  -H "Authorization: Bearer $PHOSRA_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "sync_mode": "incremental"
}'
Response
json
{
  "id": "550e8400-e29b-41d4-a716-446655440000",
  "source_id": "550e8400-e29b-41d4-a716-446655440000",
  "sync_mode": "full",
  "trigger_type": "manual",
  "status": "pending",
  "rules_pushed": 0,
  "rules_skipped": 0,
  "rules_failed": 0,
  "error_message": null,
  "started_at": null,
  "completed_at": null,
  "created_at": "2025-01-15T09:30:00Z"
}