The short answer: the API reads your account's support tickets, opens new ones, replies and closes them, and reads Knowledge Base articles and announcements. Tickets are always in your account's name. You read with support:read and write with support:write.
Reading tickets and departments
| Operation |
What it does |
| GET /v1/tickets |
The account's tickets, most recent reply first, in pages. Filter ?status=open. |
| GET /v1/tickets/{id} |
One ticket, by number, with every message, oldest first. For attachments, only the name comes back. |
| GET /v1/support/departments |
The departments that can receive tickets. |
Opening a ticket
curl https://api.mozout.com/v1/tickets -X POST \
-H "Authorization: Bearer $RLX_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: 2c5e8f1a-4b7d-4e9a-b3c6-d8f0a1b2c3d4" \
-d '{"department_id": 1, "subject": "Help with the plan", "message": "I need help with my plan."}'
| 1 |
Pick the department with GET /v1/support/departments and use its department_id.
|
|
| 2 |
Link the ticket to what it is about: a service with service_id or a domain with domain_id. Priority can be low, medium or high.
|
|
| 3 |
Always send Idempotency-Key: retrying with the same key does not open another ticket.
|
|
You can open up to 10 tickets per hour, per account. A department that needs extra details answers 422 with department_portal_only: open that ticket in My MozOut. With a Sandbox key, no ticket is created and the id is null.
Replying and closing
| Operation |
What it does |
| POST /v1/tickets/{id}/replies |
Adds your reply. Replying to a closed ticket reopens it, and reopened is true. Up to 30 replies per hour, per account. Send an Idempotency-Key so a retry does not reply twice. |
| POST /v1/tickets/{id}/close |
Closes the ticket. Some can only be closed by our team: for those it answers 409 closure_not_allowed. |
|
Opening, replying and closing through the API sends the same e-mails as in My MozOut, including the satisfaction survey on closing. For a program that runs on its own, bear that in mind before opening tickets in bulk. Attachments cannot be sent through the API yet: add them in My MozOut.
|
Knowledge Base and announcements
Only published articles come back, in the Accept-Language language when a translation exists. Searching is limited to 30 per minute, per account.
| Operation |
What it returns |
| GET /v1/kb/categories |
The categories. |
| GET /v1/kb/articles |
The articles. Use q to search and category to pick a category. |
| GET /v1/kb/articles/{id} |
One article, with the text in HTML. |
| GET /v1/announcements, /v1/announcements/{id} |
Published announcements, most recent first, and the text of each. |
|
A practical idea: your monitoring system notices the site is down and opens a ticket linked to the service straight away, with the time and what it saw; before that, it shows your team the Knowledge Base articles found by a q search. Response times are in the Support Policy.
|
|
Want to connect your system to our support? See the API page and test with a Sandbox key, which creates no tickets.
See the API page
|
RECOMMENDED PRODUCT Web hosting with cPanel Domain and SSL included, daily backups and the panel you already know. from R118.80/mo (3-year plan, with coupon) See plans |