Status Pages API

Manage your status pages using a simple HTTP API.

Do you need help with the integration?

Let us know at [email protected]

Obtaining an API token

Please, see Obtaining an API token.

Adding resources to your status page

Please, see Status Page Resources API.

get
Listing all existing status pages

https://betteruptime.com/api/v2/status-pages
Returns a list of all your status pages.
Request
Response
Request
Headers
Authorization
required
string
Bearer YOUR_API_TOKEN
Response
200: OK
Returns a list of existing status pages
{
"data": [
{
"id": "123456789",
"type": "status_page",
"attributes": {
"company_name": "Best company",
"company_url": "https://best-company.com",
"contact_url": null,
"logo_url": null,
"timezone": "Tokyo",
"subdomain": "best-company-tokyo",
"custom_domain": null,
"custom_css": null,
"google_analytics_id": null,
"min_incident_length": 400,
"announcement": null,
"announcement_embed_enabled": false,
"announcement_embed_css": "",
"announcement_embed_link": "",
"subscribable": false,
"hide_from_search_engines": false,
"password_enabled": false,
"history": 90,
"created_at": "2020-08-10T07:34:38.848Z",
"updated_at": "2020-12-08T14:12:31.680Z"
}
}
],
"pagination": {
"first": "https://betteruptime.com/api/v2/status-pages?page=1",
"last": "https://betteruptime.com/api/v2/status-pages?page=1",
"prev": null,
"next": null
}
}
Example cURL
Example cURL
curl --request GET \
--url https://betteruptime.com/api/v2/status-pages \
--header 'Authorization: Bearer YOUR_API_TOKEN'

get
Getting a single status page

https://betteruptime.com/api/v2/status-pages/:status_page_id
Returns a single status page
Request
Response
Request
Path Parameters
status_page_id
required
string
The ID of the status page you want to get
Headers
Authorization
required
string
Bearer YOUR_API_TOKEN
Response
200: OK
Returns a single status page
{
"data": {
"id": "123456789",
"type": "status_page",
"attributes": {
"company_name": "Best company",
"company_url": "https://best-company.com",
"contact_url": null,
"logo_url": null,
"timezone": "Tokyo",
"subdomain": "best-company-tokyo",
"custom_domain": null,
"custom_css": null,
"google_analytics_id": null,
"min_incident_length": 400,
"announcement": null,
"announcement_embed_enabled": false,
"announcement_embed_css": "",
"announcement_embed_link": "",
"subscribable": false,
"hide_from_search_engines": false,
"password_enabled": false,
"history": 90,
"created_at": "2020-08-10T07:34:38.848Z",
"updated_at": "2020-12-08T14:12:31.680Z"
}
}
}
Example cURL
Example cURL
curl --request GET \
--url https://betteruptime.com/api/v2/status-pages/123456789 \
--header 'Authorization: Bearer YOUR_API_TOKEN'

post
Creating a new status page

https://betteruptime.com/api/v2/status-pages
Returns a newly created status page or validation errors.
Request
Response
Request
Headers
Authorization
required
string
Bearer YOUR_API_TOKEN
Content-Type
required
string
application/json
Form Data Parameters
history
optional
integer
Number of days to display on the status page. Minimum 90 days.
company_name
required
string
Name of your company
company_url
required
string
URL of your company's website
contact_url
optional
string
URL that should be used for contacting you in case of an emergency
logo_url
optional
string
A direct link to your company's logo. The image should be under 20MB in size
timezone
required
string
What timezone should we display your status page in? The accepted values can be found in the Rails TimeZone documentation. https://api.rubyonrails.org/classes/ActiveSupport/TimeZone.html
subdomain
required
string
What subdomain should we use for your status page? This needs to be unique across our entire application, so choose carefully
custom_domain
optional
string
Do you want a custom domain on your status page? Add a CNAME record that points your domain to status.betteruptime.com Example: CNAME status.walmine.com statuspage.betteruptime.com
min_incident_length
optional
integer
If you don't want to display short incidents on your status page, this attribute is for you
subscribable
optional
boolean
Do you want to allow users to subscribe to your status page changes?
hide_from_search_engines
optional
boolean
Hide your status page from search engines
custom_css
optional
string
Unleash your inner designer and tweak our status page design to fit your branding
google_analytics_id
optional
string
Specify your own Google Analytics ID if you want to receive hits on your status page
announcement
optional
string
Add an announcement to your status page
announcement_embed%visible
optional
boolean
Toggle this field if you want to show an announcement in your embed You can embed the announcement using this snippet: <script src="https://betteruptime.com/widgets/announcement.js" data-id="<SET STATUS_PAGE_ID>" async="async" type="text/javascript"></script>
announcement_embed%link
optional
string
Point your embedded announcement to a specified URL
announcement_embed%custom_css
optional
string
Modify the design of the announcement embed
password_enabled
optional
boolean
Do you want to enable password protection on your status page?
password
optional
string
Set a password of your status page (we won't store it as plaintext, promise) Required when password_enabled: true We will set password_enabled: false automatically when you send us an empty password
Response
201: Created
{
"id": "123456789",
"type": "status_page",
"attributes": {
"company_name": "Best company",
"company_url": "https://best-company.com",
"contact_url": null,
"logo_url": null,
"timezone": "Tokyo",
"subdomain": "best-company-tokyo",
"custom_domain": null,
"custom_css": null,
"google_analytics_id": null,
"min_incident_length": 400,
"announcement": null,
"announcement_embed_enabled": false,
"announcement_embed_css": null,
"announcement_embed_link": null,
"subscribable": false,
"hide_from_search_engines": false,
"password_enabled": false,
"history": 90,
"created_at": "2020-08-10T07:34:38.848Z",
"updated_at": "2020-12-08T14:12:31.680Z"
}
}
422: Unprocessable Entity
{
"errors": "Sorry, you misspelled some attributes",
"invalid_attributes": [
"company_urlll"
]
}
Example cURL
Example cURL
curl --request POST \
--url https://betteruptime.com/api/v2/status-pages \
--header 'Authorization: Bearer YOUR_API_TOKEN' \
--header 'Content-Type: application/json' \
--data '{
"company_url": "https://best-company.com",
"company_name": "Best company",
"subdomain": "best-company-tokyo",
"timezone": "Tokyo"
}'

