StatusHub API documentation

Table of contents

  1. Status page
  2. Incident
  3. Incident update
  4. Service status
  5. Maintenance
  6. Subscriber

Introduction

StatusHub provides an API that gives access to status pages and status updates. The API is built using RESTful principles. JSON is supported as responses to API calls.

Version

The current version is 1.0. To user specific version of our API you must provide request header for its specific version. If header is not added the most recent version of API will be used.

Example

Header to choose version 1 of the StatusHub API:

'Accept: application/vnd.statushub.v1'

Authentication

Authentication is performed with API Key. To generate API Key please sign in to StatusHub, go to tab "Account" and then choose "API Key" from menu. API Key should be passed as a part of a query string with name api_key.

Response Codes

We return the following response codes:

Response Code Description
200 Success / 201 Created Everything went fine
202 Accepted Everything went fine.
422 Unprocessable Entity You tried to create or update an object with invalid data.
404 Not Found You tried to access an object that does not exist in your account.
400 Bad Request You tried to create or update an object with invalid data.
500 Internal Server Error Oops. Something went wrong on our end. Don't worry, we're on the case!

Status Page

Index Status Pages

Indexes user status pages.

Request arguments
Property Type Description
per_page integer Default is 25. A limit on the number of objects to be returned.
page integer Number of paginated page.
Response arguments
Property Type Description
id integer Id of status page
name string Name of status page
updated_at datetime Date of status page update.
logo object Logo image for status page.
services_count integer Amount of services
down_services_count integer Amount of down services
subdomain string Name of subdomain

EXAMPLE REQUEST

curl -X GET -H "Content-type: application/json" -d '{"api_key":"zUYwqLqwTqpyJ2bA7osy"}' https://api.statushub.io/api/status_pages

EXAMPLE RESPONSE

[
   {
      "id":12,
      "name":"Example",
      "updated_at":"2013-09-27T08:28:22Z",
      "logo":null,
      "services_count":1,
      "down_services_count":0,
      "subdomain":"samplesubdomain"
   }
]

EXAMPLE REQUEST

class StatusPage < ActiveResource::Base
  self.site = "https://api.statushub.io/api"
end
StatusPage.find(:all, :params => {:api_key => "mChkJMujDrHGvPMvcsEx", :page => 1, :per_page => 15})

EXAMPLE RESPONSE

[
    #<StatusPage:0x007f85c0e7f660 @attributes={
        "id"=>23,
        "name"=>"Status Page Name",
        "updated_at"=>"2013-09-25T15:28:07Z",
        "logo"=>nil,
        "services_count"=>1,
        "down_services_count"=>0,
        "subdomain"=>"subdomain"
    },
    @prefix_options={},
    @persisted=true>
]

Show Status Pages

Returns user status page.

Request arguments
Property Type Description
id string name of status page subdomain
Response arguments
Property Type Description
id integer Id of status page
name string Name of status page
updated_at datetime Date of status page update
logo object Logo image for status page
services_count integer Amount of services
down_services_count integer Amount of down services
subdomain string Name of subdomain
latest_status_update object Latest created status update for status page
services array List of status page services. Service has its name and name of status state "up"/"down"

EXAMPLE REQUEST

curl -X GET -H "Content-type: application/json" -d '{"api_key":"zUYwqLqwTqpyJ2bA7osy"}' https://api.statushub.io/api/status_pages/samplesubdomain

EXAMPLE RESPONSE

{
   "id":12,
   "name":"Example",
   "updated_at":"2013-09-27T08:28:22Z",
   "logo":null,
   "services_count":1,
   "down_services_count":0,
   "subdomain":"samplesubdomain",
   "services":[
      {
        "id":42
        "name":"Availability",
        "updated_at":"2013-09-23T12:28:27Z",
        "up":true
      }
   ]
}

EXAMPLE REQUEST

class StatusPage < ActiveResource::Base
  self.site = "https://api.statushub.io/api"
end
StatusPage.find("subdomain", :params => {:api_key => "mChkJMujDrHGvPMvcsEx"})

EXAMPLE RESPONSE

<StatusPage:0x007f85bb2c08b0 @attributes={
    "id"=>23,
    "name"=>"Status Page Name",
    "updated_at"=>"2013-09-25T16:07:44Z",
    "logo"=>nil,
    "services_count"=>1,
    "down_services_count"=>0,
    "subdomain"=>"subdomain",
    "services"=>[
        #<StatusPage::Service:0x007f85bb2d9e28 @attributes={
            "id"=>42
            "name"=>"Availability",
            "updated_at"=>"2013-09-23T10:48:21Z",
            "up"=>true
        },
        @prefix_options={},
        @persisted=false>
    ]
},
@prefix_options={},
@persisted=true>

