LeadArc Docsv1

Markdown for agents

This page as plain markdown, ready to paste into an LLM.

.md

Tasks

Follow-up work items, anchored to a lead and owned by a person.

tasks:readread bucketreturns list of task

Tasks, filterable by lead, assignee, due date, status

bash
curl -sS https://api.leadarc.io/v1/workspaces/airpay/tasks?limit=25 \
  -H "Authorization: Bearer $LEADARC_API_KEY"

Query parameters. Anything else is 400 unsupported_filter.

assignee_id cursor due_after due_before lead_id limit order status task_type

Errors from this endpoint, on top of the common ones: invalid_cursor, invalid_request, not_found, unprocessable.

json
{
  "object": "list",
  "data": [{
    "object": "task",
    "id": "tsk_i-_uD-R7uXULK8lecjVGbgq71OpftiUkqXfdvx",
    "workspace": "airpay",
    "lead_id": "lead_BP2vnPmKyttNP2OlH_mWL78t1o6nBVC6oVbHny",
    "reply_id": "rep_Dk9dw7dVABGNJm9HK9onvZKXLneRRpj9MIB-C3",
    "title": null,
    "notes": "Send the onboarding one-pager and the Loom.",
    "task_type": null,
    "due_date": "2026-07-29",
    "due_time": "10:30",
    "status": "open",
    "creator_id": "usr_zaDRRpdu8EPZSU3i89lvZgKPkVQo4uBFA_KOhm",
    "assignee_id": "usr_zaDRRpdu8EPZSU3i89lvZgKPkVQo4uBFA_KOhm",
    "completed_at": null,
    "created_at": "2026-07-27T09:30:00Z",
    "sequence": null
  }],
  "has_more": false,
  "next_cursor": null
}

Notes.

  1. tasks has no client_id column. Every query derives the tenant through tasks.response_idresponses_index.client_id, and adds isNotNull(tasks.response_id) unconditionally. response_id is nullable so a task can hang off a CRM company_id instead. The CRM is dead but the rows exist, and a company-anchored task has no lead, no reply, and no workspace derivable this way. Those rows are invisible to the API.
  1. tasks has no status column. Status is derived: open is completed_at IS NULL AND deleted_at IS NULL. deleted_at rows are filtered out and never surfaced as a status.
  1. tasks has no title column. title is present in the object for shape stability and is always null for a manually created task. The only source is followup_sequence_steps.title, so it is populated only on a task materialized by a sequence. POST and PATCH reject title with 400 invalid_request rather than accepting it and dropping it.
  1. due_time is a wall-clock text string in the viewer's local timezone, not an instant. tasks.due_time is text holding "HH:MM" in 24-hour form. tasks.due_date is a date column with mode:"date", a calendar day. A task with due_date: "2026-07-29" and due_time: null is due by calendar day only.
  1. sequence is the only sanctioned view of the materialization internals. When a task came from a sequence it is { "id": "seq_…", "name": "Interested follow-up", "step_index": 2 }. The raw sequence_id, enrollment_id, sequence_step_id, email_template_id, email_body, and linkedin_text columns are withheld.
tasks:writewrite bucketreturns task

Create a task on a lead

bash
curl -sS https://api.leadarc.io/v1/workspaces/airpay/tasks \
  -X POST \
  -H "Authorization: Bearer $LEADARC_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"lead_id":"lead_BP2vnPmKyttNP2OlH_mWL78t1o6nBVC6oVbHny","due_date":"...","due_time":"..."}'

Body fields. An unknown field is rejected.

lead_id due_date due_time notes assignee_id

Errors from this endpoint, on top of the common ones: invalid_cursor, invalid_request, not_found, unprocessable.

json
{
  "lead_id": "lead_BP2vnPmKyttNP2OlH_mWL78t1o6nBVC6oVbHny",
  "due_date": "2026-07-29",
  "due_time": "10:30",
  "notes": "Send the onboarding one-pager and the Loom.",
  "assignee_id": "usr_zaDRRpdu8EPZSU3i89lvZgKPkVQo4uBFA_KOhm"
}

201 with the created task. creator_id is the key's owner.

assignee_id is validated against the workspace's assignable members. company_id and opportunity_id are never accepted.

Not idempotent. A retry creates a second task.

tasks:writewrite bucketreturns task

Edit due date, time, notes, assignee

bash
curl -sS https://api.leadarc.io/v1/workspaces/airpay/tasks/tsk_i-_uD-R7uXULK8lecjVGbgq71OpftiUkqXfdvx \
  -X PATCH \
  -H "Authorization: Bearer $LEADARC_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"due_date":"...","due_time":"...","notes":"..."}'

Body fields. An unknown field is rejected.

due_date due_time notes assignee_id

Errors from this endpoint, on top of the common ones: invalid_request, not_found.

tasks:writewrite bucketreturns task

Complete a task

bash
curl -sS https://api.leadarc.io/v1/workspaces/airpay/tasks/tsk_i-_uD-R7uXULK8lecjVGbgq71OpftiUkqXfdvx/complete \
  -X POST \
  -H "Authorization: Bearer $LEADARC_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"completed":"..."}'

Body fields. An unknown field is rejected.

completed

Errors from this endpoint, on top of the common ones: invalid_request.

tasks:writewrite bucketreturns task

Soft-delete a task

bash
curl -sS https://api.leadarc.io/v1/workspaces/airpay/tasks/tsk_i-_uD-R7uXULK8lecjVGbgq71OpftiUkqXfdvx \
  -X DELETE \
  -H "Authorization: Bearer $LEADARC_API_KEY"

Errors from this endpoint, on top of the common ones: invalid_request, not_found.

There is no hard delete for anything in this API.


Base URL https://api.leadarc.io/v1. Generated from the API source.