Skip to main content
Authentication required. You must include a valid Bearer token. Only users with the ADMIN or MESA role can call this endpoint.

Endpoint

POST /api/tickets/{ticket_id}/transferir
Moves a ticket to a different department or area and assigns it to an agent in that area. The transfer is recorded via sp_transferir_ticket.

Path parameters

ticket_id
string
required
The UUID of the ticket to transfer.

Request body

nuevaArea
string
required
The name of the target area or department to transfer the ticket to.
agenteId
string
required
The user ID of the agent in the new area who will receive the ticket.
motivo
string
required
The reason for the transfer. This text is stored in the ticket history.

Response

message
string
Confirmation string. Returns "Transferido" on success.

Error codes

StatusDescription
401No token provided or token is invalid.
403Your role is not ADMIN or MESA.
404No ticket found with the given ticket_id.

Example

curl --request POST \
  --url https://your-domain.com/api/tickets/{ticket_id}/transferir \
  --header 'Authorization: Bearer {token}' \
  --header 'Content-Type: application/json' \
  --data '{
    "nuevaArea": "Infraestructura",
    "agenteId": "usr_def456",
    "motivo": "Requires infrastructure team expertise"
  }'
{
  "message": "Transferido"
}

Build docs developers (and LLMs) love