Skip to main content

SDK Installation

The Crontify SDK is a zero-dependency Node.js package with full TypeScript support.

Requirements​

  • Node.js 18 or later (uses native fetch)
  • TypeScript 5.0+ (if using TypeScript — not required)

Install​

npm install @crontify/sdk
yarn add @crontify/sdk
pnpm add @crontify/sdk

Verify​

import { CrontifyMonitor } from '@crontify/sdk';
console.log(CrontifyMonitor); // Should not throw

CommonJS​

The SDK ships both ESM and CJS builds. CommonJS require works without any extra configuration:

const { CrontifyMonitor } = require('@crontify/sdk');

Environment variables​

Store your credentials as environment variables — never hardcode them:

# .env
CRONTIFY_API_KEY=ck_live_...
CRONTIFY_MONITOR_ID=clxxx...

Get your API key from the API Keys page in your dashboard. Get your monitor ID from the monitor detail page.