Amlexia SDKs
Official client libraries for Amlexia — operational intelligence for APIs, AI providers, payments, and infrastructure.
| Package | Registry | Install |
|---|---|---|
| Node.js | npm @amlexiahq/node |
npm install @amlexiahq/node |
| Python | PyPI amlexia |
pip install amlexia |
| Go | GitHub sdks/go |
go get github.com/Amlexia/Amlexia/sdks/go@latest |
| Ruby | GitHub sdks/ruby |
See Ruby README |
| Shared (Node) | npm @amlexiahq/shared |
Dependency of @amlexiahq/node
|
- Dashboard: https://app.amlexia.com
- Ingest API: https://ingest.amlexia.com
- Support: support@amlexia.com
- Status: https://status.amlexia.com
License: Proprietary — not open source. See LICENSE. Use is subject to the Terms of Service.
Documentation
| Doc | Description |
|---|---|
| Getting started | Account, first event, dashboard |
| Environment variables | All AMLEXIA_* and related env vars |
| Event fields | Every track() field and ingest mapping |
| Node.js SDK | API reference, Express, Fastify, Hono, Next.js, OTEL |
| Python SDK | API reference, FastAPI, Flask, Django |
| Go SDK | HTTP client, OpenAI/Anthropic helpers, tracing |
| Ruby SDK | HTTP client, OpenAI/Anthropic helpers, tracing |
| @amlexiahq/shared | Tracing IDs, provider detection, PII scrubbing |
| Examples | Runnable samples |
| AI setup prompts | Master prompt for Cursor/Copilot — install, env, all frameworks, OpenAI, Stripe, cost_usd, verify |
| Publishing | Release process for maintainers |
Quick start
Node.js
import { AmlexiaClient } from '@amlexiahq/node';
const client = new AmlexiaClient({
sdkKey: process.env.AMLEXIA_SDK_KEY!,
ingestUrl: process.env.AMLEXIA_INGEST_URL ?? 'https://ingest.amlexia.com',
});
await client.track({
endpoint: 'POST /v1/chat',
method: 'POST',
statusCode: 200,
latencyMs: 320,
provider: 'openai',
tokensInput: 120,
tokensOutput: 80,
});
await client.shutdown();Python
from amlexia import AmlexiaClient
client = AmlexiaClient.from_env()
client.track("POST /v1/chat", "POST", 200, 320, provider="openai", tokens_input=120, tokens_output=80)
client.shutdown()Repository layout
packages/shared/ @amlexiahq/shared — tracing, providers, scrubber
sdks/node/ @amlexiahq/node — Node.js SDK + framework middleware
sdks/python/ amlexia — Python SDK + framework integrations
examples/ Minimal Express and FastAPI samples
docs/ Cross-SDK guides
How ingestion works
- Your app calls
track()(or middleware does it automatically). - Events are buffered and sent in batches to
POST /v1/events. - Default flush: every 5 seconds or 50 events (configurable).
- On shutdown, call
shutdown()to flush remaining events.
Retries use exponential backoff (up to 5 attempts by default).
Framework support
| Framework | Node | Python |
|---|---|---|
| Express | @amlexiahq/node/express |
— |
| Fastify | @amlexiahq/node/fastify |
— |
| Hono | @amlexiahq/node/hono |
— |
| Next.js App Router | @amlexiahq/node/next |
— |
| FastAPI | — | amlexia.fastapi_integration |
| Flask | — | amlexia.flask_integration |
| Django | — | amlexia.django_integration |
Develop from source
pnpm install
pnpm build
pnpm typecheckSupport
- Email: support@amlexia.com
- Contact: https://amlexia.com/contact
- Security: https://amlexia.com/security