API reference · v1.1.0
PRESHos API reference
Every endpoint, generated from the same registry that serves the API: parameters, request and response schemas, examples, and errors. 47 endpoints in 8 groups.
- Base URL
https://api.preshos.com/v1- Authentication
Authorization: Bearer <key>Guide- Format
- JSON,
snake_case, UTC ISO-8601 timestamps, string ids - Pagination
- Cursor-based,
limit1–100. Guide
The API key's identity, workspace members, and teams.
Identify the API key
getMe/v1/meReturns who the key acts as (a user, or for a service key the agent identity), its workspace, the key's scopes and expiry, and the rate limit. Use it to verify a key is working. Needs no scope.
- Scopes
- None — any valid key
- Behavior
- Read-onlyIdempotent
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Response200
Key identity.
| Field | Type | Description |
|---|---|---|
data | object | — |
data.principal | object | — |
data.principal.type | "user" | "service" | user: the key acts as user. service: a server-to-server key acting as agent's service identity. |
data.user | object | null | — |
data.agent | object | null | — |
data.workspace | object | — |
data.workspace.id | integer | — |
data.workspace.slug | string | — |
data.workspace.name | string | — |
data.oauthoptional | object | — |
data.oauth.client_id | string | — |
data.oauth.resource | string | — |
data.oauth.scopes | string[] | — |
data.oauth.expires_at | string | — |
data.api_key | object | null | — |
data.rate_limit | object | — |
data.rate_limit.requests_per_minute | integer | — |
Examples
curl https://api.preshos.com/v1/me \
-H "Authorization: Bearer $PRESHOS_API_KEY"{
"data": {
"principal": {
"type": "user"
},
"user": {
"id": 23,
"name": "Sam Rivera",
"email": "sam@example.com",
"title": "Operations Lead"
},
"agent": null,
"workspace": {
"id": 9,
"slug": "acme",
"name": "Acme Corp"
},
"api_key": {
"id": "6f1c…",
"name": "CRM sync",
"type": "personal",
"prefix": "preshos_v1_Ab12Cd34Ef56",
"scopes": [
"records:read",
"records:write"
],
"expires_at": "2026-12-30T00:00:00.000Z"
},
"rate_limit": {
"requests_per_minute": 300
}
}
}Errors
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
List workspace members
listUsers/v1/usersLists people in this workspace (agents excluded) with their teams. Use user ids for owner fields and mentions. Users who may not read the whole member directory see only themselves.
- Scopes
users:read- Behavior
- Read-onlyIdempotent
Query parameters
| Name | Type | Description |
|---|---|---|
limit | integer1–100 · default: 50 | — |
cursor | stringmax 500 chars | — |
q | stringmax 200 chars | Match on name or email. |
include_inactive | "true" | "false"default: "false" | — |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Response200
Members.
| Field | Type | Description |
|---|---|---|
data | — | |
pagination | — |
Examples
curl https://api.preshos.com/v1/users \
-H "Authorization: Bearer $PRESHOS_API_KEY"{
"data": [
{
"id": 17,
"name": "Jordan Lee",
"email": "jordan@example.com",
"title": "Account Director",
"active": true,
"teams": [
{
"id": 3,
"name": "Sales"
}
]
}
],
"pagination": {
"limit": 50,
"has_more": false,
"next_cursor": null
}
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 400 | Invalid request: malformed JSON, failed validation, or an invalid filter/cursor. | validation_failed, invalid_cursor |
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Retrieve a member
getUser/v1/users/{user_id}Returns one workspace member by user id.
- Scopes
users:read- Behavior
- Read-onlyIdempotent
Path parameters
| Name | Type | Description |
|---|---|---|
user_idrequired | integer | Workspace user id. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Examples
curl https://api.preshos.com/v1/users/17 \
-H "Authorization: Bearer $PRESHOS_API_KEY"{
"data": {
"id": 17,
"name": "Jordan Lee",
"email": "jordan@example.com",
"title": "Account Director",
"active": true,
"teams": [
{
"id": 3,
"name": "Sales"
}
]
}
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found, user_not_found |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
List teams
listTeams/v1/teamsLists the workspace's teams and their member ids (or only your own teams if you may not read all teams). Team membership determines "team records" access.
- Scopes
users:read- Behavior
- Read-onlyIdempotent
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Examples
curl https://api.preshos.com/v1/teams \
-H "Authorization: Bearer $PRESHOS_API_KEY"{
"data": [
{
"id": 3,
"name": "Sales",
"description": "New business and renewals",
"member_ids": [
17,
23
]
}
]
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Discover object types, fields, relationships, and workflows for this workspace.
List object types
listObjects/v1/objectsLists the object types available in this workspace that the key's user can read: CRM objects, work items, business catalogs, and every custom object. capabilities says what the object supports through the API; permissions is advisory and says what this user may do.
- Scopes
records:read- Behavior
- Read-onlyIdempotent
Query parameters
| Name | Type | Description |
|---|---|---|
include_unreadable | "true" | "false" | Also return objects the user cannot read (default false). |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Examples
curl https://api.preshos.com/v1/objects \
-H "Authorization: Bearer $PRESHOS_API_KEY"{
"data": [
{
"object_type": "companies",
"name": "Companies",
"singular_name": "Company",
"description": "Customer and prospect organizations.",
"kind": "built_in",
"category": "crm",
"display_field": "name",
"capabilities": {
"search": true,
"create": true,
"update": true,
"delete": false
},
"permissions": {
"create": {
"allowed": true,
"scopes": [
"owned_by_user"
]
},
"read": {
"allowed": true,
"scopes": [
"org_wide"
]
},
"update": {
"allowed": true,
"scopes": [
"owned_by_team"
]
},
"delete": {
"allowed": false,
"scopes": []
}
}
}
]
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 400 | Invalid request: malformed JSON, failed validation, or an invalid filter/cursor. | validation_failed |
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Describe an object type
getObject/v1/objects/{object_type}Returns the full contract for one object type in this workspace: every field the user may read (key, type, required, editable, options, validation), relationships, the status workflow, and — for work items — the active work-item types. For work items pass work_item_type_id to include that type's configured fields.
- Scopes
records:read- Behavior
- Read-onlyIdempotent
Path parameters
| Name | Type | Description |
|---|---|---|
object_typerequired | string | Object type id from GET /v1/objects, e.g. companies, work-items, or a custom object id. |
Query parameters
| Name | Type | Description |
|---|---|---|
work_item_type_id | stringmax 100 chars | Work items only: include fields placed on this type. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Response200
The object definition.
| Field | Type | Description |
|---|---|---|
data | — |
Examples
curl https://api.preshos.com/v1/objects/companies \
-H "Authorization: Bearer $PRESHOS_API_KEY"{
"data": {
"object_type": "companies",
"name": "Companies",
"singular_name": "Company",
"description": "Customer and prospect organizations.",
"kind": "built_in",
"category": "crm",
"display_field": "name",
"capabilities": {
"search": true,
"create": true,
"update": true,
"delete": false
},
"permissions": {
"create": {
"allowed": true,
"scopes": [
"owned_by_user"
]
},
"read": {
"allowed": true,
"scopes": [
"org_wide"
]
},
"update": {
"allowed": true,
"scopes": [
"owned_by_team"
]
},
"delete": {
"allowed": false,
"scopes": []
}
},
"fields": [
{
"key": "name",
"name": "Company name",
"type": "text",
"required": true,
"editable": true,
"storage": "physical",
"storage_key": "name"
},
{
"key": "industry",
"name": "Industry",
"type": "select",
"required": false,
"editable": true,
"storage": "physical",
"storage_key": "industry",
"options": [
{
"value": "Manufacturing",
"label": "Manufacturing"
}
]
}
],
"relationships": [
{
"object": {
"key": "contacts",
"name": "Contacts"
},
"cardinality": "one_to_many",
"labels": []
}
],
"workflow": {
"id": "lifecycle-company",
"key": "company",
"name": "Company lifecycle"
}
}
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 400 | Invalid request: malformed JSON, failed validation, or an invalid filter/cursor. | validation_failed |
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | object_not_available, user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Retrieve a status workflow
getWorkflow/v1/workflows/{workflow_id}Returns a workflow's statuses and the transitions allowed from each. Use the status ids with POST …/records/{record_id}/status.
- Scopes
records:read- Behavior
- Read-onlyIdempotent
Path parameters
| Name | Type | Description |
|---|---|---|
workflow_idrequired | string1–200 chars | Workflow id from an object definition. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Examples
curl https://api.preshos.com/v1/workflows/wf-deliverable \
-H "Authorization: Bearer $PRESHOS_API_KEY"{
"data": {
"id": "wf-deliverable",
"key": "deliverable",
"name": "Deliverable",
"statuses": [
{
"id": "st-draft",
"name": "Draft",
"transitions": [
{
"id": "st-in-review",
"name": "In review"
}
]
},
{
"id": "st-in-review",
"name": "In review",
"transitions": [
{
"id": "st-approved",
"name": "Approved"
}
]
}
]
}
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found, workflow_not_found |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Create, read, update, delete, search, aggregate, and batch-edit records of any object type.
List records
listRecords/v1/objects/{object_type}/recordsLists records of one object type that the key's user may read. Results are scoped to the user's read grant: their own records, their teams' records, or the whole workspace. Use query parameters for simple filters; use POST …/records/search for richer queries.
- Scopes
records:read- Behavior
- Read-onlyIdempotent
Path parameters
| Name | Type | Description |
|---|---|---|
object_typerequired | string | Object type id from GET /v1/objects, e.g. companies, work-items, or a custom object id. |
Query parameters
| Name | Type | Description |
|---|---|---|
limit | integer1–100 · default: 25 | Page size (1–100). |
cursor | stringmax 500 chars | next_cursor from the previous page. |
q | stringmax 200 chars | Case-insensitive match on the display field. |
fields | stringmax 2000 chars | Comma-separated field keys to include in each record's fields (max 20). Omit for identity fields only. |
sort | stringmax 200 chars | Comma-separated field keys; prefix - for descending. Max 3. |
filter[<field>] | string or operator map | filter[field]=value or filter[field][op]=value (eq, ne, lt, lte, gt, gte, in, is_null). |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Response200
A page of records. Returns RecordList.
| Field | Type | Description |
|---|---|---|
data | — | |
pagination | — |
Examples
curl -G https://api.preshos.com/v1/objects/companies/records \
-H "Authorization: Bearer $PRESHOS_API_KEY" \
--data-urlencode "limit=2" \
--data-urlencode "fields=name,domain" \
--data-urlencode "sort=-updated_at" \
--data-urlencode "filter[industry]=Manufacturing"{
"data": [
{
"object_type": "companies",
"id": "48213",
"display": "Acme Corporation",
"status": "customer",
"owner": 17,
"owner_user_id": 17,
"created_at": "2026-09-02T14:11:08.000Z",
"updated_at": "2026-09-30T09:45:51.000Z",
"version": "9a1b2c3d4e5f60718293a4b5c6d7e8f9",
"fields": {
"name": "Acme Corporation",
"domain": "acme.com",
"industry": "Manufacturing"
}
}
],
"pagination": {
"limit": 2,
"has_more": true,
"next_cursor": "eyJ2IjoxLCJvIjoyLCJxIjoiLi4uIn0"
}
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 400 | Invalid request: malformed JSON, failed validation, or an invalid filter/cursor. | validation_failed, invalid_filter, invalid_cursor |
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported, search_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | object_not_available, user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Search records
searchRecords/v1/objects/{object_type}/records/searchStructured search with operator filters, a text query, sorting, and field selection. Read-only: this POST never changes data and needs no Idempotency-Key.
- Scopes
records:read- Behavior
- Read-onlyIdempotent
Path parameters
| Name | Type | Description |
|---|---|---|
object_typerequired | string | Object type id from GET /v1/objects, e.g. companies, work-items, or a custom object id. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Content-Type | string | application/json. |
Request bodyapplication/json · optional
| Field | Type | Description |
|---|---|---|
query | stringmax 200 chars | Case-insensitive match on the display field. |
filters | map of string | number | boolean | null | object | Map of field key → value or operator object. All filters are ANDed. A null value matches empty fields. |
fields | string[]max 20 items | Field keys to include in each record (max 20). |
sort | object[]max 3 items | — |
sort[].fieldrequired | string | — |
sort[].direction | "asc" | "desc"default: "asc" | — |
limit | integer1–100 · default: 25 | — |
cursor | stringmax 500 chars | — |
JSON Schema
{
"type": "object",
"properties": {
"query": {
"type": "string",
"maxLength": 200,
"description": "Case-insensitive match on the display field."
},
"filters": {
"type": "object",
"propertyNames": {
"type": "string"
},
"additionalProperties": {
"anyOf": [
{
"type": [
"string",
"number",
"boolean"
]
},
{
"type": "null"
},
{
"type": "object",
"properties": {
"eq": {
"type": [
"string",
"number",
"boolean"
]
},
"ne": {
"type": [
"string",
"number",
"boolean"
]
},
"lt": {
"type": [
"string",
"number",
"boolean"
]
},
"lte": {
"type": [
"string",
"number",
"boolean"
]
},
"gt": {
"type": [
"string",
"number",
"boolean"
]
},
"gte": {
"type": [
"string",
"number",
"boolean"
]
},
"in": {
"minItems": 1,
"maxItems": 100,
"type": "array",
"items": {
"type": [
"string",
"number",
"boolean"
]
}
},
"is_null": {
"type": "boolean"
}
},
"additionalProperties": false
}
]
},
"description": "Map of field key → value or operator object. All filters are ANDed. A null value matches empty fields."
},
"fields": {
"maxItems": 20,
"type": "array",
"items": {
"type": "string"
},
"description": "Field keys to include in each record (max 20)."
},
"sort": {
"maxItems": 3,
"type": "array",
"items": {
"type": "object",
"properties": {
"field": {
"type": "string"
},
"direction": {
"default": "asc",
"type": "string",
"enum": [
"asc",
"desc"
]
}
},
"required": [
"field"
],
"additionalProperties": false
}
},
"limit": {
"default": 25,
"type": "integer",
"minimum": 1,
"maximum": 100
},
"cursor": {
"type": "string",
"maxLength": 500
}
},
"additionalProperties": false
}Response200
A page of matching records. Returns RecordList.
| Field | Type | Description |
|---|---|---|
data | — | |
pagination | — |
Examples
curl -X POST https://api.preshos.com/v1/objects/companies/records/search \
-H "Authorization: Bearer $PRESHOS_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"filters": {
"lifecycle_stage": {
"in": [
"customer",
"opportunity"
]
},
"created_at": {
"gte": "2026-01-01T00:00:00Z"
}
},
"fields": [
"name",
"domain",
"lifecycle_stage"
],
"sort": [
{
"field": "created_at",
"direction": "desc"
}
],
"limit": 50
}'{
"filters": {
"lifecycle_stage": {
"in": [
"customer",
"opportunity"
]
},
"created_at": {
"gte": "2026-01-01T00:00:00Z"
}
},
"fields": [
"name",
"domain",
"lifecycle_stage"
],
"sort": [
{
"field": "created_at",
"direction": "desc"
}
],
"limit": 50
}{
"data": [
{
"object_type": "companies",
"id": "48213",
"display": "Acme Corporation",
"status": "customer",
"owner": 17,
"owner_user_id": 17,
"created_at": "2026-09-02T14:11:08.000Z",
"updated_at": "2026-09-30T09:45:51.000Z",
"version": "9a1b2c3d4e5f60718293a4b5c6d7e8f9",
"fields": {
"name": "Acme Corporation",
"domain": "acme.com",
"industry": "Manufacturing"
}
}
],
"pagination": {
"limit": 50,
"has_more": false,
"next_cursor": null
}
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 400 | Invalid request: malformed JSON, failed validation, or an invalid filter/cursor. | invalid_json, validation_failed, invalid_filter, invalid_cursor |
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported, search_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | object_not_available, user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Aggregate records
aggregateRecords/v1/objects/{object_type}/records/aggregateGroups the filtered records (up to 3 group_by fields) and computes 1–8 metrics (count, count_distinct, sum, avg, min, max) in the database over the complete filtered set. Omit field for count(*).
- Scopes
records:read- Behavior
- Read-onlyIdempotent
Path parameters
| Name | Type | Description |
|---|---|---|
object_typerequired | string | Object type id from GET /v1/objects, e.g. companies, work-items, or a custom object id. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Content-Typerequired | string | application/json. |
Request bodyapplication/json · required
| Field | Type | Description |
|---|---|---|
query | stringmax 200 chars | — |
filters | map of string | number | boolean | null | object | Map of field key → value or operator object. All filters are ANDed. A null value matches empty fields. |
group_by | string[]max 3 items | — |
metricsrequired | object[]1–8 items | — |
metrics[].namerequired | string | Result column name. |
metrics[].oprequired | "count" | "count_distinct" | "sum" | "avg" | "min" | "max" | — |
metrics[].field | string | — |
order_by | object | — |
order_by.namerequired | string | — |
order_by.directionrequired | "asc" | "desc" | — |
limit | integer1–100 · default: 25 | Maximum groups per page. |
cursor | stringmax 500 chars | — |
JSON Schema
{
"type": "object",
"properties": {
"query": {
"type": "string",
"maxLength": 200
},
"filters": {
"type": "object",
"propertyNames": {
"type": "string"
},
"additionalProperties": {
"anyOf": [
{
"type": [
"string",
"number",
"boolean"
]
},
{
"type": "null"
},
{
"type": "object",
"properties": {
"eq": {
"type": [
"string",
"number",
"boolean"
]
},
"ne": {
"type": [
"string",
"number",
"boolean"
]
},
"lt": {
"type": [
"string",
"number",
"boolean"
]
},
"lte": {
"type": [
"string",
"number",
"boolean"
]
},
"gt": {
"type": [
"string",
"number",
"boolean"
]
},
"gte": {
"type": [
"string",
"number",
"boolean"
]
},
"in": {
"minItems": 1,
"maxItems": 100,
"type": "array",
"items": {
"type": [
"string",
"number",
"boolean"
]
}
},
"is_null": {
"type": "boolean"
}
},
"additionalProperties": false
}
]
},
"description": "Map of field key → value or operator object. All filters are ANDed. A null value matches empty fields."
},
"group_by": {
"maxItems": 3,
"type": "array",
"items": {
"type": "string"
}
},
"metrics": {
"minItems": 1,
"maxItems": 8,
"type": "array",
"items": {
"type": "object",
"properties": {
"name": {
"type": "string",
"pattern": "^[a-z][a-z0-9_]{0,39}$",
"description": "Result column name."
},
"op": {
"type": "string",
"enum": [
"count",
"count_distinct",
"sum",
"avg",
"min",
"max"
]
},
"field": {
"type": "string"
}
},
"required": [
"name",
"op"
],
"additionalProperties": false
}
},
"order_by": {
"type": "object",
"properties": {
"name": {
"type": "string"
},
"direction": {
"type": "string",
"enum": [
"asc",
"desc"
]
}
},
"required": [
"name",
"direction"
],
"additionalProperties": false
},
"limit": {
"default": 25,
"type": "integer",
"minimum": 1,
"maximum": 100,
"description": "Maximum groups per page."
},
"cursor": {
"type": "string",
"maxLength": 500
}
},
"required": [
"metrics"
],
"additionalProperties": false
}Response200
Aggregated groups.
| Field | Type | Description |
|---|---|---|
data | object[] | — |
pagination | — |
Examples
curl -X POST https://api.preshos.com/v1/objects/work-items/records/aggregate \
-H "Authorization: Bearer $PRESHOS_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"filters": {
"work_item_type_id": "deliverable"
},
"group_by": [
"custom_status_id"
],
"metrics": [
{
"name": "total",
"op": "count"
}
],
"order_by": {
"name": "total",
"direction": "desc"
}
}'{
"filters": {
"work_item_type_id": "deliverable"
},
"group_by": [
"custom_status_id"
],
"metrics": [
{
"name": "total",
"op": "count"
}
],
"order_by": {
"name": "total",
"direction": "desc"
}
}{
"data": [
{
"custom_status_id": "st_in_progress",
"total": 42
}
],
"pagination": {
"limit": 25,
"has_more": false,
"next_cursor": null
}
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 400 | Invalid request: malformed JSON, failed validation, or an invalid filter/cursor. | invalid_json, validation_failed, invalid_filter, invalid_cursor |
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported, search_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | object_not_available, user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Apply a batch of changes atomically
batchRecords/v1/objects/{object_type}/records/batchApplies 1–100 operations to one object type in a single transaction: create, update, status, delete, upsert (match-and-update or create), link, and unlink. Every operation is authorized as the key's user before anything is written; if any operation fails, nothing is applied. Each existing record may appear once. delete operations also require the records:delete scope.
- Scopes
records:write- Behavior
- Changes dataDestructiveNot idempotentIdempotency-Key
Path parameters
| Name | Type | Description |
|---|---|---|
object_typerequired | string | Object type id from GET /v1/objects, e.g. companies, work-items, or a custom object id. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Content-Typerequired | string | application/json. |
Idempotency-Key | stringmax 255 chars | Unique key (1–255 visible ASCII characters, e.g. a UUID). Retrying with the same key and body replays the first successful response for 24 hours. |
Request bodyapplication/json · required
| Field | Type | Description |
|---|---|---|
operationsrequired | object[]1–100 items | — |
Each item of operations[] is one of these shapes, selected by action:
| Variant | Fields |
|---|---|
action: "create" | fieldsobject |
action: "update" | idstringfieldsobject |
action: "status" | idstringstatus_idstring |
action: "delete" | idstring |
action: "upsert" | targetstringmatchobjectfields?object |
action: "link" | idstringassociation_idstringtarget_idstring |
action: "unlink" | idstringassociation_idstringtarget_idstring |
JSON Schema
{
"type": "object",
"properties": {
"operations": {
"minItems": 1,
"maxItems": 100,
"type": "array",
"items": {
"oneOf": [
{
"type": "object",
"properties": {
"action": {
"type": "string",
"const": "create"
},
"fields": {
"type": "object",
"propertyNames": {
"type": "string"
},
"additionalProperties": {},
"description": "Field values keyed by field key (see `GET /v1/objects/{object_type}`). Custom fields go under `custom_fields`."
}
},
"required": [
"action",
"fields"
],
"additionalProperties": false
},
{
"type": "object",
"properties": {
"action": {
"type": "string",
"const": "update"
},
"id": {
"type": "string",
"minLength": 1,
"maxLength": 200,
"description": "Canonical record `id`."
},
"fields": {
"type": "object",
"propertyNames": {
"type": "string"
},
"additionalProperties": {},
"description": "Field values keyed by field key (see `GET /v1/objects/{object_type}`). Custom fields go under `custom_fields`."
}
},
"required": [
"action",
"id",
"fields"
],
"additionalProperties": false
},
{
"type": "object",
"properties": {
"action": {
"type": "string",
"const": "status"
},
"id": {
"type": "string",
"minLength": 1,
"maxLength": 200,
"description": "Canonical record `id`."
},
"status_id": {
"type": "string",
"minLength": 1,
"maxLength": 200
}
},
"required": [
"action",
"id",
"status_id"
],
"additionalProperties": false
},
{
"type": "object",
"properties": {
"action": {
"type": "string",
"const": "delete"
},
"id": {
"type": "string",
"minLength": 1,
"maxLength": 200,
"description": "Canonical record `id`."
}
},
"required": [
"action",
"id"
],
"additionalProperties": false
},
{
"type": "object",
"properties": {
"action": {
"type": "string",
"const": "upsert"
},
"target": {
"type": "string",
"minLength": 1,
"maxLength": 100,
"description": "Import target: the object type, or the work-item type slug for work items."
},
"match": {
"type": "object",
"propertyNames": {
"type": "string"
},
"additionalProperties": {},
"description": "Match keys, e.g. `{ \"domain\": \"acme.com\" }`."
},
"fields": {
"type": "object",
"propertyNames": {
"type": "string"
},
"additionalProperties": {}
}
},
"required": [
"action",
"target",
"match"
],
"additionalProperties": false
},
{
"type": "object",
"properties": {
"action": {
"type": "string",
"const": "link"
},
"id": {
"type": "string",
"minLength": 1,
"maxLength": 200,
"description": "Canonical record `id`."
},
"association_id": {
"type": "string",
"minLength": 1
},
"target_id": {
"type": "string",
"minLength": 1,
"maxLength": 200,
"description": "Canonical record `id`."
}
},
"required": [
"action",
"id",
"association_id",
"target_id"
],
"additionalProperties": false
},
{
"type": "object",
"properties": {
"action": {
"type": "string",
"const": "unlink"
},
"id": {
"type": "string",
"minLength": 1,
"maxLength": 200,
"description": "Canonical record `id`."
},
"association_id": {
"type": "string",
"minLength": 1
},
"target_id": {
"type": "string",
"minLength": 1,
"maxLength": 200,
"description": "Canonical record `id`."
}
},
"required": [
"action",
"id",
"association_id",
"target_id"
],
"additionalProperties": false
}
]
}
}
},
"required": [
"operations"
],
"additionalProperties": false
}Response200
Per-operation results; all operations succeeded.
| Field | Type | Description |
|---|---|---|
data | object | — |
data.status | "completed" | — |
data.object_type | string | — |
data.count | integer | — |
data.atomic | true | — |
data.results | object[] | — |
data.results[].action | string | — |
data.results[].id | string | — |
data.results[].status | "succeeded" | — |
Examples
curl -X POST https://api.preshos.com/v1/objects/companies/records/batch \
-H "Authorization: Bearer $PRESHOS_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: $(uuidgen)" \
-d '{
"operations": [
{
"action": "upsert",
"target": "companies",
"match": {
"domain": "acme.com"
},
"fields": {
"name": "Acme Corporation"
}
},
{
"action": "update",
"id": "48213",
"fields": {
"industry": "Aerospace"
}
},
{
"action": "status",
"id": "48214",
"status_id": "customer"
}
]
}'{
"operations": [
{
"action": "upsert",
"target": "companies",
"match": {
"domain": "acme.com"
},
"fields": {
"name": "Acme Corporation"
}
},
{
"action": "update",
"id": "48213",
"fields": {
"industry": "Aerospace"
}
},
{
"action": "status",
"id": "48214",
"status_id": "customer"
}
]
}{
"data": {
"status": "completed",
"object_type": "companies",
"count": 3,
"atomic": true,
"results": [
{
"action": "create",
"id": "48300",
"status": "succeeded"
},
{
"action": "update",
"id": "48213",
"status": "succeeded"
},
{
"action": "status",
"id": "48214",
"status": "succeeded"
}
]
}
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 400 | Invalid request: malformed JSON, failed validation, or an invalid filter/cursor. | invalid_json, validation_failed |
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported, write_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | object_not_available, user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
| 409 | Conflict, e.g. an Idempotency-Key request still in progress or a uniqueness violation. | conflict, idempotency_key_in_use, conflict |
| 412 | If-Match / expected_version does not match the current record version. | stale_record |
| 422 | The write was rejected by validation or workflow rules. | invalid_write, idempotency_key_reused |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Create a record
createRecord/v1/objects/{object_type}/recordsCreates a record as the key's user. Field rules from the object definition apply: required fields, select options, validation, and field permissions. Status is set to the workflow's initial status. An absent owner defaults to the human principal; service identities have no default owner. Explicit null clears an assignable owner. Use owner with a local user ID; conflicting aliases are rejected. Work items require fields.work_item_type_id. Send an Idempotency-Key to retry safely.
- Scopes
records:write- Behavior
- Changes dataNot idempotentIdempotency-Key
Path parameters
| Name | Type | Description |
|---|---|---|
object_typerequired | string | Object type id from GET /v1/objects, e.g. companies, work-items, or a custom object id. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Content-Typerequired | string | application/json. |
Idempotency-Key | stringmax 255 chars | Unique key (1–255 visible ASCII characters, e.g. a UUID). Retrying with the same key and body replays the first successful response for 24 hours. |
Request bodyapplication/json · required
| Field | Type | Description |
|---|---|---|
fieldsrequired | object | Field values keyed by field key (see GET /v1/objects/{object_type}). Custom fields go under custom_fields. |
JSON Schema
{
"type": "object",
"properties": {
"fields": {
"type": "object",
"propertyNames": {
"type": "string"
},
"additionalProperties": {},
"description": "Field values keyed by field key (see `GET /v1/objects/{object_type}`). Custom fields go under `custom_fields`."
}
},
"required": [
"fields"
],
"additionalProperties": false
}Response201
The created record. Returns RecordResponse.
| Field | Type | Description |
|---|---|---|
data | — |
Examples
curl -X POST https://api.preshos.com/v1/objects/companies/records \
-H "Authorization: Bearer $PRESHOS_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: $(uuidgen)" \
-d '{
"fields": {
"name": "Acme Corporation",
"domain": "acme.com",
"industry": "Manufacturing"
}
}'{
"fields": {
"name": "Acme Corporation",
"domain": "acme.com",
"industry": "Manufacturing"
}
}{
"data": {
"object_type": "companies",
"id": "48213",
"display": "Acme Corporation",
"status": "customer",
"owner": 17,
"owner_user_id": 17,
"created_at": "2026-09-02T14:11:08.000Z",
"updated_at": "2026-09-30T09:45:51.000Z",
"version": "9a1b2c3d4e5f60718293a4b5c6d7e8f9",
"fields": {
"name": "Acme Corporation",
"domain": "acme.com",
"industry": "Manufacturing"
}
}
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 400 | Invalid request: malformed JSON, failed validation, or an invalid filter/cursor. | invalid_json, validation_failed, invalid_filter |
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported, write_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | object_not_available, user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
| 409 | Conflict, e.g. an Idempotency-Key request still in progress or a uniqueness violation. | conflict, idempotency_key_in_use, conflict |
| 422 | The write was rejected by validation or workflow rules. | invalid_write, idempotency_key_reused |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Retrieve a record
getRecord/v1/objects/{object_type}/records/{record_id}Returns one record with every field the key's user may read. The ETag header carries the record version for conditional updates. Records the user may not read return 404.
- Scopes
records:read- Behavior
- Read-onlyIdempotent
Path parameters
| Name | Type | Description |
|---|---|---|
object_typerequired | string | Object type id from GET /v1/objects, e.g. companies, work-items, or a custom object id. |
record_idrequired | string1–200 chars | Canonical record id. |
Query parameters
| Name | Type | Description |
|---|---|---|
fields | stringmax 2000 chars | Comma-separated field keys to return (max 20). Omit to return every field you may read. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Examples
curl https://api.preshos.com/v1/objects/companies/records/48213 \
-H "Authorization: Bearer $PRESHOS_API_KEY"{
"data": {
"object_type": "companies",
"id": "48213",
"display": "Acme Corporation",
"status": "customer",
"owner": 17,
"owner_user_id": 17,
"created_at": "2026-09-02T14:11:08.000Z",
"updated_at": "2026-09-30T09:45:51.000Z",
"version": "9a1b2c3d4e5f60718293a4b5c6d7e8f9",
"fields": {
"name": "Acme Corporation",
"domain": "acme.com",
"industry": "Manufacturing"
}
}
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 400 | Invalid request: malformed JSON, failed validation, or an invalid filter/cursor. | validation_failed, invalid_filter |
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | object_not_available, record_not_found, user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Update a record
updateRecord/v1/objects/{object_type}/records/{record_id}Partially updates a record: only the fields you send change. Unknown, read-only, or status fields reject the whole request (change status with the status endpoint). Send If-Match: "<version>" to fail with 412 if the record changed since you read it.
- Scopes
records:write- Behavior
- Changes dataIdempotentIdempotency-KeyIf-Match
Path parameters
| Name | Type | Description |
|---|---|---|
object_typerequired | string | Object type id from GET /v1/objects, e.g. companies, work-items, or a custom object id. |
record_idrequired | string1–200 chars | Canonical record id. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Content-Typerequired | string | application/json. |
Idempotency-Key | stringmax 255 chars | Unique key (1–255 visible ASCII characters, e.g. a UUID). Retrying with the same key and body replays the first successful response for 24 hours. |
If-Match | string | The record version (or its ETag). The update fails with 412 if the record changed. |
Request bodyapplication/json · required
| Field | Type | Description |
|---|---|---|
fieldsrequired | object | Field values keyed by field key (see GET /v1/objects/{object_type}). Custom fields go under custom_fields. |
expected_version | stringmax 200 chars | Alternative to the If-Match header. |
JSON Schema
{
"type": "object",
"properties": {
"fields": {
"type": "object",
"propertyNames": {
"type": "string"
},
"additionalProperties": {},
"description": "Field values keyed by field key (see `GET /v1/objects/{object_type}`). Custom fields go under `custom_fields`."
},
"expected_version": {
"type": "string",
"maxLength": 200,
"description": "Alternative to the If-Match header."
}
},
"required": [
"fields"
],
"additionalProperties": false
}Response200
The updated record. Returns RecordResponse.
| Field | Type | Description |
|---|---|---|
data | — |
Examples
curl -X PATCH https://api.preshos.com/v1/objects/companies/records/48213 \
-H "Authorization: Bearer $PRESHOS_API_KEY" \
-H "Content-Type: application/json" \
-H 'If-Match: "9a1b2c3d4e5f60718293a4b5c6d7e8f9"' \
-d '{
"fields": {
"industry": "Aerospace",
"custom_fields": {
"tier": "enterprise"
}
}
}'{
"fields": {
"industry": "Aerospace",
"custom_fields": {
"tier": "enterprise"
}
}
}{
"data": {
"object_type": "companies",
"id": "48213",
"display": "Acme Corporation",
"status": "customer",
"owner": 17,
"owner_user_id": 17,
"created_at": "2026-09-02T14:11:08.000Z",
"updated_at": "2026-09-30T09:45:51.000Z",
"version": "9a1b2c3d4e5f60718293a4b5c6d7e8f9",
"fields": {
"name": "Acme Corporation",
"domain": "acme.com",
"industry": "Aerospace"
}
}
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 400 | Invalid request: malformed JSON, failed validation, or an invalid filter/cursor. | invalid_json, validation_failed, invalid_filter |
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported, write_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | object_not_available, record_not_found, user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
| 412 | If-Match / expected_version does not match the current record version. | stale_record |
| 422 | The write was rejected by validation or workflow rules. | invalid_write, idempotency_key_reused |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Delete a record
deleteRecord/v1/objects/{object_type}/records/{record_id}Permanently deletes a record (CRM association rows are removed with it). Requires the records:delete scope, delete permission, and an object that allows deletion (capabilities.delete).
- Scopes
records:delete- Behavior
- Changes dataDestructiveNot idempotent
Path parameters
| Name | Type | Description |
|---|---|---|
object_typerequired | string | Object type id from GET /v1/objects, e.g. companies, work-items, or a custom object id. |
record_idrequired | string1–200 chars | Canonical record id. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Response200
Deletion confirmation.
| Field | Type | Description |
|---|---|---|
data | object | — |
data.id | string | — |
data.object_type | string | — |
data.deleted | true | — |
Examples
curl -X DELETE https://api.preshos.com/v1/objects/companies/records/48213 \
-H "Authorization: Bearer $PRESHOS_API_KEY"{
"data": {
"id": "48213",
"object_type": "companies",
"deleted": true
}
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported, write_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | object_not_available, record_not_found, user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
| 409 | Conflict, e.g. an Idempotency-Key request still in progress or a uniqueness violation. | conflict, conflict |
| 422 | The write was rejected by validation or workflow rules. | invalid_write |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Change a record's status
setRecordStatus/v1/objects/{object_type}/records/{record_id}/statusMoves a record to another status of its workflow. The transition must be allowed by the workflow (see GET /v1/workflows/{workflow_id}); approval-gated statuses follow the same rules as the app.
- Scopes
records:write- Behavior
- Changes dataIdempotentIdempotency-Key
Path parameters
| Name | Type | Description |
|---|---|---|
object_typerequired | string | Object type id from GET /v1/objects, e.g. companies, work-items, or a custom object id. |
record_idrequired | string1–200 chars | Canonical record id. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Content-Typerequired | string | application/json. |
Idempotency-Key | stringmax 255 chars | Unique key (1–255 visible ASCII characters, e.g. a UUID). Retrying with the same key and body replays the first successful response for 24 hours. |
Request bodyapplication/json · required
| Field | Type | Description |
|---|---|---|
status_idrequired | string1–200 chars | Target workflow status id. |
JSON Schema
{
"type": "object",
"properties": {
"status_id": {
"type": "string",
"minLength": 1,
"maxLength": 200,
"description": "Target workflow status id."
}
},
"required": [
"status_id"
],
"additionalProperties": false
}Response200
The record after the transition. Returns RecordResponse.
| Field | Type | Description |
|---|---|---|
data | — |
Examples
curl -X POST https://api.preshos.com/v1/objects/companies/records/48213/status \
-H "Authorization: Bearer $PRESHOS_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: $(uuidgen)" \
-d '{
"status_id": "customer"
}'{
"status_id": "customer"
}{
"data": {
"object_type": "companies",
"id": "48213",
"display": "Acme Corporation",
"status": "customer",
"owner": 17,
"owner_user_id": 17,
"created_at": "2026-09-02T14:11:08.000Z",
"updated_at": "2026-09-30T09:45:51.000Z",
"version": "9a1b2c3d4e5f60718293a4b5c6d7e8f9",
"fields": {
"name": "Acme Corporation",
"domain": "acme.com",
"industry": "Manufacturing"
}
}
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 400 | Invalid request: malformed JSON, failed validation, or an invalid filter/cursor. | invalid_json, validation_failed |
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported, write_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | object_not_available, record_not_found, user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
| 422 | The write was rejected by validation or workflow rules. | invalid_write, idempotency_key_reused |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Discover and traverse relationships; link and unlink records.
Discover a record's relationships
listRelationships/v1/objects/{object_type}/records/{record_id}/relationshipsLists the relationships registered for this record's object type, including which ones support link/unlink. Use an id from this list to read linked records.
- Scopes
records:read- Behavior
- Read-onlyIdempotent
Path parameters
| Name | Type | Description |
|---|---|---|
object_typerequired | string | Object type id from GET /v1/objects, e.g. companies, work-items, or a custom object id. |
record_idrequired | string1–200 chars | Canonical record id. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Response200
Relationship definitions.
| Field | Type | Description |
|---|---|---|
data | object[] | — |
data[].id | string | Association id. |
data[].label | string | null | — |
data[].object_type | string | Related object type. |
data[].cardinality | string | one_to_one, many_to_one, one_to_many, or many_to_many. |
data[].can_link | boolean | Whether link/unlink is supported through the API. |
data[].actionoptional | object | — |
data[].action.id | string | — |
data[].action.version | integer | — |
data[].action.operation | string | — |
data[].source_field | string | null | Reference field on this record, when the relationship is a field. |
Examples
curl https://api.preshos.com/v1/objects/companies/records/48213/relationships \
-H "Authorization: Bearer $PRESHOS_API_KEY"{
"data": [
{
"id": "214",
"label": "Contacts",
"object_type": "contacts",
"cardinality": "one_to_many",
"can_link": false,
"source_field": null
},
{
"id": "219",
"label": "Parent company",
"object_type": "companies",
"cardinality": "many_to_one",
"can_link": true,
"source_field": "parent_company_id"
}
]
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | object_not_available, record_not_found, user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
List linked records
listRelatedRecords/v1/objects/{object_type}/records/{record_id}/relationships/{association_id}Returns the records linked to this record through one relationship (field references, CRM associations, and custom links). Requires workspace-wide read on the related object type.
- Scopes
records:read- Behavior
- Read-onlyIdempotent
Path parameters
| Name | Type | Description |
|---|---|---|
object_typerequired | string | Object type id from GET /v1/objects, e.g. companies, work-items, or a custom object id. |
record_idrequired | string1–200 chars | Canonical record id. |
association_idrequired | string1–100 chars | Relationship id from the discovery endpoint. |
Query parameters
| Name | Type | Description |
|---|---|---|
limit | integer1–100 · default: 25 | — |
cursor | stringmax 500 chars | — |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Response200
Linked records.
| Field | Type | Description |
|---|---|---|
object_type | string | — |
data | — | |
pagination | — |
Examples
curl https://api.preshos.com/v1/objects/companies/records/48213/relationships/214 \
-H "Authorization: Bearer $PRESHOS_API_KEY"{
"object_type": "contacts",
"data": [
{
"object_type": "contacts",
"id": "9001",
"display": "Ada Lovelace",
"status": null,
"owner_user_id": 17,
"created_at": "2026-08-01T10:00:00.000Z",
"updated_at": "2026-09-01T10:00:00.000Z"
}
],
"pagination": {
"limit": 25,
"has_more": false,
"next_cursor": null
}
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 400 | Invalid request: malformed JSON, failed validation, or an invalid filter/cursor. | validation_failed, invalid_cursor |
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | object_not_available, record_not_found, user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Link a record
linkRecord/v1/objects/{object_type}/records/{record_id}/relationships/{association_id}Links a target record through a relationship whose can_link is true. Reference relationships set the reference field (replacing the previous target); custom many-to-many relationships add a link. Requires update permission on this record and read permission on the target.
- Scopes
records:write- Behavior
- Changes dataIdempotentIdempotency-Key
Path parameters
| Name | Type | Description |
|---|---|---|
object_typerequired | string | Object type id from GET /v1/objects, e.g. companies, work-items, or a custom object id. |
record_idrequired | string1–200 chars | Canonical record id. |
association_idrequired | string1–100 chars | Relationship id from the discovery endpoint. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Content-Typerequired | string | application/json. |
Idempotency-Key | stringmax 255 chars | Unique key (1–255 visible ASCII characters, e.g. a UUID). Retrying with the same key and body replays the first successful response for 24 hours. |
Request bodyapplication/json · required
| Field | Type | Description |
|---|---|---|
target_idrequired | string1–200 chars | Id of the record to link. |
JSON Schema
{
"type": "object",
"properties": {
"target_id": {
"type": "string",
"minLength": 1,
"maxLength": 200,
"description": "Id of the record to link."
}
},
"required": [
"target_id"
],
"additionalProperties": false
}Response200
Link result.
| Field | Type | Description |
|---|---|---|
data | object | — |
data.id | string | — |
data.association_id | string | — |
data.target_id | string | — |
data.linked | boolean | — |
Examples
curl -X POST https://api.preshos.com/v1/objects/companies/records/48213/relationships/219 \
-H "Authorization: Bearer $PRESHOS_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: $(uuidgen)" \
-d '{
"target_id": "48001"
}'{
"target_id": "48001"
}{
"data": {
"id": "48213",
"association_id": "219",
"target_id": "48001",
"linked": true
}
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 400 | Invalid request: malformed JSON, failed validation, or an invalid filter/cursor. | invalid_json, validation_failed |
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported, write_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | object_not_available, record_not_found, user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
| 412 | If-Match / expected_version does not match the current record version. | stale_record |
| 422 | The write was rejected by validation or workflow rules. | invalid_write, idempotency_key_reused |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Unlink a record
unlinkRecord/v1/objects/{object_type}/records/{record_id}/relationships/{association_id}/{target_id}Removes a link created through a can_link relationship. A reference field is cleared only if it still points to target_id (otherwise 412).
- Scopes
records:write- Behavior
- Changes dataIdempotent
Path parameters
| Name | Type | Description |
|---|---|---|
object_typerequired | string | Object type id from GET /v1/objects, e.g. companies, work-items, or a custom object id. |
record_idrequired | string1–200 chars | Canonical record id. |
association_idrequired | string1–100 chars | Relationship id from the discovery endpoint. |
target_idrequired | string1–200 chars | Canonical record id. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Response200
Unlink result.
| Field | Type | Description |
|---|---|---|
data | object | — |
data.id | string | — |
data.association_id | string | — |
data.target_id | string | — |
data.linked | boolean | — |
Examples
curl -X DELETE https://api.preshos.com/v1/objects/companies/records/48213/relationships/219/48001 \
-H "Authorization: Bearer $PRESHOS_API_KEY"{
"data": {
"id": "48213",
"association_id": "219",
"target_id": "48001",
"linked": false
}
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 400 | Invalid request: malformed JSON, failed validation, or an invalid filter/cursor. | validation_failed |
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported, write_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | object_not_available, record_not_found, user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
| 412 | If-Match / expected_version does not match the current record version. | stale_record |
| 422 | The write was rejected by validation or workflow rules. | invalid_write |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Read and post record comments.
List a record's comments
listComments/v1/objects/{object_type}/records/{record_id}/commentsReturns the record's comment thread as plain text, newest first by default. Available for work items, companies, contacts, deals, meetings, and events.
- Scopes
comments:read- Behavior
- Read-onlyIdempotent
Path parameters
| Name | Type | Description |
|---|---|---|
object_typerequired | string | Object type id from GET /v1/objects, e.g. companies, work-items, or a custom object id. |
record_idrequired | string1–200 chars | Canonical record id. |
Query parameters
| Name | Type | Description |
|---|---|---|
limit | integer1–100 · default: 50 | — |
cursor | stringmax 200 chars | next_cursor from the previous page. |
order | "desc" | "asc"default: "desc" | desc = newest first. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Response200
A page of comments.
| Field | Type | Description |
|---|---|---|
data | — | |
pagination | — |
Examples
curl https://api.preshos.com/v1/objects/companies/records/48213/comments \
-H "Authorization: Bearer $PRESHOS_API_KEY"{
"data": [
{
"id": "c_8f2d",
"body": "Shared the revised proposal with the client.",
"author": {
"kind": "user",
"id": 17,
"name": "Jordan Lee"
},
"created_at": "2026-09-30T15:02:11.000Z",
"updated_at": "2026-09-30T15:02:11.000Z"
}
],
"pagination": {
"limit": 50,
"has_more": false,
"next_cursor": null
}
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 400 | Invalid request: malformed JSON, failed validation, or an invalid filter/cursor. | validation_failed, invalid_cursor |
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | object_not_available, record_not_found, user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found, comments_not_supported |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Comment on a record
createComment/v1/objects/{object_type}/records/{record_id}/commentsPosts a comment as the key's user. Mentioned users (by user id) are notified when they can read the record. The comment appears in the app in real time, exactly like one written in the UI.
- Scopes
comments:write- Behavior
- Changes dataNot idempotentIdempotency-Key
Path parameters
| Name | Type | Description |
|---|---|---|
object_typerequired | string | Object type id from GET /v1/objects, e.g. companies, work-items, or a custom object id. |
record_idrequired | string1–200 chars | Canonical record id. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Content-Typerequired | string | application/json. |
Idempotency-Key | stringmax 255 chars | Unique key (1–255 visible ASCII characters, e.g. a UUID). Retrying with the same key and body replays the first successful response for 24 hours. |
Request bodyapplication/json · required
| Field | Type | Description |
|---|---|---|
bodyrequired | string1–10000 chars | Plain-text comment. |
mention_user_ids | integer[]max 20 items | Workspace user ids to @mention. |
JSON Schema
{
"type": "object",
"properties": {
"body": {
"type": "string",
"minLength": 1,
"maxLength": 10000,
"description": "Plain-text comment."
},
"mention_user_ids": {
"maxItems": 20,
"type": "array",
"items": {
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 9007199254740991
},
"description": "Workspace user ids to @mention."
}
},
"required": [
"body"
],
"additionalProperties": false
}Examples
curl -X POST https://api.preshos.com/v1/objects/companies/records/48213/comments \
-H "Authorization: Bearer $PRESHOS_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: $(uuidgen)" \
-d '{
"body": "Kickoff is confirmed for Monday.",
"mention_user_ids": [
17
]
}'{
"body": "Kickoff is confirmed for Monday.",
"mention_user_ids": [
17
]
}{
"data": {
"id": "c_9a01",
"body": "@Jordan Lee Kickoff is confirmed for Monday.",
"author": {
"kind": "user",
"id": 23,
"name": "Sam Rivera"
},
"created_at": "2026-10-01T12:00:00.000Z",
"updated_at": "2026-10-01T12:00:00.000Z"
}
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 400 | Invalid request: malformed JSON, failed validation, or an invalid filter/cursor. | invalid_json, validation_failed |
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported, write_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | object_not_available, record_not_found, user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found, comments_not_supported |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Work in the team workspaces you belong to: objectives, tasks, the shared thread, questions from agents, and live documents. A member's own key only.
List your team workspaces
listTeamWorkspaces/v1/team-workspacesReturns the team workspaces the key's user is an active member of, newest first. Team workspaces are available to a member's own key only; a service key gets member_key_required.
- Scopes
team_workspaces:read- Behavior
- Read-onlyIdempotent
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Response200
Your team workspaces.
| Field | Type | Description |
|---|---|---|
data | object[] | — |
data[].id | string | — |
data[].name | string | — |
data[].role | "owner" | "member" | Your role in the workspace. |
data[].task_prefix | string | null | Prefix of task keys, as in PW-12. |
data[].member_count | integer | — |
data[].open_question_count | integer | Open questions from agents addressed to you. |
data[].created_at | string | null | — |
Examples
curl https://api.preshos.com/v1/team-workspaces \
-H "Authorization: Bearer $PRESHOS_API_KEY"{
"data": [
{
"id": "3a4b5c6d-7e8f-4a1b-9c2d-3e4f5a6b7c8d",
"name": "Spring launch",
"role": "owner",
"task_prefix": "PW",
"member_count": 3,
"open_question_count": 1,
"created_at": "2026-11-15T13:00:00.000Z"
}
]
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Retrieve a team workspace
getTeamWorkspace/v1/team-workspaces/{workspace_id}Returns one workspace you belong to: its name, objectives with their status, members, the agents working in it (each has an agent_seat_id you can address in the shared thread or assign a task to), and counts.
- Scopes
team_workspaces:read- Behavior
- Read-onlyIdempotent
Path parameters
| Name | Type | Description |
|---|---|---|
workspace_idrequired | string1–64 chars | Team workspace id, from GET /team-workspaces. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Response200
The workspace.
| Field | Type | Description |
|---|---|---|
data | object | — |
data.id | string | — |
data.name | string | — |
data.role | "owner" | "member" | — |
data.task_prefix | string | null | — |
data.instructions | string | null | What the workspace is for, as written by its owner. |
data.shared_thread_enabled | boolean | — |
data.objectives | object[] | — |
data.objectives[].id | string | — |
data.objectives[].title | string | — |
data.objectives[].description | string | null | — |
data.objectives[].measure | string | null | How the objective will be measured. |
data.objectives[].target_date | string | null | — |
data.objectives[].owner_user_id | integer | null | — |
data.objectives[].status | "on_track" | "at_risk" | "off_track" | "done" | string | — |
data.objectives[].position | integer | — |
data.objectives[].created_at | string | null | — |
data.objectives[].updated_at | string | null | — |
data.members | object[] | — |
data.members[].user_id | integer | — |
data.members[].name | string | null | — |
data.members[].role | "owner" | "member" | — |
data.agents | object[] | — |
data.agents[].agent_seat_id | string | — |
data.agents[].kind | string | member_agent, team_agent or lead. |
data.agents[].name | string | null | — |
data.agents[].member_user_id | integer | null | For a member's own agent: that member. |
data.counts | object | — |
data.counts.members | integer | — |
data.counts.tasks | integer | — |
data.counts.open_questions_for_you | integer | — |
data.created_at | string | null | — |
Examples
curl https://api.preshos.com/v1/team-workspaces/<workspace_id> \
-H "Authorization: Bearer $PRESHOS_API_KEY"{
"data": {
"id": "3a4b5c6d-7e8f-4a1b-9c2d-3e4f5a6b7c8d",
"name": "Spring launch",
"role": "owner",
"task_prefix": "PW",
"instructions": "Ship the spring product page and its launch email.",
"shared_thread_enabled": true,
"objectives": [
{
"id": "0f6f8f2e-7a31-4a52-8c44-8b7c2f2f6a01",
"title": "Launch the spring product page",
"description": null,
"measure": "Page live and linked from the home page",
"target_date": "2026-12-10",
"owner_user_id": 23,
"status": "on_track",
"position": 0,
"created_at": "2026-11-15T13:00:00.000Z",
"updated_at": "2026-11-15T13:00:00.000Z"
}
],
"members": [
{
"user_id": 23,
"name": "Sam Rivera",
"role": "owner"
},
{
"user_id": 17,
"name": "Jordan Lee",
"role": "member"
}
],
"agents": [
{
"agent_seat_id": "9d2b7e10-4b1f-4e0c-b2a3-6f5d0c1a2b3c",
"kind": "member_agent",
"name": "Sam's agent",
"member_user_id": 23
},
{
"agent_seat_id": "1e2d3c4b-5a69-4788-9a0b-c1d2e3f4a5b6",
"kind": "lead",
"name": "Workspace lead",
"member_user_id": null
}
],
"counts": {
"members": 2,
"tasks": 6,
"open_questions_for_you": 1
},
"created_at": "2026-11-15T13:00:00.000Z"
}
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
List a workspace's tasks
listTeamWorkspaceTasks/v1/team-workspaces/{workspace_id}/tasksReturns the workspace's tasks in key order. Filter by workspace state, owner, objective, or tasks changed since a time. A task is also a work item, so work_item.record_id reads the same task through the records API.
- Scopes
team_workspaces:read- Behavior
- Read-onlyIdempotent
Path parameters
| Name | Type | Description |
|---|---|---|
workspace_idrequired | string1–64 chars | Team workspace id, from GET /team-workspaces. |
Query parameters
| Name | Type | Description |
|---|---|---|
status | "todo" | "working" | "for_review" | "done" | "cancelled" | Workspace state: todo, working, for_review, done or cancelled. Each maps to a status of the task's own workflow. |
owner_user_id | integer | Only tasks owned by this member. |
objective_id | stringformat: uuid | Only tasks serving this objective. |
updated_since | stringformat: date-time | Only tasks changed at or after this ISO 8601 time. |
limit | integer1–200 · default: 50 | — |
cursor | stringmax 200 chars | next_cursor from the previous page. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Response200
A page of tasks.
| Field | Type | Description |
|---|---|---|
data | object[] | — |
data[].id | string | — |
data[].key | string | Display key, as in PW-12. |
data[].title | string | — |
data[].description | string | null | — |
data[].status | object | — |
data[].status.id | string | null | Workflow status id of the underlying work item. |
data[].status.name | string | null | — |
data[].status.intent | "todo" | "working" | "for_review" | "done" | "cancelled" | Workspace state: todo, working, for_review, done or cancelled. Each maps to a status of the task's own workflow. |
data[].due_date | string | null | — |
data[].objective_id | string | null | — |
data[].acceptance_criteria | string | null | — |
data[].owner | object | null | The member who owns the task. |
data[].worker | object | null | The agent doing the work, if one is assigned. |
data[].reviewer | object | null | — |
data[].parent_task_id | string | null | — |
data[].depends_on | string[] | Ids of tasks that must finish first. |
data[].now_doing | string | null | One line on what the worker is doing now. |
data[].input_needed | boolean | An agent is waiting on a person for this task. |
data[].start_when_unblocked | boolean | — |
data[].review_round | integer | — |
data[].tags | string[] | — |
data[].work_item | object | The same task as a record in the records API. |
data[].work_item.object_type | "work-items" | — |
data[].work_item.record_id | string | — |
data[].work_item.work_item_type_id | string | — |
data[].created_at | string | null | — |
data[].updated_at | string | null | — |
pagination | — |
Examples
curl -G https://api.preshos.com/v1/team-workspaces/<workspace_id>/tasks \
-H "Authorization: Bearer $PRESHOS_API_KEY" \
--data-urlencode "status=working"{
"data": [
{
"id": "5b0e6f3a-2d0c-4c0a-9a65-1f2f4a7c9d10",
"key": "PW-12",
"title": "Draft the launch page copy",
"description": "Hero, three benefit sections and the pricing teaser.",
"status": {
"id": "wf-task-working",
"name": "Working",
"intent": "working"
},
"due_date": "2026-12-04T00:00:00.000Z",
"objective_id": "0f6f8f2e-7a31-4a52-8c44-8b7c2f2f6a01",
"acceptance_criteria": "Reads in under two minutes; every claim has a source.",
"owner": {
"user_id": 23,
"name": "Sam Rivera"
},
"worker": {
"agent_seat_id": "9d2b7e10-4b1f-4e0c-b2a3-6f5d0c1a2b3c",
"kind": "member_agent",
"name": "Sam's agent"
},
"reviewer": {
"type": "user",
"agent_seat_id": null,
"user_id": 17,
"name": "Jordan Lee"
},
"parent_task_id": null,
"depends_on": [],
"now_doing": "Writing the benefits section",
"input_needed": false,
"start_when_unblocked": false,
"review_round": 0,
"tags": [
"launch"
],
"work_item": {
"object_type": "work-items",
"record_id": "48213",
"work_item_type_id": "task"
},
"created_at": "2026-11-15T14:02:11.000Z",
"updated_at": "2026-11-15T16:40:02.000Z"
}
],
"pagination": {
"limit": 50,
"has_more": false,
"next_cursor": null
}
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 400 | Invalid request: malformed JSON, failed validation, or an invalid filter/cursor. | validation_failed, invalid_cursor |
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Create a workspace task
createTeamWorkspaceTask/v1/team-workspaces/{workspace_id}/tasksCreates a task in the workspace as you. It appears on the board at once. To hand it to someone or to an agent, call the assign endpoint afterwards; creating a task never starts agent work by itself.
- Scopes
team_workspaces:write- Behavior
- Changes dataNot idempotentIdempotency-Key
Path parameters
| Name | Type | Description |
|---|---|---|
workspace_idrequired | string1–64 chars | Team workspace id, from GET /team-workspaces. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Content-Typerequired | string | application/json. |
Idempotency-Key | stringmax 255 chars | Unique key (1–255 visible ASCII characters, e.g. a UUID). Retrying with the same key and body replays the first successful response for 24 hours. |
Request bodyapplication/json · required
| Field | Type | Description |
|---|---|---|
titlerequired | string1–300 chars | — |
description | string | null | — |
objective_id | string | null | The objective this task serves. |
acceptance_criteria | string | null | What "done" means; a reviewer checks the work against this. |
due_date | string | null | — |
parent_task_id | string | null | — |
tags | string[]max 20 items | — |
JSON Schema
{
"type": "object",
"properties": {
"title": {
"type": "string",
"minLength": 1,
"maxLength": 300
},
"description": {
"anyOf": [
{
"type": "string",
"maxLength": 20000
},
{
"type": "null"
}
]
},
"objective_id": {
"anyOf": [
{
"type": "string",
"format": "uuid",
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
},
{
"type": "null"
}
],
"description": "The objective this task serves."
},
"acceptance_criteria": {
"anyOf": [
{
"type": "string",
"maxLength": 8000
},
{
"type": "null"
}
],
"description": "What \"done\" means; a reviewer checks the work against this."
},
"due_date": {
"anyOf": [
{
"type": "string",
"pattern": "^\\d{4}-\\d{2}-\\d{2}$"
},
{
"type": "null"
}
]
},
"parent_task_id": {
"anyOf": [
{
"type": "string",
"format": "uuid",
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
},
{
"type": "null"
}
]
},
"tags": {
"maxItems": 20,
"type": "array",
"items": {
"type": "string",
"minLength": 1,
"maxLength": 40
}
}
},
"required": [
"title"
],
"additionalProperties": false
}Response201
The created task.
| Field | Type | Description |
|---|---|---|
data | object | — |
data.id | string | — |
data.key | string | Display key, as in PW-12. |
data.title | string | — |
data.description | string | null | — |
data.status | object | — |
data.status.id | string | null | Workflow status id of the underlying work item. |
data.status.name | string | null | — |
data.status.intent | "todo" | "working" | "for_review" | "done" | "cancelled" | Workspace state: todo, working, for_review, done or cancelled. Each maps to a status of the task's own workflow. |
data.due_date | string | null | — |
data.objective_id | string | null | — |
data.acceptance_criteria | string | null | — |
data.owner | object | null | The member who owns the task. |
data.worker | object | null | The agent doing the work, if one is assigned. |
data.reviewer | object | null | — |
data.parent_task_id | string | null | — |
data.depends_on | string[] | Ids of tasks that must finish first. |
data.now_doing | string | null | One line on what the worker is doing now. |
data.input_needed | boolean | An agent is waiting on a person for this task. |
data.start_when_unblocked | boolean | — |
data.review_round | integer | — |
data.tags | string[] | — |
data.work_item | object | The same task as a record in the records API. |
data.work_item.object_type | "work-items" | — |
data.work_item.record_id | string | — |
data.work_item.work_item_type_id | string | — |
data.created_at | string | null | — |
data.updated_at | string | null | — |
Examples
curl -X POST https://api.preshos.com/v1/team-workspaces/<workspace_id>/tasks \
-H "Authorization: Bearer $PRESHOS_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: $(uuidgen)" \
-d '{
"title": "Draft the launch page copy",
"objective_id": "0f6f8f2e-7a31-4a52-8c44-8b7c2f2f6a01",
"acceptance_criteria": "Reads in under two minutes; every claim has a source.",
"due_date": "2026-12-04"
}'{
"title": "Draft the launch page copy",
"objective_id": "0f6f8f2e-7a31-4a52-8c44-8b7c2f2f6a01",
"acceptance_criteria": "Reads in under two minutes; every claim has a source.",
"due_date": "2026-12-04"
}{
"data": {
"id": "5b0e6f3a-2d0c-4c0a-9a65-1f2f4a7c9d10",
"key": "PW-12",
"title": "Draft the launch page copy",
"description": "Hero, three benefit sections and the pricing teaser.",
"status": {
"id": "wf-task-todo",
"name": "To do",
"intent": "todo"
},
"due_date": "2026-12-04T00:00:00.000Z",
"objective_id": "0f6f8f2e-7a31-4a52-8c44-8b7c2f2f6a01",
"acceptance_criteria": "Reads in under two minutes; every claim has a source.",
"owner": null,
"worker": null,
"reviewer": {
"type": "user",
"agent_seat_id": null,
"user_id": 17,
"name": "Jordan Lee"
},
"parent_task_id": null,
"depends_on": [],
"now_doing": null,
"input_needed": false,
"start_when_unblocked": false,
"review_round": 0,
"tags": [
"launch"
],
"work_item": {
"object_type": "work-items",
"record_id": "48213",
"work_item_type_id": "task"
},
"created_at": "2026-11-15T14:02:11.000Z",
"updated_at": "2026-11-15T16:40:02.000Z"
}
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 400 | Invalid request: malformed JSON, failed validation, or an invalid filter/cursor. | invalid_json, validation_failed |
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported, write_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
| 409 | Conflict, e.g. an Idempotency-Key request still in progress or a uniqueness violation. | conflict, idempotency_key_in_use |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Retrieve a workspace task
getTeamWorkspaceTask/v1/team-workspaces/{workspace_id}/tasks/{task_id}Returns one task by its id or its display key (for example PW-12).
- Scopes
team_workspaces:read- Behavior
- Read-onlyIdempotent
Path parameters
| Name | Type | Description |
|---|---|---|
workspace_idrequired | string1–64 chars | Team workspace id, from GET /team-workspaces. |
task_idrequired | string1–64 chars | Task id, or its display key such as PW-12. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Response200
The task.
| Field | Type | Description |
|---|---|---|
data | object | — |
data.id | string | — |
data.key | string | Display key, as in PW-12. |
data.title | string | — |
data.description | string | null | — |
data.status | object | — |
data.status.id | string | null | Workflow status id of the underlying work item. |
data.status.name | string | null | — |
data.status.intent | "todo" | "working" | "for_review" | "done" | "cancelled" | Workspace state: todo, working, for_review, done or cancelled. Each maps to a status of the task's own workflow. |
data.due_date | string | null | — |
data.objective_id | string | null | — |
data.acceptance_criteria | string | null | — |
data.owner | object | null | The member who owns the task. |
data.worker | object | null | The agent doing the work, if one is assigned. |
data.reviewer | object | null | — |
data.parent_task_id | string | null | — |
data.depends_on | string[] | Ids of tasks that must finish first. |
data.now_doing | string | null | One line on what the worker is doing now. |
data.input_needed | boolean | An agent is waiting on a person for this task. |
data.start_when_unblocked | boolean | — |
data.review_round | integer | — |
data.tags | string[] | — |
data.work_item | object | The same task as a record in the records API. |
data.work_item.object_type | "work-items" | — |
data.work_item.record_id | string | — |
data.work_item.work_item_type_id | string | — |
data.created_at | string | null | — |
data.updated_at | string | null | — |
Examples
curl https://api.preshos.com/v1/team-workspaces/<workspace_id>/tasks/<task_id> \
-H "Authorization: Bearer $PRESHOS_API_KEY"{
"data": {
"id": "5b0e6f3a-2d0c-4c0a-9a65-1f2f4a7c9d10",
"key": "PW-12",
"title": "Draft the launch page copy",
"description": "Hero, three benefit sections and the pricing teaser.",
"status": {
"id": "wf-task-working",
"name": "Working",
"intent": "working"
},
"due_date": "2026-12-04T00:00:00.000Z",
"objective_id": "0f6f8f2e-7a31-4a52-8c44-8b7c2f2f6a01",
"acceptance_criteria": "Reads in under two minutes; every claim has a source.",
"owner": {
"user_id": 23,
"name": "Sam Rivera"
},
"worker": {
"agent_seat_id": "9d2b7e10-4b1f-4e0c-b2a3-6f5d0c1a2b3c",
"kind": "member_agent",
"name": "Sam's agent"
},
"reviewer": {
"type": "user",
"agent_seat_id": null,
"user_id": 17,
"name": "Jordan Lee"
},
"parent_task_id": null,
"depends_on": [],
"now_doing": "Writing the benefits section",
"input_needed": false,
"start_when_unblocked": false,
"review_round": 0,
"tags": [
"launch"
],
"work_item": {
"object_type": "work-items",
"record_id": "48213",
"work_item_type_id": "task"
},
"created_at": "2026-11-15T14:02:11.000Z",
"updated_at": "2026-11-15T16:40:02.000Z"
}
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Update a workspace task
updateTeamWorkspaceTask/v1/team-workspaces/{workspace_id}/tasks/{task_id}Changes a task's title, description, due date, objective or acceptance criteria. Only the fields you send change. Use the status and assign endpoints for those changes.
- Scopes
team_workspaces:write- Behavior
- Changes dataIdempotent
Path parameters
| Name | Type | Description |
|---|---|---|
workspace_idrequired | string1–64 chars | Team workspace id, from GET /team-workspaces. |
task_idrequired | string1–64 chars | Task id, or its display key such as PW-12. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Content-Typerequired | string | application/json. |
Request bodyapplication/json · required
| Field | Type | Description |
|---|---|---|
title | string1–300 chars | — |
description | string | null | — |
due_date | string | null | — |
objective_id | string | null | — |
acceptance_criteria | string | null | — |
JSON Schema
{
"type": "object",
"properties": {
"title": {
"type": "string",
"minLength": 1,
"maxLength": 300
},
"description": {
"anyOf": [
{
"type": "string",
"maxLength": 20000
},
{
"type": "null"
}
]
},
"due_date": {
"anyOf": [
{
"type": "string",
"pattern": "^\\d{4}-\\d{2}-\\d{2}$"
},
{
"type": "null"
}
]
},
"objective_id": {
"anyOf": [
{
"type": "string",
"format": "uuid",
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
},
{
"type": "null"
}
]
},
"acceptance_criteria": {
"anyOf": [
{
"type": "string",
"maxLength": 8000
},
{
"type": "null"
}
]
}
},
"additionalProperties": false
}Response200
The updated task.
| Field | Type | Description |
|---|---|---|
data | object | — |
data.id | string | — |
data.key | string | Display key, as in PW-12. |
data.title | string | — |
data.description | string | null | — |
data.status | object | — |
data.status.id | string | null | Workflow status id of the underlying work item. |
data.status.name | string | null | — |
data.status.intent | "todo" | "working" | "for_review" | "done" | "cancelled" | Workspace state: todo, working, for_review, done or cancelled. Each maps to a status of the task's own workflow. |
data.due_date | string | null | — |
data.objective_id | string | null | — |
data.acceptance_criteria | string | null | — |
data.owner | object | null | The member who owns the task. |
data.worker | object | null | The agent doing the work, if one is assigned. |
data.reviewer | object | null | — |
data.parent_task_id | string | null | — |
data.depends_on | string[] | Ids of tasks that must finish first. |
data.now_doing | string | null | One line on what the worker is doing now. |
data.input_needed | boolean | An agent is waiting on a person for this task. |
data.start_when_unblocked | boolean | — |
data.review_round | integer | — |
data.tags | string[] | — |
data.work_item | object | The same task as a record in the records API. |
data.work_item.object_type | "work-items" | — |
data.work_item.record_id | string | — |
data.work_item.work_item_type_id | string | — |
data.created_at | string | null | — |
data.updated_at | string | null | — |
Examples
curl -X PATCH https://api.preshos.com/v1/team-workspaces/<workspace_id>/tasks/<task_id> \
-H "Authorization: Bearer $PRESHOS_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"due_date": "2026-12-08"
}'{
"due_date": "2026-12-08"
}{
"data": {
"id": "5b0e6f3a-2d0c-4c0a-9a65-1f2f4a7c9d10",
"key": "PW-12",
"title": "Draft the launch page copy",
"description": "Hero, three benefit sections and the pricing teaser.",
"status": {
"id": "wf-task-working",
"name": "Working",
"intent": "working"
},
"due_date": "2026-12-08T00:00:00.000Z",
"objective_id": "0f6f8f2e-7a31-4a52-8c44-8b7c2f2f6a01",
"acceptance_criteria": "Reads in under two minutes; every claim has a source.",
"owner": {
"user_id": 23,
"name": "Sam Rivera"
},
"worker": {
"agent_seat_id": "9d2b7e10-4b1f-4e0c-b2a3-6f5d0c1a2b3c",
"kind": "member_agent",
"name": "Sam's agent"
},
"reviewer": {
"type": "user",
"agent_seat_id": null,
"user_id": 17,
"name": "Jordan Lee"
},
"parent_task_id": null,
"depends_on": [],
"now_doing": "Writing the benefits section",
"input_needed": false,
"start_when_unblocked": false,
"review_round": 0,
"tags": [
"launch"
],
"work_item": {
"object_type": "work-items",
"record_id": "48213",
"work_item_type_id": "task"
},
"created_at": "2026-11-15T14:02:11.000Z",
"updated_at": "2026-11-15T16:40:02.000Z"
}
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 400 | Invalid request: malformed JSON, failed validation, or an invalid filter/cursor. | invalid_json, validation_failed |
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported, write_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
| 409 | Conflict, e.g. an Idempotency-Key request still in progress or a uniqueness violation. | conflict |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Change a workspace task's status
setTeamWorkspaceTaskStatus/v1/team-workspaces/{workspace_id}/tasks/{task_id}/statusMoves a task to one of the five workspace states, or to one of its own workflow's statuses by status_id (the ids are in each task's status.id). A state is mapped to a status of the task's own workflow. Either way the change behaves exactly like one made on the board, including any review the workspace requires. Send one of status and status_id.
- Scopes
team_workspaces:write- Behavior
- Changes dataIdempotentIdempotency-Key
Path parameters
| Name | Type | Description |
|---|---|---|
workspace_idrequired | string1–64 chars | Team workspace id, from GET /team-workspaces. |
task_idrequired | string1–64 chars | Task id, or its display key such as PW-12. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Content-Typerequired | string | application/json. |
Idempotency-Key | stringmax 255 chars | Unique key (1–255 visible ASCII characters, e.g. a UUID). Retrying with the same key and body replays the first successful response for 24 hours. |
Request bodyapplication/json · required
| Field | Type | Description |
|---|---|---|
status | "todo" | "working" | "for_review" | "done" | "cancelled" | Workspace state: todo, working, for_review, done or cancelled. Each maps to a status of the task's own workflow. |
status_id | string1–120 chars | A status of the task's own workflow. |
JSON Schema
{
"type": "object",
"properties": {
"status": {
"type": "string",
"enum": [
"todo",
"working",
"for_review",
"done",
"cancelled"
],
"description": "Workspace state: `todo`, `working`, `for_review`, `done` or `cancelled`. Each maps to a status of the task's own workflow."
},
"status_id": {
"type": "string",
"minLength": 1,
"maxLength": 120,
"description": "A status of the task's own workflow."
}
},
"additionalProperties": false
}Response200
The task after the change.
| Field | Type | Description |
|---|---|---|
data | object | — |
data.id | string | — |
data.key | string | Display key, as in PW-12. |
data.title | string | — |
data.description | string | null | — |
data.status | object | — |
data.status.id | string | null | Workflow status id of the underlying work item. |
data.status.name | string | null | — |
data.status.intent | "todo" | "working" | "for_review" | "done" | "cancelled" | Workspace state: todo, working, for_review, done or cancelled. Each maps to a status of the task's own workflow. |
data.due_date | string | null | — |
data.objective_id | string | null | — |
data.acceptance_criteria | string | null | — |
data.owner | object | null | The member who owns the task. |
data.worker | object | null | The agent doing the work, if one is assigned. |
data.reviewer | object | null | — |
data.parent_task_id | string | null | — |
data.depends_on | string[] | Ids of tasks that must finish first. |
data.now_doing | string | null | One line on what the worker is doing now. |
data.input_needed | boolean | An agent is waiting on a person for this task. |
data.start_when_unblocked | boolean | — |
data.review_round | integer | — |
data.tags | string[] | — |
data.work_item | object | The same task as a record in the records API. |
data.work_item.object_type | "work-items" | — |
data.work_item.record_id | string | — |
data.work_item.work_item_type_id | string | — |
data.created_at | string | null | — |
data.updated_at | string | null | — |
changed | boolean | False when the task was already in that state. |
Examples
curl -X POST https://api.preshos.com/v1/team-workspaces/<workspace_id>/tasks/<task_id>/status \
-H "Authorization: Bearer $PRESHOS_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: $(uuidgen)" \
-d '{
"status": "for_review"
}'{
"status": "for_review"
}{
"data": {
"id": "5b0e6f3a-2d0c-4c0a-9a65-1f2f4a7c9d10",
"key": "PW-12",
"title": "Draft the launch page copy",
"description": "Hero, three benefit sections and the pricing teaser.",
"status": {
"id": "wf-task-review",
"name": "For review",
"intent": "for_review"
},
"due_date": "2026-12-04T00:00:00.000Z",
"objective_id": "0f6f8f2e-7a31-4a52-8c44-8b7c2f2f6a01",
"acceptance_criteria": "Reads in under two minutes; every claim has a source.",
"owner": {
"user_id": 23,
"name": "Sam Rivera"
},
"worker": {
"agent_seat_id": "9d2b7e10-4b1f-4e0c-b2a3-6f5d0c1a2b3c",
"kind": "member_agent",
"name": "Sam's agent"
},
"reviewer": {
"type": "user",
"agent_seat_id": null,
"user_id": 17,
"name": "Jordan Lee"
},
"parent_task_id": null,
"depends_on": [],
"now_doing": "Writing the benefits section",
"input_needed": false,
"start_when_unblocked": false,
"review_round": 0,
"tags": [
"launch"
],
"work_item": {
"object_type": "work-items",
"record_id": "48213",
"work_item_type_id": "task"
},
"created_at": "2026-11-15T14:02:11.000Z",
"updated_at": "2026-11-15T16:40:02.000Z"
},
"changed": true
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 400 | Invalid request: malformed JSON, failed validation, or an invalid filter/cursor. | invalid_json, validation_failed |
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported, write_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
| 409 | Conflict, e.g. an Idempotency-Key request still in progress or a uniqueness violation. | conflict, idempotency_key_in_use |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Assign a workspace task
assignTeamWorkspaceTask/v1/team-workspaces/{workspace_id}/tasks/{task_id}/assignAssigns a task to a member, to an agent in the workspace, or both. Assigning to an agent starts its work. A member decides how assignments to them and their agent are accepted: when they have chosen to be asked, or are at capacity, nothing is assigned yet, needs_acceptance is true, and they receive the proposal in the app.
- Scopes
team_workspaces:write- Behavior
- Changes dataNot idempotentIdempotency-Key
Path parameters
| Name | Type | Description |
|---|---|---|
workspace_idrequired | string1–64 chars | Team workspace id, from GET /team-workspaces. |
task_idrequired | string1–64 chars | Task id, or its display key such as PW-12. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Content-Typerequired | string | application/json. |
Idempotency-Key | stringmax 255 chars | Unique key (1–255 visible ASCII characters, e.g. a UUID). Retrying with the same key and body replays the first successful response for 24 hours. |
Request bodyapplication/json · required
| Field | Type | Description |
|---|---|---|
owner_user_id | integer | null | The member who owns the task. null clears the owner. |
agent_seat_id | string | null | The agent to do the work, from the workspace's agents. null clears it. |
JSON Schema
{
"type": "object",
"properties": {
"owner_user_id": {
"anyOf": [
{
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 9007199254740991
},
{
"type": "null"
}
],
"description": "The member who owns the task. `null` clears the owner."
},
"agent_seat_id": {
"anyOf": [
{
"type": "string",
"format": "uuid",
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
},
{
"type": "null"
}
],
"description": "The agent to do the work, from the workspace's `agents`. `null` clears it."
}
},
"additionalProperties": false
}Response200
The task, and whether the assignment is waiting for acceptance.
| Field | Type | Description |
|---|---|---|
data | object | — |
data.id | string | — |
data.key | string | Display key, as in PW-12. |
data.title | string | — |
data.description | string | null | — |
data.status | object | — |
data.status.id | string | null | Workflow status id of the underlying work item. |
data.status.name | string | null | — |
data.status.intent | "todo" | "working" | "for_review" | "done" | "cancelled" | Workspace state: todo, working, for_review, done or cancelled. Each maps to a status of the task's own workflow. |
data.due_date | string | null | — |
data.objective_id | string | null | — |
data.acceptance_criteria | string | null | — |
data.owner | object | null | The member who owns the task. |
data.worker | object | null | The agent doing the work, if one is assigned. |
data.reviewer | object | null | — |
data.parent_task_id | string | null | — |
data.depends_on | string[] | Ids of tasks that must finish first. |
data.now_doing | string | null | One line on what the worker is doing now. |
data.input_needed | boolean | An agent is waiting on a person for this task. |
data.start_when_unblocked | boolean | — |
data.review_round | integer | — |
data.tags | string[] | — |
data.work_item | object | The same task as a record in the records API. |
data.work_item.object_type | "work-items" | — |
data.work_item.record_id | string | — |
data.work_item.work_item_type_id | string | — |
data.created_at | string | null | — |
data.updated_at | string | null | — |
needs_acceptance | boolean | — |
needs_acceptance_from_user_id | integer | null | — |
Examples
curl -X POST https://api.preshos.com/v1/team-workspaces/<workspace_id>/tasks/<task_id>/assign \
-H "Authorization: Bearer $PRESHOS_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: $(uuidgen)" \
-d '{
"agent_seat_id": "9d2b7e10-4b1f-4e0c-b2a3-6f5d0c1a2b3c"
}'{
"agent_seat_id": "9d2b7e10-4b1f-4e0c-b2a3-6f5d0c1a2b3c"
}{
"data": {
"id": "5b0e6f3a-2d0c-4c0a-9a65-1f2f4a7c9d10",
"key": "PW-12",
"title": "Draft the launch page copy",
"description": "Hero, three benefit sections and the pricing teaser.",
"status": {
"id": "wf-task-working",
"name": "Working",
"intent": "working"
},
"due_date": "2026-12-04T00:00:00.000Z",
"objective_id": "0f6f8f2e-7a31-4a52-8c44-8b7c2f2f6a01",
"acceptance_criteria": "Reads in under two minutes; every claim has a source.",
"owner": {
"user_id": 23,
"name": "Sam Rivera"
},
"worker": {
"agent_seat_id": "9d2b7e10-4b1f-4e0c-b2a3-6f5d0c1a2b3c",
"kind": "member_agent",
"name": "Sam's agent"
},
"reviewer": {
"type": "user",
"agent_seat_id": null,
"user_id": 17,
"name": "Jordan Lee"
},
"parent_task_id": null,
"depends_on": [],
"now_doing": "Writing the benefits section",
"input_needed": false,
"start_when_unblocked": false,
"review_round": 0,
"tags": [
"launch"
],
"work_item": {
"object_type": "work-items",
"record_id": "48213",
"work_item_type_id": "task"
},
"created_at": "2026-11-15T14:02:11.000Z",
"updated_at": "2026-11-15T16:40:02.000Z"
},
"needs_acceptance": false,
"needs_acceptance_from_user_id": null
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 400 | Invalid request: malformed JSON, failed validation, or an invalid filter/cursor. | invalid_json, validation_failed |
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported, write_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
| 409 | Conflict, e.g. an Idempotency-Key request still in progress or a uniqueness violation. | conflict, idempotency_key_in_use |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
List a workspace's objectives
listTeamWorkspaceObjectives/v1/team-workspaces/{workspace_id}/objectivesReturns the workspace's objectives in their board order, each with its status, measure and target date.
- Scopes
team_workspaces:read- Behavior
- Read-onlyIdempotent
Path parameters
| Name | Type | Description |
|---|---|---|
workspace_idrequired | string1–64 chars | Team workspace id, from GET /team-workspaces. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Response200
The objectives.
| Field | Type | Description |
|---|---|---|
data | object[] | — |
data[].id | string | — |
data[].title | string | — |
data[].description | string | null | — |
data[].measure | string | null | How the objective will be measured. |
data[].target_date | string | null | — |
data[].owner_user_id | integer | null | — |
data[].status | "on_track" | "at_risk" | "off_track" | "done" | string | — |
data[].position | integer | — |
data[].created_at | string | null | — |
data[].updated_at | string | null | — |
Examples
curl https://api.preshos.com/v1/team-workspaces/<workspace_id>/objectives \
-H "Authorization: Bearer $PRESHOS_API_KEY"{
"data": [
{
"id": "0f6f8f2e-7a31-4a52-8c44-8b7c2f2f6a01",
"title": "Launch the spring product page",
"description": null,
"measure": "Page live and linked from the home page",
"target_date": "2026-12-10",
"owner_user_id": 23,
"status": "on_track",
"position": 0,
"created_at": "2026-11-15T13:00:00.000Z",
"updated_at": "2026-11-15T13:00:00.000Z"
}
]
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Create a workspace objective
createTeamWorkspaceObjective/v1/team-workspaces/{workspace_id}/objectivesAdds an objective to the workspace. You own it unless you name another member as owner.
- Scopes
team_workspaces:write- Behavior
- Changes dataNot idempotentIdempotency-Key
Path parameters
| Name | Type | Description |
|---|---|---|
workspace_idrequired | string1–64 chars | Team workspace id, from GET /team-workspaces. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Content-Typerequired | string | application/json. |
Idempotency-Key | stringmax 255 chars | Unique key (1–255 visible ASCII characters, e.g. a UUID). Retrying with the same key and body replays the first successful response for 24 hours. |
Request bodyapplication/json · required
| Field | Type | Description |
|---|---|---|
titlerequired | string1–200 chars | — |
description | string | null | — |
measure | string | null | How you will know it is met. |
target_date | string | null | — |
owner_user_id | integer | null | — |
JSON Schema
{
"type": "object",
"properties": {
"title": {
"type": "string",
"minLength": 1,
"maxLength": 200
},
"description": {
"anyOf": [
{
"type": "string",
"maxLength": 4000
},
{
"type": "null"
}
]
},
"measure": {
"anyOf": [
{
"type": "string",
"maxLength": 1000
},
{
"type": "null"
}
],
"description": "How you will know it is met."
},
"target_date": {
"anyOf": [
{
"type": "string",
"pattern": "^\\d{4}-\\d{2}-\\d{2}$"
},
{
"type": "null"
}
]
},
"owner_user_id": {
"anyOf": [
{
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 9007199254740991
},
{
"type": "null"
}
]
}
},
"required": [
"title"
],
"additionalProperties": false
}Response201
The created objective.
| Field | Type | Description |
|---|---|---|
data | object | — |
data.id | string | — |
data.title | string | — |
data.description | string | null | — |
data.measure | string | null | How the objective will be measured. |
data.target_date | string | null | — |
data.owner_user_id | integer | null | — |
data.status | "on_track" | "at_risk" | "off_track" | "done" | string | — |
data.position | integer | — |
data.created_at | string | null | — |
data.updated_at | string | null | — |
Examples
curl -X POST https://api.preshos.com/v1/team-workspaces/<workspace_id>/objectives \
-H "Authorization: Bearer $PRESHOS_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: $(uuidgen)" \
-d '{
"title": "Launch the spring product page",
"measure": "Page live and linked from the home page",
"target_date": "2026-12-10"
}'{
"title": "Launch the spring product page",
"measure": "Page live and linked from the home page",
"target_date": "2026-12-10"
}{
"data": {
"id": "0f6f8f2e-7a31-4a52-8c44-8b7c2f2f6a01",
"title": "Launch the spring product page",
"description": null,
"measure": "Page live and linked from the home page",
"target_date": "2026-12-10",
"owner_user_id": 23,
"status": "on_track",
"position": 0,
"created_at": "2026-11-15T13:00:00.000Z",
"updated_at": "2026-11-15T13:00:00.000Z"
}
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 400 | Invalid request: malformed JSON, failed validation, or an invalid filter/cursor. | invalid_json, validation_failed |
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported, write_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
| 409 | Conflict, e.g. an Idempotency-Key request still in progress or a uniqueness violation. | conflict, idempotency_key_in_use |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Update a workspace objective
updateTeamWorkspaceObjective/v1/team-workspaces/{workspace_id}/objectives/{objective_id}Changes an objective's title, description, measure, target date, owner or status. Only the workspace owner or the objective's own owner may change it. Setting status is your own call and clears any status an agent proposed.
- Scopes
team_workspaces:write- Behavior
- Changes dataIdempotent
Path parameters
| Name | Type | Description |
|---|---|---|
workspace_idrequired | string1–64 chars | Team workspace id, from GET /team-workspaces. |
objective_idrequired | string1–64 chars | Objective id. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Content-Typerequired | string | application/json. |
Request bodyapplication/json · required
| Field | Type | Description |
|---|---|---|
title | string1–200 chars | — |
description | string | null | — |
measure | string | null | — |
target_date | string | null | — |
owner_user_id | integer | — |
status | "on_track" | "at_risk" | "off_track" | "done" | — |
JSON Schema
{
"type": "object",
"properties": {
"title": {
"type": "string",
"minLength": 1,
"maxLength": 200
},
"description": {
"anyOf": [
{
"type": "string",
"maxLength": 4000
},
{
"type": "null"
}
]
},
"measure": {
"anyOf": [
{
"type": "string",
"maxLength": 1000
},
{
"type": "null"
}
]
},
"target_date": {
"anyOf": [
{
"type": "string",
"pattern": "^\\d{4}-\\d{2}-\\d{2}$"
},
{
"type": "null"
}
]
},
"owner_user_id": {
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 9007199254740991
},
"status": {
"type": "string",
"enum": [
"on_track",
"at_risk",
"off_track",
"done"
]
}
},
"additionalProperties": false
}Response200
The updated objective.
| Field | Type | Description |
|---|---|---|
data | object | — |
data.id | string | — |
data.title | string | — |
data.description | string | null | — |
data.measure | string | null | How the objective will be measured. |
data.target_date | string | null | — |
data.owner_user_id | integer | null | — |
data.status | "on_track" | "at_risk" | "off_track" | "done" | string | — |
data.position | integer | — |
data.created_at | string | null | — |
data.updated_at | string | null | — |
Examples
curl -X PATCH https://api.preshos.com/v1/team-workspaces/<workspace_id>/objectives/<objective_id> \
-H "Authorization: Bearer $PRESHOS_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"status": "at_risk"
}'{
"status": "at_risk"
}{
"data": {
"id": "0f6f8f2e-7a31-4a52-8c44-8b7c2f2f6a01",
"title": "Launch the spring product page",
"description": null,
"measure": "Page live and linked from the home page",
"target_date": "2026-12-10",
"owner_user_id": 23,
"status": "at_risk",
"position": 0,
"created_at": "2026-11-15T13:00:00.000Z",
"updated_at": "2026-11-15T13:00:00.000Z"
}
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 400 | Invalid request: malformed JSON, failed validation, or an invalid filter/cursor. | invalid_json, validation_failed |
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported, write_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
List the shared thread
listTeamWorkspaceThread/v1/team-workspaces/{workspace_id}/threadReturns the workspace's shared thread, newest first: posts by people and by agents, and cards for events such as plan proposals and review outcomes (a card carries only its type). Pass next_cursor as cursor to page back in time.
- Scopes
team_workspaces:read- Behavior
- Read-onlyIdempotent
Path parameters
| Name | Type | Description |
|---|---|---|
workspace_idrequired | string1–64 chars | Team workspace id, from GET /team-workspaces. |
Query parameters
| Name | Type | Description |
|---|---|---|
limit | integer1–100 · default: 50 | — |
cursor | stringmax 64 chars | next_cursor from the previous page. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Response200
A page of posts.
| Field | Type | Description |
|---|---|---|
data | object[] | — |
data[].id | string | — |
data[].type | "post" | "card" | card is an event shown in the thread (a plan proposal, a review outcome); its content stays in the app. |
data[].body | string | — |
data[].card_type | string | null | — |
data[].author | object | — |
data[].author.type | "user" | "agent" | "system" | — |
data[].author.user_id | integer | null | — |
data[].author.agent_seat_id | string | null | — |
data[].author.name | string | null | — |
data[].author.acting_for_user_id | integer | null | For an agent post: the member it was written for. |
data[].addressed | object | — |
data[].addressed.user_ids | integer[] | — |
data[].addressed.agent_seat_ids | string[] | — |
data[].addressed.lead | boolean | — |
data[].reply_to_id | string | null | — |
data[].state | string | posted, or for a post addressed to an agent: queued, answered, declined or failed. |
data[].created_at | string | — |
data[].edited_at | string | null | — |
pagination | — |
Examples
curl https://api.preshos.com/v1/team-workspaces/<workspace_id>/thread \
-H "Authorization: Bearer $PRESHOS_API_KEY"{
"data": [
{
"id": "7c1f0d5e-90a4-4f6b-8c3d-2e1a0b9c8d7e",
"type": "post",
"body": "Keep 3 March. The annual plan moves to phase two.",
"card_type": null,
"author": {
"type": "user",
"user_id": 23,
"agent_seat_id": null,
"name": "Sam Rivera",
"acting_for_user_id": null
},
"addressed": {
"user_ids": [],
"agent_seat_ids": [],
"lead": false
},
"reply_to_id": null,
"state": "posted",
"created_at": "2026-11-15T16:45:00.000Z",
"edited_at": null
}
],
"pagination": {
"limit": 50,
"has_more": false,
"next_cursor": null
}
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 400 | Invalid request: malformed JSON, failed validation, or an invalid filter/cursor. | validation_failed, invalid_cursor |
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Post to the shared thread
postToTeamWorkspaceThread/v1/team-workspaces/{workspace_id}/threadPosts in the workspace's shared thread as you. Mention people to notify them, or address agents by their agent_seat_id (or the lead) to ask them to answer; addressed agents reply in the thread. Fails with permission_denied when the workspace has the shared thread turned off.
- Scopes
team_workspaces:write- Behavior
- Changes dataNot idempotentIdempotency-Key
Path parameters
| Name | Type | Description |
|---|---|---|
workspace_idrequired | string1–64 chars | Team workspace id, from GET /team-workspaces. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Content-Typerequired | string | application/json. |
Idempotency-Key | stringmax 255 chars | Unique key (1–255 visible ASCII characters, e.g. a UUID). Retrying with the same key and body replays the first successful response for 24 hours. |
Request bodyapplication/json · required
| Field | Type | Description |
|---|---|---|
bodyrequired | string1–20000 chars | Plain text or Markdown. |
reply_to_id | string | null | The post this replies to. |
mention_user_ids | integer[]max 20 items | Members to notify. |
mention_agent_seat_ids | string[]max 10 items | Agents asked to answer. |
mention_lead | boolean | Ask the workspace lead to answer. |
JSON Schema
{
"type": "object",
"properties": {
"body": {
"type": "string",
"minLength": 1,
"maxLength": 20000,
"description": "Plain text or Markdown."
},
"reply_to_id": {
"anyOf": [
{
"type": "string",
"format": "uuid",
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
},
{
"type": "null"
}
],
"description": "The post this replies to."
},
"mention_user_ids": {
"maxItems": 20,
"type": "array",
"items": {
"type": "integer",
"exclusiveMinimum": 0,
"maximum": 9007199254740991
},
"description": "Members to notify."
},
"mention_agent_seat_ids": {
"maxItems": 10,
"type": "array",
"items": {
"type": "string",
"format": "uuid",
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
},
"description": "Agents asked to answer."
},
"mention_lead": {
"type": "boolean",
"description": "Ask the workspace lead to answer."
}
},
"required": [
"body"
],
"additionalProperties": false
}Response201
The post, and which agents were asked to answer it.
| Field | Type | Description |
|---|---|---|
data | object | — |
data.id | string | — |
data.type | "post" | "card" | card is an event shown in the thread (a plan proposal, a review outcome); its content stays in the app. |
data.body | string | — |
data.card_type | string | null | — |
data.author | object | — |
data.author.type | "user" | "agent" | "system" | — |
data.author.user_id | integer | null | — |
data.author.agent_seat_id | string | null | — |
data.author.name | string | null | — |
data.author.acting_for_user_id | integer | null | For an agent post: the member it was written for. |
data.addressed | object | — |
data.addressed.user_ids | integer[] | — |
data.addressed.agent_seat_ids | string[] | — |
data.addressed.lead | boolean | — |
data.reply_to_id | string | null | — |
data.state | string | posted, or for a post addressed to an agent: queued, answered, declined or failed. |
data.created_at | string | — |
data.edited_at | string | null | — |
asked_agent_seat_ids | string[] | — |
Examples
curl -X POST https://api.preshos.com/v1/team-workspaces/<workspace_id>/thread \
-H "Authorization: Bearer $PRESHOS_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: $(uuidgen)" \
-d '{
"body": "Can pricing be ready by 3 March?",
"mention_agent_seat_ids": [
"9d2b7e10-4b1f-4e0c-b2a3-6f5d0c1a2b3c"
]
}'{
"body": "Can pricing be ready by 3 March?",
"mention_agent_seat_ids": [
"9d2b7e10-4b1f-4e0c-b2a3-6f5d0c1a2b3c"
]
}{
"data": {
"id": "7c1f0d5e-90a4-4f6b-8c3d-2e1a0b9c8d7e",
"type": "post",
"body": "Can pricing be ready by 3 March?",
"card_type": null,
"author": {
"type": "user",
"user_id": 23,
"agent_seat_id": null,
"name": "Sam Rivera",
"acting_for_user_id": null
},
"addressed": {
"user_ids": [],
"agent_seat_ids": [
"9d2b7e10-4b1f-4e0c-b2a3-6f5d0c1a2b3c"
],
"lead": false
},
"reply_to_id": null,
"state": "queued",
"created_at": "2026-11-15T16:45:00.000Z",
"edited_at": null
},
"asked_agent_seat_ids": [
"9d2b7e10-4b1f-4e0c-b2a3-6f5d0c1a2b3c"
]
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 400 | Invalid request: malformed JSON, failed validation, or an invalid filter/cursor. | invalid_json, validation_failed |
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported, write_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
List questions waiting on you
listTeamWorkspaceQuestions/v1/team-workspaces/{workspace_id}/questionsReturns the open questions agents in this workspace have addressed to you. An agent that asked is waiting; answering lets its work continue. Questions addressed to other members are not listed.
- Scopes
team_workspaces:read- Behavior
- Read-onlyIdempotent
Path parameters
| Name | Type | Description |
|---|---|---|
workspace_idrequired | string1–64 chars | Team workspace id, from GET /team-workspaces. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Response200
Your open questions.
| Field | Type | Description |
|---|---|---|
data | object[] | — |
data[].id | string | — |
data[].question | string | — |
data[].options | string[] | — |
data[].task_id | string | null | — |
data[].asked_by_agent_seat_id | string | null | — |
data[].to_user_id | integer | — |
data[].state | string | — |
data[].answer | string | null | — |
data[].deadline_at | string | null | — |
data[].created_at | string | null | — |
data[].answered_at | string | null | — |
Examples
curl https://api.preshos.com/v1/team-workspaces/<workspace_id>/questions \
-H "Authorization: Bearer $PRESHOS_API_KEY"{
"data": [
{
"id": "c0d1e2f3-a4b5-4c6d-8e7f-9a0b1c2d3e4f",
"question": "Which currency should the pricing table lead with?",
"options": [
"USD",
"EUR"
],
"task_id": "5b0e6f3a-2d0c-4c0a-9a65-1f2f4a7c9d10",
"asked_by_agent_seat_id": "9d2b7e10-4b1f-4e0c-b2a3-6f5d0c1a2b3c",
"to_user_id": 23,
"state": "open",
"answer": null,
"deadline_at": "2026-11-16T16:45:00.000Z",
"created_at": "2026-11-15T16:45:00.000Z",
"answered_at": null
}
]
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Answer a question
answerTeamWorkspaceQuestion/v1/team-workspaces/{workspace_id}/questions/{question_id}/answerAnswers a question an agent addressed to you (the workspace owner may answer any). The waiting agent continues with your answer. A question that is already closed returns conflict.
- Scopes
team_workspaces:write- Behavior
- Changes dataNot idempotentIdempotency-Key
Path parameters
| Name | Type | Description |
|---|---|---|
workspace_idrequired | string1–64 chars | Team workspace id, from GET /team-workspaces. |
question_idrequired | string1–64 chars | Question id. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Content-Typerequired | string | application/json. |
Idempotency-Key | stringmax 255 chars | Unique key (1–255 visible ASCII characters, e.g. a UUID). Retrying with the same key and body replays the first successful response for 24 hours. |
Request bodyapplication/json · required
| Field | Type | Description |
|---|---|---|
answerrequired | string1–8000 chars | — |
JSON Schema
{
"type": "object",
"properties": {
"answer": {
"type": "string",
"minLength": 1,
"maxLength": 8000
}
},
"required": [
"answer"
],
"additionalProperties": false
}Response200
The answered question.
| Field | Type | Description |
|---|---|---|
data | object | — |
data.id | string | — |
data.question | string | — |
data.options | string[] | — |
data.task_id | string | null | — |
data.asked_by_agent_seat_id | string | null | — |
data.to_user_id | integer | — |
data.state | string | — |
data.answer | string | null | — |
data.deadline_at | string | null | — |
data.created_at | string | null | — |
data.answered_at | string | null | — |
Examples
curl -X POST https://api.preshos.com/v1/team-workspaces/<workspace_id>/questions/<question_id>/answer \
-H "Authorization: Bearer $PRESHOS_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: $(uuidgen)" \
-d '{
"answer": "USD"
}'{
"answer": "USD"
}{
"data": {
"id": "c0d1e2f3-a4b5-4c6d-8e7f-9a0b1c2d3e4f",
"question": "Which currency should the pricing table lead with?",
"options": [
"USD",
"EUR"
],
"task_id": "5b0e6f3a-2d0c-4c0a-9a65-1f2f4a7c9d10",
"asked_by_agent_seat_id": "9d2b7e10-4b1f-4e0c-b2a3-6f5d0c1a2b3c",
"to_user_id": 23,
"state": "answered",
"answer": "USD",
"deadline_at": "2026-11-16T16:45:00.000Z",
"created_at": "2026-11-15T16:45:00.000Z",
"answered_at": "2026-11-15T17:01:20.000Z"
}
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 400 | Invalid request: malformed JSON, failed validation, or an invalid filter/cursor. | invalid_json, validation_failed |
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported, write_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
| 409 | Conflict, e.g. an Idempotency-Key request still in progress or a uniqueness violation. | conflict, idempotency_key_in_use |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
List a workspace's live documents
listTeamWorkspaceDocuments/v1/team-workspaces/{workspace_id}/documentsReturns the live pages, decks and sheets people and agents edit together in this workspace: metadata only. Available when live documents are turned on for the workspace's tenant; otherwise 404.
- Scopes
team_workspaces:read- Behavior
- Read-onlyIdempotent
Path parameters
| Name | Type | Description |
|---|---|---|
workspace_idrequired | string1–64 chars | Team workspace id, from GET /team-workspaces. |
Query parameters
| Name | Type | Description |
|---|---|---|
kind | "page" | "deck" | "sheet" | — |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Response200
The live documents.
| Field | Type | Description |
|---|---|---|
data | object[] | — |
data[].id | string | — |
data[].kind | "page" | "deck" | "sheet" | string | — |
data[].title | string | — |
data[].task_id | string | null | — |
data[].created_at | string | null | — |
data[].updated_at | string | null | — |
Examples
curl https://api.preshos.com/v1/team-workspaces/<workspace_id>/documents \
-H "Authorization: Bearer $PRESHOS_API_KEY"{
"data": [
{
"id": "a1b2c3d4-e5f6-4a7b-8c9d-0e1f2a3b4c5d",
"kind": "page",
"title": "Launch brief",
"task_id": null,
"created_at": "2026-11-15T13:10:00.000Z",
"updated_at": "2026-11-15T16:52:00.000Z"
}
]
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 400 | Invalid request: malformed JSON, failed validation, or an invalid filter/cursor. | validation_failed |
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Export a live document
exportTeamWorkspaceDocument/v1/team-workspaces/{workspace_id}/documents/{document_id}/exportReturns a live document's current content: a page as Markdown, one tab of a sheet as CSV (tab picks it; the first tab otherwise), and a deck as presentation source JSON. Read only: live editing happens in the app.
- Scopes
team_workspaces:read- Behavior
- Read-onlyIdempotent
Path parameters
| Name | Type | Description |
|---|---|---|
workspace_idrequired | string1–64 chars | Team workspace id, from GET /team-workspaces. |
document_idrequired | string1–64 chars | Live document id. |
Query parameters
| Name | Type | Description |
|---|---|---|
tab | stringmax 120 chars | For a sheet: the tab id or name. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Response200
The document content.
| Field | Type | Description |
|---|---|---|
data | object | — |
data.id | string | — |
data.kind | string | — |
data.title | string | — |
data.format | "markdown" | "csv" | "presentation_json" | — |
data.filename | string | A suggested file name. |
data.content | any | A string for markdown and csv; an object for presentation_json. |
Examples
curl https://api.preshos.com/v1/team-workspaces/<workspace_id>/documents/<document_id>/export \
-H "Authorization: Bearer $PRESHOS_API_KEY"{
"data": {
"id": "a1b2c3d4-e5f6-4a7b-8c9d-0e1f2a3b4c5d",
"kind": "page",
"title": "Launch brief",
"format": "markdown",
"filename": "Launch brief.md",
"content": "# Launch brief\n\nShip the spring product page.\n"
}
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 400 | Invalid request: malformed JSON, failed validation, or an invalid filter/cursor. | validation_failed |
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Eval suites, experiments, trial verdicts and gate results. A member's own key only; the member's evals grant and each suite's own access decide every call.
List eval suites
listEvalSuites/v1/evals/suitesThe eval suites you can see, most recently changed first. A suite holds the test cases that score one agent. Case content is never included.
- Scopes
evals:read- Behavior
- Read-onlyIdempotent
Query parameters
| Name | Type | Description |
|---|---|---|
page | integer1–10000 · default: 1 | Page number, from 1. |
page_size | integer1–100 · default: 25 | Rows per page, up to 100. |
search | string1–120 chars | Match on the suite name or key. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Response200
A page of suites.
| Field | Type | Description |
|---|---|---|
data | object[] | — |
data[].id | string | — |
data[].key | string | — |
data[].name | string | — |
data[].status | string | active or archived. |
data[].task_category | string | null | — |
data[].visibility | string | null | private, team or organization. |
data[].can_read_content | boolean | null | Whether you may read what this suite's cases say. Null in a list. |
data[].updated_at | string | null | — |
total | integer | — |
Examples
curl -G https://api.preshos.com/v1/evals/suites \
-H "Authorization: Bearer $PRESHOS_API_KEY" \
--data-urlencode "page_size=25"{
"data": [
{
"id": "5d0c1a2b-3c4d-4e5f-8a6b-7c8d9e0f1a2b",
"key": "permission-approval-starter-a132",
"name": "Permission and approval starter",
"status": "active",
"task_category": "permission_approval",
"visibility": "organization",
"can_read_content": null,
"updated_at": "2026-11-16T10:00:00.000Z"
}
],
"total": 1
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 400 | Invalid request: malformed JSON, failed validation, or an invalid filter/cursor. | validation_failed |
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Retrieve an eval suite
getEvalSuite/v1/evals/suites/{suite_id}One suite you can see. can_read_content says whether you may read what its cases say; the suite itself never carries case content.
- Scopes
evals:read- Behavior
- Read-onlyIdempotent
Path parameters
| Name | Type | Description |
|---|---|---|
suite_idrequired | stringformat: uuid | Eval suite id, from GET /evals/suites. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Response200
The suite.
| Field | Type | Description |
|---|---|---|
data | object | — |
data.id | string | — |
data.key | string | — |
data.name | string | — |
data.status | string | active or archived. |
data.task_category | string | null | — |
data.visibility | string | null | private, team or organization. |
data.can_read_content | boolean | null | Whether you may read what this suite's cases say. Null in a list. |
data.updated_at | string | null | — |
Examples
curl https://api.preshos.com/v1/evals/suites/<suite_id> \
-H "Authorization: Bearer $PRESHOS_API_KEY"{
"data": {
"id": "5d0c1a2b-3c4d-4e5f-8a6b-7c8d9e0f1a2b",
"key": "permission-approval-starter-a132",
"name": "Permission and approval starter",
"status": "active",
"task_category": "permission_approval",
"visibility": "organization",
"can_read_content": true,
"updated_at": "2026-11-16T10:00:00.000Z"
}
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Export an eval suite
exportEvalSuite/v1/evals/suites/{suite_id}/exportThe suite as a portable JSONL document (preshos.eval.suite 1.0): its cases, the graders they use and their fixture sets, named by key. Needs the evals:content scope and content read on this suite (its owner, or organization-wide read). Member ids, run ids and secrets are left out and counted in redaction. Every export is audited.
- Scopes
evals:readevals:content- Behavior
- Read-onlyIdempotent
Path parameters
| Name | Type | Description |
|---|---|---|
suite_idrequired | stringformat: uuid | Eval suite id, from GET /evals/suites. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Response200
The suite file and what was left out of it.
| Field | Type | Description |
|---|---|---|
data | object | — |
data.jsonl | string | The file, one JSON document per line. |
data.cases | integer | — |
data.graders | integer | — |
data.fixture_sets | integer | — |
data.redaction | object | — |
data.redaction.member_ids_removed | integer | — |
data.redaction.run_ids_removed | integer | — |
data.redaction.secrets_redacted | integer | — |
data.content_hash | string | — |
Examples
curl https://api.preshos.com/v1/evals/suites/<suite_id>/export \
-H "Authorization: Bearer $PRESHOS_API_KEY"{
"data": {
"jsonl": "{\"format\":\"preshos.eval.suite\",\"version\":\"1.0\"}\n",
"cases": 4,
"graders": 4,
"fixture_sets": 0,
"redaction": {
"member_ids_removed": 0,
"run_ids_removed": 0,
"secrets_redacted": 0
},
"content_hash": "sha256:0000000000000000000000000000000000000000000000000000000000000000"
}
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
| 409 | Conflict, e.g. an Idempotency-Key request still in progress or a uniqueness violation. | conflict |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Start an eval experiment
createEvalExperiment/v1/evals/experimentsCreates and queues an experiment on a suite you may run, as you. Name the suite by suite_id or suite_key. Without dataset_version_id the suite's latest frozen dataset version is used; without grader_version_ids the graders of the suite's most recent experiment are used (cases may also carry their own). The same Idempotency-Key returns the same experiment.
- Scopes
evals:write- Behavior
- Changes dataNot idempotentIdempotency-Key
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Content-Typerequired | string | application/json. |
Idempotency-Key | stringmax 255 chars | Unique key (1–255 visible ASCII characters, e.g. a UUID). Retrying with the same key and body replays the first successful response for 24 hours. |
Request bodyapplication/json · required
| Field | Type | Description |
|---|---|---|
suite_id | stringformat: uuid | — |
suite_key | string | — |
name | string1–160 chars | — |
mode | "harness" | "fixture" | "historical"default: "harness" | — |
trials_per_case | integer1–50 · default: 1 | — |
dataset_version_id | stringformat: uuid | — |
grader_version_ids | string[]max 20 items | — |
baseline_experiment_id | stringformat: uuid | — |
JSON Schema
{
"type": "object",
"properties": {
"suite_id": {
"type": "string",
"format": "uuid",
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
},
"suite_key": {
"type": "string",
"pattern": "^[a-z0-9][a-z0-9_-]{0,62}$"
},
"name": {
"type": "string",
"minLength": 1,
"maxLength": 160
},
"mode": {
"default": "harness",
"type": "string",
"enum": [
"harness",
"fixture",
"historical"
]
},
"trials_per_case": {
"default": 1,
"type": "integer",
"minimum": 1,
"maximum": 50
},
"dataset_version_id": {
"type": "string",
"format": "uuid",
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
},
"grader_version_ids": {
"maxItems": 20,
"type": "array",
"items": {
"type": "string",
"format": "uuid",
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
}
},
"baseline_experiment_id": {
"type": "string",
"format": "uuid",
"pattern": "^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$"
}
},
"additionalProperties": false
}Response201
The queued experiment.
| Field | Type | Description |
|---|---|---|
data | object | — |
data.id | string | — |
data.suite_id | string | — |
data.name | string | — |
data.mode | string | harness, fixture or historical. |
data.status | string | draft, queued, running, paused, completed, failed or canceled. |
data.status_reason | string | null | — |
data.trigger | string | null | How it was started. Experiments started here are ci. |
data.trials_per_case | integer | — |
data.baseline_experiment_id | string | null | — |
data.queued_at | string | null | — |
data.started_at | string | null | — |
data.finished_at | string | null | — |
data.summary | object | null | — |
Examples
curl -X POST https://api.preshos.com/v1/evals/experiments \
-H "Authorization: Bearer $PRESHOS_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: $(uuidgen)" \
-d '{
"suite_key": "permission-approval-starter-a132",
"trials_per_case": 1
}'{
"suite_key": "permission-approval-starter-a132",
"trials_per_case": 1
}{
"data": {
"id": "9a8b7c6d-5e4f-4a3b-9c2d-1e0f9a8b7c6d",
"suite_id": "5d0c1a2b-3c4d-4e5f-8a6b-7c8d9e0f1a2b",
"name": "Permission and approval starter (API)",
"mode": "harness",
"status": "queued",
"status_reason": null,
"trigger": "ci",
"trials_per_case": 1,
"baseline_experiment_id": null,
"queued_at": "2026-11-16T10:01:00.000Z",
"started_at": null,
"finished_at": null,
"summary": null
}
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 400 | Invalid request: malformed JSON, failed validation, or an invalid filter/cursor. | invalid_json, validation_failed |
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported, write_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
| 409 | Conflict, e.g. an Idempotency-Key request still in progress or a uniqueness violation. | conflict, idempotency_key_in_use |
| 422 | The write was rejected by validation or workflow rules. | invalid_write, idempotency_key_reused |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Retrieve an eval experiment
getEvalExperiment/v1/evals/experiments/{experiment_id}One experiment of a suite you can see, with its status and a summary of its trials. Poll this until status is completed, failed or canceled.
- Scopes
evals:read- Behavior
- Read-onlyIdempotent
Path parameters
| Name | Type | Description |
|---|---|---|
experiment_idrequired | stringformat: uuid | Experiment id, from POST /evals/experiments. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Response200
The experiment.
| Field | Type | Description |
|---|---|---|
data | object | — |
data.id | string | — |
data.suite_id | string | — |
data.name | string | — |
data.mode | string | harness, fixture or historical. |
data.status | string | draft, queued, running, paused, completed, failed or canceled. |
data.status_reason | string | null | — |
data.trigger | string | null | How it was started. Experiments started here are ci. |
data.trials_per_case | integer | — |
data.baseline_experiment_id | string | null | — |
data.queued_at | string | null | — |
data.started_at | string | null | — |
data.finished_at | string | null | — |
data.summary | object | null | — |
Examples
curl https://api.preshos.com/v1/evals/experiments/<experiment_id> \
-H "Authorization: Bearer $PRESHOS_API_KEY"{
"data": {
"id": "9a8b7c6d-5e4f-4a3b-9c2d-1e0f9a8b7c6d",
"suite_id": "5d0c1a2b-3c4d-4e5f-8a6b-7c8d9e0f1a2b",
"name": "Permission and approval starter (API)",
"mode": "harness",
"status": "completed",
"status_reason": null,
"trigger": "ci",
"trials_per_case": 1,
"baseline_experiment_id": null,
"queued_at": "2026-11-16T10:01:00.000Z",
"started_at": "2026-11-16T10:01:05.000Z",
"finished_at": "2026-11-16T10:04:40.000Z",
"summary": {
"total": 4,
"passed": 4,
"failed": 0,
"pass_rate": 1
}
}
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
List the trials of an experiment
listEvalTrials/v1/evals/experiments/{experiment_id}/trialsOne row per trial: whether it ran, what the graders concluded, and its cost. No case content, replies or evidence are returned.
- Scopes
evals:read- Behavior
- Read-onlyIdempotent
Path parameters
| Name | Type | Description |
|---|---|---|
experiment_idrequired | stringformat: uuid | Experiment id, from POST /evals/experiments. |
Query parameters
| Name | Type | Description |
|---|---|---|
page | integer1–10000 · default: 1 | Page number, from 1. |
page_size | integer1–100 · default: 25 | Rows per page, up to 100. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Response200
A page of trials.
| Field | Type | Description |
|---|---|---|
data | object[] | — |
data[].id | string | — |
data[].case_id | string | null | — |
data[].trial_index | integer | — |
data[].attempt | integer | null | — |
data[].execution_status | string | Did it run: queued, running, completed, failed, timed_out, canceled, blocked or infra_error. |
data[].verdict | string | null | What the graders concluded: passed, failed, inconclusive, or why there is no conclusion. Null until graded. |
data[].status_reason | string | null | — |
data[].evidence_completeness | string | null | — |
data[].cost_usd | number | null | Null when the cost is not known. |
data[].finished_at | string | null | — |
total | integer | — |
Examples
curl https://api.preshos.com/v1/evals/experiments/<experiment_id>/trials \
-H "Authorization: Bearer $PRESHOS_API_KEY"{
"data": [
{
"id": "1b2c3d4e-5f60-4a7b-8c9d-0e1f2a3b4c5d",
"case_id": "2c3d4e5f-6071-4b8c-9d0e-1f2a3b4c5d6e",
"trial_index": 0,
"attempt": 1,
"execution_status": "completed",
"verdict": "passed",
"status_reason": null,
"evidence_completeness": "complete",
"cost_usd": 0.012,
"finished_at": "2026-11-16T10:02:10.000Z"
}
],
"total": 4
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 400 | Invalid request: malformed JSON, failed validation, or an invalid filter/cursor. | validation_failed |
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
List the gate results of an experiment
listEvalGateResults/v1/evals/experiments/{experiment_id}/gatesHow the experiment did against each gate of its suite. blocks is true when a blocking gate failed and no override was approved; that is what a CI job should fail on. Empty until the experiment has finished and its gates were evaluated.
- Scopes
evals:read- Behavior
- Read-onlyIdempotent
Path parameters
| Name | Type | Description |
|---|---|---|
experiment_idrequired | stringformat: uuid | Experiment id, from POST /evals/experiments. |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Response200
The gate results.
| Field | Type | Description |
|---|---|---|
data | object[] | — |
data[].id | string | — |
data[].gate_id | string | — |
data[].gate_key | string | null | — |
data[].outcome | string | passed, failed or insufficient_evidence. |
data[].enforcement | string | advisory reports only; blocking stops what asked. |
data[].reasons | string[] | — |
data[].blocks | boolean | True for a failed blocking gate with no approved override. |
blocks | boolean | — |
Examples
curl https://api.preshos.com/v1/evals/experiments/<experiment_id>/gates \
-H "Authorization: Bearer $PRESHOS_API_KEY"{
"data": [
{
"id": "3d4e5f60-7182-4c9d-8e0f-2a3b4c5d6e7f",
"gate_id": "4e5f6071-8293-4d0e-9f1a-3b4c5d6e7f80",
"gate_key": "starter-safety",
"outcome": "passed",
"enforcement": "advisory",
"reasons": [],
"blocks": false
}
],
"blocks": false
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported |
| 404 | Object type, record, or route not found (or not readable by this user). | user_not_found, workflow_not_found, comments_not_supported, team_workspace_not_found, team_workspace_task_not_found, team_workspace_objective_not_found, team_workspace_question_not_found, team_workspace_document_not_found |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Search across object types.
Search across objects
search/v1/searchFull-text style search across work items, companies, contacts, meetings, events, and custom objects, filtered to what the key's user may read. Each hit carries object_type and id for the records endpoints. Service keys search the display field of every object their agent may read workspace-wide.
- Scopes
records:read- Behavior
- Read-onlyIdempotent
Query parameters
| Name | Type | Description |
|---|---|---|
qrequired | string2–200 chars | Search text (2+ characters). |
limit | integer1–30 · default: 20 | — |
Headers
| Name | Type | Description |
|---|---|---|
Authorizationrequired | string | Bearer <api key>. The key acts as the user who created it. |
Response200
Search hits, best first.
| Field | Type | Description |
|---|---|---|
data | — |
Examples
curl -G https://api.preshos.com/v1/search \
-H "Authorization: Bearer $PRESHOS_API_KEY" \
--data-urlencode "q=acme"{
"data": [
{
"object_type": "companies",
"id": "48213",
"display": "Acme Corporation",
"subtitle": "acme.com",
"url": "/companies/48213"
}
]
}Errors
| Status | Meaning | Codes |
|---|---|---|
| 400 | Invalid request: malformed JSON, failed validation, or an invalid filter/cursor. | validation_failed |
| 403 | Insufficient key scope, developer access revoked, or missing object/record/field permission. | developer_access_revoked, tenant_host_mismatch, insufficient_scope, permission_denied, member_key_required, search_not_supported |
Also 401 (key), 429 (rate limit), and 500, like every endpoint. All errors use the error envelope; see every error code.
Shared schemas referenced by request and response bodies. Responses may gain new properties at any time; ignore the ones you do not use.
A record of any object type. fields holds every readable business field keyed by field key; fields you may not read are omitted.
| Field | Type | Description |
|---|---|---|
object_type | string | Registry object type, e.g. companies, work-items, or a custom object id. |
idoptional | string | Canonical record id when readable. Use it for every record endpoint. |
public_idoptional | string | Work items only: the legacy/public id used in app deep links. |
work_item_type_idoptional | string | Work items only: the tenant work-item type (e.g. task). |
displayoptional | string | null | Primary display value (name/title). |
statusoptional | string | null | Current status value or workflow status id. |
owneroptional | integer | null | Canonical local owner user ID. Null when authorized and empty; omitted when not readable. |
owner_displayoptional | string | null | Authorized owner display name; never replaces the ID. |
owner_user_id | integer | null | Deprecated compatibility envelope for owner; null when empty or not readable. |
created_atoptional | string | null | ISO-8601 UTC. |
updated_atoptional | string | null | ISO-8601 UTC. |
versionoptional | string | Opaque concurrency token. Send as If-Match on PATCH. |
record_propertiesoptional | object | Readable standard values for this record, including its effective workflow and lifecycle dates. |
fieldsoptional | object | — |
A page of records.
| Field | Type | Description |
|---|---|---|
data | — | |
pagination | — |
A single record.
| Field | Type | Description |
|---|---|---|
data | — |
Cursor pagination. Pass next_cursor as cursor with the same query to fetch the next page.
| Field | Type | Description |
|---|---|---|
limit | integer | Page size used for this response. |
has_more | boolean | Whether another page exists. |
next_cursor | string | null | Opaque cursor for the next page, or null. |
Every non-2xx response uses this envelope.
| Field | Type | Description |
|---|---|---|
error | object | — |
error.type | "invalid_request_error" | "authentication_error" | "permission_error" | "not_found_error" | "conflict_error" | "idempotency_error" | "rate_limit_error" | "api_error" | — |
error.code | string | Stable, machine-readable error code. |
error.message | string | Human-readable explanation. May change; do not parse. |
error.paramoptional | string | The parameter or field that caused the error, when known. |
error.detailsoptional | object | — |
error.request_id | string | Include this when contacting support. |
An object type available in this workspace.
| Field | Type | Description |
|---|---|---|
object_type | string | — |
name | string | null | — |
singular_name | string | null | — |
description | string | null | — |
kind | "built_in" | "work_item" | "default" | string | default = tenant custom object. |
category | string | — |
display_field | string | null | — |
capabilities | — | |
permissions | — |
Full description of an object type for this workspace and caller.
| Field | Type | Description |
|---|---|---|
object_type | string | — |
name | string | null | — |
singular_name | string | null | — |
description | string | null | — |
kind | string | — |
category | string | — |
display_field | string | null | — |
capabilities | — | |
permissions | — | |
fields | — | |
record_propertiesoptional | map of string | Standard record properties mapped to readable field keys in this workspace and type. Unavailable bindings are omitted. |
actionsoptional | object[] | Registered write operations this caller may use, subject to record and transition checks. |
actions[].id | string | — |
actions[].version | integer | — |
actions[].operation | string | — |
actions[].status_idoptional | string | — |
relationships | — | |
workflow | — | |
work_item_typesoptional | object[] | Work items only: active work-item types and their workflows. |
work_item_types[].id | string | — |
work_item_types[].name | string | null | — |
work_item_types[].workflow | — |
Operations the object supports through the API, independent of the caller's permissions.
| Field | Type | Description |
|---|---|---|
search | boolean | — |
create | boolean | — |
update | boolean | — |
delete | boolean | — |
What the calling user may do with this object type.
| Field | Type | Description |
|---|---|---|
create | — | |
read | — | |
update | — | |
delete | — |
Advisory access for the calling user. Every request is still authorized individually.
| Field | Type | Description |
|---|---|---|
allowed | boolean | — |
scopes | ("owned_by_user" | "owned_by_team" | "org_wide")[] | Record scopes granted: your own records, your teams' records, or the whole workspace. |
A field of an object type.
| Field | Type | Description |
|---|---|---|
key | string | Key used in fields for reads, writes, filters, and sorting. |
canonical_field_idoptional | string | null | — |
aliasesoptional | string[] | — |
owner_modeoptional | "assignable" | "creator" | — |
referenceoptional | object | — |
reference.schemaoptional | string | — |
reference.tableoptional | string | — |
reference.columnoptional | string | — |
name | string | null | — |
type | string | Data type, e.g. text, number, date, select, boolean, reference. |
required | boolean | — |
editable | boolean | — |
storage | string | physical columns are filterable/sortable; jsonb values live under custom_fields. |
storage_key | string | — |
optionsoptional | — | |
constraintsoptional | object | — |
An allowed value for a select field.
| Field | Type | Description |
|---|---|---|
value | any | — |
labeloptional | string | — |
A relationship from this object to another.
| Field | Type | Description |
|---|---|---|
object | object | — |
object.key | string | — |
object.name | string | null | — |
cardinality | string | — |
labels | string[] | — |
A status workflow with its statuses and allowed transitions.
| Field | Type | Description |
|---|---|---|
id | string | — |
key | string | null | — |
name | string | null | — |
statuses | object[] | — |
statuses[].id | string | Status id. Send it to the status endpoint. |
statuses[].name | string | null | — |
statuses[].transitions | object[] | Statuses this status may move to. |
A status workflow reference. Fetch statuses with GET /v1/workflows/{workflow_id}.
| Field | Type | Description |
|---|---|---|
id | string | — |
key | string | null | — |
name | string | null | — |
A workspace member.
| Field | Type | Description |
|---|---|---|
id | integer | — |
name | string | null | — |
email | string | null | — |
title | string | null | — |
active | boolean | — |
teams | object[] | — |
teams[].id | integer | — |
teams[].name | string | null | — |
A team of workspace members.
| Field | Type | Description |
|---|---|---|
id | integer | — |
name | string | null | — |
description | string | null | — |
member_ids | integer[] | — |
A comment on a record.
| Field | Type | Description |
|---|---|---|
id | string | — |
body | string | Plain-text body. |
author | object | — |
author.kind | "user" | "agent" | string | — |
author.id | integer | null | — |
author.name | string | null | — |
created_at | string | null | — |
updated_at | string | null | — |
A cross-object search hit.
| Field | Type | Description |
|---|---|---|
object_type | string | — |
id | string | — |
display | string | null | — |
subtitle | string | null | — |
url | string | null | Deep link into the PRESHos app. |