Skip to main content
PATCH
/
api
/
v1
/
workspaces
/
{workspace_id}
/
sync
/
state
Update Sync State
curl --request PATCH \
  --url https://api.example.com/api/v1/workspaces/{workspace_id}/sync/state \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "last_base_ref_sync_ref": "<string>",
  "last_base_ref_sync_sha": "<string>",
  "add_synced_head_refs": [
    "<string>"
  ],
  "add_synced_checkpoints": [
    "<string>"
  ]
}
'
{
  "synced_head_refs": [
    "<string>"
  ],
  "synced_checkpoints": [
    "<string>"
  ],
  "last_base_ref_sync_at": "2023-11-07T05:31:56Z",
  "last_base_ref_sync_ref": "<string>",
  "last_base_ref_sync_sha": "<string>"
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

workspace_id
string
required

Body

application/json

Request to update sync state after successful upload.

last_base_ref_sync_ref
string | null
last_base_ref_sync_sha
string | null
add_synced_head_refs
string[] | null
add_synced_checkpoints
string[] | null

Response

Successful Response

Current sync state for a workspace.

synced_head_refs
string[]
required
synced_checkpoints
string[]
required
last_base_ref_sync_at
string<date-time> | null
last_base_ref_sync_ref
string | null
last_base_ref_sync_sha
string | null