Monitor
Create Monitor
Changed onCreate a monitor.
Monitors run on a fixed frequency to detect material changes in web content. Set type=event_stream to monitor a search query, or type=snapshot to monitor a specific task run's output. The monitor runs once immediately at creation, then continues on the configured schedule.
post/v1/monitors
Request
- Base URLhttps://api.parallel.ai
- AuthAPI key in header x-api-key
Request body
Example request
{
"type": "event_stream",
"frequency": "1h",
"webhook": {
"url": "https://example.com/webhook"
},
"metadata": {
"slack_thread_id": "1234567890.123456",
"user_id": "U123ABC"
},
"settings": {
"query": "Extract recent news about AI",
"output_schema": {
"json_schema": {
"additionalProperties": false,
"properties": {
"gdp": {
"description": "GDP in USD for the year, formatted like '$3.1 trillion (2023)'",
"type": "string"
}
},
"required": [
"gdp"
],
"type": "object"
}
},
"advanced_settings": {
"source_policy": {
"include_domains": [
"wikipedia.org",
"docs.python.org/3",
".edu"
],
"exclude_domains": [
"reddit.com",
"youtube.com/shorts",
".ai"
],
"after_date": "2024-01-01"
},
"location": "us"
}
}
}Response
Monitor created successfully.
Example response
{
"type": "event_stream",
"status": "active",
"frequency": "1h",
"processor": "lite",
"webhook": {
"url": "https://example.com/webhook"
},
"metadata": {
"slack_thread_id": "1234567890.123456",
"user_id": "U123ABC"
},
"created_at": "2025-01-15T10:30:00Z",
"last_run_at": "2025-01-15T10:30:00Z",
"settings": {
"query": "Extract recent news about AI",
"output_schema": {
"json_schema": {
"additionalProperties": false,
"properties": {
"gdp": {
"description": "GDP in USD for the year, formatted like '$3.1 trillion (2023)'",
"type": "string"
}
},
"required": [
"gdp"
],
"type": "object"
}
},
"advanced_settings": {
"source_policy": {
"include_domains": [
"wikipedia.org",
"docs.python.org/3",
".edu"
],
"exclude_domains": [
"reddit.com",
"youtube.com/shorts",
".ai"
],
"after_date": "2024-01-01"
},
"location": "us"
}
},
"output": {
"latest_snapshot": {
"basis": [
{
"confidence": "low"
}
]
}
}
}Changes
- warning
added the new
coreenum value to theresponse property for the response status - info
added the new
coreenum value to the request property
- warning
- info
added the new optional request property
- info