Skip to main content
POST
/
v1
/
tasks
Create a task
curl --request POST \
  --url https://api.slant.app/v1/tasks \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "book_id": "abc123xyz",
  "title": "Follow up with client",
  "description": "Call to discuss portfolio",
  "deadline_at": "2024-12-31T23:59:59Z",
  "all_day": true,
  "status": "todo",
  "priority": "low_priority",
  "household_id": "<string>",
  "contact_id": "<string>",
  "business_id": "<string>",
  "assigned_to_id": "<string>",
  "assigned_team_id": "<string>"
}
'
{
  "id": "abc123xyz",
  "title": "Follow up with client",
  "all_day": true,
  "status": "todo",
  "created_at": "2023-11-07T05:31:56Z",
  "updated_at": "2023-11-07T05:31:56Z",
  "description": "<string>",
  "deadline_at": "2023-11-07T05:31:56Z",
  "priority": "low_priority",
  "completed_at": "2023-11-07T05:31:56Z",
  "assigned_to": {
    "id": "<string>",
    "name": "<string>",
    "email": "jsmith@example.com"
  },
  "assigned_team": {
    "id": "<string>",
    "name": "<string>"
  },
  "record": {
    "id": "<string>",
    "type": "household",
    "name": "<string>"
  }
}

Authorizations

Authorization
string
header
required

OAuth 2.0 Bearer Token from Clerk authentication

Headers

Idempotency-Key
string

Unique key to ensure idempotent request handling. If a request with the same key was already processed, the original response will be returned.

Body

application/json
book_id
string
required

The book ID

Example:

"abc123xyz"

title
string
required

Task title

Example:

"Follow up with client"

description
string

Task description

Example:

"Call to discuss portfolio"

deadline_at
string<date-time>

Deadline for the task

Example:

"2024-12-31T23:59:59Z"

all_day
boolean
default:true

Whether this is an all-day task

status
enum<string>
default:todo

Task status

Available options:
todo,
done
priority
enum<string>

Task priority

Available options:
low_priority,
medium_priority,
high_priority,
urgent_priority
household_id
string

Associate task with a household (mutually exclusive with contact_id and business_id)

contact_id
string

Associate task with a contact (mutually exclusive with household_id and business_id)

business_id
string

Associate task with a business (mutually exclusive with household_id and contact_id)

assigned_to_id
string

User ID to assign the task to

assigned_team_id
string

Team ID to assign the task to (mutually exclusive with assigned_to_id)

Response

task created

id
string
required

The task ID

Example:

"abc123xyz"

title
string
required

Task title

Example:

"Follow up with client"

all_day
boolean
required

Whether this is an all-day task

status
enum<string>
required

Task status

Available options:
todo,
done
created_at
string<date-time>
required

When the task was created

updated_at
string<date-time>
required

When the task was last updated

description
string | null

Task description

deadline_at
string<date-time> | null

Deadline for the task

priority
enum<string> | null

Task priority

Available options:
low_priority,
medium_priority,
high_priority,
urgent_priority
completed_at
string<date-time> | null

When the task was completed

assigned_to
object
assigned_team
object
record
object

The associated record (household, contact, or business) this task is linked to