- Search task types
🔐 Required role:
API_ADMIN📖 Data dictionary: Task type
Advanced task type filtering with a flexible where clause and dynamic ordering
Uses standard limit/offset pagination via pageSize and page — see Pagination. Use total.aggregate.count to detect the end.
Supports flexible filtering across any task type field using a flexible where clause, with pagination and dynamic ordering.
Deactivated task types (including deactivated TimeCode records) are included, unlike GET /gql/v1/task-types; filter on active to choose them: { "active": { "_eq": false } } returns only deactivated task types.
Common filter examples (pass in the where field):
- By code:
{ "code": { "_eq": "PREP" } } - By active status:
{ "active": { "_eq": true } } - By billable flag:
{ "billable": { "_eq": true } } - By category:
{ "taskTypeCategoryId": { "_eq": 5 } } - By service line:
{ "serviceLineId": { "_eq": 2 } } - Combined:
{ "_and": [ { "billable": { "_eq": true } }, { "active": { "_eq": true } } ] }
Limit — number of records to return (not a page count).
Offset — number of records to skip. This is not a page index. To fetch the next N rows after the first N, send pageSize: N and page: N. An offset at or beyond total.aggregate.count returns an empty result array.
Flexible where clause for filtering. Supports operators such as _eq, _neq, _in, _nin, _ilike, _gte, _lte, and logical combinators _and, _or, _not.
{ "_and": [ { … }, { … } ] }
- Sandbox (requires Cloudflare Access headers)https://api.sandbox.aiwyn.app/gql/v1/task-types/search
- Staging (requires Cloudflare Access headers)https://api.staging.aiwyn.app/gql/v1/task-types/search
- Production (your live firm data; no Cloudflare Access headers)https://api.aiwyn.ai/gql/v1/task-types/search
curl -i -X POST \
https://api.sandbox.aiwyn.app/gql/v1/task-types/search \
-H 'Authorization: Bearer <YOUR_JWT_HERE>' \
-H 'CF-Access-Client-Id: YOUR_API_KEY_HERE' \
-H 'CF-Access-Client-Secret: YOUR_API_KEY_HERE' \
-H 'Content-Type: application/json' \
-d '{
"pageSize": 25,
"page": 0,
"where": {
"_and": [
{
"billable": {
"_eq": true
}
},
{
"active": {
"_eq": true
}
}
]
},
"orderBy": [
{
"display": "asc"
}
]
}'{ "taskTypes": [ { … } ], "total": { "aggregate": { … } } }