What starts the work, and what it talks to.

Start a script or a flow on a schedule, from a webhook, a form, an event or a system you poll. Reach other systems through connections whose addresses and credentials belong to each workspace, so dev and production never cross, and the repository never holds a secret.

  • five ways in
  • signed webhooks
  • pause with a reason
  • bound per workspace

Five ways in, one list.

Every trigger in a workspace is listed in one place, drafts included, with when it last fired, when it fires next and the last request it refused.

  • Each starts a script or a flow, and a flow can have several, each starting its own branch.
  • A trigger can tag the run it starts from what it was given, such as an order's number.
  • All of them use the same extension point a team can use to add its own.

Each one, in detail.

TriggerWhat it does
ScheduleCron in the workspace's time zone or one you name, with the next five times shown before you save, and Fire now. A time is skipped while the last run is still going, unless you allow overlap, and a workspace with 200 runs waiting stops taking more from its schedules until the queue shrinks.
WebhookA long, random address per trigger that takes JSON, a form or text. Hand the script the body, or the whole request with its headers, minus the sender's cookies and authorization. Check an HMAC signature before anything starts, and answer from the flow within 25 seconds if the sender needs a reply.
FormUp to thirty fields of seven plain types, served as a page of the tenant's portal, to anyone or to people signed in. Sending one page twice starts one run, and a field only machines fill in keeps bots out.
EventPublished by your scripts, through the API, or by the platform when a run fails or succeeds, a flow finishes or a deploy lands. A filter picks what each listener wants, and a chain of events that starts more events stops at ten deep.
Poll sourceCode your team writes, run on a worker each tick with where it last got to. It gives back what's new and where to start next time. The same kind of code can stand in front of a webhook to check a signature in a sender's own format.

Stop it without a deploy.

When a supplier's API is down or an import goes wrong, you need it to stop now, not after a review.

  • Pause one trigger in any workspace, production included, with a reason for whoever looks next. The pause outlives deploys until someone resumes it.
  • Pausing and resuming are both in the audit log.
  • Operators can pause every trigger on the instance at once. Schedules keep their times and fire once when resumed; webhooks are answered 503.
  • A new dev workspace and a cloned one start with their triggers paused, so a test never runs beside production.
examples/acme/src/index.tstriggers
export const syncEveryFiveMinutes = defineSchedule({
  path: "orders/sync-every-five-minutes",
  script: syncOrders,
  cron: "*/5 * * * *",
  timezone: "America/New_York",
});

/** Receives an order the moment the shop takes it. */
export const orderPlaced = defineWebhook({
  path: "orders/placed",
  script: receiveOrder,
});

From the Acme example. A trigger can also be made and edited in the console.

Connections, bound per workspace.

Code names a connection. Each workspace says where it points and with which credentials. Promoting to production stops until production has its own bound, so a dev key never ends up live.

  • Secrets are written once, encrypted with the tenant's key, and never shown again.
  • A deploy lists what a workspace still has to bind.
  • A clone of production starts with nothing bound, so it can't touch a real system until you say.
examples/acme/src/index.tsdefineConnection
// Where each connection points, and its credential,
// is set per workspace.
export const shop = defineConnection({
  path: "shop", description: "The web shop's order API.",
});
export const erp = defineConnection({
  path: "erp", description: "The ERP's import API.",
});

What a connection can be.

HTTP
A base address and its auth, handed to the script as a client that sends both. Every worker has it.
OAuth 2.0
A member presses Connect and agrees at the provider, with presets for Google and Microsoft. The instance keeps and refreshes the tokens; workers get only the current access token.
Mail
Send through the tenant's own mail server, with its own credential. The instance's mail settings are never lent out.
Connectors your team writes
A schema for the settings and code that builds the client. Its setup screen is a form drawn from that schema.
Groups of connections
One member per client or per shop, each with its own address and credential, added without a deploy. A script picks one by key.
Tested where it runs
Test from the setup screen runs on a worker, and the result is kept: "Reached" with how long it took, or "Failed" with the status.
Kept off your private network
The instance refuses addresses that are loopback, private or cloud metadata unless an operator allows them by name.
Called from where it's reachable
Name a worker pool on the script, and the call happens from inside the client's network.

Wire it to the systems you have.

Five ways in, and connections that keep dev and production apart.