{"_id":"@reflag/node-sdk","_rev":"26-c4a2318778a27ff619f331eac9ffa849","name":"@reflag/node-sdk","dist-tags":{"latest":"1.8.1"},"versions":{"1.0.0-alpha.1":{"name":"@reflag/node-sdk","version":"1.0.0-alpha.1","license":"MIT","_id":"@reflag/node-sdk@1.0.0-alpha.1","maintainers":[{"name":"roncohen1","email":"cohen1+1@gmail.com"},{"name":"pavkam","email":"alex+git@ciobanu.org"},{"name":"makwarth","email":"makwarth@gmail.com"}],"homepage":"https://github.com/reflagcom/javascript#readme","bugs":{"url":"https://github.com/reflagcom/javascript/issues"},"dist":{"shasum":"cc21dad2bb9ffed578c4be1759c8d6a8b78c60f7","tarball":"https://registry.npmjs.org/@reflag/node-sdk/-/node-sdk-1.0.0-alpha.1.tgz","fileCount":57,"integrity":"sha512-v2HlEtdPrCpBf3KFf4ZLCfjxkOQo4E14lG7+DqPwDyvGa666T1tbcUvpHOuNQICcIlS+TDFZwEVtVbHAj3hTHQ==","signatures":[{"sig":"MEUCIGsqPUW8+CjKAYt1/T1N2+GICzWJbV4JpqK8pqJBWZ41AiEAlpNX032ncS788yKMHjwzZ1yUrHhJvG1ZBA2CLRdgpmY=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":230324},"main":"./dist/src/index.js","types":"./dist/types/src/index.d.ts","gitHead":"d70378c8d717b140cfbaf5f05ec018d60fc26724","scripts":{"dev":"vite","lint":"eslint .","test":"vitest -c vite.config.js","build":"tsc --project tsconfig.build.json","start":"vite","format":"yarn lint --fix && yarn prettier --write","lint:ci":"eslint --output-file eslint-report.json --format json .","test:ci":"vitest run -c vite.config.js --reporter=default --reporter=junit --outputFile=junit.xml","coverage":"vitest run --coverage","prettier":"prettier --check .","preversion":"yarn lint && yarn prettier && yarn vitest run -c vite.config.js && yarn build"},"_npmUser":{"name":"pavkam","email":"alex+git@ciobanu.org"},"repository":{"url":"git+https://github.com/reflagcom/javascript.git","type":"git"},"_npmVersion":"lerna/8.1.3/node@v20.15.1+arm64 (darwin)","description":"Node.js, JavaScript/TypeScript client for [Reflag.com](https://reflag.com).","directories":{},"_nodeVersion":"20.15.1","dependencies":{"@reflag/flag-evaluation":"1.0.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"c8":"~10.1.0","vite":"~5.4.18","eslint":"^9.21.0","vitest":"~1.6.0","ts-node":"~10.9.2","prettier":"^3.5.2","typescript":"^5.7.3","@babel/core":"~7.24.7","@types/node":"^22.12.0","flush-promises":"~1.0.2","vite-plugin-dts":"~3.9.1","@reflag/tsconfig":"~0.0.2","@vitest/coverage-v8":"~1.6.0","@reflag/eslint-config":"~0.0.2"},"_npmOperationalInternal":{"tmp":"tmp/node-sdk_1.0.0-alpha.1_1756796002015_0.39643381656158194","host":"s3://npm-registry-packages-npm-production"}},"1.0.0-alpha.2":{"name":"@reflag/node-sdk","version":"1.0.0-alpha.2","license":"MIT","_id":"@reflag/node-sdk@1.0.0-alpha.2","maintainers":[{"name":"roncohen1","email":"cohen1+1@gmail.com"},{"name":"pavkam","email":"alex+git@ciobanu.org"},{"name":"makwarth","email":"makwarth@gmail.com"}],"homepage":"https://github.com/reflagcom/javascript#readme","bugs":{"url":"https://github.com/reflagcom/javascript/issues"},"dist":{"shasum":"2d2ab46afa7edb2bab6c1213a212d6a7ac82a3d5","tarball":"https://registry.npmjs.org/@reflag/node-sdk/-/node-sdk-1.0.0-alpha.2.tgz","fileCount":57,"integrity":"sha512-xJrHAfL5KkcxHruUTtESOozu9zbEp2X/vVXE8I2DOMDpDwJesUwVdaPVKixw1Y3lZUVB1hfBbnhAjaWMd/k0vQ==","signatures":[{"sig":"MEYCIQD30vI+JiGjKTyuoDhATz9Uxg/Tjbau6C5laeBJtWV0SAIhAMNfUmd8Mnu8rpwntQ2rCmYnu3h5u1rl38pU6ZWQMqzY","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":230332},"main":"./dist/src/index.js","types":"./dist/types/src/index.d.ts","gitHead":"f0284ab26ecc354cfb9e81e7bfd922d6f969b6bc","scripts":{"dev":"vite","lint":"eslint .","test":"vitest -c vite.config.js","build":"tsc --project tsconfig.build.json","start":"vite","format":"yarn lint --fix && yarn prettier --write","lint:ci":"eslint --output-file eslint-report.json --format json .","test:ci":"vitest run -c vite.config.js --reporter=default --reporter=junit --outputFile=junit.xml","coverage":"vitest run --coverage","prettier":"prettier --check .","preversion":"yarn lint && yarn prettier && yarn vitest run -c vite.config.js && yarn build"},"_npmUser":{"name":"pavkam","email":"alex+git@ciobanu.org"},"repository":{"url":"git+https://github.com/reflagcom/javascript.git","type":"git"},"_npmVersion":"lerna/8.1.3/node@v20.15.1+arm64 (darwin)","description":"Node.js, JavaScript/TypeScript client for [Reflag.com](https://reflag.com).","directories":{},"_nodeVersion":"20.15.1","dependencies":{"@reflag/flag-evaluation":"1.0.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"c8":"~10.1.0","vite":"~5.4.18","eslint":"^9.21.0","vitest":"~1.6.0","ts-node":"~10.9.2","prettier":"^3.5.2","typescript":"^5.7.3","@babel/core":"~7.24.7","@types/node":"^22.12.0","flush-promises":"~1.0.2","vite-plugin-dts":"~3.9.1","@reflag/tsconfig":"~0.0.2","@vitest/coverage-v8":"~1.6.0","@reflag/eslint-config":"~0.0.2"},"_npmOperationalInternal":{"tmp":"tmp/node-sdk_1.0.0-alpha.2_1756805086832_0.37418868656778814","host":"s3://npm-registry-packages-npm-production"}},"1.0.0-alpha.3":{"name":"@reflag/node-sdk","version":"1.0.0-alpha.3","license":"MIT","_id":"@reflag/node-sdk@1.0.0-alpha.3","maintainers":[{"name":"roncohen1","email":"cohen1+1@gmail.com"},{"name":"pavkam","email":"alex+git@ciobanu.org"},{"name":"makwarth","email":"makwarth@gmail.com"}],"homepage":"https://github.com/reflagcom/javascript#readme","bugs":{"url":"https://github.com/reflagcom/javascript/issues"},"dist":{"shasum":"f439c711ab84102b0881db97cd8a785a024515c5","tarball":"https://registry.npmjs.org/@reflag/node-sdk/-/node-sdk-1.0.0-alpha.3.tgz","fileCount":57,"integrity":"sha512-jebZN9dsfLJyAW90/6AYsTe03kX0Khsi4SEk4ZlKLqExR4JsTnNuyaKPg98hF6B9ZT47KwvTcOu7CX+cysDDJw==","signatures":[{"sig":"MEYCIQDmo+/tbz4pEixDI5v8giXyLMPczhxyWtJOSk+CWR5puQIhAIvnQ/8R4MJTiYLOLZIsNfzeoYSEDMIywNaEtGDjuKCC","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":231363},"main":"./dist/src/index.js","types":"./dist/types/src/index.d.ts","gitHead":"d82ab8460d83e490b4e6fd2a20897305445c7f06","scripts":{"dev":"vite","lint":"eslint .","test":"vitest -c vite.config.js","build":"tsc --project tsconfig.build.json","start":"vite","format":"yarn lint --fix && yarn prettier --write","lint:ci":"eslint --output-file eslint-report.json --format json .","test:ci":"vitest run -c vite.config.js --reporter=default --reporter=junit --outputFile=junit.xml","coverage":"vitest run --coverage","prettier":"prettier --check .","preversion":"yarn lint && yarn prettier && yarn vitest run -c vite.config.js && yarn build"},"_npmUser":{"name":"pavkam","email":"alex+git@ciobanu.org"},"repository":{"url":"git+https://github.com/reflagcom/javascript.git","type":"git"},"_npmVersion":"lerna/8.1.3/node@v20.15.1+arm64 (darwin)","description":"Node.js, JavaScript/TypeScript client for [Reflag.com](https://reflag.com).","directories":{},"_nodeVersion":"20.15.1","dependencies":{"@reflag/flag-evaluation":"1.0.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"c8":"~10.1.0","vite":"~5.4.18","eslint":"^9.21.0","vitest":"~1.6.0","ts-node":"~10.9.2","prettier":"^3.5.2","typescript":"^5.7.3","@babel/core":"~7.24.7","@types/node":"^22.12.0","flush-promises":"~1.0.2","vite-plugin-dts":"~3.9.1","@reflag/tsconfig":"~0.0.2","@vitest/coverage-v8":"~1.6.0","@reflag/eslint-config":"~0.0.2"},"_npmOperationalInternal":{"tmp":"tmp/node-sdk_1.0.0-alpha.3_1756813087740_0.11266225218452375","host":"s3://npm-registry-packages-npm-production"}},"1.0.0":{"name":"@reflag/node-sdk","version":"1.0.0","license":"MIT","_id":"@reflag/node-sdk@1.0.0","maintainers":[{"name":"roncohen1","email":"cohen1+1@gmail.com"},{"name":"pavkam","email":"alex+git@ciobanu.org"},{"name":"makwarth","email":"makwarth@gmail.com"}],"homepage":"https://github.com/reflagcom/javascript#readme","bugs":{"url":"https://github.com/reflagcom/javascript/issues"},"dist":{"shasum":"334d7733b5d6866889ebc30a330877dec77120b5","tarball":"https://registry.npmjs.org/@reflag/node-sdk/-/node-sdk-1.0.0.tgz","fileCount":57,"integrity":"sha512-eb/Q8f32ZDqhns/dskEC7/A7DhJSI5iVHjV3aGhAs5Lz4qSqHyOJmk1Nd5t/jn2DB7f05JnyCQ2PGP/gPSf32g==","signatures":[{"sig":"MEUCIQDRR1Uu8IKqkmATKzq477NkdlEJNPryBFk0s8Ro9Vc2wgIgdRP7Qhzz5xULGc6OTCICjpYJwwCANQApg32z5CjWgyk=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":231347},"main":"./dist/src/index.js","types":"./dist/types/src/index.d.ts","gitHead":"bcd6258c6b7394b76dbf60f48dd63f0cad5cc231","scripts":{"dev":"vite","lint":"eslint .","test":"vitest -c vite.config.js","build":"tsc --project tsconfig.build.json","start":"vite","format":"yarn lint --fix && yarn prettier --write","lint:ci":"eslint --output-file eslint-report.json --format json .","test:ci":"vitest run -c vite.config.js --reporter=default --reporter=junit --outputFile=junit.xml","coverage":"vitest run --coverage","prettier":"prettier --check .","preversion":"yarn lint && yarn prettier && yarn vitest run -c vite.config.js && yarn build"},"_npmUser":{"name":"pavkam","email":"alex+git@ciobanu.org"},"repository":{"url":"git+https://github.com/reflagcom/javascript.git","type":"git"},"_npmVersion":"lerna/8.1.3/node@v20.15.1+arm64 (darwin)","description":"Node.js, JavaScript/TypeScript client for [Reflag.com](https://reflag.com).","directories":{},"_nodeVersion":"20.15.1","dependencies":{"@reflag/flag-evaluation":"1.0.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"c8":"~10.1.0","vite":"~5.4.18","eslint":"^9.21.0","vitest":"~1.6.0","ts-node":"~10.9.2","prettier":"^3.5.2","typescript":"^5.7.3","@babel/core":"~7.24.7","@types/node":"^22.12.0","flush-promises":"~1.0.2","vite-plugin-dts":"~3.9.1","@reflag/tsconfig":"~0.0.2","@vitest/coverage-v8":"~1.6.0","@reflag/eslint-config":"~0.0.2"},"_npmOperationalInternal":{"tmp":"tmp/node-sdk_1.0.0_1756846724368_0.8777340745012718","host":"s3://npm-registry-packages-npm-production"}},"1.0.1":{"name":"@reflag/node-sdk","version":"1.0.1","license":"MIT","_id":"@reflag/node-sdk@1.0.1","maintainers":[{"name":"roncohen1","email":"cohen1+1@gmail.com"},{"name":"pavkam","email":"alex+git@ciobanu.org"},{"name":"makwarth","email":"makwarth@gmail.com"}],"homepage":"https://github.com/reflagcom/javascript#readme","bugs":{"url":"https://github.com/reflagcom/javascript/issues"},"dist":{"shasum":"b48165d40a82d9c0dc071b46e39bae16176252d3","tarball":"https://registry.npmjs.org/@reflag/node-sdk/-/node-sdk-1.0.1.tgz","fileCount":53,"integrity":"sha512-UUmxjspx3hExHDzmtBrZux9fDP44SQok9sQawM+OV0zvJzPyR9b6g3UuK/vNnr+RPMgKoaBvlPeU4kEB70Gt1A==","signatures":[{"sig":"MEUCIQCrCVS6Lhmynmoc3EGarxY8DHSH2pKVsi9JMC4TpOyEqAIgMDkWgQXXOn018lwU8rwEA4wk8+n6swjPHeAkyJTg604=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":222128},"main":"./dist/src/index.js","types":"./dist/types/src/index.d.ts","gitHead":"e5fff593ec44d0b1ed75afa6994a648ca5c71174","scripts":{"dev":"vite","lint":"eslint .","test":"vitest -c vite.config.js","build":"tsc --project tsconfig.build.json","start":"vite","format":"yarn lint --fix && yarn prettier --write","lint:ci":"eslint --output-file eslint-report.json --format json .","test:ci":"vitest run -c vite.config.js --reporter=default --reporter=junit --outputFile=junit.xml","coverage":"vitest run --coverage","prettier":"prettier --check .","preversion":"yarn lint && yarn prettier && yarn vitest run -c vite.config.js && yarn build"},"_npmUser":{"name":"pavkam","email":"alex+git@ciobanu.org"},"repository":{"url":"git+https://github.com/reflagcom/javascript.git","type":"git"},"_npmVersion":"lerna/8.1.3/node@v20.15.1+x64 (linux)","description":"Node.js, JavaScript/TypeScript client for [Reflag.com](https://reflag.com).","directories":{},"_nodeVersion":"20.15.1","dependencies":{"@reflag/flag-evaluation":"1.0.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"c8":"~10.1.0","vite":"~5.4.18","eslint":"^9.21.0","vitest":"~1.6.0","ts-node":"~10.9.2","prettier":"^3.5.2","typescript":"^5.7.3","@babel/core":"~7.24.7","@types/node":"^22.12.0","flush-promises":"~1.0.2","vite-plugin-dts":"~3.9.1","@reflag/tsconfig":"~0.0.2","@vitest/coverage-v8":"~1.6.0","@reflag/eslint-config":"~0.0.2"},"_npmOperationalInternal":{"tmp":"tmp/node-sdk_1.0.1_1757512326107_0.8761181834880951","host":"s3://npm-registry-packages-npm-production"}},"1.1.0":{"name":"@reflag/node-sdk","version":"1.1.0","license":"MIT","_id":"@reflag/node-sdk@1.1.0","maintainers":[{"name":"roncohen1","email":"cohen1+1@gmail.com"},{"name":"pavkam","email":"alex+git@ciobanu.org"},{"name":"makwarth","email":"makwarth@gmail.com"}],"homepage":"https://github.com/reflagcom/javascript#readme","bugs":{"url":"https://github.com/reflagcom/javascript/issues"},"dist":{"shasum":"1b429876237d12ac8fc757cbd8098767c4de3086","tarball":"https://registry.npmjs.org/@reflag/node-sdk/-/node-sdk-1.1.0.tgz","fileCount":53,"integrity":"sha512-rletIqNjeAdL6h745bunxj+mFKZHXNgIgzZ86XMwoD1i5kkuqZt+AIHsxwRjVzqJq9AcW0j/cdR3d5Xqq0EMbw==","signatures":[{"sig":"MEQCIFN0TYKzxqKEAKFYVzWI8diStrGRE/f6pZP/g9yqyvS8AiAHrtIWymal02dT6Zb1D59TQ6sENsDLHcruJlSZn3zbRw==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":230717},"main":"./dist/src/index.js","types":"./dist/types/src/index.d.ts","gitHead":"445631de206a512db2793547ac451b75e3a9ee6a","scripts":{"dev":"vite","lint":"eslint .","test":"vitest run","build":"tsc --project tsconfig.build.json","start":"vite","format":"yarn lint --fix && yarn prettier --write","lint:ci":"eslint --output-file eslint-report.json --format json .","test:ci":"yarn test --reporter=default --reporter=junit --outputFile=junit.xml","coverage":"yarn test --coverage","prettier":"prettier --check .","preversion":"yarn lint && yarn prettier && yarn test && yarn build","test:watch":"vitest"},"_npmUser":{"name":"pavkam","email":"alex+git@ciobanu.org"},"repository":{"url":"git+https://github.com/reflagcom/javascript.git","type":"git"},"_npmVersion":"lerna/8.1.3/node@v20.15.1+x64 (linux)","description":"Node.js, JavaScript/TypeScript client for [Reflag.com](https://reflag.com).","directories":{},"_nodeVersion":"20.15.1","dependencies":{"@reflag/flag-evaluation":"1.0.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"c8":"~10.1.0","vite":"~5.4.18","eslint":"^9.21.0","vitest":"~1.6.0","ts-node":"~10.9.2","prettier":"^3.5.2","typescript":"^5.7.3","@babel/core":"~7.24.7","@types/node":"^22.12.0","flush-promises":"~1.0.2","vite-plugin-dts":"~3.9.1","@reflag/tsconfig":"~0.0.2","@vitest/coverage-v8":"~1.6.0","@reflag/eslint-config":"~0.0.2"},"_npmOperationalInternal":{"tmp":"tmp/node-sdk_1.1.0_1759390817807_0.9564763030863617","host":"s3://npm-registry-packages-npm-production"}},"1.2.0":{"name":"@reflag/node-sdk","version":"1.2.0","license":"MIT","_id":"@reflag/node-sdk@1.2.0","maintainers":[{"name":"roncohen1","email":"cohen1+1@gmail.com"}],"homepage":"https://github.com/reflagcom/javascript#readme","bugs":{"url":"https://github.com/reflagcom/javascript/issues"},"dist":{"shasum":"9f4f67babe9a6e5565fff8a235e40b176b85f08d","tarball":"https://registry.npmjs.org/@reflag/node-sdk/-/node-sdk-1.2.0.tgz","fileCount":51,"integrity":"sha512-Nb+ZC56jYOB8ovQaRMuorKMIb5NDVqt7fljmoTMVeOG0JNhJwsPOifzA2GAsvcawklk50E1qYeVBag6Xarqzvw==","signatures":[{"sig":"MEUCIHsmSCMvf+tMquk7P0uehB4ZlWv77Q9kGjMzkx2kxrqEAiEA/Jq00dUEiCGZWba21PB585DoVjjOEG8WHTNmKMxTENU=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@reflag%2fnode-sdk@1.2.0","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":230609},"main":"./dist/src/index.js","types":"./dist/types/src/index.d.ts","gitHead":"f10aab94a09f5e73daf379b786d7f1b6f15fe799","scripts":{"dev":"vite","lint":"eslint .","test":"vitest run","build":"tsc --project tsconfig.build.json","start":"vite","format":"yarn lint --fix && yarn prettier --write","lint:ci":"eslint --output-file eslint-report.json --format json .","test:ci":"yarn test --reporter=default --reporter=junit --outputFile=junit.xml","coverage":"yarn test --coverage","prettier":"prettier --check .","preversion":"yarn lint && yarn prettier && yarn test && yarn build","test:watch":"vitest"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:db682705-3e50-4045-b2c3-1cc375631f25"}},"repository":{"url":"git+https://github.com/reflagcom/javascript.git","type":"git"},"_npmVersion":"11.6.2","description":"Node.js, JavaScript/TypeScript client for [Reflag.com](https://reflag.com).","directories":{},"_nodeVersion":"24.13.0","dependencies":{"@reflag/flag-evaluation":"1.0.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"c8":"~10.1.0","vite":"~5.4.18","eslint":"^9.21.0","vitest":"~1.6.0","ts-node":"~10.9.2","prettier":"^3.5.2","typescript":"^5.7.3","@babel/core":"~7.24.7","@types/node":"^22.12.0","flush-promises":"~1.0.2","vite-plugin-dts":"~3.9.1","@reflag/tsconfig":"~0.0.2","@vitest/coverage-v8":"~1.6.0","@reflag/eslint-config":"~0.0.2"},"_npmOperationalInternal":{"tmp":"tmp/node-sdk_1.2.0_1771964968077_0.4208397654891076","host":"s3://npm-registry-packages-npm-production"}},"1.3.0":{"name":"@reflag/node-sdk","version":"1.3.0","license":"MIT","_id":"@reflag/node-sdk@1.3.0","maintainers":[{"name":"roncohen1","email":"cohen1+1@gmail.com"}],"homepage":"https://github.com/reflagcom/javascript#readme","bugs":{"url":"https://github.com/reflagcom/javascript/issues"},"dist":{"shasum":"cf9eb11b42dd6de90312846fa2614a09823de2f0","tarball":"https://registry.npmjs.org/@reflag/node-sdk/-/node-sdk-1.3.0.tgz","fileCount":51,"integrity":"sha512-o0mBYj31fb8ELmUckv6fKu2Ck/0yP6XqSIxDfOCCD8DYPL+Jb66N857cn1iOYlrGOg8aUCas64vkk3mM+0eMzw==","signatures":[{"sig":"MEUCIQDuSO+7YSG6sBoZhl7RqgQ7y12Xg9mJr4lyHExKyLM9AQIgDqHk/vzjNSPldGIDlFdXbZWZdsu4aT8jVWqbcOweZTU=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@reflag%2fnode-sdk@1.3.0","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":237376},"main":"./dist/src/index.js","types":"./dist/types/src/index.d.ts","gitHead":"21bb469f7b884ce6a0f9dc838ef13452629863f4","scripts":{"dev":"vite","lint":"eslint .","test":"vitest run","build":"tsc --project tsconfig.build.json","start":"vite","format":"yarn lint --fix && yarn prettier --write","lint:ci":"eslint --output-file eslint-report.json --format json .","test:ci":"yarn test --reporter=default --reporter=junit --outputFile=junit.xml","coverage":"yarn test --coverage","prettier":"prettier --check .","preversion":"yarn lint && yarn prettier && yarn test && yarn build","test:watch":"vitest"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:db682705-3e50-4045-b2c3-1cc375631f25"}},"repository":{"url":"git+https://github.com/reflagcom/javascript.git","type":"git"},"_npmVersion":"11.6.2","description":"Node.js, JavaScript/TypeScript client for [Reflag.com](https://reflag.com).","directories":{},"_nodeVersion":"24.13.0","dependencies":{"@reflag/flag-evaluation":"1.0.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"c8":"~10.1.0","vite":"~5.4.18","eslint":"^9.21.0","vitest":"~1.6.0","ts-node":"~10.9.2","prettier":"^3.5.2","typescript":"^5.7.3","@babel/core":"~7.24.7","@types/node":"^22.12.0","flush-promises":"~1.0.2","vite-plugin-dts":"~3.9.1","@reflag/tsconfig":"~0.0.2","@vitest/coverage-v8":"~1.6.0","@reflag/eslint-config":"~0.0.2"},"_npmOperationalInternal":{"tmp":"tmp/node-sdk_1.3.0_1773434501377_0.8314913365106631","host":"s3://npm-registry-packages-npm-production"}},"1.4.0":{"name":"@reflag/node-sdk","version":"1.4.0","license":"MIT","_id":"@reflag/node-sdk@1.4.0","maintainers":[{"name":"roncohen1","email":"cohen1+1@gmail.com"}],"homepage":"https://github.com/reflagcom/javascript#readme","bugs":{"url":"https://github.com/reflagcom/javascript/issues"},"dist":{"shasum":"a8b476dd46c786015f882d3c74d2fdd69138d4cd","tarball":"https://registry.npmjs.org/@reflag/node-sdk/-/node-sdk-1.4.0.tgz","fileCount":55,"integrity":"sha512-sCxrrbnUXiGGxfWqVd7kxKhnAN9/V3BCwHpdSavL7IPw4BpZjYDXxYzNSIFxzlJDTPaF3M2100fBHTJ4xwMUkg==","signatures":[{"sig":"MEQCIGeOAwyZ+mQiTaHQzaa+ZJ8xIb9YeSqD7KcAoud540DRAiBXWsRC1zs3snV+vEJKJHtronWQvS4xWWafoHGxIl0BVQ==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@reflag%2fnode-sdk@1.4.0","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":278244},"main":"./dist/src/index.js","types":"./dist/types/src/index.d.ts","gitHead":"19df533e5c81280d53f251e3d213cd9829ff4d61","scripts":{"dev":"vite","lint":"eslint .","test":"vitest run","build":"tsc --project tsconfig.build.json","start":"vite","format":"yarn lint --fix && yarn prettier --write","lint:ci":"eslint --output-file eslint-report.json --format json .","test:ci":"yarn test --reporter=default --reporter=junit --outputFile=junit.xml","coverage":"yarn test --coverage","prettier":"prettier --check .","preversion":"yarn lint && yarn prettier && yarn test && yarn build","test:watch":"vitest"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:db682705-3e50-4045-b2c3-1cc375631f25"}},"repository":{"url":"git+https://github.com/reflagcom/javascript.git","type":"git"},"_npmVersion":"11.6.2","description":"Node.js, JavaScript/TypeScript client for [Reflag.com](https://reflag.com).","directories":{},"_nodeVersion":"24.13.0","dependencies":{"@redis/client":"^5.11.0","@aws-sdk/client-s3":"^3.888.0","@google-cloud/storage":"^7.19.0","@reflag/flag-evaluation":"1.0.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"c8":"~10.1.0","vite":"~5.4.18","eslint":"^9.21.0","vitest":"~1.6.0","ts-node":"~10.9.2","prettier":"^3.5.2","typescript":"^5.7.3","@babel/core":"~7.24.7","@types/node":"^22.12.0","flush-promises":"~1.0.2","vite-plugin-dts":"~3.9.1","@reflag/tsconfig":"~0.0.2","@vitest/coverage-v8":"~1.6.0","@reflag/eslint-config":"~0.0.2"},"_npmOperationalInternal":{"tmp":"tmp/node-sdk_1.4.0_1773915497224_0.2803889118102154","host":"s3://npm-registry-packages-npm-production"}},"1.4.1":{"name":"@reflag/node-sdk","version":"1.4.1","license":"MIT","_id":"@reflag/node-sdk@1.4.1","maintainers":[{"name":"roncohen1","email":"cohen1+1@gmail.com"}],"homepage":"https://github.com/reflagcom/javascript#readme","bugs":{"url":"https://github.com/reflagcom/javascript/issues"},"dist":{"shasum":"b0beb177e55174860e2daa1867c8ade51ec7c0ed","tarball":"https://registry.npmjs.org/@reflag/node-sdk/-/node-sdk-1.4.1.tgz","fileCount":55,"integrity":"sha512-twflpYESb/xgv9WCMt5M3Dkh2b/ZxLWCgbGGTgDYUHu0QS86iwVnQrmbC89Wt7HA4fkPCQNndyoY3cGkox9/XQ==","signatures":[{"sig":"MEUCIQCs9mC/XkrbDybLkB10lsNur/No6ALSvxXnmawpKr5BcAIgfWHFr7v3RMUxV+qF/EaNjplSXblAoyGbR+MB24ZJag8=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@reflag%2fnode-sdk@1.4.1","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":279449},"main":"./dist/src/index.js","types":"./dist/types/src/index.d.ts","gitHead":"8c4c5467041e1c75e66123af8aa1aefe2963e153","scripts":{"dev":"vite","lint":"eslint .","test":"vitest run","build":"tsc --project tsconfig.build.json","start":"vite","format":"yarn lint --fix && yarn prettier --write","lint:ci":"eslint --output-file eslint-report.json --format json .","test:ci":"yarn test --reporter=default --reporter=junit --outputFile=junit.xml","coverage":"yarn test --coverage","prettier":"prettier --check .","preversion":"yarn lint && yarn prettier && yarn test && yarn build","test:watch":"vitest"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:db682705-3e50-4045-b2c3-1cc375631f25"}},"repository":{"url":"git+https://github.com/reflagcom/javascript.git","type":"git"},"_npmVersion":"11.6.2","description":"Node.js, JavaScript/TypeScript client for [Reflag.com](https://reflag.com).","directories":{},"_nodeVersion":"24.13.0","dependencies":{"@redis/client":"^5.11.0","@aws-sdk/client-s3":"^3.888.0","@google-cloud/storage":"^7.19.0","@reflag/flag-evaluation":"1.0.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"c8":"~10.1.0","vite":"~5.4.18","eslint":"^9.21.0","vitest":"~1.6.0","ts-node":"~10.9.2","prettier":"^3.5.2","typescript":"^5.7.3","@babel/core":"~7.24.7","@types/node":"^22.12.0","flush-promises":"~1.0.2","vite-plugin-dts":"~3.9.1","@reflag/tsconfig":"~0.0.2","@vitest/coverage-v8":"~1.6.0","@reflag/eslint-config":"~0.0.2"},"_npmOperationalInternal":{"tmp":"tmp/node-sdk_1.4.1_1774032410240_0.8551282408890504","host":"s3://npm-registry-packages-npm-production"}},"1.4.2":{"name":"@reflag/node-sdk","version":"1.4.2","license":"MIT","_id":"@reflag/node-sdk@1.4.2","maintainers":[{"name":"roncohen1","email":"cohen1+1@gmail.com"}],"homepage":"https://github.com/reflagcom/javascript#readme","bugs":{"url":"https://github.com/reflagcom/javascript/issues"},"dist":{"shasum":"91d8f027bd2b7700f02b0a8a21c29f7e35369c2b","tarball":"https://registry.npmjs.org/@reflag/node-sdk/-/node-sdk-1.4.2.tgz","fileCount":55,"integrity":"sha512-xp45V8EyIDslJpqkwooIKqdhycwzMbljibAsGdn6x6CQZwvs9hV9yj56CiI0BE+Ex+8fAajd+lL3HgTK0D9RkQ==","signatures":[{"sig":"MEYCIQC9US3+QWKzc10pvQtENJZzs0lyQ+rL54gTW2pqRUKEAwIhAIvi0hnGSzJ3qJSBkvbhbIOPsH+wc/eeuT/pVkb19Ro2","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@reflag%2fnode-sdk@1.4.2","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":279593},"main":"./dist/src/index.js","types":"./dist/types/src/index.d.ts","gitHead":"fdce8b92665030d57d0ce41fbc4297b67b19becb","scripts":{"dev":"vite","lint":"eslint .","test":"vitest run","build":"tsc --project tsconfig.build.json","start":"vite","format":"yarn lint --fix && yarn prettier --write","lint:ci":"eslint --output-file eslint-report.json --format json .","test:ci":"yarn test --reporter=default --reporter=junit --outputFile=junit.xml","coverage":"yarn test --coverage","prettier":"prettier --check .","preversion":"yarn lint && yarn prettier && yarn test && yarn build","test:watch":"vitest"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:db682705-3e50-4045-b2c3-1cc375631f25"}},"repository":{"url":"git+https://github.com/reflagcom/javascript.git","type":"git"},"_npmVersion":"11.6.2","description":"Node.js, JavaScript/TypeScript client for [Reflag.com](https://reflag.com).","directories":{},"_nodeVersion":"24.13.0","dependencies":{"@redis/client":"^5.11.0","@aws-sdk/client-s3":"^3.888.0","@google-cloud/storage":"^7.19.0","@reflag/flag-evaluation":"1.0.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"c8":"~10.1.0","vite":"~5.4.18","eslint":"^9.21.0","vitest":"~1.6.0","ts-node":"~10.9.2","prettier":"^3.5.2","typescript":"^5.7.3","@babel/core":"~7.24.7","@types/node":"^22.12.0","flush-promises":"~1.0.2","vite-plugin-dts":"~3.9.1","@reflag/tsconfig":"~0.0.2","@vitest/coverage-v8":"~1.6.0","@reflag/eslint-config":"~0.0.2"},"_npmOperationalInternal":{"tmp":"tmp/node-sdk_1.4.2_1774642156491_0.4754544930086957","host":"s3://npm-registry-packages-npm-production"}},"1.5.0":{"name":"@reflag/node-sdk","version":"1.5.0","license":"MIT","_id":"@reflag/node-sdk@1.5.0","maintainers":[{"name":"roncohen1","email":"cohen1+1@gmail.com"}],"homepage":"https://github.com/reflagcom/javascript#readme","bugs":{"url":"https://github.com/reflagcom/javascript/issues"},"dist":{"shasum":"fbdfc0e0eff961c2f2b39ed684b6ece653753080","tarball":"https://registry.npmjs.org/@reflag/node-sdk/-/node-sdk-1.5.0.tgz","fileCount":59,"integrity":"sha512-ICbWPl9E5CVPOHVdYHtiinSTEf5LSfXtgTm6MzfFUpGOn3Rg6ta3Liu6AO2O9l4U03/KmJs+K07644g87yDXug==","signatures":[{"sig":"MEUCIQCjqvjcNjlZ7jX1zW5aLkuGm++dbYTo5Va5SPRWy+lAdAIgUaxSobHsy/7lhvjHUfOm78eKDQthcO7CzDiIXNYSIfI=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@reflag%2fnode-sdk@1.5.0","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":318740},"main":"./dist/src/index.js","types":"./dist/types/src/index.d.ts","gitHead":"1a6c8fb60290d3f1c4db0fcbce68f99e11033bfd","scripts":{"dev":"vite","lint":"eslint .","test":"vitest run","build":"tsc --project tsconfig.build.json","start":"vite","format":"yarn lint --fix && yarn prettier --write","lint:ci":"eslint --output-file eslint-report.json --format json .","test:ci":"yarn test --reporter=default --reporter=junit --outputFile=junit.xml","coverage":"yarn test --coverage","prettier":"prettier --check .","preversion":"yarn lint && yarn prettier && yarn test && yarn build","test:watch":"vitest"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:db682705-3e50-4045-b2c3-1cc375631f25"}},"repository":{"url":"git+https://github.com/reflagcom/javascript.git","type":"git"},"_npmVersion":"11.6.2","description":"Node.js, JavaScript/TypeScript client for [Reflag.com](https://reflag.com).","directories":{},"_nodeVersion":"24.13.0","dependencies":{"@redis/client":"^5.11.0","@aws-sdk/client-s3":"^3.888.0","@google-cloud/storage":"^7.19.0","@reflag/flag-evaluation":"1.0.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"c8":"~10.1.0","vite":"~6.4.2","eslint":"^9.21.0","vitest":"~1.6.0","ts-node":"~10.9.2","prettier":"^3.5.2","typescript":"^5.7.3","@babel/core":"~7.24.7","@types/node":"^22.12.0","flush-promises":"~1.0.2","vite-plugin-dts":"~3.9.1","@reflag/tsconfig":"~0.0.2","@vitest/coverage-v8":"~1.6.0","@reflag/eslint-config":"~0.0.2"},"_npmOperationalInternal":{"tmp":"tmp/node-sdk_1.5.0_1775562978370_0.23828188318024268","host":"s3://npm-registry-packages-npm-production"}},"1.5.1":{"name":"@reflag/node-sdk","version":"1.5.1","license":"MIT","_id":"@reflag/node-sdk@1.5.1","maintainers":[{"name":"roncohen1","email":"cohen1+1@gmail.com"}],"homepage":"https://github.com/reflagcom/javascript#readme","bugs":{"url":"https://github.com/reflagcom/javascript/issues"},"dist":{"shasum":"c593051a97003ff70a7962cc31dc8c8983089120","tarball":"https://registry.npmjs.org/@reflag/node-sdk/-/node-sdk-1.5.1.tgz","fileCount":59,"integrity":"sha512-GNVlPEXhZvi1MPHxSjJZJtIoZPmrlkUN2jPF797UGc5VdewoZBLzNFhE/JrUWSkqM1k8u+zh4/5k2LHhOaHwgQ==","signatures":[{"sig":"MEUCIQDgl0Mif4uufcCiJ40FHcog8K92UP4yOdeJSkkkhzOTzAIgeFyVQEI9CvmaeV/DZjY98JqfJ4NpNYfjstFhEkC7XiI=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@reflag%2fnode-sdk@1.5.1","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":326542},"main":"./dist/src/index.js","types":"./dist/types/src/index.d.ts","gitHead":"512c86aff50fb579f73ddf096988d33977b6382a","scripts":{"dev":"vite","fmt":"oxfmt --check .","lint":"oxlint .","test":"vitest run","build":"tsc --project tsconfig.build.json","start":"vite","format":"yarn fmt:fix && yarn lint:fix","fmt:fix":"oxfmt --write .","lint:ci":"oxlint .","test:ci":"yarn test --reporter=default --reporter=junit --outputFile=junit.xml","coverage":"yarn test --coverage","lint:fix":"oxlint --fix .","preversion":"yarn lint && yarn fmt && yarn test && yarn build","test:watch":"vitest"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:db682705-3e50-4045-b2c3-1cc375631f25"}},"repository":{"url":"git+https://github.com/reflagcom/javascript.git","type":"git"},"_npmVersion":"11.6.2","description":"Node.js, JavaScript/TypeScript client for [Reflag.com](https://reflag.com).","directories":{},"_nodeVersion":"24.13.0","dependencies":{"@redis/client":"^5.11.0","@aws-sdk/client-s3":"^3.888.0","@googleapis/storage":"21.2.0","@reflag/flag-evaluation":"1.0.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"c8":"~10.1.0","vite":"~6.4.2","vitest":"~1.6.0","ts-node":"~10.9.2","typescript":"^5.7.3","@babel/core":"~7.24.7","@types/node":"^22.12.0","flush-promises":"~1.0.2","vite-plugin-dts":"~3.9.1","@reflag/tsconfig":"~0.0.2","@vitest/coverage-v8":"~1.6.0"},"_npmOperationalInternal":{"tmp":"tmp/node-sdk_1.5.1_1775637146580_0.31475062309428137","host":"s3://npm-registry-packages-npm-production"}},"1.6.0":{"name":"@reflag/node-sdk","version":"1.6.0","license":"MIT","_id":"@reflag/node-sdk@1.6.0","maintainers":[{"name":"roncohen1","email":"cohen1+1@gmail.com"}],"homepage":"https://github.com/reflagcom/javascript#readme","bugs":{"url":"https://github.com/reflagcom/javascript/issues"},"dist":{"shasum":"68660dd7dbc6028ea15d165172cdc32a6d0462b2","tarball":"https://registry.npmjs.org/@reflag/node-sdk/-/node-sdk-1.6.0.tgz","fileCount":59,"integrity":"sha512-PprKX2WVvrBmDkfAgjhC8AsocdFHoUDgJLU/TEDoHoPo2xWOr2zEd2y6xrjkOgPyVRFzRayBLCcvcmpOpJmalQ==","signatures":[{"sig":"MEQCIBYLi7XGXW1mH2kqAWsrjCh7eCmA52Qcc3gZzHWkeGz1AiBHhG6mKRo6ZXnqfk2O9m9j3otFzlVfZGyX1UmEyYbsbw==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@reflag%2fnode-sdk@1.6.0","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":328204},"main":"./dist/src/index.js","types":"./dist/types/src/index.d.ts","gitHead":"ba2902117cc080acb8c6db4c2994a4b73932438b","scripts":{"dev":"vite","fmt":"oxfmt --check .","lint":"oxlint .","test":"vitest run","build":"tsc --project tsconfig.build.json","start":"vite","format":"yarn fmt:fix && yarn lint:fix","fmt:fix":"oxfmt --write .","lint:ci":"oxlint .","test:ci":"yarn test --reporter=default --reporter=junit --outputFile=junit.xml","coverage":"yarn test --coverage","lint:fix":"oxlint --fix .","preversion":"yarn lint && yarn fmt && yarn test && yarn build","test:watch":"vitest"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:db682705-3e50-4045-b2c3-1cc375631f25"}},"repository":{"url":"git+https://github.com/reflagcom/javascript.git","type":"git"},"_npmVersion":"11.6.2","description":"Node.js, JavaScript/TypeScript client for [Reflag.com](https://reflag.com).","directories":{},"_nodeVersion":"24.13.0","dependencies":{"@redis/client":"^5.11.0","@aws-sdk/client-s3":"^3.888.0","@googleapis/storage":"21.2.0","@reflag/flag-evaluation":"1.0.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"c8":"~10.1.0","vite":"~6.4.2","vitest":"~1.6.0","ts-node":"~10.9.2","typescript":"^5.7.3","@babel/core":"~7.24.7","@types/node":"^22.12.0","flush-promises":"~1.0.2","vite-plugin-dts":"~3.9.1","@reflag/tsconfig":"~0.0.2","@vitest/coverage-v8":"~1.6.0"},"_npmOperationalInternal":{"tmp":"tmp/node-sdk_1.6.0_1776603628931_0.8682286062445586","host":"s3://npm-registry-packages-npm-production"}},"1.7.0":{"name":"@reflag/node-sdk","version":"1.7.0","license":"MIT","_id":"@reflag/node-sdk@1.7.0","maintainers":[{"name":"roncohen1","email":"cohen1+1@gmail.com"}],"homepage":"https://github.com/reflagcom/javascript#readme","bugs":{"url":"https://github.com/reflagcom/javascript/issues"},"dist":{"shasum":"eeacc41d30408791c116b7421023c82dac1da8ff","tarball":"https://registry.npmjs.org/@reflag/node-sdk/-/node-sdk-1.7.0.tgz","fileCount":59,"integrity":"sha512-WKH/GMyIkRlVRBjzBp5CRBO7lsPgvPzjbsEc+V+3iYw0MD8+RTMknD0oybpj1c0oTuMDgHs9XXpLL8ZF7UquWw==","signatures":[{"sig":"MEQCIEBy3hjYgtpAVelJIZh/ekvmCDVS5ri7q0QCv59nvs3XAiBq9XznOkifl0zupjxxcPKQ/gRXkQCLtpIEg+wCN4zo6A==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@reflag%2fnode-sdk@1.7.0","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":328041},"main":"./dist/src/index.js","types":"./dist/types/src/index.d.ts","gitHead":"07762fdbd46968ffd1cc671c3c10cce2957f7524","scripts":{"dev":"vite","fmt":"oxfmt --check .","lint":"oxlint .","test":"vitest run","build":"tsc --project tsconfig.build.json","start":"vite","format":"yarn fmt:fix && yarn lint:fix","fmt:fix":"oxfmt --write .","lint:ci":"oxlint .","test:ci":"yarn test --reporter=default --reporter=junit --outputFile=junit.xml","coverage":"yarn test --coverage","lint:fix":"oxlint --fix .","preversion":"yarn lint && yarn fmt && yarn test && yarn build","test:watch":"vitest"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:db682705-3e50-4045-b2c3-1cc375631f25"}},"repository":{"url":"git+https://github.com/reflagcom/javascript.git","type":"git"},"_npmVersion":"11.6.2","description":"Node.js, JavaScript/TypeScript client for [Reflag.com](https://reflag.com).","directories":{},"_nodeVersion":"24.13.0","dependencies":{"@redis/client":"^5.11.0","@aws-sdk/client-s3":"^3.888.0","@googleapis/storage":"21.2.0","@reflag/flag-evaluation":"1.0.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"c8":"~10.1.0","vite":"~6.4.2","vitest":"~1.6.0","ts-node":"~10.9.2","typescript":"^5.7.3","@babel/core":"~7.24.7","@types/node":"^22.12.0","flush-promises":"~1.0.2","vite-plugin-dts":"~3.9.1","@reflag/tsconfig":"~0.0.2","@vitest/coverage-v8":"~1.6.0"},"_npmOperationalInternal":{"tmp":"tmp/node-sdk_1.7.0_1779908697381_0.32082092170536525","host":"s3://npm-registry-packages-npm-production"}},"1.7.1":{"name":"@reflag/node-sdk","version":"1.7.1","license":"MIT","_id":"@reflag/node-sdk@1.7.1","maintainers":[{"name":"roncohen1","email":"cohen1+1@gmail.com"}],"homepage":"https://github.com/reflagcom/javascript#readme","bugs":{"url":"https://github.com/reflagcom/javascript/issues"},"dist":{"shasum":"c351811760864112d8614c366bb8362fa3300768","tarball":"https://registry.npmjs.org/@reflag/node-sdk/-/node-sdk-1.7.1.tgz","fileCount":59,"integrity":"sha512-zOlc9ETzWC6BqGzzR9L01Vdv4fpUvcB+U3HsWQKnYTxP9VxB+IpGKkIbzVvUoMtwdr9x6jbHx1OXI47ma3VmWA==","signatures":[{"sig":"MEUCIQD3UnFgzNV9yC5TifN+eSCzpVXZzOcN29hOKvYPCWdWMQIgb0lCI+dVZr4hg3EfkJnZFEB0Cb3HE+bJfBtSvRQCClY=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@reflag%2fnode-sdk@1.7.1","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":328041},"main":"./dist/src/index.js","types":"./dist/types/src/index.d.ts","gitHead":"5aa5a6493d573cdc50a8a70f7fd90e258c95f9ef","scripts":{"dev":"vite","fmt":"oxfmt --check .","lint":"oxlint .","test":"vitest run","build":"tsc --project tsconfig.build.json","start":"vite","format":"yarn fmt:fix && yarn lint:fix","fmt:fix":"oxfmt --write .","lint:ci":"oxlint .","test:ci":"yarn test --reporter=default --reporter=junit --outputFile=junit.xml","coverage":"yarn test --coverage","lint:fix":"oxlint --fix .","preversion":"yarn lint && yarn fmt && yarn test && yarn build","test:watch":"vitest"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:db682705-3e50-4045-b2c3-1cc375631f25"}},"repository":{"url":"git+https://github.com/reflagcom/javascript.git","type":"git"},"_npmVersion":"11.6.2","description":"Node.js, JavaScript/TypeScript client for [Reflag.com](https://reflag.com).","directories":{},"_nodeVersion":"24.13.0","dependencies":{"@redis/client":"^5.11.0","@aws-sdk/client-s3":"^3.888.0","@googleapis/storage":"21.2.0","@reflag/flag-evaluation":"1.0.1"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"c8":"~10.1.0","vite":"~6.4.2","vitest":"~1.6.0","ts-node":"~10.9.2","typescript":"^5.7.3","@babel/core":"~7.29.6","@types/node":"^22.12.0","flush-promises":"~1.0.2","vite-plugin-dts":"~3.9.1","@reflag/tsconfig":"~0.0.2","@vitest/coverage-v8":"~1.6.0"},"_npmOperationalInternal":{"tmp":"tmp/node-sdk_1.7.1_1787052136612_0.22543956051838454","host":"s3://npm-registry-packages-npm-production"}},"1.7.2":{"name":"@reflag/node-sdk","version":"1.7.2","license":"MIT","_id":"@reflag/node-sdk@1.7.2","maintainers":[{"name":"roncohen1","email":"cohen1+1@gmail.com"}],"homepage":"https://github.com/reflagcom/javascript#readme","bugs":{"url":"https://github.com/reflagcom/javascript/issues"},"dist":{"shasum":"22a3a3c7fd03f3101b774509ea920dfccb12dbc9","tarball":"https://registry.npmjs.org/@reflag/node-sdk/-/node-sdk-1.7.2.tgz","fileCount":59,"integrity":"sha512-3xvYM74bhI78bMkgNMiinnlvTpv8WP9e55a4yDN9wGvEpkCdCWKubgICHoOZZA2ONEep1UOsc5iDpANgKyV2zw==","signatures":[{"sig":"MEUCICZVm33r0EyOyVwuIHqRE/JIKSTHCbEQuOJdy3Mi/xTAAiEAoGAntN45Aj3JRM4Y+XD0DouAp08pi7AnKWZ4FVzhYVM=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@reflag%2fnode-sdk@1.7.2","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":331520},"main":"./dist/src/index.js","types":"./dist/types/src/index.d.ts","gitHead":"6f7264bd43713e582ce9a55a240094d1249a1ed8","scripts":{"dev":"vite","fmt":"oxfmt --check .","lint":"oxlint .","test":"vitest run","build":"tsc --project tsconfig.build.json","start":"vite","format":"yarn fmt:fix && yarn lint:fix","fmt:fix":"oxfmt --write .","lint:ci":"oxlint .","test:ci":"yarn test --reporter=default --reporter=junit --outputFile=junit.xml","coverage":"yarn test --coverage","lint:fix":"oxlint --fix .","preversion":"yarn lint && yarn fmt && yarn test && yarn build","test:watch":"vitest"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:db682705-3e50-4045-b2c3-1cc375631f25"}},"repository":{"url":"git+https://github.com/reflagcom/javascript.git","type":"git"},"_npmVersion":"11.6.2","description":"Node.js, JavaScript/TypeScript client for [Reflag.com](https://reflag.com).","directories":{},"_nodeVersion":"24.13.0","dependencies":{"@redis/client":"^5.11.0","@aws-sdk/client-s3":"^3.888.0","@googleapis/storage":"21.2.0","@reflag/flag-evaluation":"1.1.0"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"c8":"~10.1.0","vite":"~6.4.2","vitest":"~1.6.0","ts-node":"~10.9.2","typescript":"^5.7.3","@babel/core":"~7.29.6","@types/node":"^22.12.0","flush-promises":"~1.0.2","vite-plugin-dts":"~3.9.1","@reflag/tsconfig":"~0.0.2","@vitest/coverage-v8":"~1.6.0"},"_npmOperationalInternal":{"tmp":"tmp/node-sdk_1.7.2_1788687651359_0.9464255683792211","host":"s3://npm-registry-packages-npm-production"}},"1.7.3":{"name":"@reflag/node-sdk","version":"1.7.3","license":"MIT","_id":"@reflag/node-sdk@1.7.3","maintainers":[{"name":"roncohen1","email":"cohen1+1@gmail.com"}],"homepage":"https://github.com/reflagcom/javascript#readme","bugs":{"url":"https://github.com/reflagcom/javascript/issues"},"dist":{"shasum":"5f80e9c4233419517f32f2da91e118e52c51ac20","tarball":"https://registry.npmjs.org/@reflag/node-sdk/-/node-sdk-1.7.3.tgz","fileCount":59,"integrity":"sha512-/yWuv5El8+X+BiBH+76VmQpskjtH5MHCV5Bs06v7J9ROQkYcy5uui5f28qtPgLd8Cr8fR6Pha/0hdgXvJUQ9kw==","signatures":[{"sig":"MEUCIAlR/6OXYZ/8kxrdxV/UCxT8tpc3sKH9acOGQynIo2B0AiEAsUjeKfxMXXs8MW0hp1PBQuRxBX0VMtV9GCV1HkMgq+E=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@reflag%2fnode-sdk@1.7.3","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":331520},"main":"./dist/src/index.js","types":"./dist/types/src/index.d.ts","gitHead":"6d2429b57350aa886912ba651d1332539167f511","scripts":{"dev":"vite","fmt":"oxfmt --check .","lint":"oxlint .","test":"vitest run","build":"tsc --project tsconfig.build.json","start":"vite","format":"yarn fmt:fix && yarn lint:fix","fmt:fix":"oxfmt --write .","lint:ci":"oxlint .","test:ci":"yarn test --reporter=default --reporter=junit --outputFile=junit.xml","coverage":"yarn test --coverage","lint:fix":"oxlint --fix .","preversion":"yarn lint && yarn fmt && yarn test && yarn build","test:watch":"vitest"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:db682705-3e50-4045-b2c3-1cc375631f25"}},"repository":{"url":"git+https://github.com/reflagcom/javascript.git","type":"git"},"_npmVersion":"11.6.2","description":"Node.js, JavaScript/TypeScript client for [Reflag.com](https://reflag.com).","directories":{},"_nodeVersion":"24.13.0","dependencies":{"@redis/client":"^5.11.0","@aws-sdk/client-s3":"^3.888.0","@googleapis/storage":"21.2.0","@reflag/flag-evaluation":"1.1.1"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"c8":"~10.1.0","vite":"~6.4.2","vitest":"~1.6.0","ts-node":"~10.9.2","typescript":"^5.7.3","@babel/core":"~7.29.6","@types/node":"^22.12.0","flush-promises":"~1.0.2","vite-plugin-dts":"~3.9.1","@reflag/tsconfig":"~0.0.2","@vitest/coverage-v8":"~1.6.0"},"_npmOperationalInternal":{"tmp":"tmp/node-sdk_1.7.3_1788784839417_0.9223652716406439","host":"s3://npm-registry-packages-npm-production"}},"1.8.0":{"name":"@reflag/node-sdk","version":"1.8.0","license":"MIT","_id":"@reflag/node-sdk@1.8.0","maintainers":[{"name":"roncohen1","email":"cohen1+1@gmail.com"}],"homepage":"https://github.com/reflagcom/javascript#readme","bugs":{"url":"https://github.com/reflagcom/javascript/issues"},"dist":{"shasum":"983b3ab574db7bd6e9f368791369972175ed1777","tarball":"https://registry.npmjs.org/@reflag/node-sdk/-/node-sdk-1.8.0.tgz","fileCount":59,"integrity":"sha512-FyzFSWulkT4yWUesz609hlQsjmSqJCafH4gYexSLG1X95C/djw77Ds4+IcG7ZC1azPXXkYv9b9F8ca4wZLGw+Q==","signatures":[{"sig":"MEQCICDzhXAMPWbz8nieFRXqpvVDO0pNizTs00NBtfdFsOfeAiBF+bbqPnjN4+Fu7lIpyuIjJssZ4D0PtSGF16UJMHANNQ==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@reflag%2fnode-sdk@1.8.0","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":337134},"main":"./dist/src/index.js","types":"./dist/types/src/index.d.ts","gitHead":"44e46957e03a3d37cf19fdcdaa4fb5c5bdc2b8d1","scripts":{"dev":"vite","fmt":"oxfmt --check .","lint":"oxlint .","test":"vitest run","build":"tsc --project tsconfig.build.json","start":"vite","format":"yarn fmt:fix && yarn lint:fix","fmt:fix":"oxfmt --write .","lint:ci":"oxlint .","test:ci":"yarn test --reporter=default --reporter=junit --outputFile=junit.xml","coverage":"yarn test --coverage","lint:fix":"oxlint --fix .","preversion":"yarn lint && yarn fmt && yarn test && yarn build","test:watch":"vitest"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:db682705-3e50-4045-b2c3-1cc375631f25"}},"repository":{"url":"git+https://github.com/reflagcom/javascript.git","type":"git"},"_npmVersion":"11.6.2","description":"Node.js, JavaScript/TypeScript client for [Reflag.com](https://reflag.com).","directories":{},"_nodeVersion":"24.13.0","dependencies":{"@redis/client":"^5.11.0","@aws-sdk/client-s3":"^3.888.0","@googleapis/storage":"21.2.0","@reflag/flag-evaluation":"1.1.1"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"c8":"~10.1.0","vite":"~6.4.2","vitest":"~1.6.0","ts-node":"~10.9.2","typescript":"^5.7.3","@babel/core":"~7.29.6","@types/node":"^22.12.0","flush-promises":"~1.0.2","vite-plugin-dts":"~3.9.1","@reflag/tsconfig":"~0.0.2","@vitest/coverage-v8":"~1.6.0"},"_npmOperationalInternal":{"tmp":"tmp/node-sdk_1.8.0_1788888814470_0.6557341250509552","host":"s3://npm-registry-packages-npm-production"}},"1.8.1":{"_id":"@reflag/node-sdk@1.8.1","bugs":{"url":"https://github.com/reflagcom/javascript/issues"},"dist":{"shasum":"6233ee84d9fea1ab679afabf7a3dc6c9da10e5e5","tarball":"https://registry.npmjs.org/@reflag/node-sdk/-/node-sdk-1.8.1.tgz","fileCount":59,"integrity":"sha512-5gLgQ+woPEUZUupsrz/WJrJaCnsAhTwlpL6LHwWfdQkArPO5vPjNQfoH9mmi6a+8LeZgLAdfIbYYwTsvoPKdXQ==","signatures":[{"sig":"MEUCIExl5AUrNCIOFnZgHjwLzs/5kvwfVWeDHZia/RR2qJg6AiEAsJpioi6G0XgHUOxguHhJG+LjwvYTZG0LwRkkippwpYw=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"},{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEYCIQCV1KxFx44gCocYnHTDPwS83ORKi0K6RzyncVkRmbiTeQIhAIJXfaz+NduDq6yWq35tT/cIVE9AUXyjmbfkkdc6NWuJ"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@reflag%2fnode-sdk@1.8.1","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":339538},"main":"./dist/src/index.js","name":"@reflag/node-sdk","types":"./dist/types/src/index.d.ts","gitHead":"39c6c1b3bb88390ad543b2d69d3df213610e4c7e","license":"MIT","scripts":{"dev":"vite","fmt":"oxfmt --check .","lint":"oxlint .","test":"vitest run","build":"tsc --project tsconfig.build.json","start":"vite","format":"yarn fmt:fix && yarn lint:fix","fmt:fix":"oxfmt --write .","lint:ci":"oxlint .","test:ci":"yarn test --reporter=default --reporter=junit --outputFile=junit.xml","coverage":"yarn test --coverage","lint:fix":"oxlint --fix .","preversion":"yarn lint && yarn fmt && yarn test && yarn build","test:watch":"vitest"},"version":"1.8.1","_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:db682705-3e50-4045-b2c3-1cc375631f25"}},"homepage":"https://github.com/reflagcom/javascript#readme","repository":{"url":"git+https://github.com/reflagcom/javascript.git","type":"git"},"_npmVersion":"11.6.2","description":"Node.js, JavaScript/TypeScript client for [Reflag.com](https://reflag.com).","directories":{},"maintainers":[{"name":"roncohen1","email":"cohen1+1@gmail.com"}],"_nodeVersion":"24.13.0","dependencies":{"@redis/client":"^5.11.0","@aws-sdk/client-s3":"^3.888.0","@googleapis/storage":"21.2.0","@reflag/flag-evaluation":"1.1.1"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"c8":"~10.1.0","vite":"~6.4.2","vitest":"~1.6.0","ts-node":"~10.9.2","typescript":"^5.7.3","@babel/core":"~7.29.6","@types/node":"^22.12.0","flush-promises":"~1.0.2","vite-plugin-dts":"~3.9.1","@reflag/tsconfig":"~0.0.2","@vitest/coverage-v8":"~1.6.0"},"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/node-sdk_1.8.1_1789375883770_0.9731910278770266"}}},"time":{"created":"2025-09-02T06:53:21.924Z","modified":"2026-09-14T08:51:24.344Z","1.10.0":"2025-09-02T06:47:47.987Z","1.0.0-alpha.1":"2025-09-02T06:53:22.195Z","1.0.0-alpha.2":"2025-09-02T09:24:47.016Z","1.0.0-alpha.3":"2025-09-02T11:38:07.947Z","1.0.0":"2025-09-02T20:58:44.544Z","1.0.1":"2025-09-10T13:52:06.305Z","1.1.0":"2025-10-02T07:40:18.016Z","1.2.0":"2026-02-24T20:29:28.214Z","1.3.0":"2026-03-13T20:41:41.535Z","1.4.0":"2026-03-19T10:18:17.385Z","1.4.1":"2026-03-20T18:46:50.379Z","1.4.2":"2026-03-27T20:09:16.684Z","1.5.0":"2026-04-07T11:56:18.542Z","1.5.1":"2026-04-08T08:32:26.766Z","1.6.0":"2026-04-19T13:00:29.112Z","1.7.0":"2026-05-27T19:04:57.515Z","1.7.1":"2026-08-18T11:22:16.751Z","1.7.2":"2026-09-06T09:40:51.501Z","1.7.3":"2026-09-07T12:40:39.589Z","1.8.0":"2026-09-08T17:33:34.754Z","1.8.1":"2026-09-14T08:51:23.849Z"},"bugs":{"url":"https://github.com/reflagcom/javascript/issues"},"license":"MIT","homepage":"https://github.com/reflagcom/javascript#readme","repository":{"url":"git+https://github.com/reflagcom/javascript.git","type":"git"},"description":"Node.js, JavaScript/TypeScript client for [Reflag.com](https://reflag.com).","maintainers":[{"name":"roncohen1","email":"cohen1+1@gmail.com"}],"readme":"# Reflag Node.js SDK\n\nNode.js, JavaScript/TypeScript client for [Reflag.com](https://reflag.com).\n\nReflag supports flag toggling, tracking flag usage, collecting feedback on features, and [remotely configuring flags](#remote-config).\n\n## Installation\n\nInstall using your favorite package manager:\n\n{% tabs %}\n{% tab title=\"npm\" %}\n\n```sh\nnpm i @reflag/node-sdk\n```\n\n{% endtab %}\n\n{% tab title=\"yarn\" %}\n\n```sh\nyarn add @reflag/node-sdk\n```\n\n{% endtab %}\n\n{% tab title=\"bun\" %}\n\n```sh\nbun add @reflag/node-sdk\n```\n\n{% endtab %}\n\n{% tab title=\"pnpm\" %}\n\n```sh\npnpm add @reflag/node-sdk\n```\n\n{% endtab %}\n\n{% tab title=\"deno\" %}\n\n```sh\ndeno add npm:@reflag/node-sdk\n```\n\n{% endtab %}\n{% endtabs %}\n\nOther supported languages/frameworks are in the [Supported languages](https://docs.reflag.com/quickstart/supported-languages) documentation pages.\n\nYou can also [use the HTTP API directly](https://docs.reflag.com/api/http-api)\n\n## Basic usage\n\nTo get started you need to obtain your secret key from the [environment settings](https://app.reflag.com/env-current/settings/app-environments)\nin Reflag.\n\nReflag will load settings through the various environment variables automatically (see [Configuring](#configuring) below).\n\n1. Find the Reflag secret key for your development environment under [environment settings](https://app.reflag.com/env-current/settings/app-environments) in Reflag.\n2. Set `REFLAG_SECRET_KEY` in your `.env` file\n3. Create a `reflag.ts` file containing the following:\n\n```typescript\nimport { ReflagClient } from \"@reflag/node-sdk\";\n\n// Create a new instance of the client with the secret key. Additional options\n// are available, such as supplying a logger and other custom properties.\n//\n// We recommend that only one global instance of `client` should be created\n// to avoid multiple round-trips to our servers.\nexport const reflagClient = new ReflagClient();\n\n// Initialize the client and begin fetching flag targeting definitions.\n// You must call this method prior to any calls to `getFlags()`,\n// otherwise an empty object will be returned.\nreflagClient.initialize().then(() => {\n  console.log(\"Reflag initialized!\");\n});\n```\n\nOnce the client is initialized, you can obtain flags along with the `isEnabled`\nstatus to indicate whether the flag is targeted for this user/company:\n\n> [!IMPORTANT]\n> If `user.id` is not given, the whole `user` object is ignore. Similarly, without `company.id` the `company` object is ignored.\n\n```typescript\n// configure the client\nconst boundClient = reflagClient.bindClient({\n  user: {\n    id: \"john_doe\",\n    name: \"John Doe\",\n    email: \"john@acme.com\",\n    avatar: \"https://example.com/users/jdoe\",\n  },\n  company: {\n    id: \"acme_inc\",\n    name: \"Acme, Inc.\",\n    avatar: \"https://example.com/companies/acme\",\n  },\n});\n\n// get the huddle flag using company, user and custom context to\n// evaluate the targeting.\nconst { isEnabled, track, config } = boundClient.getFlag(\"huddle\");\n\nif (isEnabled) {\n  // this is your flag gated code ...\n  // send an event when the flag is used:\n  track();\n\n  if (config?.key === \"zoom\") {\n    // this code will run if a given remote configuration\n    // is set up.\n  }\n\n  // CAUTION: if you plan to use the event for automated feedback surveys\n  // call `flush` immediately after `track`. It can optionally be awaited\n  // to guarantee the sent happened.\n  boundClient.flush();\n}\n```\n\nYou can also use the `getFlags()` method which returns a map of all flags:\n\n```typescript\n// get the current flags (uses company, user and custom context to\n// evaluate the flags).\nconst flags = boundClient.getFlags();\nconst bothEnabled = flags.huddle?.isEnabled && flags.voiceHuddle?.isEnabled;\n```\n\n## High performance flag targeting\n\nThe SDK contacts the Reflag servers when you call `initialize()`\nand downloads the flags with their targeting rules.\nThese rules are then matched against the user/company information you provide\nto `getFlags()` (or through `bindClient(..).getFlags()`). That means the\n`getFlags()` call does not need to contact the Reflag servers once\n`initialize()` has completed. By default, `ReflagClient` uses\n`flagsSyncMode: \"push\"`, which keeps targeting rules up to date via live SSE\nupdates. You can switch `flagsSyncMode` to `polling` for periodic background\nrefreshes or `in-request` for request-driven refreshes instead.\n\n### Batch Operations\n\nThe SDK automatically batches operations like user/company updates and flag tracking events to minimize API calls.\nThe batch buffer is configurable through the client options:\n\n```typescript\nconst client = new ReflagClient({\n  batchOptions: {\n    maxSize: 100, // Maximum number of events to batch\n    intervalMs: 10000, // Flush interval in milliseconds (default: 10000)\n  },\n});\n```\n\nYou can manually flush the batch buffer at any time:\n\n```typescript\nawait client.flush();\n```\n\n> [!TIP]\n> It's recommended to call `flush()` before your application shuts down to ensure all events are sent.\n\n### Rate Limiting\n\nThe SDK includes automatic rate limiting for flag events to prevent overwhelming the API.\nRate limiting is applied per unique combination of flag key and evaluation context.\nThis behavior is built in and does not currently require configuration.\n\n### Flag definitions\n\nFlag definitions include the rules needed to determine which flags should be enabled and which config values should be applied to any given user/company.\nFlag definitions are automatically fetched when calling `initialize()`.\nThey are then cached and refreshed in the background.\nIt's also possible to get the currently in use flag definitions:\n\n```typescript\nimport fs from \"fs\";\n\nconst client = new ReflagClient();\n\nconst flagDefs = await client.getFlagDefinitions();\n// [{\n//   key: \"huddle\",\n//   description: \"Live voice conversations with colleagues.\"\n//   flag: { ... }\n//   config: { ... }\n// }]\n```\n\n### Fallback provider\n\n`flagsFallbackProvider` is a reliability feature that lets the SDK persist the latest successfully fetched raw flag definitions to fallback storage such as a local file, Redis, S3, GCS, or a custom backend.\n\n> [!NOTE]\n>\n> `fallbackFlags` is deprecated. Prefer `flagsFallbackProvider` for startup fallback and outage recovery.\n> `flagsFallbackProvider` is not used in offline mode.\n\n#### How it works\n\nReflag servers remain the primary source of truth. On `initialize()`, the SDK always tries to fetch a live copy of the flag definitions first, and it continues refreshing those definitions from the Reflag servers over time.\n\nIf that initial live fetch fails, the SDK can call `flagsFallbackProvider.load()` and start with the last saved snapshot instead. This is mainly useful for cold starts in the exceedingly rare case that Reflag has an outage.\n\nIf Reflag becomes unavailable after the SDK has already initialized successfully, the SDK keeps using the last successfully fetched definitions it already has in memory. In other words, the fallback provider is mainly what helps future processes start, not what keeps an already running process alive.\n\nAfter successfully fetching updated flag definitions, the SDK calls `flagsFallbackProvider.save()` to keep the stored snapshot up to date.\n\nTypical reliability flow:\n\n1. The SDK starts and tries to fetch live flag definitions from Reflag.\n2. If that succeeds, those definitions are used immediately and the SDK continues operating normally.\n3. After successfully fetching updated flag definitions, the SDK saves the latest snapshot through the fallback provider so a recent copy is available if needed later.\n4. If a future process starts while Reflag is unavailable, it can load the last saved snapshot from the fallback provider and still initialize.\n5. Once Reflag becomes available again, the SDK resumes using live data and refreshes the fallback snapshot.\n\nMost deployments run multiple SDK processes, so more than one process may save identical flag definitions to the fallback storage at roughly the same time. This is expected and generally harmless for backends like a local file, Redis, S3, or GCS because the operation is cheap. In practice, this only becomes worth thinking about once you have many thousands of SDK processes writing to the same fallback storage.\n\n> [!TIP]\n> If you are building a web or client-side application and want the most resilient setup, combine `flagsFallbackProvider` on the server with bootstrapped flags on the client.\n>\n> `flagsFallbackProvider` helps new server processes start if they cannot reach Reflag during initialization. Bootstrapping helps clients render from server-provided flags instead of depending on an initial client-side fetch from the Reflag servers.\n>\n> This applies to React (`getFlagsForBootstrap()` + `ReflagBootstrappedProvider`), React Native, the Browser SDK (`bootstrappedState`), and the Vue SDK (bootstrapped flags via the provider).\n\n#### Built-in providers\n\nYou can access the built-in providers through the `fallbackProviders` namespace:\n\n- `fallbackProviders.static(...)`\n- `fallbackProviders.file(...)`\n- `fallbackProviders.redis(...)`\n- `fallbackProviders.s3(...)`\n- `fallbackProviders.gcs(...)`\n\n##### Static provider\n\nIf you just want a fixed fallback copy of simple enabled/disabled flags, you can provide a static map:\n\n```typescript\nimport { ReflagClient, fallbackProviders } from \"@reflag/node-sdk\";\n\nconst client = new ReflagClient({\n  secretKey: process.env.REFLAG_SECRET_KEY,\n  flagsFallbackProvider: fallbackProviders.static({\n    flags: {\n      huddle: true,\n      \"smart-summaries\": false,\n    },\n  }),\n});\n\nawait client.initialize();\n```\n\n##### File provider\n\n```typescript\nimport { ReflagClient, fallbackProviders } from \"@reflag/node-sdk\";\n\nconst client = new ReflagClient({\n  secretKey: process.env.REFLAG_SECRET_KEY,\n  flagsFallbackProvider: fallbackProviders.file({\n    directory: \".reflag\",\n  }),\n});\n\nawait client.initialize();\n```\n\nThe file provider stores one snapshot file per environment in the configured\n`directory`, using the filename\n`flags-fallback-<secretKeyHash.slice(0, 16)>.json`.\n\n##### Redis provider\n\nThe built-in Redis provider creates a Redis client automatically when omitted and uses `REDIS_URL` from the environment. It stores snapshots under the configured `keyPrefix` and appends the first 16 characters of the secret key hash to that prefix.\n\nWithout a `keyPrefix` set, it will default to the key `reflag:flags-fallback:<secretKeyHash.slice(0, 16)>`. When you provide a custom `keyPrefix`, any trailing `:` is trimmed before the hash suffix is appended.\n\n```typescript\nimport { ReflagClient, fallbackProviders } from \"@reflag/node-sdk\";\n\nconst client = new ReflagClient({\n  secretKey: process.env.REFLAG_SECRET_KEY,\n  flagsFallbackProvider: fallbackProviders.redis(),\n});\n\nawait client.initialize();\n```\n\n##### S3 provider\n\nThe built-in S3 provider works out of the box using the AWS SDK's default credential chain and region resolution. It stores the snapshot object under the configured `keyPrefix` and uses the filename `flags-fallback-<secretKeyHash.slice(0, 16)>.json`.\n\nWithout a `keyPrefix` set, it will default to the object key `reflag/flags-fallback/flags-fallback-<secretKeyHash.slice(0, 16)>.json`. When you provide a custom `keyPrefix`, any trailing `/` is trimmed before the filename is appended.\n\n```typescript\nimport { ReflagClient, fallbackProviders } from \"@reflag/node-sdk\";\n\nconst client = new ReflagClient({\n  secretKey: process.env.REFLAG_SECRET_KEY,\n  flagsFallbackProvider: fallbackProviders.s3({\n    bucket: \"reflag-fallback-bucket\",\n  }),\n});\n\nawait client.initialize();\n```\n\n##### GCS provider\n\nThe built-in GCS provider works out of the box using Google Cloud's default application credentials. It stores the snapshot object under the configured `keyPrefix` and uses the filename `flags-fallback-<secretKeyHash.slice(0, 16)>.json`.\n\nWithout a `keyPrefix` set, it will default to the object key `reflag/flags-fallback/flags-fallback-<secretKeyHash.slice(0, 16)>.json`. When you provide a custom `keyPrefix`, any trailing `/` is trimmed before the filename is appended.\n\n```typescript\nimport { ReflagClient, fallbackProviders } from \"@reflag/node-sdk\";\n\nconst client = new ReflagClient({\n  secretKey: process.env.REFLAG_SECRET_KEY,\n  flagsFallbackProvider: fallbackProviders.gcs({\n    bucket: \"reflag-fallback-bucket\",\n  }),\n});\n\nawait client.initialize();\n```\n\n#### Testing fallback startup locally\n\nTo test fallback startup in your own app, first run it once with a working Reflag connection so a snapshot is saved. Then restart it with the same secret key and fallback provider configuration, but set `apiBaseUrl` (or set the `REFLAG_API_BASE_URL` environment variable) to `http://127.0.0.1:65535`. That forces the live fetch to fail and lets you verify that the SDK initializes from the saved snapshot instead.\n\n#### Writing a custom provider\n\nIf you just store definitions in your database or similar, a custom provider can be very small:\n\n```typescript\nimport type {\n  FlagsFallbackProvider,\n  FlagsFallbackSnapshot,\n} from \"@reflag/node-sdk\";\n\nexport const customFallbackProvider: FlagsFallbackProvider = {\n  async load(context) {\n    // load snapshot from database\n    // optionally, look up the snapshot using the context.secretKeyHash as a key\n    return snapshot;\n  },\n\n  async save(context, snapshot) {\n    const serialized = JSON.stringify(snapshot);\n    // write serialized snapshot to database, optionally using context.secretKeyHash as a key\n  },\n};\n```\n\n## Bootstrapping client-side applications\n\nThe `getFlagsForBootstrap()` method is useful whenever you need to pass flag data to another runtime or serialize it without wrapper functions. Server-side rendering (SSR) is a common example, but it is also useful for other bootstrapping and hydration flows.\n\n```typescript\nconst client = new ReflagClient();\nawait client.initialize();\n\n// Get bootstrapped state with full context\nconst bootstrappedState = client.getFlagsForBootstrap({\n  user: {\n    id: \"user123\",\n    name: \"John Doe\",\n    email: \"john@acme.com\",\n  },\n  company: {\n    id: \"company456\",\n    name: \"Acme Inc\",\n    plan: \"enterprise\",\n  },\n  other: {\n    source: \"web\",\n    platform: \"desktop\",\n  },\n});\n\n// Pass this data to your client-side application\nconsole.log(bootstrappedState);\n// {\n//   context: { ... },\n//   flags: {\n//     \"huddle\": {\n//       \"key\": \"huddle\",\n//       \"isEnabled\": true,\n//       \"config\": {\n//         \"key\": \"enhanced\",\n//         \"payload\": { \"maxParticipants\": 50, \"videoQuality\": \"hd\" },\n//       }\n//     }\n//   },\n//   flagStateVersion: 42\n// }\n```\n\nYou can also use a bound client for simpler API:\n\n```typescript\nconst boundClient = client.bindClient({\n  user: { id: \"user123\", name: \"John Doe\", email: \"john@acme.com\" },\n  company: { id: \"company456\", name: \"Acme Inc\", plan: \"enterprise\" },\n});\n\nconst bootstrappedState = boundClient.getFlagsForBootstrap();\n```\n\n### Key differences from `getFlags()`\n\n- **Raw data**: Returns plain objects without `track()` functions, making them JSON serializable\n- **Context included**: Returns both the evaluated flags and the context used for evaluation\n- **Version included**: Returns `flagStateVersion` when known so bootstrapped clients can avoid redundant live-update refreshes\n- **Bootstrapping focus**: Designed specifically for passing data to client-side applications\n\n## Edge-runtimes like Cloudflare Workers\n\nTo use the Reflag NodeSDK with Cloudflare workers, set the `node_compat` flag [in your wrangler file](https://developers.cloudflare.com/workers/runtime-apis/nodejs/#get-started).\n\nInstead of using `ReflagClient`, use `EdgeClient` and make sure you call `ctx.waitUntil(reflag.flush());` before returning from your worker function.\n\n```typescript\nimport { EdgeClient } from \"@reflag/node-sdk\";\n\n// set the REFLAG_SECRET_KEY environment variable or pass the secret key in the constructor\nconst reflag = new EdgeClient();\n\nexport default {\n  async fetch(request, _env, ctx): Promise<Response> {\n    // initialize the client and wait for it to complete\n    // if the client was initialized on a previous invocation, this is a no-op.\n    await reflag.initialize();\n    const flags = reflag.getFlags({\n      user: { id: \"userId\" },\n      company: { id: \"companyId\" },\n    });\n\n    // ensure all events are flushed and any requests to refresh the flag cache\n    // have completed after the response is sent\n    ctx.waitUntil(reflag.flush());\n\n    return new Response(\n      `Flags for user ${userId} and company ${companyId}: ${JSON.stringify(flags, null, 2)}`,\n    );\n  },\n};\n```\n\nSee [examples/cloudflare-worker](https://github.com/reflagcom/javascript/tree/main/packages/node-sdk/examples/cloudflare-worker/src/index.ts) for a deployable example.\n\nReflag maintains a cached set of flag definitions in the memory of your worker which it uses to decide which flags to turn on for which users/companies.\n\nThe SDK caches flag definitions in memory for fast performance. The first request to a new worker instance fetches definitions from Reflag's servers, while subsequent requests use the cache. When the cache expires, it's updated in the background. `ctx.waitUntil(reflag.flush())` ensures completion of the background work, so response times are not affected. This background work may increase wall-clock time for your worker, but it will not measurably increase billable CPU time on platforms like Cloudflare.\n\n`EdgeClient` uses `flagsSyncMode: \"in-request\"`. Refresh fetch starts are throttled to at most once per second, and Cloudflare Workers cannot rely on delayed timer callbacks to run follow-up refreshes later. That means `refreshFlags()` calls made during the throttle window only mark a refresh as pending, so the call itself may resolve before the fetch runs. The queued refresh runs on the next request/access or `refreshFlags()` call after the throttle window expires.\n\n## Error Handling\n\nThe SDK is designed to fail gracefully and never throw exceptions to the caller. Instead, it logs errors and provides\nfallback behavior:\n\n1. **Flag Evaluation Failures**:\n\n   ```typescript\n   const { isEnabled } = client.getFlag(\"my-flag\");\n   // If flag evaluation fails, isEnabled will be false\n   ```\n\n2. **Network Errors**:\n\n   ```typescript\n   // Network errors during tracking are logged but don't affect your application\n   const { isEnabled, track } = client.getFlag(\"my-flag\");\n   if (isEnabled) {\n     // network errors are caught internally and logged and never bubbled up to your application\n     // no need to try/catch around \"track\" or \"getFlag\"\n     await track();\n   }\n   ```\n\n3. **Missing Context**:\n\n   ```typescript\n   // The SDK tracks missing context fields but continues operation\n   const flags = client.getFlags({\n     user: { id: \"user123\" },\n     // Missing company context will be logged but won't cause errors\n   });\n   ```\n\n4. **Offline Mode**:\n\n   ```typescript\n   // In offline mode, the SDK uses explicit local configuration only.\n   // It does not fetch from Reflag or use flagsFallbackProvider.\n   const client = new ReflagClient({\n     offline: true,\n     flagOverrides: () => ({\n       \"my-flag\": true,\n     }),\n   });\n   ```\n\nThe SDK logs all errors with appropriate severity levels. You can customize logging by providing your own logger:\n\n```typescript\nconst client = new ReflagClient({\n  logger: {\n    debug: (msg) => console.debug(msg),\n    info: (msg) => console.info(msg),\n    warn: (msg) => console.warn(msg),\n    error: (msg, error) => {\n      console.error(msg, error);\n      // Send to your error tracking service\n      errorTracker.capture(error);\n    },\n  },\n});\n```\n\n## Remote config\n\nRemote config is a dynamic and flexible approach to configuring flag behavior outside of your app – without needing to re-deploy it.\n\nSimilar to `isEnabled`, each flag has a `config` property. This configuration is managed from within Reflag.\nIt is managed similar to the way access to flags is managed, but instead of the binary `isEnabled` you can have\nmultiple configuration values which are given to different user/companies.\n\n```ts\nconst flags = reflagClient.getFlags();\n// {\n//   huddle: {\n//     isEnabled: true,\n//     targetingVersion: 42,\n//     config: {\n//       key: \"gpt-3.5\",\n//       payload: { maxTokens: 10000, model: \"gpt-3.5-beta1\" }\n//     }\n//   }\n// }\n```\n\n`key` is mandatory for a config, but if a flag has no config or no config value was matched against the context, the `key` will be `undefined`. Make sure to check against this case when trying to use the configuration in your application. `payload` is an optional JSON value for arbitrary configuration needs.\n\nJust as `isEnabled`, accessing `config` on the object returned by `getFlags` does not automatically\ngenerate a `check` event, contrary to the `config` property on the object returned by `getFlag`.\n\n## Configuring\n\nThe Reflag `Node.js` SDK can be configured through environment variables,\na configuration file on disk or by passing options to the `ReflagClient`\nconstructor. By default, the SDK searches for `reflag.config.json` in the\ncurrent working directory.\n\n| Option                  | Type                                  | Description                                                                                                                                                                                                                                         | Env Var                                     |\n| ----------------------- | ------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------------------------------------------- |\n| `secretKey`             | string                                | The secret key used for authentication with Reflag's servers.                                                                                                                                                                                       | REFLAG_SECRET_KEY                           |\n| `logLevel`              | string                                | The log level for the SDK (e.g., `\"DEBUG\"`, `\"INFO\"`, `\"WARN\"`, `\"ERROR\"`). Default: `INFO`                                                                                                                                                         | REFLAG_LOG_LEVEL                            |\n| `offline`               | boolean                               | Operate in offline mode. Default: `false`, except in tests it will default to `true` based off of the `TEST` env. var. In offline mode the SDK does not fetch from Reflag and does not use `flagsFallbackProvider`.                                 | REFLAG_OFFLINE                              |\n| `apiBaseUrl`            | string                                | The base API URL for the Reflag servers.                                                                                                                                                                                                            | REFLAG_API_BASE_URL                         |\n| `flagOverrides`         | Record<string, boolean>               | An object specifying flag overrides for testing or local development. See [examples/express/app.test.ts](https://github.com/reflagcom/javascript/tree/main/packages/node-sdk/examples/express/app.test.ts) for how to use `flagOverrides` in tests. | REFLAG_FLAGS_ENABLED, REFLAG_FLAGS_DISABLED |\n| `flagsFallbackProvider` | `FlagsFallbackProvider`               | Optional provider used to load and save raw flag definitions for fallback startup when the initial live fetch fails. Available only through the constructor. Ignored in offline mode.                                                               | -                                           |\n| `flagsSyncMode`         | `\"polling\" \\| \"in-request\" \\| \"push\"` | Flag-definition sync mode. `push` subscribes to live updates, `polling` uses periodic background refresh, and `in-request` refreshes stale flags during request handling. Default: `\"push\"`.                                                        | -                                           |\n| `flagsPushUrl`          | string                                | Push endpoint used when `flagsSyncMode: \"push\"`. The SDK opens it as an authenticated streaming GET. Default: `https://front.reflag.com/sse/server`.                                                                                                | -                                           |\n| `configFile`            | string                                | Load this config file from disk. Default: `reflag.config.json`                                                                                                                                                                                      | REFLAG_CONFIG_FILE                          |\n\n> [!NOTE]\n>\n> `REFLAG_FLAGS_ENABLED` and `REFLAG_FLAGS_DISABLED` are comma separated lists of flags which will be enabled or disabled respectively.\n\n`reflag.config.json` example:\n\n```json\n{\n  \"secretKey\": \"...\",\n  \"logLevel\": \"warn\",\n  \"offline\": true,\n  \"apiBaseUrl\": \"https://proxy.slick-demo.com\",\n  \"flagOverrides\": {\n    \"huddles\": true,\n    \"voiceChat\": { \"isEnabled\": false },\n    \"aiAssist\": {\n      \"isEnabled\": true,\n      \"config\": {\n        \"key\": \"gpt-4.0\",\n        \"payload\": {\n          \"maxTokens\": 50000\n        }\n      }\n    }\n  }\n}\n```\n\nWhen using a `reflag.config.json` for local development, make sure you add it to your\n`.gitignore` file. You can also set these options directly in the `ReflagClient`\nconstructor. The precedence for configuration options is as follows, listed in the\norder of importance:\n\n1. Options passed along to the constructor directly,\n2. Environment variable,\n3. The config file.\n\n## Type safe flags\n\nTo get type checked flags, install the Reflag CLI:\n\n```sh\nnpm i --save-dev @reflag/cli\n```\n\nthen generate the types:\n\n```sh\nnpx reflag flags types\n```\n\nThis will generate a `reflag.d.ts` containing all your flags.\nAny flag look ups will now be checked against the flags that exist in Reflag.\n\nHere's an example of a failed type check:\n\n```typescript\nimport { ReflagClient } from \"@reflag/node-sdk\";\n\nexport const reflagClient = new ReflagClient();\n\nreflagClient.initialize().then(() => {\n  console.log(\"Reflag initialized!\");\n\n  // TypeScript will catch this error: \"invalid-flag\" doesn't exist\n  reflagClient.getFlag(\"invalid-flag\");\n\n  const {\n    isEnabled,\n    config: { payload },\n  } = reflagClient.getFlag(\"create-todos\");\n});\n```\n\n![Type check failed](docs/type-check-failed.png \"Type check failed\")\n\nThis is an example of a failed config payload check:\n\n```typescript\nreflagClient.initialize().then(() => {\n  // TypeScript will catch this error as well: \"minLength\" is not part of the payload.\n  if (isEnabled && todo.length > config.payload.minLength) {\n    // ...\n  }\n});\n```\n\n![Config type check failed](docs/type-check-payload-failed.png \"Remote config type check failed\")\n\n## Testing with flag overrides\n\nWhen writing tests that cover code with flags, you can toggle flags on/off programmatically to test different behavior. For tests, you will often want to run the client in offline mode:\n\n`reflag.ts`:\n\n```typescript\nimport { ReflagClient } from \"@reflag/node-sdk\";\n\nexport const reflag = new ReflagClient({\n  offline: true,\n});\n```\n\nThere are a few ways to programmatically manipulate the overrides which are appropriate when testing:\n\n### Base overrides\n\nYou can set base overrides for a test run by passing `flagOverrides` in the constructor, replacing them later with `setFlagOverrides()` and clearing them with `clearFlagOverrides()`:\n\n```typescript\n// pass directly in the constructor\nconst client = new ReflagClient({\n  offline: true,\n  flagOverrides: { myFlag: true },\n});\n\n// or replace the base overrides at a later time\nclient.setFlagOverrides({ myFlag: false });\n\n// clear only the base overrides\nclient.clearFlagOverrides();\n```\n\n`app.test.ts`:\n\n```typescript\nimport { reflag } from \"./reflag.ts\";\n\nbeforeAll(async () => await reflag.initialize());\nafterEach(() => {\n  reflag.clearFlagOverrides();\n});\n\ndescribe(\"API Tests\", () => {\n  it(\"should return 200 for the root endpoint\", async () => {\n    reflag.setFlagOverrides({\n      \"show-todo\": true,\n    });\n\n    const response = await request(app).get(\"/\");\n    expect(response.status).toBe(200);\n    expect(response.body).toEqual({ message: \"Ready to manage some TODOs!\" });\n  });\n});\n```\n\n### Layering overrides\n\n`pushFlagOverrides()` serves a different purpose: it adds a temporary layer on top of the base overrides and returns a remove function that removes only that layer. This is useful for nested tests:\n\n```typescript\nexport const flag = function (name: string, enabled: boolean): void {\n  let remove: (() => void) | undefined;\n\n  beforeEach(function () {\n    remove = reflagClient.pushFlagOverrides({ [name]: enabled });\n  });\n\n  afterEach(function () {\n    remove?.();\n    remove = undefined;\n  });\n};\n\ndescribe(\"foo\", () => {\n  describe(\"with new search ranking enabled\", () => {\n    flag(\"search-ranking-v2\", true);\n\n    describe(\"with summaries enabled\", () => {\n      flag(\"smart-summaries\", true);\n\n      // ...\n    });\n  });\n});\n```\n\nThe precedence is:\n\n1. Base overrides from the constructor or `setFlagOverrides()`\n2. Temporary layers added by `pushFlagOverrides()`\n\nIf the same flag is set in both places, the pushed override wins until its remove function is called.\n\n### Context dependent overrides\n\n`setFlagOverrides()` and `pushFlagOverrides()` also accept a function if the override depends on the evaluation context:\n\n```typescript\nconst remove = client.pushFlagOverrides((context) => ({\n  \"smart-summaries\": context.user?.id === \"qa-user\",\n}));\n\n// ...\n\nremove();\n```\n\n### Additional ways to provide flag overrides\n\nYou also have these additional ways to provide overrides, which can be helpful when testing out locally:\n\n1. Through environment variables:\n\n```bash\nREFLAG_FLAGS_ENABLED=flag1,flag2\nREFLAG_FLAGS_DISABLED=flag3,flag4\n```\n\n1. Through `reflag.config.json`:\n\n```json\n{\n  \"flagOverrides\": {\n    \"delete-todos\": {\n      \"isEnabled\": true,\n      \"config\": {\n        \"key\": \"dev-config\",\n        \"payload\": {\n          \"requireConfirmation\": true,\n          \"maxDeletionsPerDay\": 5\n        }\n      }\n    }\n  }\n}\n```\n\n## Remote Flag Evaluation\n\nIn addition to local flag evaluation, Reflag supports remote evaluation using stored context. This is useful when you want to evaluate flags using user/company attributes that were previously sent to Reflag:\n\n```typescript\n// First, update user and company attributes\nawait client.updateUser(\"user123\", {\n  attributes: {\n    role: \"admin\",\n    subscription: \"premium\",\n  },\n});\n\nawait client.updateCompany(\"company456\", {\n  attributes: {\n    tier: \"enterprise\",\n    employees: 1000,\n  },\n});\n\n// Later, evaluate flags remotely using stored context.\n// Note: the argument order is (userId, companyId, additionalContext?)\nconst userId = \"user123\";\nconst companyId = \"company456\";\n\nconst flags = await client.getFlagsRemote(userId, companyId);\n// Or evaluate a single flag\nconst flag = await client.getFlagRemote(\"create-todos\", userId, companyId);\n\n// You can also provide additional context\nconst flagsWithContext = await client.getFlagsRemote(userId, companyId, {\n  other: {\n    location: \"US\",\n    platform: \"mobile\",\n  },\n});\n```\n\nRemote evaluation is particularly useful when:\n\n- You want to use the most up-to-date user/company attributes stored in Reflag\n- You don't want to pass all context attributes with every evaluation\n- You need to ensure consistent flag evaluation across different services\n\n## Using with Express\n\nA popular way to integrate the Reflag Node.js SDK is through an express middleware.\n\n```typescript\nimport reflag from \"./reflag\";\nimport express from \"express\";\nimport { BoundReflagClient } from \"@reflag/node-sdk\";\n\n// Augment the Express types to include a `boundReflagClient` property on the\n// `res.locals` object.\n// This will allow us to access the ReflagClient instance in our route handlers\n// without having to pass it around manually\ndeclare global {\n  namespace Express {\n    interface Locals {\n      boundReflagClient: BoundReflagClient;\n    }\n  }\n}\n\n// Add express middleware\napp.use((req, res, next) => {\n  // Extract the user and company IDs from the request\n  // You'll want to use a proper authentication and identification\n  // mechanism in a real-world application\n  const user = {\n    id: req.user?.id,\n    name: req.user?.name,\n    email: req.user?.email\n  }\n\n  const company = {\n    id: req.user?.companyId,\n    name: req.user?.companyName\n  }\n\n  // Create a new BoundReflagClient instance by calling the `bindClient`\n  // method on a `ReflagClient` instance\n  // This will create a new instance that is bound to the user/company given.\n  const boundReflagClient = reflag.bindClient({ user, company });\n\n  // Store the BoundReflagClient instance in the `res.locals` object so we\n  // can access it in our route handlers\n  res.locals.boundReflagClient = boundReflagClient;\n  next();\n});\n\n// Now use res.locals.boundReflagClient in your handlers\napp.get(\"/todos\", async (_req, res) => {\n  const { track, isEnabled } = res.locals.boundReflagClient.getFlag(\"show-todos\");\n\n  if (!isEnabled) {\n    res.status(403).send({\"error\": \"flag inaccessible\"})\n    return\n  }\n\n  ...\n}\n```\n\nSee [examples/express/app.ts](https://github.com/reflagcom/javascript/tree/main/packages/node-sdk/example/express/app.ts) for a full example.\n\n## Remote flag evaluation with stored context\n\nIf you don't want to provide context each time when evaluating flags but\nrather you would like to utilize the attributes you sent to Reflag previously\n(by calling `updateCompany` and `updateUser`) you can do so by calling `getFlagsRemote`\n(or `getFlagRemote` for a specific flag) with just `userId` and `companyId`\nin that order.\nThese methods will call Reflag's servers and flags will be evaluated remotely\nusing the stored attributes.\n\n```typescript\n// Update user and company attributes\nclient.updateUser(\"john_doe\", {\n  attributes: {\n    name: \"John O.\",\n    role: \"admin\",\n  },\n});\n\nclient.updateCompany(\"acme_inc\", {\n  attributes: {\n    name: \"Acme, Inc\",\n    tier: \"premium\"\n  },\n});\n...\n\n// This will evaluate flags using the stored attributes for the user/company pair\nconst flags = await client.getFlagsRemote(\"john_doe\", \"acme_inc\");\n```\n\n> [!IMPORTANT]\n> User and company attribute updates are processed asynchronously, so there might\n> be a small delay between when attributes are updated and when they are available\n> for evaluation.\n\n## Opting out of tracking\n\nThere are use cases in which you not want to be sending `user`, `company` and\n`track` events to [Reflag.com](https://reflag.com). These are usually cases where you could be impersonating\nanother user in the system and do not want to interfere with the data being\ncollected by Reflag.\n\nTo disable tracking, bind the client using `bindClient()` as follows:\n\n```typescript\n// binds the client to a given user and company and set `enableTracking` to `false`.\nconst boundClient = client.bindClient({ user, company, enableTracking: false });\n\nboundClient.track(\"some event\"); // this will not actually send the event to Reflag.\n\n// the following code will not update the `user` nor `company` in Reflag and will\n// not send `track` events either.\nconst { isEnabled, track } = boundClient.getFlag(\"user-menu\");\nif (isEnabled) {\n  track();\n}\n```\n\nAnother way way to disable tracking without employing a bound client is to call `getFlag()`\nor `getFlags()` by supplying `enableTracking: false` in the arguments passed to\nthese functions.\n\n> [!IMPORTANT]\n> Note, however, that calling `track()`, `updateCompany()` or `updateUser()` in the `ReflagClient`\n> will still send tracking data. As such, it is always recommended to use `bindClient()`\n> when using this SDK.\n\n## Flushing\n\nReflagClient employs a batching technique to minimize the number of calls that are sent to\nReflag's servers.\n\nBy default, the SDK attempts to flush pending events when the Node.js event loop empties\n(the `beforeExit` event). This behavior is controlled by the `flushOnExit` option in the client configuration:\n\n```typescript\nconst client = new ReflagClient({\n  batchOptions: {\n    flushOnExit: false, // disable automatic flushing on exit\n  },\n});\n```\n\nNode.js does not emit `beforeExit` for unhandled termination signals (such as `SIGTERM` or\n`SIGINT`) or explicit `process.exit()` calls. For these shutdown paths, **await `client.flush()`\nin your application's existing graceful shutdown hook**, after stopping incoming work and\nwaiting for in-flight requests or jobs to finish, and before exiting. This ensures events\nproduced during shutdown are included. Automatic flushing is best-effort and does not replace\nan application-managed shutdown hook.\n\n## Tracking custom events and setting custom attributes\n\nTracking allows events and updating user/company attributes in Reflag.\nFor example, if a customer changes their plan, you'll want Reflag to know about it,\nin order to continue to provide up-do-date targeting information in the Reflag interface.\n\nThe following example shows how to register a new user, associate it with a company\nand finally update the plan they are on.\n\n```typescript\n// registers the user with Reflag using the provided unique ID, and\n// providing a set of custom attributes (can be anything)\nclient.updateUser(\"user_id\", {\n  attributes: { longTimeUser: true, payingCustomer: false },\n});\nclient.updateCompany(\"company_id\", { userId: \"user_id\" });\n\n// the user started a voice huddle\nclient.track(\"user_id\", \"huddle\", { attributes: { voice: true } });\n```\n\nIt's also possible to achieve the same through a bound client in the following manner:\n\n```typescript\nconst boundClient = client.bindClient({\n  user: { id: \"user_id\", longTimeUser: true, payingCustomer: false },\n  company: { id: \"company_id\" },\n});\n\nboundClient.track(\"huddle\", { attributes: { voice: true } });\n```\n\nSome attributes are used by Reflag to improve the UI, and are recommended\nto provide for easier navigation:\n\n- `name` -- display name for `user`/`company`,\n- `email` -- the email of the user,\n- `avatar` -- the URL for `user`/`company` avatar image.\n\nAttributes cannot be nested (multiple levels) and must be either strings,\nintegers or booleans.\n\n## Managing `Last seen`\n\nBy default `updateUser`/`updateCompany` calls automatically update the given\nuser/company `Last seen` property on Reflag servers.\n\nYou can control if `Last seen` should be updated when the events are sent by setting\n`meta.active = false`. This is often useful if you\nhave a background job that goes through a set of companies just to update their\nattributes but not their activity.\n\nExample:\n\n```typescript\nclient.updateUser(\"john_doe\", {\n  attributes: { name: \"John O.\" },\n  meta: { active: true },\n});\n\nclient.updateCompany(\"acme_inc\", {\n  attributes: { name: \"Acme, Inc\" },\n  meta: { active: false },\n});\n```\n\n`bindClient()` updates attributes on the Reflag servers but does not automatically\nupdate `Last seen`.\n\n## Zero PII\n\nThe Reflag SDK doesn't collect any metadata and HTTP IP addresses are _not_ being\nstored. For tracking individual users, we recommend using something like database\nID as userId, as it's unique and doesn't include any PII (personal identifiable\ninformation). If, however, you're using e.g. email address as userId, but prefer\nnot to send any PII to Reflag, you can hash the sensitive data before sending\nit to Reflag:\n\n```typescript\nimport { sha256 } from 'crypto-hash';\n\nclient.updateUser({ userId: await sha256(\"john_doe\"), ... });\n```\n\n## Migrating from Bucket SDK\n\nIf you have been using the Bucket SDKs previously, the following list will help you migrate to Reflag SDK:\n\n- `Bucket*` classes, and types have been renamed to `Reflag*` (e.g. `BucketClient` is now `ReflagClient`)\n- `Feature*` classes, and types have been renamed to `Flag*` (e.g. `Feature` is now `Flag`, `RawFeatures` is now `RawFlags`)\n- When using strongly-typed flags, the new `Flags` interface replaced `Features` interface\n- All methods that contained `feature` in the name have been renamed to use the `flag` terminology (e.g. `getFeature` is `getFlag`)\n- All environment variables that were prefixed with `BUCKET_` are now prefixed with `REFLAG_`\n- The `BUCKET_HOST` environment variable and `host` option have been removed from `ReflagClient` constructor, use `REFLAG_API_BASE_URL` instead\n- The `BUCKET_FEATURES_ENABLED` and `BUCKET_FEATURES_DISABLED` have been renamed to `REFLAG_FLAGS_ENABLED` and `REFLAG_FLAGS_DISABLED`\n- The default configuration file has been renamed from `bucketConfig.json` to `reflag.config.json`\n- The `fallbackFeatures` property in client constructor and configuration files has been renamed to `fallbackFlags`\n- `featureKey` has been renamed to `flagKey` in all methods that accepts that argument\n- The SDKs will not emit `evaluate` and `evaluate-config` events anymore\n\n## Typescript\n\nTypes are bundled together with the library and exposed automatically when importing\nthrough a package manager.\n\n## License\n\n> MIT License\n> Copyright (c) 2025 Bucket ApS\n","readmeFilename":"README.md"}