Skip to main content
POST
/
internal
/
unit21-queue
Insert a new item into the unit21 queue
curl --request POST \
  --url https://api.platform.dakota.xyz/internal/unit21-queue \
  --header 'Content-Type: application/json' \
  --header 'x-api-key: <api-key>' \
  --data '
{
  "content": {},
  "type": "entity",
  "external_id": "cust_abc123",
  "next_attempt_at": 1735693200,
  "failed_count": 0,
  "is_dead": false
}
'
{
  "id": "12345",
  "content": {},
  "type": "entity",
  "created_at": 1735693200,
  "failed_count": 0,
  "is_dead": false,
  "external_id": "cust_abc123",
  "completed_at": 1735693200,
  "next_attempt_at": 1735693200
}

Authorizations

x-api-key
string
header
required

Body

application/json
content
object
required

JSON content for the queue item

type
string
required

Type of the queue item

Example:

"entity"

external_id
string

Optional external identifier

Example:

"cust_abc123"

next_attempt_at
integer<int64>

Unix timestamp for next attempt (optional)

Example:

1735693200

failed_count
integer<int64>

Initial failed count (defaults to 0)

Example:

0

is_dead
boolean

Whether the item is dead (defaults to false)

Example:

false

Response

Queue item created successfully

id
string
required

Unique identifier for the queue item

Example:

"12345"

content
object
required

JSON content for the queue item

type
string
required

Type of the queue item

Example:

"entity"

created_at
integer<int64>
required

Unix timestamp when created

Example:

1735693200

failed_count
integer<int64>
required

Number of failed attempts

Example:

0

is_dead
boolean
required

Whether the item is dead

Example:

false

external_id
string

External identifier

Example:

"cust_abc123"

completed_at
integer<int64>

Unix timestamp when completed

Example:

1735693200

next_attempt_at
integer<int64>

Unix timestamp for next attempt

Example:

1735693200