> ## Documentation Index
> Fetch the complete documentation index at: https://docs.sayvyai.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Create CRM task

> Create a new CRM task linked to a contact and emit a task_created activity event

Create a new follow-up task or reminder linked to an existing contact. Creating a task automatically emits a `task_created` audit event on the contact's [activity timeline](/api-reference/contacts/get-activities).

***

### Authentication

This endpoint requires Bearer token authentication.

```http theme={null}
Authorization: Bearer <token>
```

| Header | Type | Required | Description | Format |
| :- | :- | :- | :- | :- |
| `Authorization` | `string` | **Yes** | Scoped organization API key or Bearer JWT token | `Bearer <token>` |

***

### Input parameters

<ParamField header="Authorization" type="string" required>
  Bearer token for authentication. Format: `Bearer <token>`.
</ParamField>

<ParamField body="contact_id" type="string" required>
  UUID of the existing contact this task is associated with. Example: `7b8f9e2a-4c1d-48ef-9123-bcde456789ab`.
</ParamField>

<ParamField body="title" type="string" required>
  Task title or summary action item (maximum 255 characters). Example: `Review customer custom pricing request`.
</ParamField>

<ParamField body="description" type="string">
  Detailed task description, conversation context, or instructions.
</ParamField>

<ParamField body="due_at" type="string">
  Target completion deadline in ISO 8601 format (e.g. `2026-10-15T15:00:00Z`).
</ParamField>

<ParamField body="assignee_id" type="string">
  UUID of the team member assigned to execute the task.
</ParamField>

***

### Response Fields

<ResponseField name="id" type="string">
  Generated UUID identifier of the created task.
</ResponseField>

<ResponseField name="organization_id" type="string">
  Organization UUID.
</ResponseField>

<ResponseField name="contact_id" type="string">
  Associated contact UUID.
</ResponseField>

<ResponseField name="title" type="string">
  Task title.
</ResponseField>

<ResponseField name="description" type="string">
  Detailed description or `null`.
</ResponseField>

<ResponseField name="due_at" type="string">
  Due timestamp in ISO 8601 format, or `null`.
</ResponseField>

<ResponseField name="assignee_id" type="string">
  Assigned user UUID or `null`.
</ResponseField>

<ResponseField name="status" type="string">
  Initialized state: `pending`.
</ResponseField>

<ResponseField name="created_by_type" type="string">
  Actor type that initiated the task (`user`).
</ResponseField>

<ResponseField name="created_by_id" type="string">
  UUID of the creating user.
</ResponseField>

<ResponseField name="completed_at" type="string">
  Timestamp of completion (`null` upon creation).
</ResponseField>

<ResponseField name="created_at" type="string">
  ISO 8601 creation timestamp.
</ResponseField>

<ResponseField name="updated_at" type="string">
  ISO 8601 modification timestamp.
</ResponseField>

<ResponseField name="contact" type="object">
  Linked contact summary (`id`, `name`, `phone_number`).
</ResponseField>

***

<RequestExample>
  ```bash cURL theme={null}
  curl -X POST "https://api.sayvy.ai/api/v1/crm/tasks" \
    -H "Authorization: Bearer <token>" \
    -H "Content-Type: application/json" \
    -d '{
      "contact_id": "7b8f9e2a-4c1d-48ef-9123-bcde456789ab",
      "title": "Send updated contract agreement",
      "description": "Include annual billing terms and SLA addendum.",
      "due_at": "2026-10-15T17:00:00Z",
      "assignee_id": "a1b2c3d4-e5f6-4a5b-8c9d-0e1f2a3b4c5d"
    }'
  ```

  ```python Python theme={null}
  import requests

  url = "https://api.sayvy.ai/api/v1/crm/tasks"

  payload = {
      "contact_id": "7b8f9e2a-4c1d-48ef-9123-bcde456789ab",
      "title": "Send updated contract agreement",
      "description": "Include annual billing terms and SLA addendum.",
      "due_at": "2026-10-15T17:00:00Z",
      "assignee_id": "a1b2c3d4-e5f6-4a5b-8c9d-0e1f2a3b4c5d"
  }

  headers = {
      "Authorization": "Bearer <token>",
      "Content-Type": "application/json"
  }

  response = requests.post(url, json=payload, headers=headers)
  print(response.status_code)
  print(response.json())
  ```

  ```javascript JavaScript theme={null}
  const response = await fetch("https://api.sayvy.ai/api/v1/crm/tasks", {
    method: "POST",
    headers: {
      "Authorization": "Bearer <token>",
      "Content-Type": "application/json"
    },
    body: JSON.stringify({
      contact_id: "7b8f9e2a-4c1d-48ef-9123-bcde456789ab",
      title: "Send updated contract agreement",
      description: "Include annual billing terms and SLA addendum.",
      due_at: "2026-10-15T17:00:00Z",
      assignee_id: "a1b2c3d4-e5f6-4a5b-8c9d-0e1f2a3b4c5d"
    })
  });

  const data = await response.json();
  console.log(data);
  ```

  ```java Java theme={null}
  import java.net.URI;
  import java.net.http.HttpClient;
  import java.net.http.HttpRequest;
  import java.net.http.HttpResponse;

  String jsonPayload = """
  {
    "contact_id": "7b8f9e2a-4c1d-48ef-9123-bcde456789ab",
    "title": "Send updated contract agreement",
    "due_at": "2026-10-15T17:00:00Z"
  }
  """;

  HttpRequest request = HttpRequest.newBuilder()
      .uri(URI.create("https://api.sayvy.ai/api/v1/crm/tasks"))
      .header("Authorization", "Bearer <token>")
      .header("Content-Type", "application/json")
      .POST(HttpRequest.BodyPublishers.ofString(jsonPayload))
      .build();

  HttpResponse<String> response =
      HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
  System.out.println(response.body());
  ```
