Work Types
Manage work types that classify employees and vacancies by employment category.
Endpoints
| Method | Path | Description |
|---|---|---|
GET | /org/:orgId/work-types | List work types |
GET | /org/:orgId/work-types/:id | Get work type |
POST | /org/:orgId/work-types | Create work type |
PATCH | /org/:orgId/work-types/:id | Update work type |
DELETE | /org/:orgId/work-types/:id | Delete work type |
List Work Types
GET /org/:orgId/work-typesReturns a paginated list of work types in the organization.
Query Parameters
| Parameter | Type | Default | Description |
|---|---|---|---|
page | integer | 1 | Page number |
limit | integer | 20 | Records per page (max 200) |
search | string | — | Search by name |
sortBy | string | name | Sort field: name, sortOrder, createdAt |
sortDir | string | asc | asc or desc |
Example Request
bash
curl -X GET "https://{tenant}.flowstate.inc/api/v1/org/{orgId}/work-types?sortBy=name&limit=50" \
-H "Authorization: Bearer private_..."Example Response
json
{
"data": [
{
"id": "clx6t7u8v9w0x1y2",
"name": "Full-time",
"description": "Standard full-time employment",
"overheadPercentage": 0.3,
"isActive": true,
"sortOrder": 0,
"excludeHolidays": false,
"createdAt": "2024-01-10T08:00:00Z",
"updatedAt": "2025-11-20T14:00:00Z"
},
{
"id": "clx1e2n3g4r5o0t6",
"name": "Part-time",
"description": "Part-time employment, typically 50% FTE",
"overheadPercentage": 0.15,
"isActive": true,
"sortOrder": 1,
"excludeHolidays": false,
"createdAt": "2024-01-05T08:00:00Z",
"updatedAt": "2025-09-01T10:00:00Z"
}
],
"meta": {
"page": 1,
"limit": 50,
"total": 3,
"hasNextPage": false
}
}Get Work Type
GET /org/:orgId/work-types/:idReturns a single work type by ID.
Example Request
bash
curl -X GET "https://{tenant}.flowstate.inc/api/v1/org/{orgId}/work-types/clx6t7u8v9w0x1y2" \
-H "Authorization: Bearer private_..."Example Response
json
{
"data": {
"id": "clx6t7u8v9w0x1y2",
"name": "Full-time",
"description": "Standard full-time employment",
"overheadPercentage": 0.3,
"isActive": true,
"sortOrder": 0,
"excludeHolidays": false,
"createdAt": "2024-01-10T08:00:00Z",
"updatedAt": "2025-11-20T14:00:00Z"
}
}Create Work Type
POST /org/:orgId/work-typesCreates a new work type.
Request Body
json
{
"name": "Full-time",
"description": "Standard full-time employment",
"overheadPercentage": 0.3
}Example Request
bash
curl -X POST "https://{tenant}.flowstate.inc/api/v1/org/{orgId}/work-types" \
-H "Authorization: Bearer private_..." \
-H "Content-Type: application/json" \
-d '{
"name": "Full-time",
"description": "Standard full-time employment",
"overheadPercentage": 0.3
}'Example Response
json
{
"data": {
"id": "clx3d4e5f6g7h8i9",
"name": "Full-time",
"description": "Standard full-time employment",
"overheadPercentage": 0.3,
"isActive": true,
"sortOrder": 0,
"excludeHolidays": false,
"createdAt": "2026-03-11T09:40:00Z",
"updatedAt": "2026-03-11T09:40:00Z"
}
}Status: 201 Created
Update Work Type
PATCH /org/:orgId/work-types/:idUpdates one or more fields on an existing work type. Only include the fields you want to change.
Example Request
bash
curl -X PATCH "https://{tenant}.flowstate.inc/api/v1/org/{orgId}/work-types/clx6t7u8v9w0x1y2" \
-H "Authorization: Bearer private_..." \
-H "Content-Type: application/json" \
-d '{
"overheadPercentage": 0.35,
"description": "Standard full-time employment with updated overhead rate."
}'Example Response
json
{
"data": {
"id": "clx6t7u8v9w0x1y2",
"name": "Full-time",
"description": "Standard full-time employment with updated overhead rate.",
"overheadPercentage": 0.35,
"isActive": true,
"sortOrder": 0,
"excludeHolidays": false,
"createdAt": "2024-01-10T08:00:00Z",
"updatedAt": "2026-03-11T09:45:00Z"
}
}Delete Work Type
DELETE /org/:orgId/work-types/:idDeletes a work type. Work types that are actively assigned to employees or vacancies cannot be deleted until those references are removed.
Example Request
bash
curl -X DELETE "https://{tenant}.flowstate.inc/api/v1/org/{orgId}/work-types/clx6t7u8v9w0x1y2" \
-H "Authorization: Bearer private_..."Example Response
json
{
"data": {
"id": "clx6t7u8v9w0x1y2",
"deleted": true
}
}Status: 200 OK
Field Reference
| Field | Type | Required | Description |
|---|---|---|---|
id | string | — | Unique identifier (read-only) |
name | string | Yes | Work type name |
description | string | No | Work type description |
overheadPercentage | number | No | Overhead multiplier for cost calculations (default: 0) |
isActive | boolean | No | Whether the work type is active (default: true) |
sortOrder | integer | No | Display sort order (default: 0) |
excludeHolidays | boolean | No | Whether to exclude holidays from FTE calculations (default: false) |
createdAt | datetime | — | Record creation timestamp (read-only) |
updatedAt | datetime | — | Last modification timestamp (read-only) |