paperclip_add_routine_trigger
Add a schedule, webhook, or API trigger to your routine. Define a cron expression for scheduled triggers to automate recurring execution.
Instructions
Add a trigger to a routine. Supports schedule (cron), webhook, and api trigger kinds.
Args:
routineId: string — Routine UUID (example: "rtn_abc123")
kind: string — Trigger kind: schedule | webhook | api
cronExpression: string (optional) — 5-field cron expression, required for schedule triggers (example: "*/5 * * * *")
timezone: string (optional) — Timezone for schedule triggers (default: UTC)
Returns: Returns the created trigger object: id, routineId, kind, cronExpression, createdAt.
Examples:
Use when: scheduling a routine to run every 5 minutes after creating it
Don't use when: the trigger already exists — use paperclip_update_routine_trigger to modify it
Error Handling:
400: invalid cron expression → must be a 5-field cron (e.g. '*/5 * * * *')
401: authentication failed → check PAPERCLIP_API_KEY
404: routine not found → verify ID with paperclip_list_routines
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| routineId | Yes | Routine UUID | |
| kind | Yes | Trigger kind: schedule | webhook | api | |
| cronExpression | No | 5-field cron expression for schedule triggers (e.g. '*/5 * * * *'). Required when kind is 'schedule'. | |
| timezone | No | Timezone for schedule triggers (e.g. 'UTC', 'America/New_York'). Default: UTC |