TrellisDevelopers

Shifts

GET
/labor/shifts

Query Parameters

staffUserId?string
locationId?string
status?|||
clockInStart?string
Formatdate-time
clockInEnd?string
Formatdate-time

Header Parameters

x-tenant-id?string

Selects the tenant by id. When both tenant headers are omitted, the server falls back to the configured default tenant slug.

x-tenant-slug?string

Selects the tenant by slug. Use this when you know the tenant slug instead of the tenant id.

x-location-id?string

Adds a location scope to the request for location-aware reads, writes, and audit entries.

x-auth-provider?"hexclave"

Test-only Hexclave provider identifier used with x-auth-user-id when trusted identity headers are explicitly enabled. Production clients must use a Hexclave bearer token.

Value in

  • "hexclave"
x-auth-user-id?string

Temporary auth subject used to resolve the acting staff user through the staff auth identity mapping.

Response Body

application/json

curl -X GET "https://example.com/labor/shifts" \  -H "x-tenant-id: tenant-local" \  -H "x-tenant-slug: trellis-local" \  -H "x-location-id: loc-tasting-room" \  -H "x-auth-provider: hexclave" \  -H "x-auth-user-id: user_abc123"
{  "shifts": [    {      "id": "string",      "tenantId": "string",      "locationId": "string",      "staffUserId": "string",      "jobRole": "string",      "status": "active",      "source": "pos",      "clockInAt": "2019-08-24T14:15:22Z",      "clockOutAt": "2019-08-24T14:15:22Z",      "reviewStartedAt": "2019-08-24T14:15:22Z",      "reviewCompletedAt": "2019-08-24T14:15:22Z",      "reopenedAt": "2019-08-24T14:15:22Z",      "declaredCashTips": 0,      "nonCashTips": 0,      "cashSalesTotal": 0,      "cashExpectedToTurnIn": 0,      "cashTurnedIn": 0,      "cashVariance": 0,      "tipPayoutAmount": 0,      "notes": "string",      "payload": {        "property1": null,        "property2": null      },      "createdAt": "2019-08-24T14:15:22Z",      "updatedAt": "2019-08-24T14:15:22Z"    }  ],  "page": {    "total": 0  }}
POST
/labor/shifts/clock-in

Header Parameters

x-tenant-id?string

Selects the tenant by id. When both tenant headers are omitted, the server falls back to the configured default tenant slug.

x-tenant-slug?string

Selects the tenant by slug. Use this when you know the tenant slug instead of the tenant id.

x-location-id?string

Adds a location scope to the request for location-aware reads, writes, and audit entries.

x-auth-provider?"hexclave"

Test-only Hexclave provider identifier used with x-auth-user-id when trusted identity headers are explicitly enabled. Production clients must use a Hexclave bearer token.

Value in

  • "hexclave"
x-auth-user-id?string

Temporary auth subject used to resolve the acting staff user through the staff auth identity mapping.

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

