Skip to main content
POST
Rotate a monitor webhook secret
0 credits Requires monitors:write permission. See the guide for examples and usage.

Authorizations

Authorization
string
header
required

Send your API key as Authorization: Bearer <API_KEY>. Keys have full access unless restricted to specific permissions.

Path Parameters

monitor_id
string
required

ID of the monitor.

Example:

"mon_123"

Response

Secret rotated. Returns the monitor with the new webhook.secret.

id
string
required

Unique ID of the monitor.

Example:

"mon_123"

mode
enum<string>
required

Monitor category. Always web.

Available options:
web
name
string
required

Display name of the monitor.

Example:

"Acme pricing monitor"

target
Page target · object
required

What to watch: a page, a sitemap, data extracted from a site, or web search results.

change_detection
Exact · object
required

How changes are judged. Defaults to semantic for extract and search targets and for page targets with instructions; otherwise exact. Sitemap targets support only exact, and extract targets only semantic.

status
enum<string>
required

active monitors run on schedule. failed monitors keep running after a failed run and return to active on the next success. paused monitors don't run until you set status to active; Context.dev also pauses monitors after repeated failures or credit shortfalls.

Available options:
active,
paused,
failed
created_at
string<date-time>
required

When the monitor was created.

updated_at
string<date-time>
required

When the monitor was last updated.

request_id
string<uuid>
required

Unique ID of this request, also in X-Request-Id. Include it when contacting support.

Example:

"3f1c2a6e-8b4d-4c1e-9f0a-2d7b5e6c8a91"

schedule
Interval · object

How often the monitor runs. Defaults to once a day.

webhook
object | null

Webhook that receives monitor events. null when no webhook is configured.

last_run_at
string<date-time> | null

When the most recent run ended. null until the first run ends.

last_change_at
string<date-time> | null

When the monitor last detected a change. null until it detects one.

next_run_at
string<date-time> | null

When the next scheduled run is due. null while paused.

last_error
object | null

Error from the most recent failed run. null when the last run succeeded.

webhook_failure
object | null

Details of failing webhook deliveries. null when deliveries succeed or no webhook is configured; cleared by the next successful delivery or a new webhook URL.

baseline
Page baseline · object

What the next run compares against. Returned only by GET /monitors/{monitor_id}; null until the first capture finishes or after the target changes.

tags
string[]

Labels for grouping monitors. Filter monitors, changes, and credit usage by tag.

Maximum array length: 20
Required string length: 1 - 50
Example:
policies
string[]

Access policy IDs applied to every run.

Example:
key_metadata
object

Credits this request used and your remaining balance.