跳转到主要内容
POST
/
v1
/
monitors
创建监控
curl --request POST \
  --url https://api.olostep.com/v1/monitors \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "query": "<string>",
  "frequency": "<string>",
  "email": "<string>",
  "webhook_url": "<string>",
  "phone_number": "<string>",
  "metadata": {},
  "output_schema": {}
}
'
{
  "id": "<string>",
  "object": "monitor",
  "status": "active",
  "fda_id": "<string>",
  "query": "<string>",
  "frequency": "<string>",
  "cron_expression": "<string>",
  "notification_target": "<string>",
  "metadata": {},
  "output_schema": {},
  "created": 123,
  "updated": 123
}

Documentation Index

Fetch the complete documentation index at: https://docs.olostep.com/llms.txt

Use this file to discover all available pages before exploring further.

授权

Authorization
string
header
必填

Bearer认证头格式为Bearer ,其中是你的认证令牌。

请求体

application/json
query
string
必填

自然语言的监控意图。如果查询中包含 URL,监控将专注于该 URL。

frequency
string
必填

自然语言的计划指令(例如:'每天在 9am America/Los_Angeles' 或 '每个工作日在 14:30')。如果未指定时区,则使用 UTC。

email
string

通知电子邮件。与 webhook_url 和 phone_number 互斥。

webhook_url
string<uri>

通知 webhook URL(http/https)。与 email 和 phone_number 互斥。

phone_number
string

E.164 格式的通知电话号码(例如:'+14155552671')。提供时,通知通过 SMS 发送。与 email 和 webhook_url 互斥。

Pattern: ^\+[1-9]\d{1,14}$
metadata
object
output_schema
object

可选的 JSON 模式,用于强制结构化监控提取输出。

响应

监控已接受并激活。

id
string
object
string
示例:

"monitor"

status
string
示例:

"active"

fda_id
string
query
string
frequency
string

自然语言的计划指令。由调度器解释;如果未提供时区,则默认为 UTC。

cron_expression
string
notification_channel
enum<string>
可用选项:
email,
webhook,
sms
notification_target
string
metadata
object
output_schema
object
created
integer
updated
integer