Transparent Node.JS wrapper for the API

Usage no npm install needed!

<script type="module">
  import nodeUpdown from '';



npm David PRs Welcome MIT license

Transparent Node.js wrapper for the API

Uses cross-fetch so should work in browsers and in node.

yarn add node-updown


There are two ways to use the library:


import { UpdownClient } from 'node-updown';

// Create the client with your API key (readonly or full access)
const client = new UpdownClient('API_KEY');

// Use one of the methods to interact with the API
let check = await client.getCheck('TOKEN');

This is the recommended way to use if you need to make lots of API calls, or if you have a long-running application (e.g. a server).


import { getCheck } from 'node-updown';

// Use the API function directly, by adding your API key
let check = await getCheck('API_KEY', 'TOKEN');

This is useful if you only need to make one or two API calls, or if you want to limit the size of your bundle by tree-shaking the unused functions.


In this documentation, we'll use the client instance. To use the functional API, simply add your API key as the first argument. So client.getCheck(token) becomes getCheck(apiKey, token).

The API is kept as transparent as possible, so all values and options should mirror the Updown API documentation closely. Consult the API docs to see the returned data for each call.

Tokens are always required, most other settings are optional unless listed otherwise. All functions operating on an entity will take the entity ID/token as a first parameter (or second, if you're using the functional API) and an options object containing the remaining parameters.

The library is entirely promise-based.

Time strings should be in one of the supported formats.

Get checks


Get check


Get downtimes

client.getDowntimes(token, { page });
  • page (number): the page to fetch, default 1

Get metrics

client.getMetrics(token, { from, to, group });
  • from (time): start time, default 1 month ago
  • to (time): end time, default now
  • group (string): group data by hour ('time') or by monitoring location ('host')

Add check


See the API docs for the full list of parameters

Update check

client.updateCheck(token, params);

See the API docs for the full list of parameters

Delete check


Get monitoring nodes


Note: this function does not require an API key

Get IP addresses of monitoring nodes


Note: these functions do not require an API key

Get webhooks


Add webhook

client.addWebhook({ url });
  • url (string): the URL of the webhook

Delete webhook

  • id (string): ID of the webhook you want to delete


If you experience any bugs or errors, or if you have any questions about how to use this library, be sure to create an issue.


This package is licensed under the MIT license.