Skip to main content
POST
/
tasks
Create a task
curl --request POST \
  --url https://api.salesive.com/api/v1/tasks \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "title": "Restock best-sellers",
  "details": "Reorder the top 10 SKUs before the weekend.",
  "dueDate": "2026-07-03T17:00:00.000Z",
  "status": "to do",
  "recurring": "weekly",
  "recurringSchedule": {
    "every": 1,
    "until": "2026-12-31T00:00:00.000Z"
  },
  "isAI": false,
  "assignees": [
    "66a0c1d2e3f4a5b6c7d8e9f0"
  ]
}
'
{
  "status": 201,
  "success": true,
  "message": "Task created",
  "data": {
    "_id": "66c1f0a3c2d4e5f6a7b8c9d0",
    "title": "Restock best-sellers",
    "details": "Reorder the top 10 SKUs before the weekend.",
    "dueDate": "2026-07-03T17:00:00.000Z",
    "status": "to do",
    "recurring": "weekly",
    "recurringSchedule": {
      "every": 1,
      "until": "2026-12-31T00:00:00.000Z"
    },
    "isAI": false,
    "assignees": [
      "66a0c1d2e3f4a5b6c7d8e9f0"
    ],
    "shop": "6680aabbccddeeff00112200",
    "createdBy": "66a0c1d2e3f4a5b6c7d8e9f0",
    "createdAt": "2026-06-21T10:30:00.000Z",
    "updatedAt": "2026-06-21T10:30:00.000Z"
  }
}
Creates a task; recurringSchedule is required when recurring is daily, weekly or monthly. The store is bound to your app token server-side — never send a shop id.

Authorizations

Authorization
string
header
required

Installed-app access token (prefix app_), issued by the OAuth install flow. The store is bound to the token server-side — never send a shop id.

Body

application/json
title
string
required

Task title.

details
string

Free-text task details.

dueDate
string<date-time> | null

When the task is due (ISO 8601), or null.

status
enum<string>
default:to do

Task status.

Available options:
to do,
in progress,
done,
skipped
recurring
enum<string>
default:none

Recurrence cadence.

Available options:
none,
daily,
weekly,
monthly
recurringSchedule
object

Recurrence schedule. Required when recurring is daily, weekly or monthly.

isAI
boolean
default:false

Whether the task was generated by AI.

assignees
string[]

User ObjectId strings assigned to the task.

Response

The created task.

Standard Salesive response envelope. The operation-specific payload is carried in data.

status
integer
required

HTTP status code, echoed in the body.

success
boolean
required

Whether the request succeeded.

message
string
required

Human-readable result message.

data
object

A task belonging to the store.