Status types
Returns status types — the reference for the status_id values in schedule entries: working day, vacation, sick leave, and others. The response contains both system statuses and your organization's custom statuses.
Scope
No scope required — this is a reference resource with no secrets, available to any valid key for the organization, regardless of its scopes (see Scopes and permissions → Reference resources without a scope). The reference is needed to interpret schedule entries, so it's open with no additional conditions.
Query parameters
| Parameter | Required | Description |
|---|---|---|
limit |
no | Integer 1..200, defaults to 100. |
cursor |
no | The meta.next_cursor value from the previous response — for the next page. |
from/to, department_id, and employee_id are not supported on this resource: passing any of them returns 400 validation_error (the parameter is explicitly rejected, not silently ignored — see Conventions → Filters). This is a reference resource with no time dimension and no department attachment.
Request
curl -s https://smengo.com/api/v1/status-types \
-H "Authorization: Bearer smg_live_XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
With a smaller page size:
curl -s "https://smengo.com/api/v1/status-types?limit=50" \
-H "Authorization: Bearer smg_live_XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
Response
{
"data": [
{
"id": "c2e4a6b8-1d3f-4a5c-8e7b-9f0a1b2c3d4e",
"code": "work",
"label": { "ru": "Работает", "uk": "Працює", "en": "Working" },
"color": "#22c55e",
"counts_as_present": true,
"is_system": true,
"start_time": "09:00:00",
"end_time": "18:00:00"
},
{
"id": "d4f6a8c0-2e5b-4b7d-9a1c-6e8f0b2d4a86",
"code": "training",
"label": { "ru": "Обучение", "uk": "Навчання", "en": "Training" },
"color": "#818cf8",
"counts_as_present": false,
"is_system": false,
"start_time": null,
"end_time": null
}
],
"meta": { "next_cursor": null }
}
Response fields
| Field | Type | Description |
|---|---|---|
id |
string (uuid) |
The status type's unique identifier; status_id in Schedule entries points to it. |
code |
string |
The status's machine code. System codes: work, vacation, sick, dayoff, late; custom statuses have their own codes. |
label |
object |
The multilingual name, keyed by locale, as-is: { "ru": …, "uk": …, "en": … }. The only object field in all of v1 — every other API field is scalar. |
color |
string |
The status's color in hex (#22c55e); never null. |
counts_as_present |
boolean |
Whether the status counts as presence: a day with this status is considered worked (for example, a working day — yes, vacation — no). |
is_system |
boolean |
true — a system status, shared by all organizations; false — your organization's custom status. |
start_time |
string (HH:MM:SS) | null |
The status's optional default shift window — its start, in the organization's timezone. |
end_time |
string (HH:MM:SS) | null |
The default window's end; statuses without a time have both fields null. |
The response contains both system statuses and your organization's custom statuses. System ones (is_system: true) are shared by all organizations; custom ones are yours only — other organizations' custom statuses never appear in the response.
Pagination
The list is sorted by sort_order, id — yet the sort_order field itself is not returned in data[]: the sorting by it exists, the field in the response doesn't (unlike shift presets). If there are more statuses than limit, meta.next_cursor holds a cursor for the next page — pass it verbatim as cursor on the next request:
curl -s "https://smengo.com/api/v1/status-types?limit=1&cursor=eyJrIjoxLCJpZCI6ImMyZTRhNmI4LTFkM2YtNGE1Yy04ZTdiLTlmMGExYjJjM2Q0ZSJ9" \
-H "Authorization: Bearer smg_live_XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX"
meta.next_cursor is null once there are no more statuses. Full pagination rules are in Conventions → Pagination.
What's next
- Schedule entries — where
status_idpoints to statuses. - Shift presets — the other reference resource for interpreting the schedule.
- Organization — the timezone
start_time/end_timeare interpreted in.