Set/clear Platform Alert

Set/clear or update platform alert

URL: https://api.statushub.io/api/status_pages/:subdomain/platform_alert

Request arguments
Property Type Required? Description
alert_enabled boolean yes 'true' to enable alert, 'false' to disable it
alert_title text only if 'alert_enabled' is 'true' title of the alert
alert_message text only if 'alert_enabled' is 'true' message of the alert
Response arguments
Property Type Description
status string response message

EXAMPLE REQUEST

curl -X POST -H "Content-type: application/json" -d '{"api_key":"2iZGUdJXzbYtpE44kBuD", "status_page": {"alert_enabled": "true", "alert_title": "Title of the alert", "alert_message": "Message of the alert"}}'  https://api.statushub.io/api/status_pages/samplesubdomain/platform_alert

EXAMPLE RESPONSE

 {
   "status": "OK"
 }

MISSING PARAMETER RESPONSE

 {
   "status": "Invalid Parameters: param is missing or the value is empty: alert_title"
 }

Incident

Index Incident

Indexes user status pages.

URL: https://api.statushub.io/api/status_pages/:subdomain/services/:service_id/incidents

Request arguments
Property Type Description
per_page integer Default is 25. A limit on the number of objects to be returned.
page integer Number of paginated page.
Response arguments
Property Type Description
id integer Id number
title string Title of incident
start_time datetime Date of incident occurrence
created_at datetime Date of creation
updated_at datetime Date of update
incident_updates Array List of incident updates which has incident state
Incident Update Response arguments
Property Type Description
id integer Id number
body text Message of Incident Update
incident_type string Incident status name
start_time datetime Date of incident update occurrence
created_at datetime Date of creation
updated_at datetime Date of update

EXAMPLE REQUEST

curl -X GET -H "Content-type: application/json" -d '{"api_key":"2iZGUdJXzbYtpE44kBuD", "per_page":1}' https://api.statushub.io/api/status_pages/samplesubdomain/services/42/incidents

EXAMPLE RESPONSE

[
   {
      "id":1,
      "title":"htd",
      "start_time":"2013-10-11T08:12:52Z",
      "created_at":"2013-10-10T16:33:53Z",
      "updated_at":"2013-10-10T16:33:53Z",
      "incident_updates":[
         {
            "id":157,
            "body":"message",
            "incident_type":"investigating",
            "start_time":"2013-10-11T08:12:52Z",
            "created_at":"2013-10-11T07:07:12Z",
            "updated_at":"2013-10-11T07:07:12Z"
         }
      ]
   }
]

Create Incident

Create incident and its status.

URL: https://api.statushub.io/api/status_pages/:subdomain/services/:service_id/incidents

Request arguments
Property Type Description
title string Title of Incident
start_time string Time of incident occurrence (optional, current time if not used)
update hash Incident Update
Incident Update arguments
Property Type Description
body text Message of incident update
incident_type string Incident Status. It's one of these values: investigating, resolved, monitoring, identified
Response arguments
Property Type Description
id integer Id number
title string Title of incident
start_time datetime Date of incident occurrence
created_at datetime Date of creation
updated_at datetime Date of update
incident_updates Array List of incident updates which has incident state
Incident Update Response arguments
Property Type Description
id integer Id number
body text Message of Incident Update
incident_type string Incident status name
start_time datetime Date of incident update occurrence
created_at datetime Date of creation
updated_at datetime Date of update

To change status of service while adding incident use optional argument service_status

Service status arguments
Property Type Description
status_name string Name of status. One of these values: up, degraded-performance, down

EXAMPLE REQUEST (without changing service status)

curl -X POST -H "Content-type: application/json" -d '{"api_key":"2iZGUdJXzbYtpE44kBuD", "incident": { "title": "title", "update" :{"body": "message", "incident_type":"investigating"} }}' https://api.statushub.io/api/status_pages/samplesubdomain/services/42/incidents

EXAMPLE REQUEST (with updating service status)

curl -X POST -H "Content-type: application/json" -d '{"api_key":"2iZGUdJXzbYtpE44kBuD", "incident": { "title": "title", "update" :{"body": "message", "incident_type":"investigating"}}, "service_status": {"status_name": "degraded-performance"} }' https://api.statushub.io/api/status_pages/samplesubdomain/services/42/incidents

