Skip to main content
PATCH
/
monitors
/
{id}
Update a Monitor
curl --request PATCH \
  --url https://api.exa.ai/monitors/{id} \
  --header 'Content-Type: application/json' \
  --header 'x-api-key: <api-key>' \
  --data '
{
  "name": "<string>",
  "search": {
    "query": "Latest developments in LLM capabilities",
    "numResults": 10,
    "contents": {
      "text": false,
      "highlights": false,
      "summary": true,
      "extras": {
        "links": 1,
        "imageLinks": 1,
        "richImageLinks": 0,
        "richLinks": 0,
        "codeBlocks": 0
      },
      "context": true,
      "livecrawlTimeout": 1000,
      "maxAgeHours": 24,
      "filterEmptyResults": true,
      "subpages": 1,
      "subpageTarget": "sources"
    }
  },
  "trigger": {
    "type": "interval",
    "period": "<string>"
  },
  "outputSchema": {
    "type": "<string>",
    "description": "<string>"
  },
  "metadata": {
    "slack_channel_id": "C123ABC",
    "slack_thread_id": "1745444400.123456",
    "user_id": "U123ABC"
  },
  "webhook": {
    "url": "<string>",
    "events": []
  }
}
'
import requests

url = "https://api.exa.ai/monitors/{id}"

payload = {
"name": "<string>",
"search": {
"query": "Latest developments in LLM capabilities",
"numResults": 10,
"contents": {
"text": False,
"highlights": False,
"summary": True,
"extras": {
"links": 1,
"imageLinks": 1,
"richImageLinks": 0,
"richLinks": 0,
"codeBlocks": 0
},
"context": True,
"livecrawlTimeout": 1000,
"maxAgeHours": 24,
"filterEmptyResults": True,
"subpages": 1,
"subpageTarget": "sources"
}
},
"trigger": {
"type": "interval",
"period": "<string>"
},
"outputSchema": {
"type": "<string>",
"description": "<string>"
},
"metadata": {
"slack_channel_id": "C123ABC",
"slack_thread_id": "1745444400.123456",
"user_id": "U123ABC"
},
"webhook": {
"url": "<string>",
"events": []
}
}
headers = {
"x-api-key": "<api-key>",
"Content-Type": "application/json"
}

response = requests.patch(url, json=payload, headers=headers)

print(response.text)
const options = {
method: 'PATCH',
headers: {'x-api-key': '<api-key>', 'Content-Type': 'application/json'},
body: JSON.stringify({
name: '<string>',
search: {
query: 'Latest developments in LLM capabilities',
numResults: 10,
contents: {
text: false,
highlights: false,
summary: true,
extras: {links: 1, imageLinks: 1, richImageLinks: 0, richLinks: 0, codeBlocks: 0},
context: true,
livecrawlTimeout: 1000,
maxAgeHours: 24,
filterEmptyResults: true,
subpages: 1,
subpageTarget: 'sources'
}
},
trigger: {type: 'interval', period: '<string>'},
outputSchema: {type: '<string>', description: '<string>'},
metadata: {
slack_channel_id: 'C123ABC',
slack_thread_id: '1745444400.123456',
user_id: 'U123ABC'
},
webhook: {url: '<string>', events: []}
})
};

fetch('https://api.exa.ai/monitors/{id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
{
  "id": "<string>",
  "name": "<string>",
  "search": {
    "query": "Latest developments in LLM capabilities",
    "numResults": 10,
    "contents": {
      "text": false,
      "highlights": false,
      "summary": true,
      "extras": {
        "links": 1,
        "imageLinks": 1,
        "richImageLinks": 0,
        "richLinks": 0,
        "codeBlocks": 0
      },
      "context": true,
      "livecrawlTimeout": 1000,
      "maxAgeHours": 24,
      "filterEmptyResults": true,
      "subpages": 1,
      "subpageTarget": "sources"
    }
  },
  "trigger": {
    "type": "interval",
    "period": "6h"
  },
  "outputSchema": {
    "type": "<string>",
    "description": "<string>"
  },
  "metadata": {
    "slack_channel_id": "C123ABC",
    "slack_thread_id": "1745444400.123456",
    "user_id": "U123ABC"
  },
  "webhook": {
    "url": "<string>",
    "events": []
  },
  "nextRunAt": "2023-11-07T05:31:56Z",
  "createdAt": "2023-11-07T05:31:56Z",
  "updatedAt": "2023-11-07T05:31:56Z"
}

Authorizations

x-api-key
string
header
required

Pass your Exa API key in the x-api-key header. You can also authenticate with Authorization: Bearer .

Path Parameters

id
string
required

The monitor ID

Body

application/json
name
string | null

Update the monitor name

status
enum<string>

Update the monitor status (can only set to active or paused)

Available options:
active,
paused

Partial search params to merge. All fields are optional for updates.

trigger
object | null

Update the schedule. Set to null to remove the schedule.

outputSchema
object

Controls the format of the run output. Defaults to { "type": "text" } if not specified. When type is "text", the output is a plain text summary. When type is "object", the output is structured JSON. If no properties are specified with "object" type, a schema is inferred automatically; otherwise the output adheres to the provided schema.

metadata
object | null

Update metadata. Set to null to remove. Echoed back in webhook deliveries so you can route updates to systems like Slack.

Example:
{
"slack_channel_id": "C123ABC",
"slack_thread_id": "1745444400.123456",
"user_id": "U123ABC"
}
webhook
object

Partial webhook params to merge. All fields are optional for updates.

Response

200 - application/json

The updated monitor

id
string
required

The unique identifier for the monitor

name
string | null
required

An optional display name

status
enum<string>
required

The status of the monitor. active monitors run on schedule and can be triggered manually. paused monitors can only be triggered manually. disabled monitors are auto-disabled after 10 consecutive authentication failures.

Available options:
active,
paused,
disabled
trigger
object | null
required

The interval-based schedule for automatic runs. Null if no schedule is set.

outputSchema
object
required

Controls the format of the run output. Defaults to { "type": "text" } if not specified. When type is "text", the output is a plain text summary. When type is "object", the output is structured JSON. If no properties are specified with "object" type, a schema is inferred automatically; otherwise the output adheres to the provided schema.

metadata
object | null
required

Optional key-value metadata for your own tracking. Echoed back in webhook deliveries so you can route updates to systems like Slack.

Example:
{
"slack_channel_id": "C123ABC",
"slack_thread_id": "1745444400.123456",
"user_id": "U123ABC"
}
webhook
object
required
nextRunAt
string<date-time>
required

When the next scheduled run will occur. Null if no trigger is set.

createdAt
string<date-time>
required

When the monitor was created

updatedAt
string<date-time>
required

When the monitor was last updated