curl -X POST "https://example.com/labor/shifts/clock-in" \  -H "x-tenant-id: tenant-local" \  -H "x-tenant-slug: trellis-local" \  -H "x-location-id: loc-tasting-room" \  -H "x-auth-provider: hexclave" \  -H "x-auth-user-id: user_abc123" \  -H "Content-Type: application/json" \  -d '{    "locationId": "string"  }'
{  "shift": {    "id": "string",    "tenantId": "string",    "locationId": "string",    "staffUserId": "string",    "jobRole": "string",    "status": "active",    "source": "pos",    "clockInAt": "2019-08-24T14:15:22Z",    "clockOutAt": "2019-08-24T14:15:22Z",    "reviewStartedAt": "2019-08-24T14:15:22Z",    "reviewCompletedAt": "2019-08-24T14:15:22Z",    "reopenedAt": "2019-08-24T14:15:22Z",    "declaredCashTips": 0,    "nonCashTips": 0,    "cashSalesTotal": 0,    "cashExpectedToTurnIn": 0,    "cashTurnedIn": 0,    "cashVariance": 0,    "tipPayoutAmount": 0,    "notes": "string",    "payload": {      "property1": null,      "property2": null    },    "createdAt": "2019-08-24T14:15:22Z",    "updatedAt": "2019-08-24T14:15:22Z"  },  "breaks": [    {      "id": "string",      "tenantId": "string",      "shiftId": "string",      "breakTypeId": "string",      "title": "string",      "paid": true,      "status": "active",      "startedAt": "2019-08-24T14:15:22Z",      "endedAt": "2019-08-24T14:15:22Z",      "waived": true,      "payload": {        "property1": null,        "property2": null      },      "createdAt": "2019-08-24T14:15:22Z",      "updatedAt": "2019-08-24T14:15:22Z"    }  ],  "summary": {    "shiftId": "string",    "status": "active",    "totalMinutes": 0,    "breakMinutes": 0,    "workedMinutes": 0,    "openBreakCount": 0,    "openCheckCount": 0,    "paidOpenCheckCount": 0,    "authorizedPaymentCount": 0,    "openTabCount": 0,    "unresolvedPaymentCount": 0,    "missedBreakCount": 0,    "cashOutstanding": 0,    "minimumCashTipsRequired": 0,    "requiresCashReconciliation": true,    "requiresCashTipDeclaration": true,    "requiresShiftReview": true,    "steps": {      "clockedOut": true,      "checksClosed": true,      "breaksResolved": true,      "cashReconciled": true,      "cashTipsDeclared": true,      "reviewCompleted": true    }  }}
GET
/labor/shifts/{id}

Path Parameters

id*string
Length1 <= length

Header Parameters

x-tenant-id?string

Selects the tenant by id. When both tenant headers are omitted, the server falls back to the configured default tenant slug.

x-tenant-slug?string

Selects the tenant by slug. Use this when you know the tenant slug instead of the tenant id.

x-location-id?string

Adds a location scope to the request for location-aware reads, writes, and audit entries.

x-auth-provider?"hexclave"

Test-only Hexclave provider identifier used with x-auth-user-id when trusted identity headers are explicitly enabled. Production clients must use a Hexclave bearer token.

Value in

  • "hexclave"
x-auth-user-id?string

Temporary auth subject used to resolve the acting staff user through the staff auth identity mapping.

Response Body

application/json

curl -X GET "https://example.com/labor/shifts/string" \  -H "x-tenant-id: tenant-local" \  -H "x-tenant-slug: trellis-local" \  -H "x-location-id: loc-tasting-room" \  -H "x-auth-provider: hexclave" \  -H "x-auth-user-id: user_abc123"
{  "shift": {    "id": "string",    "tenantId": "string",    "locationId": "string",    "staffUserId": "string",    "jobRole": "string",    "status": "active",    "source": "pos",    "clockInAt": "2019-08-24T14:15:22Z",    "clockOutAt": "2019-08-24T14:15:22Z",    "reviewStartedAt": "2019-08-24T14:15:22Z",    "reviewCompletedAt": "2019-08-24T14:15:22Z",    "reopenedAt": "2019-08-24T14:15:22Z",    "declaredCashTips": 0,    "nonCashTips": 0,    "cashSalesTotal": 0,    "cashExpectedToTurnIn": 0,    "cashTurnedIn": 0,    "cashVariance": 0,    "tipPayoutAmount": 0,    "notes": "string",    "payload": {      "property1": null,      "property2": null    },    "createdAt": "2019-08-24T14:15:22Z",    "updatedAt": "2019-08-24T14:15:22Z"  },  "breaks": [    {      "id": "string",      "tenantId": "string",      "shiftId": "string",      "breakTypeId": "string",      "title": "string",      "paid": true,      "status": "active",      "startedAt": "2019-08-24T14:15:22Z",      "endedAt": "2019-08-24T14:15:22Z",      "waived": true,      "payload": {        "property1": null,        "property2": null      },      "createdAt": "2019-08-24T14:15:22Z",      "updatedAt": "2019-08-24T14:15:22Z"    }  ],  "summary": {    "shiftId": "string",    "status": "active",    "totalMinutes": 0,    "breakMinutes": 0,    "workedMinutes": 0,    "openBreakCount": 0,    "openCheckCount": 0,    "paidOpenCheckCount": 0,    "authorizedPaymentCount": 0,    "openTabCount": 0,    "unresolvedPaymentCount": 0,    "missedBreakCount": 0,    "cashOutstanding": 0,    "minimumCashTipsRequired": 0,    "requiresCashReconciliation": true,    "requiresCashTipDeclaration": true,    "requiresShiftReview": true,    "steps": {      "clockedOut": true,      "checksClosed": true,      "breaksResolved": true,      "cashReconciled": true,      "cashTipsDeclared": true,      "reviewCompleted": true    }  }}
DELETE
/labor/shifts/{id}