EXAMPLE RESPONSE

{
   "id":80,
   "title":"title",
   "start_time":"2013-10-11T08:12:52Z",
   "created_at":"2013-10-11T08:12:52Z",
   "updated_at":"2013-10-11T08:12:52Z",
   "incident_updates":[
      {
         "id":158,
         "body":"message",
         "incident_type":"investigating",
         "start_time":"2013-10-11T08:12:52Z",
         "created_at":"2013-10-11T08:12:52Z",
         "updated_at":"2013-10-11T08:12:52Z"
      }
   ]
}

Show Incident

Show Incident details.

URL: https://api.statushub.io/api/status_pages/:subdomain/services/:service_id/incidents/:id

Response arguments
Property Type Description
id integer Id number
title string Title of incident
start_time datetime Date of incident occurrence
created_at datetime Date of creation
updated_at datetime Date of update
incident_updates Array List of incident updates which has incident state
Incident Update Response arguments
Property Type Description
id integer Id number
body text Message of Incident Update
incident_type string Incident status name
start_time datetime Date of incident update occurrence
created_at datetime Date of creation
updated_at datetime Date of update

EXAMPLE REQUEST

curl -X GET -H "Content-type: application/json" -d '{"api_key":"2iZGUdJXzbYtpE44kBuD" }' https://api.statushub.io/api/status_pages/samplesubdomain/services/42/incidents/80

EXAMPLE RESPONSE

{
  "id":80,
  "title":"title",
  "start_time":"2013-10-11T08:12:52Z",
  "created_at":"2013-10-11T08:12:52Z",
  "updated_at":"2013-10-11T08:12:52Z",
  "incident_updates":[
    {
        "id":158,
        "body":"message",
        "incident_type":"investigating",
        "created_at":"2013-10-11T08:12:52Z",
        "updated_at":"2013-10-11T08:12:52Z"
    }
  ]
}

Update Incident

Update incident attributes.

URL: https://api.statushub.io/api/status_pages/:subdomain/services/:service_id/incidents/:id

Request arguments
Property Type Description
title string Title of Incident
Response arguments
Property Type Description
id integer Id number
title string Title of incident
start_time datetime Date of incident occurrence
created_at datetime Date of creation
updated_at datetime Date of update

EXAMPLE REQUEST

curl -X PUT -H "Content-type: application/json" -d '{"api_key":"2iZGUdJXzbYtpE44kBuD", "incident": { "title": "Changed title"}}' https://api.statushub.io/api/status_pages/samplesubdomain/services/42/incidents/80

EXAMPLE RESPONSE

{
  "id":80,
  "title":"title",
  "start_time":"2013-10-11T08:12:52Z",
  "created_at":"2013-10-11T08:12:52Z",
  "updated_at":"2013-10-11T08:12:52Z",
}

Delete Incident

Remove incident and its incident updates.

URL: https://api.statushub.io/api/status_pages/:subdomain/services/:service_id/incidents/:id

Response arguments
Property Type Description
status string Status of incident removing action

EXAMPLE REQUEST

curl -X DELETE -H "Content-type: application/json" -d '{"api_key":"2iZGUdJXzbYtpE44kBuD"}' https://api.statushub.io/api/status_pages/samplesubdomain/services/42/incidents/80

EXAMPLE RESPONSE

{"status":"OK"}

Incident Update

Index incident updates

List incident updates for an incident.

URL: https://api.statushub.io/api/status_pages/:subdomain/services/:service_id/incidents/:incident_id/incident_updates

Request arguments
Property Type Description
per_page integer Default is 25. A limit on the number of objects to be returned.
page integer Number of paginated page.
Response arguments
Property Type Description
id integer Id number for incident update
body text Message of incident update
incident_type string Incident Status. It's one of these values: investigating, resolved, monitoring, identified
start_time datetime Date of incident update occurrence
created_at datetime Date of creation
updated_at datetime Date of update

EXAMPLE REQUEST

curl -X GET -H "Content-type: application/json" -d '{"api_key":"2iZGUdJXzbYtpE44kBuD","per_page": 1}'  https://api.statushub.io/api/status_pages/samplesubdomain/services/42/incidents/1/incident_updates

EXAMPLE RESPONSE

[
   {
      "id":155,
      "body":"message",
      "incident_type":"resolved",
      "start_time":"2013-10-10T16:33:53Z",
      "created_at":"2013-10-10T16:33:53Z",
      "updated_at":"2013-10-10T16:33:53Z"
   }
]

