Mandraki Mandraki
Get started

Tasks

Create, read, update, and delete tasks and projects through the Mandraki Bot API.

Overview

The Tasks endpoints let you manage tasks and projects within your organization. Tasks can be organized into projects, assigned to users, prioritized, and tracked through customizable statuses.

Base path: /orgs/{orgId}/bot/tasks

List Tasks

Retrieve tasks with optional filtering, sorting, and pagination.

GET /orgs/{orgId}/bot/tasks

Required scope: tasks:read

Query Parameters

ParameterTypeDefaultDescription
projectIdUUID—Filter by project
teamIdUUID—Filter by team
assigneeIdUUID—Filter by assignee
statusIdstring—Filter by status ID
statusCategoryenum—Filter by status category: not_started, in_progress, done, cancelled
priorityenum—Filter by priority: urgent, high, medium, low, none
dueBeforeISO 8601—Tasks due before this date
dueAfterISO 8601—Tasks due after this date
parentTaskIdUUID or null—Filter subtasks of a parent (null for top-level only)
searchstring—Full-text search on task title
limitinteger50Results per page (1-200)
offsetinteger0Pagination offset
sortenumsort_orderSort by: created, updated, due, priority, sort_order
sortDirenumascSort direction: asc, desc

Example Request

curl -X GET "https://app.mandraki.cloud/api/v1/orgs/{orgId}/bot/tasks?projectId={projectId}&priority=high&limit=10" \
  -H "Authorization: Bearer mak_..."

Example Response

{
  "tasks": [
    {
      "id": "550e8400-e29b-41d4-a716-446655440000",
      "title": "Review Q1 report",
      "description": "Review and approve the Q1 financial report",
      "projectId": "project-uuid",
      "statusId": "in-progress",
      "priority": "high",
      "assigneeId": "user-uuid",
      "dueDate": "2026-04-01T00:00:00.000Z",
      "tags": ["finance", "quarterly"],
      "createdAt": "2026-03-25T10:00:00.000Z",
      "updatedAt": "2026-03-26T14:30:00.000Z"
    }
  ],
  "total": 1
}

Get Task

Retrieve a single task by ID.

GET /orgs/{orgId}/bot/tasks/{taskId}

Required scope: tasks:read

Example Request

curl -X GET "https://app.mandraki.cloud/api/v1/orgs/{orgId}/bot/tasks/{taskId}" \
  -H "Authorization: Bearer mak_..."

Example Response

{
  "id": "550e8400-e29b-41d4-a716-446655440000",
  "title": "Review Q1 report",
  "description": "Review and approve the Q1 financial report",
  "projectId": "project-uuid",
  "statusId": "in-progress",
  "priority": "high",
  "assigneeId": "user-uuid",
  "dueDate": "2026-04-01T00:00:00.000Z",
  "startDate": null,
  "estimate": 4,
  "tags": ["finance", "quarterly"],
  "parentTaskId": null,
  "sprintId": null,
  "customFields": {},
  "createdAt": "2026-03-25T10:00:00.000Z",
  "updatedAt": "2026-03-26T14:30:00.000Z"
}

Error: Task Not Found

{
  "error": "Task not found"
}

Create Task

Create a new task.

POST /orgs/{orgId}/bot/tasks

Required scope: tasks:write

Request Body

FieldTypeRequiredDescription
titlestring (1-500)YesTask title
descriptionstring (max 10,000)NoTask description
projectIdUUIDNoProject to add the task to
statusIdstring (max 50)NoStatus ID (uses project default if omitted)
priorityenumNourgent, high, medium, low, none
assigneeIdUUIDNoUser to assign the task to
dueDateISO 8601NoDue date
startDateISO 8601NoStart date
parentTaskIdUUIDNoParent task (creates a subtask)
estimatenumber (0-1000)NoTime estimate in hours
tagsstring[] (max 20)NoTags (each max 50 chars)
sprintIdUUIDNoSprint to add the task to
customFieldsobjectNoKey-value pairs for custom fields
sourceTypeenumNoOrigin: message, call, email, pa, manual, recurring
sourceIdstringNoID of the source resource
sourceUrlURLNoURL linking back to the source

