OpenAPI specification

Download the OpenAPI 3.1.0 document for the Samva API and generate clients from it.

The Samva API publishes an OpenAPI 3.1.0 document. Use it to generate a client, inspect operations, or import the API into a tool.

Access the specification

The OpenAPI document is available at:

https://api.samva.dev/v1/openapi.json

For development:

https://api.samva.localhost/v1/openapi.json

Use the specification

Interactive documentation

You can use tools like Swagger UI or Scalar to explore the API:

  1. Download the OpenAPI document from /v1/openapi.json
  2. Import it into Swagger UI, Postman, or your preferred API tool
  3. Explore endpoints, schemas, and examples

Code generation

Generate client libraries for your preferred language:

TypeScript/JavaScript.

npx @hey-api/openapi-ts -i https://api.samva.dev/v1/openapi.json -o ./src/client

Python.

openapi-generator generate -i https://api.samva.dev/v1/openapi.json -g python -o ./python-client

Go.

openapi-generator generate -i https://api.samva.dev/v1/openapi.json -g go -o ./go-client

Postman collection

Samva also publishes an official Postman collection derived from this OpenAPI document:

  1. Open Postman
  2. Click Import
  3. Select Link and enter: https://api.samva.dev/v1/postman.json
  4. Import the collection

The served collection updates with the public API, but an import into Postman is a snapshot. Reimport it to refresh your local collection.

Specification details

The OpenAPI document includes:

  • All exported SDK endpoints. Authenticated and public HttpApi operations in the generated SDK surface.
  • Request and response schemas.
  • API key authentication details.
  • Request and response examples.
  • Error schema documentation.

SDK generation

The official Samva TypeScript SDK is generated from this OpenAPI document:

npm install samva

View SDK Documentation →

Next steps

On this page