Create incident updates

Create incidents status.

URL: https://api.statushub.io/api/status_pages/:subdomain/services/:service_id/incidents/:incident_id/incident_updates

Request arguments
Property Type Description
body text Message of incident update
incident_type string Incident Status. It's one of these values: investigating, resolved, monitoring, identified
start_time datetime Date of incident update occurrence
Response arguments
Property Type Description
id integer Id number for incident update
body text Message of incident update
incident_type string Incident Status
start_time datetime Date of incident update occurrence
created_at datetime Date of creation
updated_at datetime Date of update

To change status of service while creating incident update use optional argument service_status

Service status arguments
Property Type Description
status_name string Name of status. One of these values: up, degraded-performance, down

EXAMPLE REQUEST (without updating service status)

curl -X POST -H "Content-type: application/json" -d '{"api_key":"2iZGUdJXzbYtpE44kBuD", "incident_update": { "body": "message", "incident_type":"investigating"}}' https://api.statushub.io/api/status_pages/samplesubdomain/services/42/incidents/1/incident_updates

EXAMPLE REQUEST (with service status update)

curl -X POST -H "Content-type: application/json" -d '{"api_key":"2iZGUdJXzbYtpE44kBuD", "incident_update": { "body": "message", "incident_type":"investigating"}, "service_status": {"status_name": "up"}}' https://api.statushub.io/api/status_pages/samplesubdomain/services/42/incidents/1/incident_updates

EXAMPLE RESPONSE

{
   "id":157,
   "body":"message",
   "incident_type":"investigating",
   "start_time":"2013-10-11T07:07:12Z",
   "created_at":"2013-10-11T07:07:12Z",
   "updated_at":"2013-10-11T07:07:12Z"
}

Show incident updates

Show incident update attributes.

URL: https://api.statushub.io/api/status_pages/:subdomain/services/:service_id/incidents/:incident_id/incident_updates/:id

Response arguments
Property Type Description
id integer Id number for incident update
body text Message of incident update
incident_type string Incident Status
start_time datetime Date of incident update occurrence
created_at datetime Date of creation
updated_at datetime Date of update

EXAMPLE REQUEST

curl -X GET -H "Content-type: application/json" -d '{"api_key":"2iZGUdJXzbYtpE44kBuD"}' https://api.statushub.io/api/status_pages/samplesubdomain/services/42/incidents/1/incident_updates/1

EXAMPLE RESPONSE

{
   "id":1,
   "body":"message",
   "incident_type":"investigating",
   "start_time":"2013-10-10T16:33:53Z",
   "created_at":"2013-10-10T16:33:53Z",
   "updated_at":"2013-10-10T16:33:53Z"
}

Update incident updates

Update incident updates attributes.

URL: https://api.statushub.io/api/status_pages/:subdomain/services/:service_id/incidents/:incident_id/incident_updates/:id

Request arguments
Property Type Description
body text Message of incident update
incident_type string Incident Status. It's one of these values: investigating, resolved, monitoring, identified
Response arguments
Property Type Description
id integer Id number for incident update
body text Message of incident update
incident_type string Incident Status
start_time datetime Date of incident update occurrence
created_at datetime Date of creation
updated_at datetime Date of update

EXAMPLE REQUEST

curl -X PUT -H "Content-type: application/json" -d '{"api_key":"2iZGUdJXzbYtpE44kBuD", "incident_update": { "body": "Changed message", "incident_type":"investigating"}}' https://api.statushub.io/api/status_pages/samplesubdomain/services/42/incidents/1/incident_updates/1

EXAMPLE RESPONSE

{
   "id":1,
   "body":"Changed message",
   "incident_type":"investigating",
   "start_time":"2013-10-10T16:33:53Z",
   "created_at":"2013-10-10T16:33:53Z",
   "updated_at":"2013-10-11T07:12:55Z"
}

Delete incident updates

Remove incident update.

URL: https://api.statushub.io/api/status_pages/:subdomain/services/:service_id/incidents/:incident_id/incident_updates/:id

Response arguments
Property Type Description
status string Status of incident removing action

EXAMPLE REQUEST

curl -X DELETE -H "Content-type: application/json" -d '{"api_key":"2iZGUdJXzbYtpE44kBuD"}' https://api.statushub.io/api/status_pages/samplesubdomain/services/42/incidents/1/incident_updates/1

EXAMPLE RESPONSE

{"message":"OK"}

Service Status Update

Index service statuses

List status updates for an service.

