@eigenpal/sdk is the official TypeScript SDK. It is a typed wrapper over the
EigenPal API, generated from the OpenAPI spec. Source is open at
github.com/eigenpal/sdk-typescript.
Install
tsx,
Next.js, Vite, or any modern bundler. Plain node script.js will not work.
Get an API key from the dashboard under Settings, API Keys.
Quick start
Authentication
Pass the key explicitly, or setEIGENPAL_API_KEY and let the SDK pick it up:
apiKey option always wins over the environment fallback.
Starting runs
client.run(target, input?, options?) starts a workflow or agent. Targets are
strings like workflows.extract-invoice or agents.invoice-agent, or structured
objects like { type: 'workflow', slug: 'extract-invoice' }. Use
runAndWait to block until the run finishes and return its output.
Self-hosted
Point the SDK at your own deployment:baseUrl wins over the EIGENPAL_BASE_URL fallback and defaults to the hosted
cloud.
Errors
CatchEigenpalValidationError when inputs do not match the workflow schema; it
carries the field-level detail so you can surface it to the caller.
See the API reference for the endpoints the SDK calls.