Time entries
Ce contenu n’est pas encore disponible dans votre langue.
Time tracking is self-report per member: these endpoints read YOUR OWN entries and running timer only — there is no all-members read.
List time entries
Section titled “List time entries”List YOUR OWN time entries in a workspace (time tracking is self-report per member — there is no all-members read). Optional issueId narrows to one issue; from/to (ms epoch, on the entry start) bound the range. Newest first; returns { entries: [{ id, activityType, startedAt, stoppedAt, running, trackedMs, note, issues }], count, capped }. capped: true means more than limit matched — raise limit (default 25, max 100) or tighten the range. Answers “how much time did I log this month?”.
GET /v1/workspaces/{workspaceId}/time-entries
curl -H "Authorization: Bearer $DOTBY_TOKEN" \ "https://api.dotby.app/v1/workspaces/acme/time-entries?limit=25"Response: a list envelope { data, has_more, next_cursor }. While has_more is true, pass next_cursor back as cursor to get the next page.
Get running timer
Section titled “Get running timer”Get YOUR current running timer in a workspace (the single active block), or null when nothing is running. Returns the activity tag, start time, segments, live rate, and the issues it’s tracking.
GET /v1/workspaces/{workspaceId}/time-entries/running
curl -H "Authorization: Bearer $DOTBY_TOKEN" \ "https://api.dotby.app/v1/workspaces/acme/time-entries/running"Response: the resulting object as JSON.
Errors
Section titled “Errors”Every error is an RFC 9457 application/problem+json body with a machine-stable code. Branch on the code, not the message:
401—unauthenticated/invalid_token: the bearer token is missing, expired, or revoked. Re-authenticate; do not retry as-is.403—insufficient_scope/forbidden/upgrade_required: the token works but may not do this.upgrade_requiredmeans the workspace is not on Pro.404—not_found_or_forbidden: the resource does not exist for this token. Never probe for existence.409—idempotency_conflict: sameIdempotency-Key, different body. Mint a new key.429—rate_limited: back off for the number of seconds inRetry-After, then retry.400—validation_failed: the request shape is wrong. Fix the request; retrying unchanged will fail again.