Overview & Quick Start
OpenTelemetry Health Integration
@nexload-sdk/healthcheck-otel
v2.1.0 Stable ReleasedOpenTelemetry-friendly transforms for @nexload-sdk/healthcheck reports.
Node.jsBun
@nexload-sdk/healthcheck-otel transforms @nexload-sdk/healthcheck reports into OpenTelemetry attributes, structured semantic conventions, and metrics payloads without mandatory dependencies on heavy @opentelemetry/api packages.
10-Second Code Snippet
Section titled “10-Second Code Snippet”import { createHealthManager } from "@nexload-sdk/healthcheck";import { otelExporter } from "@nexload-sdk/healthcheck-otel";
const health = createHealthManager({ service: { name: "api" } });const exporter = otelExporter({ namespace: "app" });
const report = await health.run("readiness");const attributes = exporter.exportAttributes(report);// Ready to attach to an active OpenTelemetry trace span or log recordWhat You Get
Section titled “What You Get”- OTel Semantic Conventions: Standard attributes:
health.status,health.service.name, and individual check attributes. - Span Metadata Formatter: Automatically attaches health reports to active distributed trace spans.
- Zero Heavy SDK Dependencies: Pure data transformers that work with any existing OpenTelemetry collector or custom logger.
Installation & Requirements
Section titled “Installation & Requirements”pnpm add @nexload-sdk/healthcheck-otel @nexload-sdk/healthcheckRequires Node.js >=20.9.0 or Bun >=1.0.0.
Next Steps
Section titled “Next Steps”- Explore Production Guides & OTel Recipes for span attachment and telemetry conventions.
- Check the API Reference & Signatures for exporter options.