const url = 'https://app.monitorly.cloud/api/v1/incidents/INCIDENT_ID/page-drafts';const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://app.monitorly.cloud/api/v1/incidents/INCIDENT_ID/page-drafts \ --header 'Authorization: Bearer <token>'Draft posts for an incident, one per status page of the project that shows its check, with that check’s components, a title, a state and a text. Nothing is created or sent. Needs the editor role.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”The incident’s id.
Example
INCIDENT_IDResponses
Section titled “Responses”The drafts.
object
The page’s components on the incident’s check, with the suggested impact.
object
How badly a manual incident affects a component. While the incident is not resolved, the page shows the component as degraded performance, partial outage or major outage, unless its check is worse.
investigating while the automatic incident is open, resolved once it closed.
<check>: outage or <check>: degraded performance.
Example
[ { "autoIncidentId": "AUTO_INCIDENT_ID", "components": [ { "componentId": "COMPONENT_ID", "impact": "degraded" } ], "pageId": "PAGE_ID", "state": "investigating" }]Bad Request.
auth.credentials_conflict: the request carries both a session cookie and a token
object
Field errors, empty for errors of the whole request.
object
object
JSON pointer into the request body.
Stable code, for example check.timeout_exceeds_interval.
Example generated
{ "detail": "example", "errors": [ { "code": "example", "params": { "additionalProperty": "example" }, "pointer": "example" } ], "status": 1, "title": "example", "type": "example"}Unauthorized.
auth.unauthenticated,auth.session_expired: no session, or it endedtoken.invalid: the token is malformed, unknown, revoked or expired, or its creator left the workspace
object
Field errors, empty for errors of the whole request.
object
object
JSON pointer into the request body.
Stable code, for example check.timeout_exceeds_interval.
Example generated
{ "detail": "example", "errors": [ { "code": "example", "params": { "additionalProperty": "example" }, "pointer": "example" } ], "status": 1, "title": "example", "type": "example"}Forbidden.
auth.forbidden: your role is too low for thistoken.scope_missing: the token lacks the scope this needs;detailnames it
object
Field errors, empty for errors of the whole request.
object
object
JSON pointer into the request body.
Stable code, for example check.timeout_exceeds_interval.
Example generated
{ "detail": "example", "errors": [ { "code": "example", "params": { "additionalProperty": "example" }, "pointer": "example" } ], "status": 1, "title": "example", "type": "example"}Not Found.
request.not_found: it does not exist, or you cannot see it
object
Field errors, empty for errors of the whole request.
object
object
JSON pointer into the request body.
Stable code, for example check.timeout_exceeds_interval.
Example generated
{ "detail": "example", "errors": [ { "code": "example", "params": { "additionalProperty": "example" }, "pointer": "example" } ], "status": 1, "title": "example", "type": "example"}Too Many Requests.
token.rate_limited: more than 10 requests a second with this token
object
Field errors, empty for errors of the whole request.
object
object
JSON pointer into the request body.
Stable code, for example check.timeout_exceeds_interval.
Example generated
{ "detail": "example", "errors": [ { "code": "example", "params": { "additionalProperty": "example" }, "pointer": "example" } ], "status": 1, "title": "example", "type": "example"}Headers
Section titled “Headers”Seconds to wait before trying again.