Create routine
Save a routine: a standing question Q answers on a schedule in this conference's room until an end date, e.g. every morning at 8 until Dec 5, who is speaking today that we want to meet. A routine only reads: it never changes, approves or sends anything. Inputs: campaign_id, prompt (the question, up to 500 characters), cadence daily (at local_hour, 0-23, default 8) or every_n_hours (every_n_hours 2-24), timezone (IANA name, default UTC), starts_on and ends_on (YYYY-MM-DD; ends_on defaults to the conference's end date + 1 day and is refused when neither is known; ends_on can be at most 120 days after starts_on), destinations: room, and slack (the client's Slack channel, when its alerts are on) only from sayintel's own Q. dry_run defaults to true and writes nothing: it returns the read-back with estimated_runs (how many runs until the end date), max_runs_per_day (the account's cap, 20), paid_by (each run is one to four short gateway model calls on the owner's credits) and save_with (the same arguments with every default spelled out). Read the question, when it runs and the end date back to the person, and save only after their yes, with dry_run false and save_with's arguments. The same routine is never saved twice in one conference. At most 5 active routines per conference.
Request
curl -X POST "https://sayintel.com/api/public/v1/campaigns/<campaign_id>/routines" \
-H "Authorization: Bearer $SAYINTEL_TOKEN" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: $(uuidgen)" \
-d '{}'Try it out
Sent as a bearer token to this site only, and kept in this tab's session storage. It is never written to disk or sent anywhere else.
Path parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| campaign_id | path | string | yes | — |
Body
| Name | In | Type | Required | Description |
|---|---|---|---|---|
| prompt | body | string | no | — |
| cadence | body | stringdaily | every_n_hours | no | — |
| local_hour | body | number | no | — |
| every_n_hours | body | number | no | — |
| timezone | body | string | no | — |
| starts_on | body | string | no | — |
| ends_on | body | string | no | — |
| destinations | body | array | no | — |
| dry_run | body | boolean | no | — |
| workspace | body | string | no | Not accepted on this tool: it acts on your own account, and naming another workspace is refused. |
| acting_account | body | string | no | Which sayintel login this call acts on: an account_id or email from list_accounts. Required once logins are linked to this connection. |
Response
{
"ok": true,
"tool": "create_routine",
"kind": "write",
"data": { ... },
"error": null
}Notes
- Scope required: write. How scopes work.
- Accepts Idempotency-Key. A retry with the same key replays the first result instead of repeating the work.
- Accepts dry_run: true and always returns cost_preview before spending anything.
- Same capability over MCP as the tool create_routine. MCP setup.