Auth

Create On-Demand Sync

Changed on

Request a sync for a specific date range. Creates a sync job that is processed by a scheduler.

post/connections/on-demand-syncs

Request

  • Base URL
    https://production.trackstarhq.com
  • URL
    https://production.trackstarhq.com/connections/on-demand-syncs
  • Auth
    none required

Headers

x-trackstar-api-keystring required
Example:<x-trackstar-api-key>

Your organization-level Trackstar API key.

x-trackstar-access-tokenstring required
Example:<x-trackstar-access-token>

Your user's access token for a specific integration (ShipHero, Extensiv, etc).

Request body

start_timestring date-time required

The start time for the sync range.

end_timestring date-time required

The end time for the sync range.

function_namestring required

The function to sync.

Example request

{
  "start_time": "2023-03-15T13:45:30Z",
  "end_time": "2023-03-15T13:45:30Z",
  "function_name": "function_name"
}

Response

Successful response

Example response

{
  "data": {
    "id": "550e8400-e29b-41d4-a716-446655440000",
    "connection_id": "07b344db-0304-4866-9ae1-ac8af5292a28",
    "function_name": "get_orders",
    "status": "open",
    "requested_start_time": "2024-01-01T00:00:00Z",
    "requested_end_time": "2024-01-31T23:59:59Z",
    "created_at": "2024-01-15T12:00:00Z",
    "completed_at": "2024-01-15T12:05:00Z",
    "cancelled_at": "2024-01-15T12:05:00Z"
  }
}

Changes