statsig-node-cloudflare-kv
TypeScript icon, indicating that this package has built-in type declarations

1.0.0 • Public • Published

Statsig Node Server SDK - Edge Config Adapter

npm version

A first party Cloudflare integration with the Statsig server-side Node.js SDK.

Quick Setup

  1. Install the Statsig Node SDK
npm install statsig-node@5.3.0
  1. Install this package
npm install statsig-node-cloudflare-kv
  1. Setup the Statsig Cloudflare Integration
  2. Import the package
import { CloudflareKVDataAdapter } from 'statsig-node-cloudflare-kv'
  1. Create an instance of the CloudflareKVDataAdapter
const dataAdapter = new CloudflareKVDataAdapter(env.YOUR_KV_BINDING, 'statsig-YOUR_COMPANY_ID');
  1. When initializing the statsig sdk, add the adapter to options
await statsig.initialize(
    'server-secret-key',
    { dataAdapter: dataAdapter },
);

Readme

Keywords

none

Package Sidebar

Install

npm i statsig-node-cloudflare-kv

Weekly Downloads

232

Version

1.0.0

License

ISC

Unpacked Size

9.97 kB

Total Files

13

Last publish

Collaborators

  • kenny-statsig
  • daniel-statsig
  • sroyal
  • statsig-admin