Create my time entry
Creates one explicit canonical time entry for the authenticated principal. Requires an Idempotency-Key header; inferred time is not accepted by this operation.
/api/v1/time-entriesAuthorization
time:write_selfapi key scoperequiredRequest body
work_datestringrequiredduration_minutesnumberrequiredproject_idstringoptionalwork_item_idstringoptionalcategory_keystringrequiredbillable_statusstringoptional"billable" | "non_billable" | "investment"notesstringoptional{
"work_date": "2026-07-14",
"duration_minutes": 90,
"project_id": "proj_abc123",
"category_key": "client_delivery",
"billable_status": "billable",
"notes": "Implemented retry handling"
}Request
curl -X POST "https://www.digitalstack360.com/api/v1/time-entries" \
-H "Authorization: Bearer $DS_API_KEY" \
-H "Idempotency-Key: time-2026-07-14-client-sync" \
-H "Content-Type: application/json" \
-d '{"work_date":"2026-07-14","duration_minutes":90,"project_id":"proj_abc123","category_key":"client_delivery","billable_status":"billable","notes":"Implemented retry handling"}'Examples use a placeholder key from your environment. Store your key in $DS_API_KEY — never commit it.
Response
{
"data": {
"id": "time_01k2...",
"work_date": "2026-07-14",
"duration_minutes": 90,
"billable_status": "billable",
"category_key": "client_delivery",
"notes": "Implemented retry handling",
"target_type": "project",
"target_id": "proj_abc123",
"project_id": "proj_abc123",
"status": "draft",
"version": 1,
"source": {
"kind": "manual",
"external_source": null,
"external_id": null
},
"created_at": "2026-07-14T18:22:04Z",
"updated_at": "2026-07-14T18:22:04Z"
},
"meta": {
"idempotency_replayed": false,
"self_scoped": true
}
}Errors
missing_authNo credentials provided
invalid_api_keyAPI key is invalid or revoked
bad_requestMissing or invalid request fields
scope_insufficientKey lacks the required write scope
invalid_jsonRequest body is not valid JSON
invalid_bodyRequest body is not a JSON object
self_scope_requiredA caller-supplied user_id is never accepted
invalid_datework_date is not a real YYYY-MM-DD calendar date
invalid_durationduration_minutes is not an integer from 1 through 1440
category_requiredcategory_key is missing
category_not_foundcategory_key is not active in this workspace
billable_status_invalidbillable_status is not an allowed value
notes_too_longnotes exceeds 4,000 characters
idempotency_key_invalidIdempotency-Key is missing or exceeds 200 characters
membership_requiredThe caller is not an active workspace member
idempotency_conflictThe key was previously used with a different command
project_not_foundProject is not in the resolved workspace
target_not_foundThe attributed work item or object does not exist