Skip to main content
POST
Create a monitor

Authorizations

Authorization
string
header
required

Sent as Authorization: Bearer <token>. Three kinds are accepted: an ORG token (sv_…), bound to one workspace with a fixed role; a PERSONAL token (svu_…), which acts as you with your own live role in whichever workspace it is pointed at; and an OAUTH access token (mcp_at_…) from a connected app, limited to the workspaces you granted it. A personal or OAuth token names its workspace with the X-Sentivel-Workspace header (a slug or an id). Without it an OAuth token falls back to the connection's primary workspace, while a personal token in more than one workspace is rejected 400 invalid_request with the choices in error.details.workspaces. Membership is re-read every request, so leaving a workspace or revoking the grant takes effect at once.

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 <= 30000
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

Static string→string labels copied onto every incident this monitor opens. At most 20 entries; keys ≤64 chars, values ≤500.

Response

The created monitor.

data
object