Example Request

curl -X POST "https://app.mandraki.cloud/api/v1/orgs/{orgId}/bot/tasks" \
  -H "Authorization: Bearer mak_..." \
  -H "Content-Type: application/json" \
  -d '{
    "title": "Deploy new feature",
    "description": "Deploy the authentication refactor to production",
    "projectId": "project-uuid",
    "priority": "high",
    "assigneeId": "user-uuid",
    "dueDate": "2026-04-05T00:00:00.000Z",
    "tags": ["deployment", "auth"]
  }'

Example Response

{
  "id": "new-task-uuid",
  "title": "Deploy new feature",
  "description": "Deploy the authentication refactor to production",
  "projectId": "project-uuid",
  "priority": "high",
  "assigneeId": "user-uuid",
  "dueDate": "2026-04-05T00:00:00.000Z",
  "createdAt": "2026-03-27T12:00:00.000Z"
}

Returns 201 Created on success.

Update Task

Update an existing task. Only include the fields you want to change.

PATCH /orgs/{orgId}/bot/tasks/{taskId}

Required scope: tasks:write

Request Body

FieldTypeDescription
titlestring (1-500)New title
descriptionstring or nullNew description (null to clear)
statusIdstring (max 50)New status ID
priorityenumNew priority
assigneeIdUUID or nullNew assignee (null to unassign)
dueDateISO 8601 or nullNew due date (null to clear)
startDateISO 8601 or nullNew start date (null to clear)
estimatenumber or nullNew estimate (null to clear)
tagsstring[]Replace all tags
sortOrdernumberPosition in the list
sprintIdUUID or nullMove to sprint (null to remove)
customFieldsobjectUpdate custom fields

Example Request

curl -X PATCH "https://app.mandraki.cloud/api/v1/orgs/{orgId}/bot/tasks/{taskId}" \
  -H "Authorization: Bearer mak_..." \
  -H "Content-Type: application/json" \
  -d '{
    "priority": "urgent",
    "dueDate": "2026-04-01T00:00:00.000Z"
  }'

Example Response

Returns the full updated task object.

Delete Task

Permanently delete a task.

DELETE /orgs/{orgId}/bot/tasks/{taskId}

Required scope: tasks:write

Example Request

curl -X DELETE "https://app.mandraki.cloud/api/v1/orgs/{orgId}/bot/tasks/{taskId}" \
  -H "Authorization: Bearer mak_..."

Example Response

{
  "message": "Task deleted"
}

List Projects

Retrieve all projects, optionally filtered by team.

GET /orgs/{orgId}/bot/tasks/projects

Required scope: tasks:read

Query Parameters

ParameterTypeDescription
teamIdUUIDFilter projects by team

Example Request

curl -X GET "https://app.mandraki.cloud/api/v1/orgs/{orgId}/bot/tasks/projects?teamId={teamId}" \
  -H "Authorization: Bearer mak_..."

Example Response

{
  "projects": [
    {
      "id": "project-uuid",
      "name": "Q1 Planning",
      "description": "Q1 2026 planning and tracking",
      "icon": "clipboard",
      "color": "#4F46E5",
      "isPrivate": false,
      "createdAt": "2026-01-15T08:00:00.000Z"
    }
  ]
}

Create Project

Create a new task project.

POST /orgs/{orgId}/bot/tasks/projects

Required scope: tasks:write

Request Body

FieldTypeRequiredDescription
namestring (1-100)YesProject name
descriptionstring (max 2,000)NoProject description
iconstring (max 50)NoIcon identifier
colorhex colorNoProject color (e.g., #4F46E5)
isPrivatebooleanNoWhether the project is private

Example Request

curl -X POST "https://app.mandraki.cloud/api/v1/orgs/{orgId}/bot/tasks/projects" \
  -H "Authorization: Bearer mak_..." \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Release v2.0",
    "description": "Track all tasks for the v2.0 release",
    "color": "#059669"
  }'

Example Response

Returns 201 Created with the created project object.