URL: https://api.statushub.io/api/status_pages/:subdomain/services/:service_id/service_statuses

Response arguments
Property Type Description
id integer Id number for service status update
status_name string Name of status. One of these values: up, degraded-performance, down
start_time datetime Time of service status update
maintenances_id integer Id number of maintenance which caused status update
incident_id integer Id number of incident which caused status update
incident_update integer Id number of incident_update which caused status update

EXAMPLE REQUEST

curl -X GET -H "Content-type: application/json" -d '{"api_key":"2iZGUdJXzbYtpE44kBuD"}'  https://api.statushub.io/api/status_pages/samplesubdomain/services/42/service_statuses

EXAMPLE RESPONSE

[
   {
      "id": 42,
      "status_name": "up",
      "start_time": "2014-07-11T09:23:28.688Z",
      "maintenance_id": 115,
      "incident_id": null,
      "incident_update_id": null
   }
]

Create service status update

Create service status update.

URL: https://api.statushub.io/api/status_pages/:subdomain/services/:service_id/service_statuses

Request arguments
Property Type Description
status_name string Name of status. One of these values: up, degraded-performance, down
start_time datetime Time of service status update (optional, current time if not used)
Response arguments
Property Type Description
id integer Id number for service status update
status_name string Name of status. One of these values: up, degraded-performance, down
start_time datetime Time of service status update
maintenances_id integer Id number of maintenance which caused status update
incident_id integer Id number of incident which caused status update
incident_update integer Id number of incident_update which caused status update

EXAMPLE REQUEST

curl -X POST -H "Content-type: application/json" -d '{"api_key":"2iZGUdJXzbYtpE44kBuD", "service_status": {"status_name": "down"}}' https://api.statushub.io/api/status_pages/samplesubdomain/services/42/service_statuses

EXAMPLE RESPONSE

{
    "id": 42,
    "status_name": "up",
    "start_time": "2014-07-11T09:23:28.688Z",
    "maintenance_id": 115,
    "incident_id": null,
    "incident_update_id": null
}

Delete service status update

Remove service status.

URL: https://api.statushub.io/api/status_pages/:subdomain/services/:service_id/service_status/:id

Response arguments
Property Type Description
message text Information about result of action

EXAMPLE REQUEST

curl -X DELETE -H "Content-type: application/json" -d '{"api_key":"2iZGUdJXzbYtpE44kBuD"}' https://api.statushub.io/api/status_pages/samplesubdomain/services/42/service_status/42

EXAMPLE RESPONSE

{"message": "Service status was removed successfully"}

Maintenance

Index Maintenance

Indexes user status pages.

URL: https://api.statushub.io/api/status_pages/:subdomain/maintenances

Request arguments
Property Type Description
per_page integer Default is 25. A limit on the number of objects to be returned.
page integer Number of paginated page.
Response arguments
Property Type Description
id integer Id number
title string Title of maintenance
body string Body (details) of maintenance
start_time datetime Start Date of maintenance
end_time datetime End Date of maintenance
created_at datetime Date of creation
updated_at datetime Date of update

EXAMPLE REQUEST

curl -X GET -H "Content-type: application/json" -d '{"api_key":"2iZGUdJXzbYtpE44kBuD", "per_page":1}' https://api.statushub.io/api/status_pages/samplesubdomain/maintenances

EXAMPLE RESPONSE

{
  "id": 240,
  "title": "TEST TITLE",
  "start_time": "2015-11-12T12:17:47.000Z",
  "body": "TEST BODY",
  "end_time": "2015-11-17T12:17:47.000Z",
  "created_at": "2015-03-10T11:08:06.036Z",
  "updated_at": "2015-03-10T11:08:06.036Z",
  "services": [{
    "id": 141,
    "status_name": "up"
  }, {
    "id": 142,
    "status_name": "up"
  }]
}

Create Maintenance

Create maintenance and its status.

URL: https://api.statushub.io/api/status_pages/samplesubdomain/maintenances

Request arguments
Property Type Description
maintenance hash Maintenance Description
Maintenance Description arguments
Property Type Description
title string Title of Maintenance
body string Body (Details) of Maintenance
start_time datetime Start Date of Maintenance
end_time datetime End Date of Maintenance
services array An array of services that will be affected by the maintenance
Maintenance Services arguments
Property Type Description
service_id int the ID of the service that will be affected by the maintenance
status_name string Name of status. One of these values: up, degraded-performance, down
Response arguments
Property Type Description
id integer Id number
title string Title of incident
start_time datetime Start Date of maintenance
end_time datetime End Date of maintenance
created_at datetime Date of creation
updated_at datetime Date of update
services array An array of services (hashes) that have been associated with the maintenance
Service Statuses Response arguments ( the part of the 'services' hash)
Property Type Description
status_name string The name of the status that has been assigned to maintenance
service_id int The ID of the service that has been affected

