Create a ticket by an agent
POST
/
tickets
Create a ticket by an agent
curl --request POST \
--url http://localhost:3002/api/v1/tickets \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"customerName": "<string>",
"customerEmail": "<string>",
"subject": "<string>",
"description": "<string>"
}
'const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
customerName: '<string>',
customerEmail: '<string>',
subject: '<string>',
description: '<string>'
})
};
fetch('http://localhost:3002/api/v1/tickets', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "http://localhost:3002/api/v1/tickets"
payload = {
"customerName": "<string>",
"customerEmail": "<string>",
"subject": "<string>",
"description": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Body
application/json
Response
200
Ticket created successfully by agent
Last modified on July 18, 2026
⌘I
Create a ticket by an agent
curl --request POST \
--url http://localhost:3002/api/v1/tickets \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"customerName": "<string>",
"customerEmail": "<string>",
"subject": "<string>",
"description": "<string>"
}
'const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
customerName: '<string>',
customerEmail: '<string>',
subject: '<string>',
description: '<string>'
})
};
fetch('http://localhost:3002/api/v1/tickets', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));import requests
url = "http://localhost:3002/api/v1/tickets"
payload = {
"customerName": "<string>",
"customerEmail": "<string>",
"subject": "<string>",
"description": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)