{"_id":"@apex-inc/openfeature","name":"@apex-inc/openfeature","dist-tags":{"latest":"0.1.0"},"versions":{"0.1.0":{"name":"@apex-inc/openfeature","version":"0.1.0","description":"OpenFeature server provider for Apex experiments. A thin adapter over Apex's authoritative assignment endpoint — read Apex experiment assignments through the standard OpenFeature interface.","main":"dist/index.js","module":"dist/esm/index.js","types":"dist/index.d.ts","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/esm/index.js","require":"./dist/index.js"}},"sideEffects":false,"scripts":{"build":"tsc && tsc -p tsconfig.esm.json","dev":"tsc --watch","test":"vitest run","test:watch":"vitest"},"keywords":["apex","openfeature","feature-flags","experiments","ab-testing"],"license":"MIT","publishConfig":{"access":"public"},"engines":{"node":">=18"},"dependencies":{"@openfeature/server-sdk":"^1.22.0"},"devDependencies":{"typescript":"^5.7.0","vitest":"^3.2.4"},"_id":"@apex-inc/openfeature@0.1.0","gitHead":"22f12795c8fe02f2b13678b78448bc0c664c4566","_nodeVersion":"23.11.0","_npmVersion":"10.9.2","dist":{"integrity":"sha512-+BxsYDZDTy2M8GMkOhz94lifhqonIiACmphGcKzLG1idzhf2sEbIPtaJ0NIkerGp3aGV1N5T7Nn9rStP4T1uxQ==","shasum":"aeb852444610de63617dcca0c8d97c9d3ae8ac7f","tarball":"https://registry.npmjs.org/@apex-inc/openfeature/-/openfeature-0.1.0.tgz","fileCount":12,"unpackedSize":26078,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCID0qH73NIODrgc4UpjVZhU5XMrvtB2YkSjFVxZxoctJkAiEAyALqqH6C6bVAzhN6OIpFxqewqvq3YquawaYhrwy2VkE="}]},"_npmUser":{"name":"apex.inc","email":"chris@apex.inc"},"directories":{},"maintainers":[{"name":"apex.inc","email":"chris@apex.inc"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/openfeature_0.1.0_1781544247153_0.06230649880919503"},"_hasShrinkwrap":false}},"time":{"created":"2026-06-15T17:24:06.971Z","0.1.0":"2026-06-15T17:24:07.315Z","modified":"2026-06-15T17:24:07.518Z"},"maintainers":[{"name":"apex.inc","email":"chris@apex.inc"}],"description":"OpenFeature server provider for Apex experiments. A thin adapter over Apex's authoritative assignment endpoint — read Apex experiment assignments through the standard OpenFeature interface.","keywords":["apex","openfeature","feature-flags","experiments","ab-testing"],"license":"MIT","readme":"# @apex-inc/openfeature\n\nAn [OpenFeature](https://openfeature.dev) **server** provider for [Apex](https://apex.inc) experiments.\n\nIt's a thin adapter: teams already using OpenFeature can read Apex experiment\nassignments through the standard interface. The flag key is the Apex\n`experimentId`, and the OpenFeature `targetingKey` is the stable visitor/user\nid used for deterministic assignment.\n\n## Install\n\n```bash\nnpm install @apex-inc/openfeature @openfeature/server-sdk\n```\n\n## Usage\n\n```ts\nimport { OpenFeature } from \"@openfeature/server-sdk\";\nimport { createApexProvider } from \"@apex-inc/openfeature\";\n\nOpenFeature.setProvider(createApexProvider({ workspaceKey, apiKey }));\nconst client = OpenFeature.getClient();\n\n// flag key === experimentId, targetingKey === stable visitor/user id\nconst variant = await client.getStringValue(experimentId, \"control\", { targetingKey: userId });\n```\n\n`getBooleanValue` treats the `variant_b` arm as \"on\"; `getObjectValue` returns\nthe variant's unified assign payload.\n\n## Source of truth\n\nApex's `GET /api/experiments/{experimentId}/assign` endpoint remains\nauthoritative — this provider does not re-implement bucketing or delegate the\ndecision to a generic flag engine; it forwards the assignment Apex picked.\n","readmeFilename":"README.md","_rev":"1-1cb9c5cd401966c6dff2c7aefef75b64"}