Getting started

Installation

Install the SDK in Meteor 2, Meteor 3, or any Node.js project.

The Quickstart shows the happy path. This page covers every supported install method, including self-built containers, Docker images, and edge runtimes.

Meteor

UptimeClarity ships as an Atmosphere package. Install with:

meteor add uptimeclarity:apm

The package detects whether your app is running on Meteor 2 (Fibers) or Meteor 3 (async). No version-specific configuration is required.

Required Node version

Meteor versionRequired NodeNotes
2.x14.x – 16.xFibers-based runtime.
3.x18.x +Async runtime; Fibers shimmed.

Node.js (any framework)

For Express, Fastify, Hono, Koa, Nest, or anything else:

npm install @uptimeclarity/node
index.js
import { init } from '@uptimeclarity/node';
 
init({
  token: process.env.UPTIMECLARITY_TOKEN,
  // Optional — defaults are sensible.
  service: 'api',
  environment: process.env.NODE_ENV ?? 'production',
});

Docker

If you build your app into a container, ensure the runtime can reach https://api.uptimeclarity.com. No agent or sidecar is required.

Dockerfile
FROM node:20-alpine
WORKDIR /app
COPY package*.json ./
RUN npm ci --omit=dev
COPY . .
ENV UPTIMECLARITY_TOKEN=uc_live_…
CMD ["node", "index.js"]

Configuration sources

The SDK accepts configuration in this order of precedence (highest first):

  1. Direct call options — init({ token: '…' }).
  2. Environment variables — UPTIMECLARITY_TOKEN, UPTIMECLARITY_SERVICE, …
  3. Meteor settings — Meteor.settings.uptimeclarity (Meteor only).

Edge runtimes

Cloudflare Workers, Vercel Edge, and similar runtimes are not supported directly. Use the REST ingest API instead.