Console
Documentation/TypeScript and Python SDKs

TypeScript and Python SDKs

Use small clients with explicit retries and typed errors.

Both clients accept a base URL and API key. Requests preserve server request IDs and expose structured errors. They do not automatically retry sends after a network timeout.

TypeScript

ts
import { SqkiiClient } from '@sqkii/whatsapp';

const client = new SqkiiClient({
  apiKey: process.env.SQKII_API_KEY!,
  baseUrl: process.env.SQKII_BASE_URL,
});
const numbers = await client.numbers.list();
console.log(numbers);

Install the local package from packages/sdk-typescript until a public release is published. The SDK requires a runtime with native fetch.

Python

python
import os
from sqkii_whatsapp import SqkiiClient

client = SqkiiClient(
    api_key=os.environ['SQKII_API_KEY'],
    base_url=os.environ.get('SQKII_BASE_URL', 'http://localhost:4000'),
)
print(client.numbers())

Install with python -m pip install -e packages/sdk-python. The client uses the Python standard library and has no runtime HTTP dependency.

Generation and drift checks

Run node scripts/generate-clients.mjs <openapi-file-or-url> after changing the API contract. Commit the generated operation registries together with the API change. Run the same command with --check in CI to detect drift.

The generated call layer covers every documented operation:

ts
const result = await client.api.createMessage({
  path: { numberId: 'number_id' },
  body: { to: 'recipient_id', type: 'text', text: { body: 'Hello' } },
  options: { idempotencyKey: 'business-operation-123' },
});
python
result = client.api.create_message(
    path_parameters={'numberId': 'number_id'},
    body={'to': 'recipient_id', 'type': 'text', 'text': {'body': 'Hello'}},
    idempotency_key='business-operation-123',
)

See the generated endpoint index for operation IDs. Some response types remain extensible JSON; use the typed convenience methods for common messaging operations.

Safe retries

Retry reads with bounded backoff. For sends, preserve an idempotency key and inspect the original message state after an uncertain response. A delivered message can arrive later than an API request timeout.

Prepared 18 November 2026 · Sqkii Pte. Ltd.