retab-dev/retab.
Install
Authenticate
Each SDK readsRETAB_API_KEY from the environment by default. Get a key from the dashboard settings.
Use RETAB_API_KEY=rt_test_... for development and CI, and
RETAB_API_KEY=rt_live_... for production. The key prefix selects the
customer environment — RETAB_BASE_URL is the
Retab deployment URL, not the environment selector. Legacy sk_retab_...
keys still work and resolve to production.
Workflow Graph Resources
Blocks and edges are flat workflow resources keyed byworkflow_id. SDK calls
take the workflow id explicitly instead of nesting graph resources under a
/workflows/{workflow_id}/... path.
When creating or updating workflow blocks with a json_schema config, the
public API treats the schema structurally. JSON object property order is not
preserved as authored display order; the dashboard may preserve authored order
through internal editor state.
Workflow Reviews
Reviews use immutable versions. To submit a corrected output, create a new version underclient.workflows.reviews.versions and pass the reviewed
parent_id/parentVersionId; SDK-created versions are always corrections of an
existing version.
Workflow Eval and Experiment Runs
Workflow runs, workflow-eval runs, and experiment runs all use the same run-id-first pattern in the SDKs: create a run from the parent resource, poll the run by itsid, then inspect child records under that run.
job_id or batch_id handles. Use the
returned run id for polling, cancellation, results, and experiment metrics.