TrellisDevelopers

Server Checkout

GET
/labor/shifts/{id}/server-checkout

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/server-checkout" \  -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"
{  "shiftId": "string",  "locationId": "string",  "staffUserId": "string",  "staffDisplayName": "string",  "jobRole": "string",  "status": "active",  "shiftWindow": {    "clockInAt": "2019-08-24T14:15:22Z",    "clockOutAt": "2019-08-24T14:15:22Z",    "reviewCompletedAt": "2019-08-24T14:15:22Z"  },  "totals": {    "orderCount": 0,    "openOrderCount": 0,    "paymentCount": 0,    "cashSalesTotal": 0,    "directNonCashTips": 0,    "pendingNonCashTips": 0,    "refundedTipAmount": 0,    "declaredCashTips": 0,    "eligibleTipBasis": 0,    "houseTipShareAmount": 0,    "poolContributionAmount": 0,    "poolShareAmount": 0,    "finalNonCashTips": 0,    "totalTipsOwed": 0,    "tipPayoutAmount": 0  },  "payout": {    "payoutMode": "cash_drawer",    "tipPoolEnabled": true,    "distributionMethod": "direct",    "finalizedAt": "2019-08-24T14:15:22Z",    "finalizedByStaffUserId": "string"  },  "participants": [    {      "shiftId": "string",      "staffUserId": "string",      "staffDisplayName": "string",      "jobRole": "string",      "workedMinutes": 0,      "directTips": 0,      "declaredCashTips": 0,      "eligibleTipBasis": 0,      "contributionAmount": 0,      "poolShareAmount": 0,      "houseTipShareAmount": 0,      "finalNonCashTips": 0,      "checkoutTotalTips": 0,      "weight": 0    }  ],  "payments": [    {      "paymentIntentId": "string",      "orderId": "string",      "orderNumber": 0,      "paymentStatus": "string",      "processorStatus": "string",      "tenderType": "string",      "amount": 0,      "capturedAmount": 0,      "tipAmount": 0,      "refundedTipAmount": 0,      "netTipAmount": 0,      "tableLabel": "string",      "closedAt": "2019-08-24T14:15:22Z",      "attributedStaffUserId": "string"    }  ],  "orders": [    {      "orderId": "string",      "orderNumber": 0,      "status": "string",      "tableLabel": "string",      "total": 0,      "tipTotal": 0,      "paymentIntentIds": [        "string"      ],      "assignedStaffUserId": "string",      "submittedAt": "2019-08-24T14:15:22Z",      "updatedAt": "2019-08-24T14:15:22Z"    }  ]}
POST
/labor/shifts/{id}/server-checkout/finalize

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/server-checkout/finalize" \  -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 '{}'
{  "shiftId": "string",  "locationId": "string",  "staffUserId": "string",  "staffDisplayName": "string",  "jobRole": "string",  "status": "active",  "shiftWindow": {    "clockInAt": "2019-08-24T14:15:22Z",    "clockOutAt": "2019-08-24T14:15:22Z",    "reviewCompletedAt": "2019-08-24T14:15:22Z"  },  "totals": {    "orderCount": 0,    "openOrderCount": 0,    "paymentCount": 0,    "cashSalesTotal": 0,    "directNonCashTips": 0,    "pendingNonCashTips": 0,    "refundedTipAmount": 0,    "declaredCashTips": 0,    "eligibleTipBasis": 0,    "houseTipShareAmount": 0,    "poolContributionAmount": 0,    "poolShareAmount": 0,    "finalNonCashTips": 0,    "totalTipsOwed": 0,    "tipPayoutAmount": 0  },  "payout": {    "payoutMode": "cash_drawer",    "tipPoolEnabled": true,    "distributionMethod": "direct",    "finalizedAt": "2019-08-24T14:15:22Z",    "finalizedByStaffUserId": "string"  },  "participants": [    {      "shiftId": "string",      "staffUserId": "string",      "staffDisplayName": "string",      "jobRole": "string",      "workedMinutes": 0,      "directTips": 0,      "declaredCashTips": 0,      "eligibleTipBasis": 0,      "contributionAmount": 0,      "poolShareAmount": 0,      "houseTipShareAmount": 0,      "finalNonCashTips": 0,      "checkoutTotalTips": 0,      "weight": 0    }  ],  "payments": [    {      "paymentIntentId": "string",      "orderId": "string",      "orderNumber": 0,      "paymentStatus": "string",      "processorStatus": "string",      "tenderType": "string",      "amount": 0,      "capturedAmount": 0,      "tipAmount": 0,      "refundedTipAmount": 0,      "netTipAmount": 0,      "tableLabel": "string",      "closedAt": "2019-08-24T14:15:22Z",      "attributedStaffUserId": "string"    }  ],  "orders": [    {      "orderId": "string",      "orderNumber": 0,      "status": "string",      "tableLabel": "string",      "total": 0,      "tipTotal": 0,      "paymentIntentIds": [        "string"      ],      "assignedStaffUserId": "string",      "submittedAt": "2019-08-24T14:15:22Z",      "updatedAt": "2019-08-24T14:15:22Z"    }  ]}