EXAMPLE REQUEST

curl -X POST -H "Content-type: application/json" -d '{"api_key": "367fc42aba5ca57a768fa196dceffcab", "maintenance": {"title": "TEST TITLE", "start_time": "2015-11-12T12:17:47Z",
"end_time": "2015-11-17T12:17:47Z", "body": "TEST BODY",
"services": [{"service_id": 141,"status_name": "up"}, {"service_id": 142,"status_name": "up"}]} }'
https://api.statushub.io/api/status_pages/samplesubdomain/maintenances

EXAMPLE RESPONSE

{
  "id": 219,
  "title": "TEST TITLE",
  "body": "TEST BODY"
  "start_time": "2015-11-12T12:17:47.000Z",
  "end_time": "2015-11-17T12:17:47.000Z",
  "created_at": "2015-03-09T13:21:15.046Z",
  "updated_at": "2015-03-09T13:21:15.046Z",
  "services": [{
    "id": 141,
    "status_name": "up"
}, {
  "id": 142,
  "status_name": "up"}]
}

Show Maintenance

Show Maintenance details.

URL: https://api.statushub.io/api/status_pages/samplesubdomain/maintenances/:maintenance_id

Response arguments
Property Type Description
id integer Id number
title string The title of particular maintenance
start_time datetime Start Date of maintenance
end_time datetime End Date of maintenance
created_at datetime Date of creation
updated_at datetime Date of update
services array An array of hashes that are services affected by the maintenance
Service Statuses Response arguments ( the part of the 'services' hash)
Property Type Description
status_name string The name of the status that has been assigned to maintenance
service_id int The ID of the service that has been affected

EXAMPLE REQUEST

curl -X GET -H "Content-type: application/json" -d '{"api_key":"367fc42aba5ca57a768fa196dceffcab"}'
https://api.statushub.io/api/status_pages/samplesubdomain/maintenances/:maintenance_id

EXAMPLE RESPONSE

{
  "id": 211,
  "title": "TEST TITLE",
  "body": "TEST BODY"
  "start_time": "2015-11-12T12:17:47.000Z",
  "end_time": "2015-11-17T12:17:47.000Z",
  "created_at": "2015-03-09T09:08:09.295Z",
  "updated_at": "2015-03-09T09:08:09.295Z",
  "services": [{
    "status_name": "up",
    "service_id": 141
  }, {
   "status_name": "up",
   "service_id": 142
  }]
}

Update Maintenance

Update maintenance attributes.

Request arguments
Property Type Description
maintenance hash A hash that contains updates for a particular maintenance
Maintenance Description arguments
Property Type Description
title string Title of Maintenance
body string Body (Details) of Maintenance
start_time datetime Start Date of Maintenance
end_time datetime End Date of Maintenance
services array An array of services and their statuses that will be updated in this maintenance
Maintenance Services arguments
Property Type Description
service_id int the ID of the service to be updated
status_name string The name of the status to be updated, One of these values: up, degraded-performance, down
Response arguments
Property Type Description
id integer Id number
title string Title of incident
start_time datetime Start Date of maintenance
end_time datetime End Date of maintenance
created_at datetime Date of creation
updated_at datetime Date of update
services array An array of services (hashes) that have been associated with the maintenance
Service Statuses Response arguments ( the part of the 'services' hash)
Property Type Description
status_name string The name of the status that has been assigned to maintenance
id int The ID of the service that has been affected

EXAMPLE REQUEST

curl -X PUT -H "Content-type: application/json" -d '{"api_key":"367fc42aba5ca57a768fa196dceffcab", "maintenance":
{ "title": "TEST TITLE", "start_time": "2015-04-13 19:15:00", "end_time": "2015-04-18 21:15:00",
"body": "TEST BODY",
"services": [{"service_id": 141,"status_name": "down"}, {"service_id": 142, "status_name": "down"}] } }'
https://api.statushub.io/api/status_pages/samplesubdomain/maintenances/:maintenance_id

EXAMPLE RESPONSE

