curl --request POST \
--url 'https://api.workstream.stateset.com/v1/brands/{brand_id}/billing/periods/{period_id}/close' \
--header "x-api-key: $STATESET_TEMPORAL_API_KEY" \
--header 'Content-Type: application/json' \
--data '{}'
{
"id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"contract_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"brand_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"period_start": "2026-08-31T14:22:05Z",
"period_end": "2026-08-31T14:22:05Z",
"status": "pending",
"currency": "USD",
"commitment_fee_minor": 4900,
"included_quantity": 1,
"consumed_quantity": 1,
"covered_quantity": 1,
"overage_quantity": 1,
"estimated_overage_minor": 1,
"estimated_savings_minor": 1,
"invoice_summary": {},
"closed_at": "2026-08-31T14:22:05Z",
"created_at": "2026-08-31T14:22:05Z",
"updated_at": "2026-08-31T14:22:05Z"
}
Close brand billing period
The closed period.
POST
/
v1
/
brands
/
{brand_id}
/
billing
/
periods
/
{period_id}
/
close
curl --request POST \
--url 'https://api.workstream.stateset.com/v1/brands/{brand_id}/billing/periods/{period_id}/close' \
--header "x-api-key: $STATESET_TEMPORAL_API_KEY" \
--header 'Content-Type: application/json' \
--data '{}'
{
"id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"contract_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"brand_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"period_start": "2026-08-31T14:22:05Z",
"period_end": "2026-08-31T14:22:05Z",
"status": "pending",
"currency": "USD",
"commitment_fee_minor": 4900,
"included_quantity": 1,
"consumed_quantity": 1,
"covered_quantity": 1,
"overage_quantity": 1,
"estimated_overage_minor": 1,
"estimated_savings_minor": 1,
"invoice_summary": {},
"closed_at": "2026-08-31T14:22:05Z",
"created_at": "2026-08-31T14:22:05Z",
"updated_at": "2026-08-31T14:22:05Z"
}
Path parameters
string (uuid)
required
string (string)
required
Request body
JSON body of typeGenericObject.
Response
object
string (uuid)
required
string (uuid)
required
string (uuid)
required
string (date-time)
required
string (date-time)
required
string
required
string
required
integer
required
integer
required
integer
required
integer
required
integer
required
integer
required
integer
required
object
required
string (date-time)
string (date-time)
required
string (date-time)
required
Status codes
| Code | Meaning |
|---|---|
200 | The closed period. |
400 | Validation error |
401 | Unauthorized |
404 | Not found |
429 | Rate limited |
500 | Internal error |
curl --request POST \
--url 'https://api.workstream.stateset.com/v1/brands/{brand_id}/billing/periods/{period_id}/close' \
--header "x-api-key: $STATESET_TEMPORAL_API_KEY" \
--header 'Content-Type: application/json' \
--data '{}'
{
"id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"contract_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"brand_id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"period_start": "2026-08-31T14:22:05Z",
"period_end": "2026-08-31T14:22:05Z",
"status": "pending",
"currency": "USD",
"commitment_fee_minor": 4900,
"included_quantity": 1,
"consumed_quantity": 1,
"covered_quantity": 1,
"overage_quantity": 1,
"estimated_overage_minor": 1,
"estimated_savings_minor": 1,
"invoice_summary": {},
"closed_at": "2026-08-31T14:22:05Z",
"created_at": "2026-08-31T14:22:05Z",
"updated_at": "2026-08-31T14:22:05Z"
}
Last modified on August 31, 2026