SDK Documentation
Flags, experiments, and service telemetry for JavaScript & TypeScript (@foredeck/sdk-js)
- Local evaluation — the ruleset is fetched once and evaluated in-process; no network call per evaluation (< 1ms).
- Exposure batching — every evaluation enqueues an exposure event, deduped and flushed asynchronously.
- Offline resilience — bootstrap ruleset, last-known-good serving, per-flag defaults; evaluation never throws.
- One SDK for the whole loop — the same client that evaluates flags emits counters, logs, traces, and request metrics, so a rollout and the telemetry that judges it share one integration.
- Edge-safe — no
node:*imports; works in Node, browsers, and edge runtimes (WinterCG APIs only).
Quickstart
Install the SDK, create a client, and evaluate your first flag.
Config as Code
Declare flags in foredeck.yaml and sync them from CI or your terminal.
API Reference
Full client API reference: createClient options and client methods.
Evaluation Spec
The portable, deterministic evaluation spec shared with the server.
Exposures
How exposure events are enqueued, deduped, batched, and flushed.
Counters
Counter metric submissions, batching, and aggregation semantics.
Logs
Structured log shipping, severity filtering, and automatic trace correlation.
Monitor your services
Instrument a service end to end — requests, logs, traces, infrastructure, and alerts.
Sign-in & organizations
Sign in, switch between your personal account and organizations, roles, and invitations.
Alerting
Notification channels, fire and recover, dedup keys, and the webhook source IP to allowlist.
Push notifications
Browser push notifications when a monitor fires or recovers.
OpenFeature
Standards-based OpenFeature provider for server and web.