Recommended
Use your framework adapter.
Adapters automatically retain normalized route templates, response status, duration, API version and explicit customer context.
Language foundation
Build on one event contract.
@apirelio/core owns event creation, route normalization, bounded metadata, retry, backpressure and graceful shutdown.
npm install @apirelio/coreimport { ApirelioClient } from '@apirelio/core'
const apirelio = new ApirelioClient({
apiKey: process.env.APIRELIO_API_KEY!,
service: 'billing-api',
environment: 'production',
})
apirelio.capture({
method: 'POST',
route: '/api/invoices/:invoice/send',
status: 202,
durationMs: 84,
customer: { id: 'cus_123', plan: 'growth' },
sdk: 'custom',
sdkVersion: '0.2.0',
})Applications using a supported framework should install its dedicated package instead of manually wrapping every request.
Off-request transport
Bounded, batched and fail-safe.
Capture only enqueues an in-memory event. Batches are delivered in the background with timeouts and bounded retry; a full queue drops telemetry instead of slowing or breaking the customer API.
Bounded queue
Backpressure protects application memory during an ingestion outage.
Selective retry
Network errors, rate limits and server failures retry with delay; invalid events fail fast.
Graceful shutdown
Framework lifecycle hooks flush pending events within a fixed timeout.
Compatibility
Supported TypeScript matrix.
@apirelio/expressExpress 4–5Node.js 20+@apirelio/fastifyFastify 4–5Node.js 20+@apirelio/nestjsNestJS 10–11Node.js 20+@apirelio/nuxtNuxt 3–4Node.js 20.19+