Scheduled and triggered runs
Run agents on a schedule, on demand, or from webhooks and Discord.
-
Schedule a deployment
Pin an agent version and environment to a cron schedule with an IANA timezone.
Read the docsconst deployment = await client.waitForPending( await client.deployments.create( { name: "Morning report", agent: process.env.AGENT_ID!, environment_id: process.env.ENVIRONMENT_ID!, initial_events: [ { type: "user.message", content: [{ type: "text", text: "Write the morning report." }] }, ], schedule: { type: "cron", expression: "0 9 * * 1-5", timezone: "America/New_York" }, }, { idempotencyKey: process.env.DEPLOYMENT_CREATE_KEY! }, ),)curl --fail-with-body -X POST "$CHECKFU_BASE_URL/v1/deployments" \ -H "Authorization: Bearer $CHECKFU_API_KEY" \ -H "Idempotency-Key: $DEPLOYMENT_CREATE_KEY" \ -H "Content-Type: application/json" \ -d @report.jsoncheckfu deployments create --idempotency-key "$DEPLOYMENT_CREATE_KEY" \ --name "Morning report" --agent "$AGENT_ID" --environment-id "$ENVIRONMENT_ID" < report.json{ "name": "deployments_create", "arguments": { "idempotency_key": "morning-report-1", "body": { "name": "Morning report", "agent": "agent_123", "environment_id": "env_123", "initial_events": [ { "type": "user.message", "content": [{ "type": "text", "text": "Write the morning report." }] } ], "schedule": { "type": "cron", "expression": "0 9 * * 1-5", "timezone": "America/New_York" } } }}# deployments/report.yamltype: deploymentname: Weekday reportagent: ../agents/reviewer.mdenvironment_id: ../environments/locked-down.yamlinitial_events: - type: user.message content: [{ type: text, text: Write the daily support report. }]schedule: type: cron expression: "0 9 * * 1-5" timezone: America/New_York -
Run on demand or from webhooks
Start a run manually, or trigger it from GitHub, Linear, Notion, Discord, or a signed webhook.
Read the docsconst run = await client.waitForPending( await client.deployments.run(deployment.id, { idempotencyKey: process.env.DEPLOYMENT_RUN_KEY!, }),)curl --fail-with-body -X POST "$CHECKFU_BASE_URL/v1/inbound_bindings" \ -H "Authorization: Bearer $CHECKFU_API_KEY" \ -H "Content-Type: application/json" \ -d '{"type":"webhook","deployment_id":"dep_123"}'checkfu deployments run --deployment-id "$DEPLOYMENT_ID" \ --idempotency-key "$DEPLOYMENT_RUN_KEY"{ "name": "deployments_run", "arguments": { "path": { "deployment_id": "dep_123" }, "idempotency_key": "report-run-1" }}# deployments/triage.yaml (omit schedule to run on demand)type: deploymentname: Issue triageagent: ../agents/reviewer.mdenvironment_id: ../environments/locked-down.yamlinitial_events: - type: user.message content: [{ type: text, text: Triage the new issue. }] -
Reconcile from Git
Keep agents, environments, deployments, memory stores, and vaults in files with checkfu apply.
Read the docs// Inspect outbound HMAC-signed webhook deliveries from the SDK:for await (const delivery of client.webhooks.deliveries.list(webhookId)) { console.log(delivery.id, delivery.status)}curl --fail-with-body "$CHECKFU_BASE_URL/v1/webhooks/$WEBHOOK_ID/deliveries" \ -H "Authorization: Bearer $CHECKFU_API_KEY"checkfu apply . --dry-runcheckfu apply . --yes{ "name": "webhooks_listDeliveries", "arguments": { "path": { "webhook_id": "wh_123" } }}# checkfu apply reconciles:# agents/*.md# environments/*.yaml# deployments/*.yaml# memory_stores/*.yaml# vaults/*.yaml# tracked in checkfu-lock.json
Managed agents for any harness
Pick the harness and model. Checkfu runs everything around them.