Create incident
POST
/incidents
Authentication
Bearer Token (hu_api_key)
Request Body required
application/jsontitle
string
REQUIRED
severity
string
REQUIRED
Enum:
minor, major, criticalstatus
string
REQUIRED
Enum:
investigating, identified, monitoring, resolvedmessage
string
monitor_ids
string[]
Array of:
Responses
201
Incident created
application/jsondata
object
title
string
REQUIRED
severity
string
REQUIRED
Enum:
minor, major, criticalstatus
string
REQUIRED
Enum:
investigating, identified, monitoring, resolvedmessage
string
monitor_ids
string[]
Array of:
curl -X POST 'https://happyuptime.com/api/v1/incidents' \ -H 'Authorization: Bearer YOUR_API_TOKEN' \ -H 'Content-Type: application/json' \ -d '{ "title": "string", "severity": "minor", "status": "investigating", "message": "string", "monitor_ids": [ "string" ]}'
const response = await fetch('https://happyuptime.com/api/v1/incidents', { method: 'POST', headers: { "Authorization": "Bearer YOUR_API_TOKEN", "Content-Type": "application/json" }, body: JSON.stringify({ "title": "string", "severity": "minor", "status": "investigating", "message": "string", "monitor_ids": [ "string" ] })});const data = await response.json();console.log(data);
import requestsheaders = { 'Authorization': 'Bearer YOUR_API_TOKEN'}response = requests.post('https://happyuptime.com/api/v1/incidents', headers=headers, json={ "title": "string", "severity": "minor", "status": "investigating", "message": "string", "monitor_ids": [ "string" ]})print(response.json())
201
Response
{ "data": { "title": "<string>", "severity": "minor", "status": "investigating", "message": "<string>", "monitor_ids": [ "<string>" ] }}
API Playground
Try this endpoint
POST
/incidents