Skip to main content
POST
/
v1
/
workflows
/
yaml
/
plan
from retab import Retab

client = Retab()

plan = client.workflows.specs.plan(yaml_definition)

print(plan.action)
for operation in plan.operations:
    print(operation.action, operation.target, operation.target_id)
{
  "workflow_id": "wf_abc123",
  "action": "update",
  "block_count": 2,
  "edge_count": 1,
  "diagnostics": {
    "issues": []
  },
  "operations": [
    {
      "action": "update_workflow",
      "target": "workflow",
      "target_id": "wf_abc123",
      "summary": "Update workflow metadata"
    }
  ]
}

Documentation Index

Fetch the complete documentation index at: https://docs.retab.com/llms.txt

Use this file to discover all available pages before exploring further.

Compute the reconcile plan for a declarative workflow YAML spec against the current draft workflow. This does not mutate workflow state. Use this before apply() to see whether the spec will create a workflow, update blocks and edges, or no-op.
from retab import Retab

client = Retab()

plan = client.workflows.specs.plan(yaml_definition)

print(plan.action)
for operation in plan.operations:
    print(operation.action, operation.target, operation.target_id)
{
  "workflow_id": "wf_abc123",
  "action": "update",
  "block_count": 2,
  "edge_count": 1,
  "diagnostics": {
    "issues": []
  },
  "operations": [
    {
      "action": "update_workflow",
      "target": "workflow",
      "target_id": "wf_abc123",
      "summary": "Update workflow metadata"
    }
  ]
}

Authorizations

Api-Key
string
header
required

Query Parameters

access_token
string | null

Body

application/json
yaml_definition
string
required

Workflow YAML definition

Response

Successful Response

workflow_id
string
required
action
enum<string>
required
Available options:
create,
update,
noop
block_count
integer
required
edge_count
integer
required
diagnostics
Diagnostics · object
required
operations
DeclarativePlanOperation · object[]
required