Supercheck LogoSupercheck

Configuration

supercheck.config.ts reference and project structureEdit

Config File

Supercheck CLI uses a TypeScript configuration file with full IntelliSense via defineConfig().

./supercheck.config.ts            # Project configuration (checked into repo)
./supercheck.config.local.ts      # Local overrides (gitignored, optional)

Config files must never contain tokens. The CLI scans for token patterns (sck_live_*, sck_trigger_*, sck_test_*) and rejects any config containing them.

Full Example

supercheck.config.ts
import { defineConfig } from '@supercheck/cli'

export default defineConfig({
  schemaVersion: '1.0',
  project: {
    organization: '019c1fe3-0a0a-7ae9-884d-61baea139786',
    project: '019c1fe3-0a0f-7089-97b3-12990d78a9ee',
  },
  api: {
    baseUrl: process.env.SUPERCHECK_URL ?? 'https://app.supercheck.io',
  },
  tests: {
    playwright: {
      testMatch: '_supercheck_/tests/**/*.pw.ts',
    },
    k6: {
      testMatch: '_supercheck_/tests/**/*.k6.ts',
    },
  },
  monitors: [
    {
      id: '019c3643-9495-7d66-a463-1c0d42d4520e',
      name: 'API Health Monitor',
      type: 'http_request',
      target: 'https://api.example.com/health',
      frequencyMinutes: 5,
      enabled: true,
      config: {
        method: 'GET',
        timeoutSeconds: 30,
        expectedStatusCodes: '200-299',
        locationConfig: {
          locations: ['eu-central', 'us-east', 'asia-pacific'],
        },
      },
      alertConfig: {
        enabled: true,
        alertOnFailure: true,
        alertOnRecovery: true,
        notificationProviders: ['019c22b5-6df9-79b7-b415-db8317b1bd0b', '019c22b5-a812-7acc-9f23-46f7904d2c2a'],
      },
    },
  ],
  jobs: [
    {
      id: '01912345-abcd-7000-8000-000000000001',
      name: 'Nightly E2E Suite',
      tests: ['_supercheck_/tests/019a1234-abcd-7000-8000-000000000001.pw.ts'],
      jobType: 'playwright',
      cronSchedule: '0 2 * * *',
      alertConfig: {
        enabled: true,
        alertOnFailure: true,
        alertOnSuccess: true,
        notificationProviders: ['019c22b5-6df9-79b7-b415-db8317b1bd0b'],
      },
    },
  ],
})

Configuration Precedence

Settings are resolved in this order (highest to lowest priority):

  1. CLI flags--url, --config, etc.
  2. Environment variablesSUPERCHECK_URL, SUPERCHECK_ORG, SUPERCHECK_PROJECT
  3. supercheck.config.local.ts — Local overrides (deep-merged)
  4. supercheck.config.ts — Project defaults

Config Path Override

# Use a specific config file
supercheck deploy --config ./configs/staging.config.ts

Supported formats: .ts, .js, .mjs

Self-Hosted Configuration

Standard Supercheck self-hosted deployments use Traefik + Let's Encrypt for automatic TLS — no certificate configuration needed.

# Self-hosted setup (that's all you need!)
export SUPERCHECK_URL="https://supercheck.yourdomain.com"
export SUPERCHECK_TOKEN="sck_live_..."

supercheck whoami

If using Cloudflare proxy, set SSL/TLS mode to "Full (strict)" in Cloudflare Dashboard.

Corporate Proxy Configuration

For environments behind HTTP proxies:

export HTTPS_PROXY="http://proxy.corp.com:8080"
export NO_PROXY="localhost,127.0.0.1,.internal.corp.com"

supercheck job trigger abc123 --wait

Project Structure

_supercheck_/ Folder

Tests, monitors, and status page definitions live in the _supercheck_/ folder:

my-project/
├── _supercheck_/
│   ├── tests/
│   │   ├── 019a1234-abcd-7000-8000-000000000001.pw.ts   # Playwright test (UUID filename)
│   │   ├── 019a1234-abcd-7000-8000-000000000002.pw.ts   # Playwright API test
│   │   └── 019a1234-abcd-7000-8000-000000000003.k6.ts   # k6 performance test
│   ├── monitors/
│   │   └── api-monitor.ts           # Monitor definition
│   └── status-pages/
│       └── main-status.ts           # Status page definition
├── supercheck.config.ts
└── package.json

File Naming Convention

ExtensionRunnerExample
*.pw.tsPlaywright019a1234-abcd-7000-8000-000000000001.pw.ts
*.k6.tsk6019a1234-abcd-7000-8000-000000000003.k6.ts

Test files pulled from the cloud are named using their database UUID ({uuid}.pw.ts or {uuid}.k6.ts). This ensures stable file paths that survive test renames in the dashboard. The test title is stored in the Supercheck database.

Config Schema Reference

project

FieldTypeRequiredDescription
organizationstringYesOrganization slug
projectstringYesProject slug

api

FieldTypeDefaultDescription
baseUrlstringhttps://app.supercheck.ioAPI base URL

tests.playwright

FieldTypeDescription
testMatchstringGlob pattern for Playwright test files

tests.k6

FieldTypeDescription
testMatchstringGlob pattern for k6 test files

jobs[]

FieldTypeDescription
idstringDatabase UUID (present for existing resources, omit for new)
namestringJob display name
jobTypestringJob type (playwright, k6)
cronSchedulestringCron expression
alertConfigobjectAlert config with notificationProviders (UUIDs), alertOnFailure, etc.

Validate & Print

# Validate config syntax and schema
supercheck config validate

# Print resolved configuration (with env var expansion)
supercheck config print

Monitoring-as-Code Commands

# Preview changes between config and server state
supercheck diff

# Deploy config to Supercheck (create/update/delete resources)
supercheck deploy
supercheck deploy --dry-run      # Preview without applying
supercheck deploy --no-delete    # Skip deletions
supercheck deploy --force        # Skip confirmation

# Tear down all managed resources
supercheck destroy
supercheck destroy --dry-run
supercheck destroy --force

Resources are reconciled using the database id — the CLI compares your local config with the server state and creates, updates, or deletes resources as needed. Resources pulled from the cloud include their id (UUID); new resources omit it and are created on deploy.

On this page