</RequestExample>

<ResponseExample>
  ```json 201 Created theme={null}
  {
    "id": "e4b9d107-1b4e-4f32-8df6-96cbef3e6801",
    "organization_id": "00000000-0000-0000-0000-000000000001",
    "contact_id": "7b8f9e2a-4c1d-48ef-9123-bcde456789ab",
    "title": "Send updated contract agreement",
    "description": "Include annual billing terms and SLA addendum.",
    "due_at": "2026-10-15T17:00:00Z",
    "assignee_id": "a1b2c3d4-e5f6-4a5b-8c9d-0e1f2a3b4c5d",
    "status": "pending",
    "created_by_type": "user",
    "created_by_id": "a1b2c3d4-e5f6-4a5b-8c9d-0e1f2a3b4c5d",
    "completed_at": null,
    "created_at": "2026-10-07T16:30:00Z",
    "updated_at": "2026-10-07T16:30:00Z",
    "contact": {
      "id": "7b8f9e2a-4c1d-48ef-9123-bcde456789ab",
      "name": "Jane Doe",
      "phone_number": "+14155550199"
    }
  }
  ```

  ```json 400 Bad Request theme={null}
  {
    "detail": "Contact not found"
  }
  ```

  ```json 401 Unauthorized theme={null}
  {
    "detail": "Unauthorized"
  }
  ```
</ResponseExample>

***

<div
  style={{
display: "flex",
alignItems: "center",
justifyContent: "space-between",
backgroundColor: "rgba(255, 255, 255, 0.03)",
border: "1px solid rgba(255, 255, 255, 0.08)",
borderRadius: "16px",
padding: "10px 18px",
marginTop: "40px",
gap: "16px",
flexWrap: "wrap"
}}
>
  <a
    href="/api-reference/crm/list-tasks"
    style={{
display: "inline-flex",
alignItems: "center",
gap: "6px",
color: "#94A3B8",
textDecoration: "none",
fontSize: "14px",
fontWeight: "500",
padding: "4px 8px"
}}
  >
    <span style={{ fontSize: "16px" }}>‹</span> Previous
  </a>

  <div
    style={{
display: "flex",
alignItems: "center",
gap: "16px",
backgroundColor: "rgba(255, 255, 255, 0.04)",
border: "1px solid rgba(255, 255, 255, 0.06)",
borderRadius: "12px",
padding: "8px 16px",
marginLeft: "auto"
}}
  >
    <div style={{ textAlign: "right" }}>
      <div style={{ fontSize: "13px", fontWeight: "700", color: "#F8FAFC" }}>Get task</div>

      <div style={{ fontSize: "11px", color: "#94A3B8", maxWidth: "260px", overflow: "hidden", textOverflow: "ellipsis", whiteSpace: "nowrap" }}>
        GET /api/v1/crm/tasks/\{task\_id}
      </div>
    </div>

    <div style={{ width: "1px", height: "24px", backgroundColor: "rgba(255, 255, 255, 0.1)" }} />

    <a
      href="/api-reference/crm/get-task"
      style={{
  display: "inline-flex",
  alignItems: "center",
  gap: "6px",
  color: "#94A3B8",
  textDecoration: "none",
  fontSize: "14px",
  fontWeight: "500"
}}
    >
      Next <span style={{ fontSize: "16px" }}>›</span>
    </a>
  </div>
</div>


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.