Skip to content

CLI

Both the TypeScript and Python SDKs ship with a CLI that generates type definitions for your task templates. Types are derived from the task template schemas you defined in the Requence UI — input and named results — giving you full type safety when calling createTask / Task.

Terminal window
npx requence-task generate-types

This creates a requence-env.d.ts file in your project root. TypeScript picks it up automatically — your createTask() calls, result, and getNodeData() will be fully typed.

| Option | Default | Description | |—|—|—| | --access-token | — | Access token (falls back to env / config file) | | --outfile | requence-env.d.ts | Name of the generated type file | | --outdir | . | Directory to write the type file to |

Variable Description
REQUENCE_TASK_ACCESS_TOKEN Access token for authentication
REQUENCE_ACCESS_TOKEN Fallback access token