{
  "id": 217,
  "title": "final update",
  "start_time": "2015-04-13T19:15:00.000Z",
  "body": "TEST BODY"
  "end_time": "2015-04-18T21:15:00.000Z",
  "created_at": "2015-03-09T12:42:01.138Z",
  "updated_at": "2015-03-09T13:17:34.100Z",
  "services": [{
    "id": 141,
    "status_name": "down"
  }, {
    "id": 142,
    "status_name": "down"}]
 }

Delete Maintenance

Remove maintenance

URL: https://api.statushub.io/api/status_pages/samplesubdomain/maintenances/:maintenance_id

Response arguments
Property Type Description
status string Status of maintenance removing action

EXAMPLE REQUEST

curl -X DELETE -H "Content-type: application/json" -d '{"api_key":"367fc42aba5ca57a768fa196dceffcab"}'
https://api.statushub.io/api/status_pages/samplesubdomain/maintenances/69

EXAMPLE RESPONSE

{"message":"OK"}

Subscriber

URL: https://api.statushub.io/api/status_pages/samplesubdomain/subscribers

Request arguments
Property Type Description
per_page integer A limit on the number of objects to be returned. Default is 25, max 100 and min 1
page integer Number of paginated page
Response arguments
Property Type Description
id integer Subscriber ID
address string Email address/Phone number/URL
created_at datetime Timestamp of when subscriber was created
less_verbose_incidents boolean Is subscriber using incidents with lower verbosity (only first and last notification)
method_name string Type of notification method: email, phone, webhook, slack
status_page_id interger StatusPage ID
subscribed_to_all_services boolean Is subscriber subscribed to all services for this hub
updated_at datetime Timestamp of when subscriber was last updated

EXAMPLE REQUEST

curl -X GET -H "Content-type: application/json" -d '{"api_key":"2iZGUdJXzbYtpE44kBuD", "per_page":1}' https://api.statushub.io/api/status_pages/samplesubdomain/subscribers

EXAMPLE RESPONSE

{
  "id": 11225,
  "address": "+12223334444",
  "created_at": "2017-05-16T12:25:08.695Z",
  "less_verbose_incidents": false,
  "method_name": "sms",
  "status_page_id": 1100,
  "subscribed_to_all_services": true,
  "updated_at": "2017-05-16T12:25:08.695Z"
}

Create Subscriber

URL: https://api.statushub.io/api/status_pages/samplesubdomain/subscribers

Request arguments
Property Type Description
subscriber hash Subscriber description
Subscriber description arguments
Property Type Description
address string Subscriber address
method_name string Type of notification method: email, phone, webhook, slack
service_ids array of integers If subscriber should be subscribed only to selected services, this array should contain ID's of services. If subscriber should be subscribed to all services, then this parameter can be omitted or have empty array as a value
less_verbose_incidents boolean Should subscriber be notified about incidents with lower verbosity (only first and last notification)
Response arguments
Property Type Description
id integer Subscriber ID
address string Email address/Phone number/URL
created_at datetime Timestamp of when subscriber was created
less_verbose_incidents boolean Is subscriber using incidents with lower verbosity (only first and last notification)
method_name string Type of notification method: email, phone, webhook, slack
services Array of services List of services to which subscriber is subscribed to
status_page_id interger StatusPage ID
subscribed_to_all_services boolean Is subscriber subscribed to all services for this hub
updated_at datetime Timestamp of when subscriber was last updated

EXAMPLE REQUEST

curl -X POST -H "Content-type: application/json" -d '{"api_key": "367fc42aba5ca57a768fa196dceffcab", "subscriber": {"address": "some-user@example.com", "method_name": "email", "service_ids": [4590, 5330], "less_verbose_incidents": true}}'
https://api.statushub.io/api/status_pages/samplesubdomain/subscribers

EXAMPLE RESPONSE

{
  "id": 11440,
  "address": "some-user@example.com",
  "created_at": "2017-06-20T13:08:55.100Z",
  "less_verbose_incidents": true,
  "method_name": "email",
  "services": [
    {
      "id": 5330,
      "name": "API v2",
      "group": "Ungrouped"
    },
    {
      "id": 4590,
      "name": "Website",
      "group": "Test group"
    }
  ],
  "status_page_id": 1100,
  "subscribed_to_all_services": false,
  "updated_at": "2017-06-20T13:08:55.507Z"
}

Show Subscriber

URL: https://api.statushub.io/api/status_pages/samplesubdomain/subscribers/:subscriber_id

