Start a Timely import

Starts an idempotent Timely-to-DigitalStack import for an exact date range of at most 90 days. Timely must already be connected; DigitalStack remains the canonical owner after import.

POST/api/v1/time-imports

Authorization

time:importapi key scoperequired
Required scope when calling with an API key.

Request body

providerstringrequired"timely"
Currently timely
date_fromstringrequired
Inclusive YYYY-MM-DD
date_tostringrequired
Inclusive YYYY-MM-DD; maximum 90-day range
confirmbooleanrequired
Must be true
Example request
{
  "provider": "timely",
  "date_from": "2026-07-01",
  "date_to": "2026-07-14",
  "confirm": true
}

Request

curl -X POST "https://www.digitalstack360.com/api/v1/time-imports" \
  -H "Authorization: Bearer $DS_API_KEY" \
  -H "Idempotency-Key: timely-import-2026-07-01-14" \
  -H "Content-Type: application/json" \
  -d '{"provider":"timely","date_from":"2026-07-01","date_to":"2026-07-14","confirm":true}'

Examples use a placeholder key from your environment. Store your key in $DS_API_KEY — never commit it.

Response

200 OK
{
  "data": {
    "id": "import_01k2...",
    "provider": "timely",
    "state": "completed",
    "imported": 42,
    "skipped": 3,
    "idempotency_replayed": false
  },
  "meta": {
    "admin_only": true,
    "idempotency_replayed": false
  }
}

Errors

401
missing_auth

No credentials provided

401
invalid_api_key

API key is invalid or revoked

400
bad_request

Missing or invalid request fields

403
scope_insufficient

Key lacks the required write scope

403
admin_required

Workspace admin or owner role is required

409
provider_not_connected

Timely is not connected

400
invalid_date_range

Range is invalid or exceeds 90 days