# List Tasks

`lawmatics_list-tasks` · Lawmatics MCP tool · Tasks

List tasks from Lawmatics with optional pagination, filtering, and sorting. Filter by the associated matter/contact/company/client id, an assigned user id, or task fields like done, priority, and due_date. Each row carries a `relationships` envelope with a to-one `taskable` {id,type} pointer to the associated record; use get-task for the full envelope including to-many pointers (users, documents, files, subtasks, comments).

## Input

- **page** `integer` (> 0) — Page number (1-based)
- **filter** `object` — Optional single-field filter; one filter at a time
  - **field** `string` (required, enum: "matter_id", "prospect_id", "contact_id", "company_id", "client_id", "user_id", "name", "done", "priority", "due_date", "created_at", "updated_at") — Field to filter on: matter_id/prospect_id (numeric id of the associated matter), contact_id, company_id, client_id, user_id (numeric id of an assigned firm user), name (task name), done (true/false), priority (high/medium/low), due_date, created_at, or updated_at (dates)
  - **operator** `string` (enum: "=", "!=", "<", "<=", ">", ">=", "like", "ilike", "null", "not_null") — Comparison operator. Omit to use the Lawmatics per-field default (= for ids/booleans/dates, ilike for strings). Use = for id fields and a range operator (e.g. <) for due_date
  - **value** `string` (required) — Value to compare against (ignored for null / not_null operators)
- **sortBy** `string` (enum: "id", "created_at", "updated_at", "due_date", "name", "priority") — Column to sort by
- **sortOrder** `string` (enum: "asc", "desc") — Sort direction; ascending or descending

## Output

- **tasks** `array` (required) — Tasks on this page of results
  - **[]** `object`
    - **id** `string` (required) — Unique ID of the task
    - **name** `string` (required) — Name/title of the task
    - **description** `string | null` (required) — Description of the task; null if unset
    - **dueDate** `string | null` (required) — ISO 8601 timestamp the task is due; null if no due date is set
    - **done** `boolean` (required) — Whether the task is completed
    - **status** `string | null` (required) — Read-only display status (e.g. "No Status"); null when the projection omits it
    - **priority** `string` (required) — Task priority as returned by the API (high, medium, low)
    - **tags** `array` (required) — Tags attached to this task
      - **[]** `object`
        - **id** `string` (required) — Unique ID of the tag
        - **name** `string` (required) — Name of the tag
        - **color** `string | null` (required) — Hex display color of the tag; null if unset
    - **assignedById** `string | null` (required) — ID of the firm user who assigned the task; null if unset or omitted
    - **recurrenceRule** `object | null` (required) — Recurrence rule with inner keys preserved exactly as the API returns them (type, frequency, weekday booleans, and an end-date key that may appear as endDate or end_date); null when the task does not recur or the projection omits it
      - **[key: string]** `string | number | boolean | null`
    - **createdAt** `string | null` (required) — When the task was created, as an ISO 8601 timestamp; null if unknown
    - **updatedAt** `string | null` (required) — When the task was last updated, as an ISO 8601 timestamp; null if unknown
    - **relationships** `object` (required) — To-one JSON:API relationship pointers as {id,type} stubs. Not materialized — follow a pointer by calling that resource's own tool. List rows carry the to-one pointer only; use get-task for the full envelope incl. to-many (users, documents, files, subtasks, comments).
      - **taskable** `object | null` (required) — Associated record (matter/prospect, contact, or company) pointer; null for unattached tasks
        - **id** `string` (required) — ID of the referenced Lawmatics record
        - **type** `string` (required) — JSON:API record class of the reference (e.g. "user", "contact", "prospect", "firm"); resolve it by calling that resource's own get/find tool — this pointer is not materialized
- **pagination** `object | null` (required) — Pagination metadata from the API response; null when the endpoint returns no meta envelope
  - **totalPages** `number | null` (required) — Total number of pages available; null if not reported
  - **limitPerPage** `number | null` (required) — Maximum tasks returned per page; null if not reported
  - **totalEntries** `number | null` (required) — Total number of tasks across all pages; null if not reported
