API & MCP Documentation

Manage your monitors, groups, alert contacts, and incidents programmatically over a simple REST API — or connect an AI agent (Claude Desktop, Cursor, …) to the UptimeDesk MCP server and set everything up conversationally. Both use the same API keys and respect the same plan limits as the dashboard.

Authentication

Every request is authenticated with an API key. Create one in Settings → API & MCP. The full key (it starts with udk_) is shown once at creation — copy it then; only a hash is stored, so it can’t be shown again. Treat a key like a password: it acts as your account.

Send it as a Bearer token in the Authorization header:

Authorization: Bearer udk_your_key_here

Scopes. Each key is either Read & write or Read-only. A read-only key can call any GET endpoint but is rejected with 403 on any create/update/delete. Revoke a key any time from Settings — it stops working immediately.

Keeping keys secure

  • Store keys in a password or secrets manager. Never commit them to source control, put them in a ticket, or paste them in chat.
  • Grant the least privilege that works — use a read-only key unless the tool needs to make changes.
  • Give each tool or environment its own named key, so you can revoke one without disrupting the others.
  • Rotate periodically: create a replacement, switch your tools over, then revoke the old key.
  • If a key is ever exposed, revoke it immediately and create a new one.

Base URL & format

All REST endpoints live under the /api/v1 prefix:

https://uptimedesk.io/api/v1

Requests with a body must send Content-Type: application/json. Every response is JSON. Success responses wrap the payload in a data field; errors return an error message and a stable code:

// success
{ "data": { "id": "clx...", "name": "My site", ... } }

// error
{ "error": "This API key is read-only. Use a read-write key to make changes.",
  "code": "FORBIDDEN" }

Rate limits

Requests are limited per API key. Exceeding the limit returns 429 with a Retry-After header (seconds).

  • REST API (/api/v1): 120 requests / minute per key.
  • MCP server (/api/mcp): 240 requests / minute per key.

Error codes

Every failure carries an HTTP status and a machine-readable code:

HTTPcodeMeaning
400VALIDATIONThe request body failed validation (missing/invalid field). The message names the problem.
401UNAUTHORIZEDMissing, malformed, invalid, or revoked API key.
403FORBIDDENThe key is read-only but the operation writes, or API access is not enabled for the account.
403PLANThe action requires a higher plan (e.g. creating a group, or a Slack contact, needs Pro).
403LIMITA plan resource cap was reached (e.g. the monitor limit). Upgrade to add more.
404NOT_FOUNDThe referenced resource does not exist in your workspace.
429RATE_LIMITEDToo many requests — retry after the Retry-After header.
500INTERNALUnexpected server error. Safe to retry.

Monitors

GET/api/v1/monitors

List all monitors in your workspace.

POST/api/v1/monitors

Create a monitor. Requires a read-write key.

ParameterTypeRequiredDescription
namestringYes1–100 characters.
urlstringYesPublic http/https URL to check. https:// is assumed if the scheme is omitted.
type"HTTP" | "PING" | "PORT"NoCheck type. Default "HTTP".
methodstringNoHTTP method: GET, HEAD, POST, PUT, PATCH, DELETE. Default GET.
expectedStatusnumberNoExpected HTTP status 100–599. Default 200.
keywordstringNoOptional. Text that must appear in the response body (≤500 chars).
requestHeadersobjectNoOptional. Map of header name → value sent with the check.
requestBodystringNoOptional request body (≤10000 chars).
checkSslbooleanNoCheck SSL certificate validity/expiry. Default true.
clientIdstringNoOptional group id to attach the monitor to (must be yours).

The check interval is set by your plan (Free: 5 min, paid: 1 min) and can’t be passed in. New alert contacts are attached automatically (the group’s defaults, or all account contacts). Creating beyond your plan’s monitor cap returns 403 LIMIT.

GET/api/v1/monitors/:id

Fetch a single monitor, including its group and incident count.

PATCH/api/v1/monitors/:id

Update a monitor. Any subset of the fields below (read-write key).

ParameterTypeRequiredDescription
namestringNo1–100 characters.
pausedbooleanNoPause (true) or resume (false) checks.
keywordstring | nullNoResponse keyword, or null to clear.
methodstringNoHTTP method.
expectedStatusnumberNoExpected HTTP status 100–599.
requestHeadersobject | nullNoRequest headers, or null to clear.
requestBodystring | nullNoRequest body, or null to clear.
checkSslbooleanNoToggle SSL checking.
clientIdstring | nullNoMove to a group, or null to detach.
DELETE/api/v1/monitors/:id