patch
Updating an existing status page

https://betteruptime.com/api/v2/status-pages/:status_page_id
Update an existing status page. Send only the parameters you wish to change (e.g. company_url )
Request
Response
Request
Path Parameters
status_page_id
required
string
The ID of the status page you want to update
Headers
Authorization
required
string
Bearer YOUR_API_TOKEN
Content-Type
required
string
application/json
Form Data Parameters
history
optional
integer
Number of days to display on the status page. Minimum 90 days.
company_name
optional
string
Name of your company
company_url
optional
string
URL of your company's website
contact_url
optional
string
URL that should be used for contacting you in case of an emergency
logo_url
optional
string
A direct link to your company's logo. The image should be under 20MB in size
timezone
optional
string
What timezone should we display your status page in? The accepted values can be found in the Rails TimeZone documentation. https://api.rubyonrails.org/classes/ActiveSupport/TimeZone.html
subdomain
optional
string
What subdomain should we use for your status page? This needs to be unique across our entire application, so choose carefully
custom_domain
optional
string
Do you want a custom domain on your status page? Add a CNAME record that points your domain to status.betteruptime.com Example: CNAME status.wallmine.com statuspage.betteruptime.com
min_incident_length
optional
integer
If you don't want to display short incidents on your status page, this attribute is for you
subscribable
optional
boolean
Do you want to allow users to subscribe to your status page changes?
hide_from_search_engines
optional
boolean
Hide your status page from search engines
custom_css
optional
string
Unleash your inner designer and tweak our status page design to fit your branding
google_analytics_id
optional
string
Specify your own Google Analytics ID if you want to receive hits on your status page
announcement
optional
string
Add an announcement to your status page
announcement_embed_visible
optional
boolean
Toggle this field if you want to show an announcement in your embed You can embed the announcement using this snippet: <script src="https://betteruptime.com/widgets/announcement.js" data-id="<SET STATUS_PAGE_ID>" async="async" type="text/javascript"></script>
announcement_embed_link
optional
string
Point your embedded announcement to a specified URL
announcement_embed_css
optional
string
Modify the design of the announcement embed
password_enabled
optional
boolean
Do you want to enable password protection on your status page?
password
optional
string
Set a password of your status page (we won't store it as plaintext, promise) Required when password_enabled: true We will set password_enabled: false automatically when you send us an empty password
Response
200: OK
{
"id": "123456789",
"type": "status_page",
"attributes": {
"company_name": "Best company - Tokyo branch",
"company_url": "https://best-company.com",
"contact_url": null,
"logo_url": null,
"timezone": "Tokyo",
"subdomain": "best-company-tokyo",
"custom_domain": null,
"custom_css": null,
"google_analytics_id": null,
"min_incident_length": 400,
"announcement": null,
"announcement_embed_enabled": false,
"announcement_embed_css": null,
"announcement_embed_link": null,
"subscribable": false,
"hide_from_search_engines": false,
"password_enabled": false,
"history": 90,
"created_at": "2020-08-10T07:34:38.848Z",
"updated_at": "2020-12-08T14:12:31.680Z"
}
}
422: Unprocessable Entity
{
"errors": "Sorry, you misspelled some attributes",
"invalid_attributes": [
"company_urlll"
]
}
Example cURL - Change company_name only
Example cURL - Change company_name only
curl --request PATCH \
--url https://betteruptime.com/api/v2/status-pages/123456789 \
--header 'Authorization: Bearer YOUR_API_TOKEN' \
--header 'Content-Type: application/json' \
--data '{
"company_name": "Best company - Tokyo branch"
}'

delete
Deleting an existing status page

https://betteruptime.com/api/v2/status-pages/:status_page_id
Permanently deletes a status page
Request
Response
Request
Path Parameters
status_page_id
required
string
The ID of the status page you want to delete
Headers
Authorization
required
string
Bearer YOUR_API_TOKEN
Response
204: No Content
Returns empty body
Example cURL
Example cURL
curl --request DELETE \
--url https://betteruptime.com/api/v2/status-pages/123456789 \
--header 'Authorization: Bearer YOUR_API_TOKEN'