Path Parameters

id*string
Length1 <= length

Header Parameters

x-tenant-id?string

Selects the tenant by id. When both tenant headers are omitted, the server falls back to the configured default tenant slug.

x-tenant-slug?string

Selects the tenant by slug. Use this when you know the tenant slug instead of the tenant id.

x-location-id?string

Adds a location scope to the request for location-aware reads, writes, and audit entries.

x-auth-provider?"hexclave"

Test-only Hexclave provider identifier used with x-auth-user-id when trusted identity headers are explicitly enabled. Production clients must use a Hexclave bearer token.

Value in

  • "hexclave"
x-auth-user-id?string

Temporary auth subject used to resolve the acting staff user through the staff auth identity mapping.

Response Body

curl -X DELETE "https://example.com/labor/shifts/string" \  -H "x-tenant-id: tenant-local" \  -H "x-tenant-slug: trellis-local" \  -H "x-location-id: loc-tasting-room" \  -H "x-auth-provider: hexclave" \  -H "x-auth-user-id: user_abc123"
Empty
POST
/labor/shifts/{id}/clock-out

Path Parameters

id*string
Length1 <= length

Header Parameters

x-tenant-id?string

Selects the tenant by id. When both tenant headers are omitted, the server falls back to the configured default tenant slug.

x-tenant-slug?string

Selects the tenant by slug. Use this when you know the tenant slug instead of the tenant id.

x-location-id?string

Adds a location scope to the request for location-aware reads, writes, and audit entries.

x-auth-provider?"hexclave"

Test-only Hexclave provider identifier used with x-auth-user-id when trusted identity headers are explicitly enabled. Production clients must use a Hexclave bearer token.

Value in

  • "hexclave"
x-auth-user-id?string

Temporary auth subject used to resolve the acting staff user through the staff auth identity mapping.

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

curl -X POST "https://example.com/labor/shifts/string/clock-out" \  -H "x-tenant-id: tenant-local" \  -H "x-tenant-slug: trellis-local" \  -H "x-location-id: loc-tasting-room" \  -H "x-auth-provider: hexclave" \  -H "x-auth-user-id: user_abc123" \  -H "Content-Type: application/json" \  -d '{}'
{  "shift": {    "id": "string",    "tenantId": "string",    "locationId": "string",    "staffUserId": "string",    "jobRole": "string",    "status": "active",    "source": "pos",    "clockInAt": "2019-08-24T14:15:22Z",    "clockOutAt": "2019-08-24T14:15:22Z",    "reviewStartedAt": "2019-08-24T14:15:22Z",    "reviewCompletedAt": "2019-08-24T14:15:22Z",    "reopenedAt": "2019-08-24T14:15:22Z",    "declaredCashTips": 0,    "nonCashTips": 0,    "cashSalesTotal": 0,    "cashExpectedToTurnIn": 0,    "cashTurnedIn": 0,    "cashVariance": 0,    "tipPayoutAmount": 0,    "notes": "string",    "payload": {      "property1": null,      "property2": null    },    "createdAt": "2019-08-24T14:15:22Z",    "updatedAt": "2019-08-24T14:15:22Z"  },  "breaks": [    {      "id": "string",      "tenantId": "string",      "shiftId": "string",      "breakTypeId": "string",      "title": "string",      "paid": true,      "status": "active",      "startedAt": "2019-08-24T14:15:22Z",      "endedAt": "2019-08-24T14:15:22Z",      "waived": true,      "payload": {        "property1": null,        "property2": null      },      "createdAt": "2019-08-24T14:15:22Z",      "updatedAt": "2019-08-24T14:15:22Z"    }  ],  "summary": {    "shiftId": "string",    "status": "active",    "totalMinutes": 0,    "breakMinutes": 0,    "workedMinutes": 0,    "openBreakCount": 0,    "openCheckCount": 0,    "paidOpenCheckCount": 0,    "authorizedPaymentCount": 0,    "openTabCount": 0,    "unresolvedPaymentCount": 0,    "missedBreakCount": 0,    "cashOutstanding": 0,    "minimumCashTipsRequired": 0,    "requiresCashReconciliation": true,    "requiresCashTipDeclaration": true,    "requiresShiftReview": true,    "steps": {      "clockedOut": true,      "checksClosed": true,      "breaksResolved": true,      "cashReconciled": true,      "cashTipsDeclared": true,      "reviewCompleted": true    }  }}
PUT
/labor/shifts/{id}/time-entry

