API Reference

Timesheet Periods API

API reference for reading timesheet periods via the Dime.Sheets public API.

Timesheet Periods API

The Timesheet Periods public API provides read-only access to concrete period date ranges. Periods are generated from templates and define the windows that time entries are bucketed into.

List periods

GET /api/v1/timesheet-periods

Returns periods, with optional filters.

Query parameters

ParameterTypeDescription
templateIdint?Filter by template
statusint?Filter by status: 0 Open, 1 Closed
yearint?Filter by year

Example request

curl "https://app.dimesheets.com/api/v1/timesheet-periods?year=2026&status=0" \
  -H "X-API-KEY: {your-api-key}"

Example response

[
  {
    "id": 14,
    "externalId": "period-2026-w14",
    "tenantId": "tenant-abc",
    "templateId": 1,
    "name": "2026-W14",
    "startDate": "2026-03-30T00:00:00Z",
    "endDate": "2026-04-05T23:59:59Z",
    "status": 0,
    "closedAt": null,
    "closedByUserId": null,
    "reopenedAt": null,
    "reopenedByUserId": null,
    "notes": null,
    "createdAt": "2026-01-01T00:00:00Z",
    "updatedAt": "2026-01-01T00:00:00Z"
  }
]

Get a period

GET /api/v1/timesheet-periods/{externalId}

Returns the period matching the given external ID, or 404 Not Found.

TimesheetPeriod model

FieldTypeDescription
idintInternal ID
externalIdstringStable external identifier
tenantIdstringTenant ID
templateIdintParent template ID
namestringPeriod name (generated from template naming pattern)
startDatedatetimePeriod start date
endDatedatetimePeriod end date
statusintPeriod status: 0 Open, 1 Closed
closedAtdatetime?When the period was closed
closedByUserIdint?User who closed the period
reopenedAtdatetime?When the period was last reopened
reopenedByUserIdint?User who reopened the period
notesstring?Admin notes
createdAtdatetimeCreation timestamp
updatedAtdatetimeLast update timestamp

Period lifecycle

Periods have two statuses:

  • Open (0) -- Time entries can be created, updated, and deleted within the period's date range.
  • Closed (1) -- The period is frozen. No inserts, updates, or deletes are allowed for entries within the date range. Attempting to mutate a time entry in a closed period returns 409 Conflict.

Only administrators can close or reopen periods. Reopening is audited.