Skip to main content
POST
/
tasks
/
_raw
Create a new task
curl --request POST \
  --url https://api.gospott.com/tasks/_raw \
  --header 'Content-Type: application/json' \
  --header 'x-api-key: <api-key>' \
  --data '
{
  "content": "Follow up with candidate about interview availability",
  "dueDate": "2024-12-31T23:59:59.000Z",
  "assignedToUserId": "550e8400-e29b-41d4-a716-446655440000",
  "links": [
    {
      "taskLinkId": null,
      "entityType": "candidate",
      "entityId": "550e8400-e29b-41d4-a716-446655440000"
    }
  ]
}
'
{
  "id": "<string>",
  "content": "<string>",
  "dueDate": "2023-11-07T05:31:56Z",
  "isCompleted": true,
  "completedAt": "2023-11-07T05:31:56Z",
  "createdAt": "2023-11-07T05:31:56Z",
  "createdBy": {
    "id": "<string>",
    "name": "<string>",
    "avatarUrl": "<string>",
    "deactivatedAt": "2023-11-07T05:31:56Z"
  },
  "assignedTo": {
    "id": "<string>",
    "name": "<string>",
    "avatarUrl": "<string>",
    "deactivatedAt": "2023-11-07T05:31:56Z"
  },
  "links": {
    "candidates": [
      {
        "taskLinkId": "<string>",
        "isMention": true,
        "id": "<string>",
        "firstName": "<string>",
        "lastName": "<string>",
        "middleName": "<string>",
        "secondLastName": "<string>",
        "avatarUrl": "<string>"
      }
    ],
    "vacancies": [
      {
        "taskLinkId": "<string>",
        "isMention": true,
        "id": "<string>",
        "name": "<string>",
        "companyId": "<string>",
        "companyName": "<string>",
        "companyLogoUrl": "<string>"
      }
    ],
    "clients": [
      {
        "taskLinkId": "<string>",
        "isMention": true,
        "id": "<string>",
        "name": "<string>",
        "logoUrl": "<string>"
      }
    ],
    "users": [
      {
        "taskLinkId": "<string>",
        "isMention": true,
        "id": "<string>",
        "name": "<string>",
        "avatarUrl": "<string>",
        "deactivatedAt": "2023-11-07T05:31:56Z"
      }
    ],
    "teams": [
      {
        "taskLinkId": "<string>",
        "isMention": true,
        "id": "<string>",
        "name": "<string>",
        "avatarUrl": "<string>"
      }
    ],
    "clientContacts": [
      {
        "taskLinkId": "<string>",
        "isMention": true,
        "id": "<string>",
        "firstName": "<string>",
        "lastName": "<string>",
        "middleName": "<string>",
        "secondLastName": "<string>",
        "avatarUrl": "<string>",
        "candidateId": "<string>",
        "companyId": "<string>",
        "companyName": "<string>",
        "companyLogoUrl": "<string>"
      }
    ]
  }
}

Authorizations

x-api-key
string
header
required

API key for authentication. Get your API key from Settings → API Keys in your Spott dashboard.

Body

application/json
content
string
required

The content/description of the task.

Example:

"Follow up with candidate about interview availability"

dueDate
string<date-time> | null
required

The due date for the task, or null if no due date

Example:

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

assignedToUserId
string | null
required

The user ID to assign the task to, or null for unassigned tasks

Example:

"550e8400-e29b-41d4-a716-446655440000"

Links to related entities (candidates, vacancies, clients, etc.)

Response

Task created successfully

id
string
required
content
string
required
dueDate
string<date-time> | null
required
isCompleted
boolean
required
completedAt
string<date-time> | null
required
createdAt
string<date-time>
required
createdBy
object
required
assignedTo
object
required