curl --request PATCH \
--url https://api.yo-lead.com/v1/tickets/{ticketId}/status \
--header 'Content-Type: application/json' \
--header 'X-YoLead-Key: <api-key>' \
--header 'X-YoLead-Signature: <api-key>' \
--header 'X-YoLead-Timestamp: <api-key>' \
--data '
{
"status": "active",
"assigneeId": "64f000000000000000000001"
}
'{
"data": {
"ticketId": "64f000000000000000000003",
"chatId": "64f000000000000000000002",
"oldStatus": "new",
"newStatus": "active",
"assigneeId": "64f000000000000000000001"
}
}Change ticket status
Changes the status of the current ticket in a chat. Allowed transitions are new to active, active to inactive, and inactive to active.
Required API key scope: read-write.
When activating a new ticket, assigneeId is required and must reference an active employee with access to the ticket channel. When reactivating an inactive ticket, assigneeId may be omitted or must match the existing assignee. assigneeId is not allowed when setting status to inactive.
The status endpoint cannot move tickets into or out of pending_assignment. Use the assignee endpoint to remove an active ticket’s assignee or assign a queued ticket. A queued ticket must be assigned before it can be closed. Each successful status transition, including taking a new ticket into work, emits one ticket.status_changed webhook with required assigneeId containing the saved employee ID or null. The webhook actor identifies the initiator and can differ from the assignee. No additional ticket.assignee_changed webhook is emitted for these status transitions.
curl --request PATCH \
--url https://api.yo-lead.com/v1/tickets/{ticketId}/status \
--header 'Content-Type: application/json' \
--header 'X-YoLead-Key: <api-key>' \
--header 'X-YoLead-Signature: <api-key>' \
--header 'X-YoLead-Timestamp: <api-key>' \
--data '
{
"status": "active",
"assigneeId": "64f000000000000000000001"
}
'{
"data": {
"ticketId": "64f000000000000000000003",
"chatId": "64f000000000000000000002",
"oldStatus": "new",
"newStatus": "active",
"assigneeId": "64f000000000000000000001"
}
}Authorizations
Path Parameters
Body
Ticket status transition.