Sync a connection now (instance admin, one tenant)
POST /v1/users/{id}/connections/{provider}/sync (syncConnection) for the tenant of tenant_id, run with an
instance admin key: the same body, parameters and answer as the tenant's own key
gets; a Location points at the admin route. Recorded in the caller's audit log
and, actor admin, in the tenant's.
See docs/admin-api.md.
tenantKeyAuthorizationBearer <token>Tenant API key, ohs_sk_ + 43 base62 characters.
tenant_id*stringThe id of a tenant; any other value is a 404.
uuidid*stringuuidprovider*stringConnector slug, see GET /v1/providers.
application/json- body
from?stringdate-timeA manual run of this connection is already queued or running.
application/json- response
One pull of one connection. status is queued, running, retrying (the last attempt
failed, see error; the next is at next_attempt_at), rate_limited (the provider asked to
wait until next_attempt_at), succeeded, failed (attempts spent, or the grant was refused)
or cancelled (the connection was disconnected). objects_stored counts the raw provider
payloads stored; the records written from them are announced by data.written webhooks.
id*integerint64provider*stringtrigger*string"backfill""scheduled""notification""manual"status*string"queued""running""retrying""rate_limited""succeeded""failed""cancelled"data_type*|Set when a notification named the one data type to pull.
window_start*stringdate-timewindow_end*stringdate-timeattempts*integerFailed attempts so far.
objects_stored*integer|nullerror*string|nullcreated_at*stringdate-timestarted_at*|date-timefinished_at*|date-timenext_attempt_at*|date-timecurl -X POST 'http://localhost:8080/v1/admin/tenants/497f6eca-6276-4993-bfeb-53cbbbba6f08/users/497f6eca-6276-4993-bfeb-53cbbbba6f08/connections/withings/sync' \ -H 'Authorization: Bearer ohs_sk_...' \ -H 'Content-Type: application/json' \ -d '{}'{ "id": 0, "provider": "string", "trigger": "backfill", "status": "queued", "data_type": "string", "window_start": "2019-08-24T14:15:22Z", "window_end": "2019-08-24T14:15:22Z", "attempts": 0, "objects_stored": 0, "error": "string", "created_at": "2019-08-24T14:15:22Z", "started_at": "2019-08-24T14:15:22Z", "finished_at": "2019-08-24T14:15:22Z", "next_attempt_at": "2019-08-24T14:15:22Z"}