Skip to main content
Most operations need judgment somewhere: an approver signs off a refund, an underwriter picks an option, an agent reads a document. A procedure keeps that judgment in typed steps: each answer must match a shape the procedure declares, called a schema. The run records who decided what, and later steps can rely on the answer’s shape.

People: tasks

A task node creates a task in Effective, assigns it to users or groups, and waits for an answer.
  • Typed answers. The task declares a result schema, which also drives the task’s form. An answer that doesn’t match it is refused, so the next step never sees a half-filled form. Choices that come from earlier steps, such as the options an agent proposed, can be offered as a list to pick from.
  • Who answers. Only a task’s assignees can answer it. A procedure’s task can’t be reassigned by hand: its assignees are the ones the procedure names. A task assigned to a group stays assigned to the group, so changes to group membership still apply.
  • What’s recorded. The run records the answer with the task and submission IDs, any note and attachments, and who answered.
  • Answering from your system. Your own system can list tasks and submit answers through the API. See Answer a task.
A task can also be created without waiting, so the run can do other work and collect the answer later with a wait node.

Approvals

An approval is a task whose result is a decision, followed by a choice on that decision. Put the step that writes after the approval, in the approved branch. A rejection goes down its own branch and ends the run with a typed result, so nothing is written. The Cancel a policy tutorial shows this end to end.

Agents: agent steps

An agent node starts an agent session with instructions, typed input and a result schema, and waits for its result.
  • Typed in, typed out. The input is checked against its schema before the agent starts, and the result must match the result schema.
  • Recorded once. When the step finishes, the run records the result. If the run resumes, it uses the recorded result and doesn’t start the agent again.
  • Bounded. An agent step’s tools, data sources and other settings are fixed in the source. Your organization’s policies on models, tools and budgets are checked when you publish and when a run starts.
  • Instructions are only what you write. Prose elsewhere in the document never becomes an agent’s instructions.
Use an agent step for judgment on unstructured material, and keep rules that must always give the same answer in code steps.

Code: what a step may touch

A function or effect can only use the capabilities it declares with uses=:
  • fetch to call outside systems,
  • secrets to read the credentials it names,
  • effective:<scope> for exactly the Effective API operations that scope allows.
A function gets no services at all: no network, secrets, clock or randomness. It can only compute from its input. Publishing checks each declared capability and each secret declaration. Effective never writes a secret’s value to the source, the version or the run record. Code that reads a secret must not return it in a step’s result, because results are recorded.

Who a run acts as

A run acts as the person who started it, or as the identity a trigger was authorized to run as. Child runs act as the same person as their parent.