API v1
v1
View as Markdown

List support requests of the instance

GET /api/v1/admin/support-requests

List the support requests of every account, the oldest first, 50 to a page. The thread, the account facts and the status changes are left out of a list. Read one request to get them.

Only an administrator of this instance can use these endpoints, and only with an API key that carries the administration scope by name. Anybody else, including an administrator whose key does not carry it, gets 404 as though the endpoint did not exist.

This endpoint also answers QUERY, with the same parameters sent in the request body. How QUERY works.

Query parameters

Sent as JSON. Anything not listed here is ignored.

view string Optional default: to_handle

Which requests to list: to_handle, waiting_on_user, solved or all. Any other value is taken as to_handle.

q string Optional

Keep only the requests that mention this text.

category string Optional

Keep only one category: feature, billing, email, question or technical.

user integer Optional

Keep only the requests of the user with this id.

age string Optional

Keep only the requests of one age: day for under 24 hours, week for 1 to 7 days, old for older than 7 days.

page integer Optional default: 1

Which page to answer with.

Returns

A page of support request objects, how many there are in all, and in meta.counts how many each view holds.

data array

The support requests on this page. An empty list rather than an error when there are none.

data[] object

One support request.

data[].type string

Always support_request. It names the kind of record, so a caller holding several kinds can tell them apart without looking at where they came from.

data[].id string

The id of this record, as a string even when it reads as a number. It is what every endpoint naming this record takes.

data[].attributes object

Everything the record holds.

data[].attributes.reference string

The reference the person quotes when writing to the support team, such as MON-482913.

data[].attributes.account_id integer

The account the request was opened from.

data[].attributes.user object

Who asked.

data[].attributes.user.name string

The name of the person who opened the request, or null once their user is deleted.

data[].attributes.user.email string

Where replies are emailed, or null once their user is deleted.

data[].attributes.category string

What the request is about: feature, billing, email, question or technical.

data[].attributes.subject string

The title the request was opened with.

data[].attributes.status string

to_handle when the person is waiting for an answer, waiting_on_user when the team is, or solved.

data[].attributes.status_label string

The status as the administrators read it, in the language of the signed in administrator.

data[].attributes.application_version string

The version of the application the request was opened from.

data[].attributes.locale string

The language the person was using when they opened it.

data[].attributes.opened_at timestamp

When the request was opened, as a count of seconds since 1970.

data[].attributes.last_activity_at timestamp

When anybody last wrote in it, the person who asked or the support team, as a count of seconds since 1970. A change of status alone does not move it.

data[].attributes.solved_at timestamp

When it was marked as solved, as a count of seconds since 1970, or null while it is open.

data[].links object

Where to find this record.

data[].links.self string

The absolute address this record is read from.

meta object

Where you are in the collection.

meta.page integer

The page this is, counting from 1.

meta.per_page integer

How many one page holds, which is the size that was asked for once it has been brought into the allowed range.

meta.total integer

How many support requests there are in all, not how many are on this page.

meta.counts object

How many requests each view holds under the filters you sent, apart from the view itself.

meta.counts.to_handle integer

Requests waiting for an answer.

meta.counts.waiting_on_user integer

Requests answered and waiting on the person.

meta.counts.solved integer

Requests marked as solved.

meta.counts.all integer

Every request.

Rate limit

Sixty requests per minute, per user, shared by every key and device. Every answer carries the budget left in X-RateLimit-Remaining.

GET
curl https://my.monicahq.com/api/v1/admin/support-requests \
-H "Authorization: Bearer $MONICA_TOKEN"
const response = await fetch('https://my.monicahq.com/api/v1/admin/support-requests', {
headers: { Authorization: `Bearer ${token}` },
})
const data = await response.json()
$response = Http::withToken($token)->get('https://my.monicahq.com/api/v1/admin/support-requests');
Response 200
{
"data": [
{
"type": "support_request",
"id": "7c1e4a92-5b3d-4f08-a6e1-93d2c8b05f17",
"attributes": {
"reference": "MON-482913",
"account_id": 12,
"user": {
"name": "Michael Scott",
"email": "[email protected]"
},
"category": "question",
"subject": "My conference room reminder never arrived",
"status": "waiting_on_user",
"status_label": "Waiting on the user",
"application_version": "5.0.0",
"locale": "en",
"opened_at": 1791547200,
"last_activity_at": 1791550800,
"solved_at": null
},
"links": {
"self": "https://my.monicahq.com/api/v1/admin/support-requests/7c1e4a92-5b3d-4f08-a6e1-93d2c8b05f17"
}
}
],
"meta": {
"page": 1,
"per_page": 50,
"total": 1,
"counts": {
"to_handle": 0,
"waiting_on_user": 1,
"solved": 0,
"all": 1
}
}
}

Keys act as you, with exactly the access you have. Make one per integration so you can revoke it alone.