Skip to content

Author workflows with an agent

Ask the agent to call inspect_contract for the exact chain and address. Review deployed code, saved state, proxy/implementation candidates, and ABI digest. If needed, confirm register_contract with a supplied ABI or explicit Sourcify candidate.

Registration never overwrites a conflicting ABI. Resolve conflicts in the web app after independent verification.

Give the agent the operational goal, allowed execution accounts, required variables, and review constraints. A V2 definition can include:

  • step, condition, and manual nodes;
  • explicit ref-based edges;
  • step outputs;
  • structured literal/variable values;
  • txcast-cel-v1 expressions;
  • canonical ABI functions; and
  • static raw calldata with a reason.

Ask for validation before storage. The account grant applies during validation and authoring.

create_workflow atomically creates the parent and populated strict draft. The result maps the agent’s readable node refs to stored UUIDs.

replace_workflow_draft replaces the entire strict definition and requires current revision, draft version, and definition digest. It cannot overwrite an incomplete human draft.

Publish the workflow revision as a separate confirmed action using the current concurrency fields. Refresh after a 409 and compare the latest definition before retrying.

No agent operation implicitly fetches an ABI while authoring.