import requests
url = "https://platform.ankra.app/api/v1/org/support/tickets"
payload = {}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({})
};
fetch('https://platform.ankra.app/api/v1/org/support/tickets', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request POST \
--url https://platform.ankra.app/api/v1/org/support/tickets \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{}'{
"ai_review_status": "pending",
"category": "technical",
"created_at": "2023-11-07T05:31:56Z",
"description": "<string>",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"organisation_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"source": "portal",
"status": "pending_review",
"subject": "<string>",
"ticket_number": 123,
"updated_at": "2023-11-07T05:31:56Z",
"ai_summary": "<string>",
"attachments": [
{
"content_type": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"filename": "<string>",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"size_bytes": 123
}
],
"cluster_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"cluster_name": "<string>",
"comments": [
{
"author_label": "<string>",
"author_type": "customer",
"body": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"author_name": "<string>"
}
],
"is_tracked_by_team": false,
"last_comment_at": "2023-11-07T05:31:56Z",
"last_comment_by": "customer",
"reported_by": "<string>",
"severity": "low"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Create a support ticket
Opens a support ticket and returns it, either from an earlier review (review_id) or directly from a subject and description. Answers 409 when the review has expired or when a flagged draft is sent without acknowledged: true, and 404 for a cluster outside the organisation.
import requests
url = "https://platform.ankra.app/api/v1/org/support/tickets"
payload = {}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({})
};
fetch('https://platform.ankra.app/api/v1/org/support/tickets', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));curl --request POST \
--url https://platform.ankra.app/api/v1/org/support/tickets \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{}'{
"ai_review_status": "pending",
"category": "technical",
"created_at": "2023-11-07T05:31:56Z",
"description": "<string>",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"organisation_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"source": "portal",
"status": "pending_review",
"subject": "<string>",
"ticket_number": 123,
"updated_at": "2023-11-07T05:31:56Z",
"ai_summary": "<string>",
"attachments": [
{
"content_type": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"filename": "<string>",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"size_bytes": 123
}
],
"cluster_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"cluster_name": "<string>",
"comments": [
{
"author_label": "<string>",
"author_type": "customer",
"body": "<string>",
"created_at": "2023-11-07T05:31:56Z",
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"author_name": "<string>"
}
],
"is_tracked_by_team": false,
"last_comment_at": "2023-11-07T05:31:56Z",
"last_comment_by": "customer",
"reported_by": "<string>",
"severity": "low"
}{
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>"
}
]
}Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Body
technical, account, billing, bug, feature_request, other Show child attributes
Show child attributes
10000Show child attributes
Show child attributes
low, medium, high, critical portal, api, cli, agent 200Response
Successful Response
pending, passed, flagged technical, account, billing, bug, feature_request, other portal, api, cli, agent pending_review, open, triaging, in_progress, waiting_customer, resolved, closed Show child attributes
Show child attributes
Show child attributes
Show child attributes
When the latest customer-visible reply on the ticket was written, by the customer or by Ankra support. Null when nobody has replied yet. A reply also moves updated_at; this field names the reply itself, since updated_at moves on status changes too.
Which side wrote the latest customer-visible reply: customer (your organisation) or team (Ankra support). Null when nobody has replied yet.
customer, team low, medium, high, critical