Programs
A program is a function Trigora can execute durably. It looks like ordinary TypeScript. Progress is committed at explicit durable operations, not by reconstructing the function from a log of everything it has already done.
import { effect, waitForEvent } from "@trigora/sdk";
export async function order(input: Order) { const payment = await effect("payment", () => charge(input)); const approval = await waitForEvent("approved"); return fulfill(payment, approval);}Between durable operations, control flow stays normal: if, loops, and local computation. The TypeScript frontend is a declared subset. Unsupported constructs fail when the program is compiled, rather than silently changing recovery.
TypeScript is the first frontend. The same execution model is meant to support other languages later.
A program is the definition. A running instance of it is an execution.