Response arguments
Property Type Description
id integer Subscriber ID
address string Email address/Phone number/URL
created_at datetime Timestamp of when subscriber was created
less_verbose_incidents boolean Is subscriber using incidents with lower verbosity (only first and last notification)
method_name string Type of notification method: email, phone, webhook, slack
services Array of services List of services to which subscriber is subscribed to
status_page_id interger StatusPage ID
subscribed_to_all_services boolean Is subscriber subscribed to all services for this hub
updated_at datetime Timestamp of when subscriber was last updated

EXAMPLE REQUEST

curl -X POST -H "Content-type: application/json" -d '{"api_key": "367fc42aba5ca57a768fa196dceffcab"}'
https://api.statushub.io/api/status_pages/samplesubdomain/subscribers/11440

EXAMPLE RESPONSE

{
  "id": 11440,
  "address": "some-user@example.com",
  "created_at": "2017-06-20T13:08:55.100Z",
  "less_verbose_incidents": true,
  "method_name": "email",
  "services": [
    {
      "id": 5330,
      "name": "API v2",
      "group": "Ungrouped"
    },
    {
      "id": 4590,
      "name": "Website",
      "group": "Test group"
    }
  ],
  "status_page_id": 1100,
  "subscribed_to_all_services": false,
  "updated_at": "2017-06-20T13:08:55.507Z"
}

Update Subscriber

URL: https://api.statushub.io/api/status_pages/samplesubdomain/subscribers/:subscriber_id

Request arguments
Property Type Description
subscriber hash Subscriber description
Subscriber description arguments
Property Type Description
address string Subscriber address
method_name string Type of notification method: email, phone, webhook, slack
service_ids array of integers If subscriber should be subscribed only to selected services, this array should contain ID's of services. If subscriber should be subscribed to all services, then this parameter have to be set to empty array
less_verbose_incidents boolean Should subscriber be notified about incidents with lower verbosity (only first and last notification)
Response arguments
Property Type Description
id integer Subscriber ID
address string Email address/Phone number/URL
created_at datetime Timestamp of when subscriber was created
less_verbose_incidents boolean Is subscriber using incidents with lower verbosity (only first and last notification)
method_name string Type of notification method: email, phone, webhook, slack
services Array of services List of services to which subscriber is subscribed to
status_page_id interger StatusPage ID
subscribed_to_all_services boolean Is subscriber subscribed to all services for this hub
updated_at datetime Timestamp of when subscriber was last updated

EXAMPLE REQUEST

curl -X PATCH -H "Content-type: application/json" -d '{"api_key": "367fc42aba5ca57a768fa196dceffcab", "subscriber": {"address": "some-user@example.com", "method_name": "email", "service_ids": [4590], "less_verbose_incidents": true}}'
https://api.statushub.io/api/status_pages/samplesubdomain/subscribers/11440

EXAMPLE RESPONSE

{
  "id": 11440,
  "address": "some-user@example.com",
  "created_at": "2017-06-20T13:08:55.100Z",
  "less_verbose_incidents": true,
  "method_name": "email",
  "services": [
    {
      "id": 4590,
      "name": "Website",
      "group": "Test group"
    }
  ],
  "status_page_id": 1100,
  "subscribed_to_all_services": false,
  "updated_at": "2017-06-20T13:08:55.507Z"
}

Delete Subscriber

URL: https://api.statushub.io/api/status_pages/samplesubdomain/subscribers/:subscriber_id

Response arguments
Property Type Description
id integer Subscriber ID
address string Email address/Phone number/URL
created_at datetime Timestamp of when subscriber was created
less_verbose_incidents boolean Is subscriber using incidents with lower verbosity (only first and last notification)
method_name string Type of notification method: email, phone, webhook, slack
services Array of services List of services to which subscriber is subscribed to
status_page_id interger StatusPage ID
subscribed_to_all_services boolean Is subscriber subscribed to all services for this hub
updated_at datetime Timestamp of when subscriber was last updated

EXAMPLE REQUEST

curl -X DELETE -H "Content-type: application/json" -d '{"api_key": "367fc42aba5ca57a768fa196dceffcab"}'
https://api.statushub.io/api/status_pages/samplesubdomain/subscribers/11440

EXAMPLE RESPONSE

{
  "id": 11440,
  "address": "some-user@example.com",
  "created_at": "2017-06-20T13:08:55.100Z",
  "less_verbose_incidents": true,
  "method_name": "email",
  "services": [
    {
      "id": 4590,
      "name": "Website",
      "group": "Test group"
    }
  ],
  "status_page_id": 1100,
  "subscribed_to_all_services": false,
  "updated_at": "2017-06-20T13:08:55.507Z"
}