Skip to main content

New TypeScript SDK Now Available in Beta

· 2 min read

The new TypeScript SDK is now available in beta. You can generate it today using the APIMatic CLI. Try it out and share your feedback with us.

What's New?​

  • Redesigned Core Architecture: Single-orchestrator pipeline with dedicated, fully decoupled components for auth, resilience, serialization, and error handling
  • Predictable Endpoint Structure: Every endpoint maps directly to its HTTP call, making the full request lifecycle visible and predictable across all methods
  • Type-Safe Models: Response models enforce optionality and presence contracts at compile time, eliminating runtime surprises
  • Per-Endpoint Typed Errors: Each endpoint exposes its own error type, fully navigable in the IDE without consulting documentation
  • Broad Runtime Compatibility: Runs on Node.js and in the browser, shipping both ESM and CommonJS builds alongside bundled type declarations

Generating the SDK​

The apimatic sdk generate command supports two flags for selecting the code generator version and stability level:

FlagOptionsDescription
--codegen-versionv3 (default), v4Version of the code generator to use.
--stabilitystable (default), betaStability level of the generated SDK.

Pass --codegen-version=v4 and --stability=beta to generate the new SDK:

apimatic sdk generate --language=typescript --codegen-version=v4 --stability=beta
note

v4 beta is currently available for C#, Python, and TypeScript. While the --codegen-version and --stability flags are accepted for all languages, using --codegen-version=v4 with any other language will result in a generation error.