创建启用状态的规则
POST
/triggers
授权
APIKey
Remote cp-auth key with automation scope; never pass it in the URL. /healthz and CORS preflight are anonymous.
类型
API Key (header: CP-X-API-KEY)
请求体
application/json
JSON "source": { "type": "incoming", "config": { } }, "filters": { "type": "text_contains", "config": { "path": "/data/post/text", "text": "bitcoin", "case_sensitive": false } }, "cooldown_minutes": 0, "actions": [ { "type": "webhook", "config": { "url": "https://example.com/events" } } ]
{
}
响应
Success
application/json
JSON "source": { "type": "price", "config": { "symbol": "string", "operator": "string", "threshold": "string", "currency": "USD" } }, "queries": [ { "id": "string", "type": "price", "config": { "symbol": "string", "currency": "USD" } } ], "filters": null, "cooldown_minutes": 0, "note": "", "id": "string", "revision": 0, "status": "string", "last_fired_at": "string", "created_at": "string", "updated_at": "string", "actions": [ { "type": "webhook", "config": { "url": "string" } } ]
{
}