Permanently delete a monitor and its history. Read-write key.

Example

curl -X POST https://uptimedesk.io/api/v1/monitors \
  -H "Authorization: Bearer udk_your_key_here" \
  -H "Content-Type: application/json" \
  -d '{ "name": "Marketing site", "url": "https://example.com", "keyword": "Welcome" }'

Groups

Groups (called “clients” internally) organize monitors and power status pages. Creating a group requires the Pro plan.

GET/api/v1/groups

List groups with monitor counts and status.

POST/api/v1/groups

Create a group (Pro, read-write key).

ParameterTypeRequiredDescription
namestringYes1–100 characters.
emailstringNoOptional contact email.
websitestringNoOptional website URL.
statusPageSlugstringNoOptional public status-page slug (lowercase letters, numbers, hyphens).
statusPageTitlestringNoOptional status-page title.
statusPagePublicbooleanNoWhether the status page is public. Default true.
statusPagePasswordstringNoOptional password to protect the status page (≥4 chars).
alertContactIdsstring[]NoDefault alert contacts for monitors in this group (must be yours).
DELETE/api/v1/groups/:id

Delete a group (read-write key). Monitors in the group are kept but detached from it.

Alert contacts

GET/api/v1/alert-contacts

List alert contacts (email/Slack destinations for down & up alerts).

POST/api/v1/alert-contacts

Create an alert contact (read-write key).

ParameterTypeRequiredDescription
namestringYes1–100 characters.
type"EMAIL" | "SLACK"YesContact type. SLACK requires the Pro plan.
valuestringYesEmail address (EMAIL) or a https://hooks.slack.com/… webhook URL (SLACK).
DELETE/api/v1/alert-contacts/:id

Delete an alert contact (read-write key). It is removed from any monitors and groups it was attached to. The account owner’s own email contact can’t be deleted (returns 403 FORBIDDEN) — it keeps the owner on every alert.

Incidents

Incidents are read-only over the API.

GET/api/v1/incidents

List recent incidents across your monitors.

ParameterTypeRequiredDescription
status"open" | "resolved"NoQuery param. Filter by state.
monitorIdstringNoQuery param. Only incidents for this monitor.
limitnumberNoQuery param. Max results 1–200. Default 50.
GET/api/v1/incidents/:id

Fetch one incident, including AI triage details when available.

Account

GET/api/v1/account

Return your plan, limits, and current usage — handy before bulk-creating monitors.

{
  "data": {
    "plan": "PRO",
    "scope": "READ_WRITE",
    "limits": { "maxMonitors": 25, "checkIntervalMinutes": 1, "maxClients": 10,
                "statusPages": true, "slackAlerts": true },
    "usage": { "monitors": 8, "groups": 2, "alertContacts": 3 }
  }
}

MCP server (for AI agents)

The MCP server exposes the same operations as tools that any MCP-capable AI agent can call, so you can say “add a monitor for example.com and alert #ops” and the agent does it. UptimeDesk doesn’t run any AI itself here — your agent supplies the model; we just expose and execute the tools.

Endpoint (JSON-RPC 2.0 over HTTP POST, authenticated with the same API key):

https://uptimedesk.io/api/mcp

Add it to your agent’s MCP config, replacing the key with one of yours:

{
  "mcpServers": {
    "uptimedesk": {
      "url": "https://uptimedesk.io/api/mcp",
      "headers": { "Authorization": "Bearer udk_your_key_here" }
    }
  }
}

Available tools

  • list_monitors, create_monitor, update_monitor, pause_monitor, delete_monitor
  • list_groups, create_group, delete_group
  • list_alert_contacts, create_alert_contact, delete_alert_contact
  • list_incidents, get_account_usage

Write tools require a read-write key. When a tool can’t run (plan limit reached, read-only key, validation), the agent receives the reason as a tool error so it can tell you what happened.

Good to know

  • Adding an alert contact makes it a live alert destination: unless a monitor sets its own contacts, new monitors auto-attach every account contact, so a Slack/email you add will start receiving real down/up alerts. Review what a connected agent creates.
  • For your privacy, monitor requestHeaders values and requestBody are redacted in API and MCP responses — a connected agent never sees secrets you stored in a monitor’s custom headers. (They’re still used when the check runs.)
Create an API key · Back to UptimeDesk