Path Parameters

id*string
Length1 <= length

Header Parameters

x-tenant-id?string

Selects the tenant by id. When both tenant headers are omitted, the server falls back to the configured default tenant slug.

x-tenant-slug?string

Selects the tenant by slug. Use this when you know the tenant slug instead of the tenant id.

x-location-id?string

Adds a location scope to the request for location-aware reads, writes, and audit entries.

x-auth-provider?"hexclave"

Test-only Hexclave provider identifier used with x-auth-user-id when trusted identity headers are explicitly enabled. Production clients must use a Hexclave bearer token.

Value in

  • "hexclave"
x-auth-user-id?string

Temporary auth subject used to resolve the acting staff user through the staff auth identity mapping.

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

curl -X PUT "https://example.com/labor/shifts/string/time-entry" \  -H "x-tenant-id: tenant-local" \  -H "x-tenant-slug: trellis-local" \  -H "x-location-id: loc-tasting-room" \  -H "x-auth-provider: hexclave" \  -H "x-auth-user-id: user_abc123" \  -H "Content-Type: application/json" \  -d '{}'
{  "shift": {    "id": "string",    "tenantId": "string",    "locationId": "string",    "staffUserId": "string",    "jobRole": "string",    "status": "active",    "source": "pos",    "clockInAt": "2019-08-24T14:15:22Z",    "clockOutAt": "2019-08-24T14:15:22Z",    "reviewStartedAt": "2019-08-24T14:15:22Z",    "reviewCompletedAt": "2019-08-24T14:15:22Z",    "reopenedAt": "2019-08-24T14:15:22Z",    "declaredCashTips": 0,    "nonCashTips": 0,    "cashSalesTotal": 0,    "cashExpectedToTurnIn": 0,    "cashTurnedIn": 0,    "cashVariance": 0,    "tipPayoutAmount": 0,    "notes": "string",    "payload": {      "property1": null,      "property2": null    },    "createdAt": "2019-08-24T14:15:22Z",    "updatedAt": "2019-08-24T14:15:22Z"  },  "breaks": [    {      "id": "string",      "tenantId": "string",      "shiftId": "string",      "breakTypeId": "string",      "title": "string",      "paid": true,      "status": "active",      "startedAt": "2019-08-24T14:15:22Z",      "endedAt": "2019-08-24T14:15:22Z",      "waived": true,      "payload": {        "property1": null,        "property2": null      },      "createdAt": "2019-08-24T14:15:22Z",      "updatedAt": "2019-08-24T14:15:22Z"    }  ],  "summary": {    "shiftId": "string",    "status": "active",    "totalMinutes": 0,    "breakMinutes": 0,    "workedMinutes": 0,    "openBreakCount": 0,    "openCheckCount": 0,    "paidOpenCheckCount": 0,    "authorizedPaymentCount": 0,    "openTabCount": 0,    "unresolvedPaymentCount": 0,    "missedBreakCount": 0,    "cashOutstanding": 0,    "minimumCashTipsRequired": 0,    "requiresCashReconciliation": true,    "requiresCashTipDeclaration": true,    "requiresShiftReview": true,    "steps": {      "clockedOut": true,      "checksClosed": true,      "breaksResolved": true,      "cashReconciled": true,      "cashTipsDeclared": true,      "reviewCompleted": true    }  }}