API ReferenceAgent Task
agentTask.create
Type: Mutation · Auth: Workspace-aware
Input
| Field | Type | Required | Default | Description |
|---|---|---|---|---|
| taskType | string | Yes | — | Task type |
| sourceType | enum(event, conversation, schedule, operator, workflow, automation_rule) | Yes | — | Source type |
| sourceRefId | string | No | — | ID of the associated source ref |
| entityType | string | No | — | Entity type |
| entityId | string | No | — | ID of the associated entity |
| title | string | Yes | — | Title |
| description | string | No | — | Description |
| priority | integer | Yes | 100 | Priority |
| assignedAgentRole | unknown | No | — | Assigned agent role |
| assignedAgentId | unknown | No | — | ID of the associated assigned agent |
| executionMode | enum(deterministic, agentic, hybrid) | Yes | "agentic" | Execution mode |
| approvalPolicy | enum(auto_execute, draft_for_review, agent_review, restricted) | Yes | "draft_for_review" | Approval policy |
| dueAt | string.date-time | No | — | Due at |
| workspaceVisible | boolean | Yes | true | Workspace visible |
| createdByUserId | string | No | — | ID of the associated created by user |
| workspaceId | string | No | — | ID of the associated workspace |
| metadata | object | No | — | Metadata |
Example
{
"taskType": "example",
"sourceType": "event",
"sourceRefId": "550e8400-e29b-41d4-a716-446655440000",
"entityType": "example",
"entityId": "550e8400-e29b-41d4-a716-446655440000",
"title": "Example Title",
"priority": 100,
"executionMode": "deterministic",
"approvalPolicy": "auto_execute",
"workspaceVisible": true
}