Skip to main content
POST
Create a monitor

Authorizations

Authorization
string
header
required

An org API token (sv_…), sent as Authorization: Bearer <token>.

Headers

Idempotency-Key
string

Opt-in safe retries. Send a unique value (a UUID); a retry with the same key replays the first response (header Idempotent-Replayed: true) instead of acting twice. Reusing a key with a different body is rejected (400); a retry while the first is in flight gets 409. Scoped to the workspace, expires after 24h.

Maximum string length: 255

Body

application/json

Discriminated on type. Omit type for an HTTP monitor (backward-compatible).

name
string
required
Required string length: 1 - 120
target
string<uri>
required

The URL to poll. http/https only; SSRF-validated.

type
enum<string>
default:http
Available options:
http
method
enum<string>
Available options:
GET,
HEAD,
POST
intervalSeconds
integer

Poll cadence (60s floor).

Required range: 60 <= x <= 86400
timeoutMs
integer
Required range: 1000 <= x <= 60000
openThreshold
integer
Required range: 1 <= x <= 10
resolveThreshold
integer
Required range: 1 <= x <= 10
expectedStatusCodes
integer[]

Healthy status codes. Empty/absent = any 2xx–3xx.

Required range: 100 <= x <= 599
keyword
string
Maximum string length: 200
keywordAbsent
string
Maximum string length: 200
jsonAssertion
object

Assert on a JSON response: navigate path (dot/bracket, leading $. optional) and compare with op.

degradedAfterMs
integer

A passing check slower than this is reported degraded (still up).

Required range: 1 <= x <= 60000
latencyThresholdMs
integer

A check slower than this FAILS (opens an incident after the flap threshold).

Required range: 1 <= x <= 60000
headers
object

Custom request headers (e.g. Authorization). Stored encrypted; sent only to the original host (dropped on a cross-host redirect).

body
string

Request body for a POST/PUT check. Stored encrypted (may carry secrets).

Maximum string length: 32768
contentType
string

Content-Type for body (default application/json).

Maximum string length: 200
environment
string | null
Maximum string length: 60
metadata
object

Response

The created monitor.

data
object