SDKs
Official client libraries for TypeScript, Python, PHP, and Go.
We publish official SDKs so you don’t have to hand-roll HTTP calls, auth headers, pagination, retries, or error handling. Every SDK is generated from the same OpenAPI spec that powers this reference, so it always matches the live API — and is fully typed.
TypeScript
npm install @usgm/sdk
Python
pip install usgm
PHP
composer require usgm/sdk
Go
go get github.com/usgm/usgm-go
What every SDK gives you
- Authentication — pass your API key once; the SDK sends it on every request.
- Typed models — resources and parameters are fully typed for editor autocomplete and safety.
- Automatic pagination — list methods return an iterator that fetches pages for you.
- Retries with backoff — transient
429/5xxresponses are retried automatically. - Typed errors — non-2xx responses raise a typed error carrying
codeandrequest_id.
Environments
Point the SDK at the sandbox while developing, then switch to production:
SDKs are generated with Fern from the gateway’s OpenAPI 3.1 document. When the API changes, the SDKs are regenerated and re-published from the same spec, so the client is never out of date.