Skip to main content
PATCH
/
v1
/
replica
/
{id}
/
chats
/
{chatId}
/
queue
/
reorder
Reorder Chat Queue
curl --request PATCH \
  --url https://api.tryreplicas.com/v1/replica/{id}/chats/{chatId}/queue/reorder \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "messageId": "<string>",
  "position": 123
}
'
{
  "success": true,
  "queue": [
    {
      "id": "<string>",
      "message": "<string>",
      "queuedAt": "2023-11-07T05:31:56Z",
      "senderUserId": "<string>",
      "senderEmail": "<string>",
      "senderDisplayName": "<string>"
    }
  ]
}

Authorizations

Authorization
string
header
required

API key authentication. Obtain your API key from the Replicas dashboard under Settings > API Keys.

Path Parameters

id
string<uuid>
required

The unique identifier of the replica

chatId
string
required

The unique identifier of the chat

Body

application/json

Request to move a queued message to a new position.

messageId
string
required

Queued message ID.

position
integer
required

Zero-based target position.

Response

Queue reordered successfully

Result of a queue mutation.

success
boolean
required

Whether the queue mutation changed the queue.

queue
object[]
required