{"_id":"better-auth-streampay","_rev":"17-420c3ae309fad499a1490f5b283989c4","name":"better-auth-streampay","dist-tags":{"latest":"2.2.1"},"versions":{"0.1.0":{"name":"better-auth-streampay","version":"0.1.0","keywords":["better-auth","better-auth-plugin","streampay","stream-pay","payments","subscriptions","saudi-arabia","fintech"],"license":"MIT","_id":"better-auth-streampay@0.1.0","maintainers":[{"name":"ali-cooking","email":"ali77dhamen@hotmail.com"}],"homepage":"https://github.com/alidhamen/better-auth-streampay#readme","bugs":{"url":"https://github.com/alidhamen/better-auth-streampay/issues"},"dist":{"shasum":"2933fba69973d8eb432a19edea2b86b302934f18","tarball":"https://registry.npmjs.org/better-auth-streampay/-/better-auth-streampay-0.1.0.tgz","fileCount":17,"integrity":"sha512-Ek+3f9QfgcY0wE0XDUb5aY3Nc72BNFGW1aFyBeQq2bYsYKNc5eygBxdorlJXe/aLAKETbnR9Ed8aUqsRNWzQSA==","signatures":[{"sig":"MEUCIQCcrIadWkCY7O7we1AknmtbglJqf98S6avB9JPX2JrEPgIgPOIRrkd3sxeXxG1ex4kmXdWgrdehL4os1yC8zr2lo58=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":407601},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","engines":{"node":">=18"},"exports":{".":{"import":{"types":"./dist/index.d.ts","default":"./dist/index.js"},"require":{"types":"./dist/index.d.cts","default":"./dist/index.cjs"}},"./client":{"import":{"types":"./dist/client.d.ts","default":"./dist/client.js"},"require":{"types":"./dist/client.d.cts","default":"./dist/client.cjs"}}},"gitHead":"4369a3384150e7f10e0e44fb41b4078286cf38df","scripts":{"dev":"tsup --watch","lint":"biome check ./src ./tests","test":"vitest run","build":"tsup","format":"biome format --write ./src ./tests","typecheck":"tsc --noEmit","test:watch":"vitest","test:coverage":"vitest run --coverage"},"_npmUser":{"name":"ali-cooking","email":"ali77dhamen@hotmail.com"},"repository":{"url":"git+https://github.com/alidhamen/better-auth-streampay.git","type":"git"},"_npmVersion":"10.9.4","description":"Community Better Auth plugin for StreamPay — consumers, checkout, portal, subscriptions, and signed webhooks. Not affiliated with Stream.","directories":{},"sideEffects":false,"_nodeVersion":"22.21.1","_hasShrinkwrap":false,"devDependencies":{"msw":"^2.13.3","zod":"^4.3.6","tsup":"^8.5.1","vite":"^8.0.8","vitest":"^4.1.4","typescript":"^5.9.3","@types/node":"^25.6.0","better-auth":"^1.6.5","@biomejs/biome":"^2.4.12","@streamsdk/typescript":"^1.0.6"},"peerDependencies":{"zod":"^3.24.0 || ^4.0.0","better-auth":"^1.4.0","@streamsdk/typescript":"^1.0.6"},"_npmOperationalInternal":{"tmp":"tmp/better-auth-streampay_0.1.0_1776352498657_0.2025562068774247","host":"s3://npm-registry-packages-npm-production"}},"0.1.1":{"name":"better-auth-streampay","version":"0.1.1","keywords":["better-auth","better-auth-plugin","streampay","stream-pay","payments","subscriptions","saudi-arabia","fintech"],"license":"MIT","_id":"better-auth-streampay@0.1.1","maintainers":[{"name":"ali-cooking","email":"ali77dhamen@hotmail.com"}],"homepage":"https://github.com/alidhamen/better-auth-streampay#readme","bugs":{"url":"https://github.com/alidhamen/better-auth-streampay/issues"},"dist":{"shasum":"ae9f42be32347c653075c02c9ad2cac4a584fb48","tarball":"https://registry.npmjs.org/better-auth-streampay/-/better-auth-streampay-0.1.1.tgz","fileCount":17,"integrity":"sha512-dTwfPUsjuq9qy5tc/fbie/nYQvms66PgnTOpMipZmD2+j+gtqWNwJQH+eoBUihTVmSD0PKwE3eUiPag0dgT/bw==","signatures":[{"sig":"MEYCIQDcTOaNTx+Akq8PIIP074oACOn42EWg3MZmcL1u/UjpOQIhAIpzKr6i7E35NeJhzQUPo9mXVEgc0lydEN9eRt77yxfK","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":407601},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","engines":{"node":">=18"},"exports":{".":{"import":{"types":"./dist/index.d.ts","default":"./dist/index.js"},"require":{"types":"./dist/index.d.cts","default":"./dist/index.cjs"}},"./client":{"import":{"types":"./dist/client.d.ts","default":"./dist/client.js"},"require":{"types":"./dist/client.d.cts","default":"./dist/client.cjs"}}},"gitHead":"2f207429fc370d3a0c4b3e45837614472152582c","scripts":{"dev":"tsup --watch","lint":"biome check ./src ./tests","test":"vitest run","build":"tsup","format":"biome format --write ./src ./tests","typecheck":"tsc --noEmit","test:watch":"vitest","test:coverage":"vitest run --coverage"},"_npmUser":{"name":"ali-cooking","email":"ali77dhamen@hotmail.com"},"repository":{"url":"git+https://github.com/alidhamen/better-auth-streampay.git","type":"git"},"_npmVersion":"10.9.4","description":"Community Better Auth plugin for StreamPay — consumers, checkout, portal, subscriptions, and signed webhooks. Not affiliated with Stream.","directories":{},"sideEffects":false,"_nodeVersion":"22.21.1","_hasShrinkwrap":false,"devDependencies":{"msw":"^2.13.3","zod":"^4.3.6","tsup":"^8.5.1","vite":"^8.0.8","vitest":"^4.1.4","typescript":"^5.9.3","@types/node":"^25.6.0","better-auth":"^1.6.5","@biomejs/biome":"^2.4.12","@streamsdk/typescript":"^1.0.6"},"peerDependencies":{"zod":"^3.24.0 || ^4.0.0","better-auth":"^1.4.0","@streamsdk/typescript":"^1.0.6"},"_npmOperationalInternal":{"tmp":"tmp/better-auth-streampay_0.1.1_1776352747664_0.6131462886113728","host":"s3://npm-registry-packages-npm-production"}},"0.1.2":{"name":"better-auth-streampay","version":"0.1.2","keywords":["better-auth","better-auth-plugin","streampay","stream-pay","payments","subscriptions","saudi-arabia","fintech"],"license":"MIT","_id":"better-auth-streampay@0.1.2","maintainers":[{"name":"ali-cooking","email":"ali77dhamen@hotmail.com"}],"homepage":"https://github.com/y0u-0/better-auth-streampay#readme","bugs":{"url":"https://github.com/y0u-0/better-auth-streampay/issues"},"dist":{"shasum":"f7cfce94dd8d9026e19a948b077e0b07ec1cb7c7","tarball":"https://registry.npmjs.org/better-auth-streampay/-/better-auth-streampay-0.1.2.tgz","fileCount":17,"integrity":"sha512-ghYCtmxn2ymI/vs7REGek5T10IqbTejTb+Iw6xvO4EPFWDS+r7aQcPgz1v83M+oPg3jshbqNeAzK31WMoCZc5g==","signatures":[{"sig":"MEUCIBVhp+SyJpk1LRY/DpnagVymD+mFMDZq/27NvsJM8Jh7AiEAozbpNQexy9NdZO0Wfjf84fDSd2qPR9bKFNYXHvl8bR4=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":407597},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","engines":{"node":">=18"},"exports":{".":{"import":{"types":"./dist/index.d.ts","default":"./dist/index.js"},"require":{"types":"./dist/index.d.cts","default":"./dist/index.cjs"}},"./client":{"import":{"types":"./dist/client.d.ts","default":"./dist/client.js"},"require":{"types":"./dist/client.d.cts","default":"./dist/client.cjs"}}},"gitHead":"80e51afb46a0b9cd718d8c6f50c1bba3778d6c51","scripts":{"dev":"tsup --watch","lint":"biome check ./src ./tests","test":"vitest run","build":"tsup","format":"biome format --write ./src ./tests","typecheck":"tsc --noEmit","test:watch":"vitest","test:coverage":"vitest run --coverage"},"_npmUser":{"name":"ali-cooking","email":"ali77dhamen@hotmail.com"},"repository":{"url":"git+https://github.com/y0u-0/better-auth-streampay.git","type":"git"},"_npmVersion":"10.9.4","description":"Community Better Auth plugin for StreamPay — consumers, checkout, portal, subscriptions, and signed webhooks. Not affiliated with Stream.","directories":{},"sideEffects":false,"_nodeVersion":"22.21.1","_hasShrinkwrap":false,"devDependencies":{"msw":"^2.13.3","zod":"^4.3.6","tsup":"^8.5.1","vite":"^8.0.8","vitest":"^4.1.4","typescript":"^5.9.3","@types/node":"^25.6.0","better-auth":"^1.6.5","@biomejs/biome":"^2.4.12","@streamsdk/typescript":"^1.0.6"},"peerDependencies":{"zod":"^3.24.0 || ^4.0.0","better-auth":"^1.4.0","@streamsdk/typescript":"^1.0.6"},"_npmOperationalInternal":{"tmp":"tmp/better-auth-streampay_0.1.2_1776353761847_0.5294834413257159","host":"s3://npm-registry-packages-npm-production"}},"0.1.3":{"name":"better-auth-streampay","version":"0.1.3","keywords":["better-auth","better-auth-plugin","streampay","stream-pay","payments","subscriptions","saudi-arabia","fintech"],"license":"MIT","_id":"better-auth-streampay@0.1.3","maintainers":[{"name":"ali-cooking","email":"ali77dhamen@hotmail.com"}],"homepage":"https://github.com/y0u-0/better-auth-streampay#readme","bugs":{"url":"https://github.com/y0u-0/better-auth-streampay/issues"},"dist":{"shasum":"b58bd5b99484cc2d8588b065b824b6bdd3e4732e","tarball":"https://registry.npmjs.org/better-auth-streampay/-/better-auth-streampay-0.1.3.tgz","fileCount":17,"integrity":"sha512-u3Eqn8tnN3gKCCNDlWanGEfuNBLHyF2zttYM56RoTYrKlXDa0vVNURh2ndkt4c2g1p795OoZq9F0uicNM+i/hA==","signatures":[{"sig":"MEYCIQDRo+SELayIRM1/UPUHNljSPxL/dAsdwofl7rJe2yJM7gIhAI9xIX/iHxdImAIhPTsqSdUMA6p9vn97wQ23F2txMYxj","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":409103},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","engines":{"node":">=18"},"exports":{".":{"import":{"types":"./dist/index.d.ts","default":"./dist/index.js"},"require":{"types":"./dist/index.d.cts","default":"./dist/index.cjs"}},"./client":{"import":{"types":"./dist/client.d.ts","default":"./dist/client.js"},"require":{"types":"./dist/client.d.cts","default":"./dist/client.cjs"}}},"gitHead":"dc31f14fe8881aaa328d48cf5e41cddebbaade2e","scripts":{"dev":"tsup --watch","lint":"biome check ./src ./tests","test":"vitest run","build":"tsup","format":"biome format --write ./src ./tests","typecheck":"tsc --noEmit","test:watch":"vitest","test:coverage":"vitest run --coverage"},"_npmUser":{"name":"ali-cooking","email":"ali77dhamen@hotmail.com"},"repository":{"url":"git+https://github.com/y0u-0/better-auth-streampay.git","type":"git"},"_npmVersion":"10.9.4","description":"Community Better Auth plugin for StreamPay — consumers, checkout, portal, subscriptions, and signed webhooks. Not affiliated with Stream.","directories":{},"sideEffects":false,"_nodeVersion":"22.21.1","_hasShrinkwrap":false,"devDependencies":{"msw":"^2.13.3","zod":"^4.3.6","tsup":"^8.5.1","vite":"^8.0.8","vitest":"^4.1.4","typescript":"^5.9.3","@types/node":"^25.6.0","better-auth":"^1.6.5","@biomejs/biome":"^2.4.12","@streamsdk/typescript":"^1.0.6"},"peerDependencies":{"zod":"^3.24.0 || ^4.0.0","better-auth":"^1.4.0","@streamsdk/typescript":"^1.0.6"},"_npmOperationalInternal":{"tmp":"tmp/better-auth-streampay_0.1.3_1776355785578_0.9266402776950957","host":"s3://npm-registry-packages-npm-production"}},"0.1.4":{"name":"better-auth-streampay","version":"0.1.4","keywords":["better-auth","better-auth-plugin","streampay","stream-pay","payments","subscriptions","saudi-arabia","fintech"],"license":"MIT","_id":"better-auth-streampay@0.1.4","maintainers":[{"name":"ali-cooking","email":"ali77dhamen@hotmail.com"}],"homepage":"https://github.com/y0u-0/better-auth-streampay#readme","bugs":{"url":"https://github.com/y0u-0/better-auth-streampay/issues"},"dist":{"shasum":"cb95641ce9fb7272c8044f36952bcd10cf6094d6","tarball":"https://registry.npmjs.org/better-auth-streampay/-/better-auth-streampay-0.1.4.tgz","fileCount":17,"integrity":"sha512-lKjrw46Au2Bc+ErxB0cEYr1qZJ94AhP61AGgJrkRqKM1PsyiynTGnpgOKpphUI1G4FGQKnfoyy053ZX1ZRFyFg==","signatures":[{"sig":"MEQCIE6SpkmFdLmuEy5ODaUHd1PLfG8AjDcQUFUoWclR/ITOAiBsa86OUTPtQPNqayH0MAAQXYM4loEFO11SdEGnvPVPQw==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":409945},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","engines":{"node":">=18"},"exports":{".":{"import":{"types":"./dist/index.d.ts","default":"./dist/index.js"},"require":{"types":"./dist/index.d.cts","default":"./dist/index.cjs"}},"./client":{"import":{"types":"./dist/client.d.ts","default":"./dist/client.js"},"require":{"types":"./dist/client.d.cts","default":"./dist/client.cjs"}}},"gitHead":"4f79a5cd1c0c06d6a2cdab1a78148292ce7dbee7","scripts":{"dev":"tsup --watch","lint":"biome check ./src ./tests","test":"vitest run","build":"tsup","format":"biome format --write ./src ./tests","typecheck":"tsc --noEmit","test:watch":"vitest","test:coverage":"vitest run --coverage"},"_npmUser":{"name":"ali-cooking","email":"ali77dhamen@hotmail.com"},"repository":{"url":"git+https://github.com/y0u-0/better-auth-streampay.git","type":"git"},"_npmVersion":"10.9.4","description":"Community Better Auth plugin for StreamPay — consumers, checkout, portal, subscriptions, and signed webhooks. Not affiliated with Stream.","directories":{},"sideEffects":false,"_nodeVersion":"22.21.1","_hasShrinkwrap":false,"devDependencies":{"msw":"^2.13.3","zod":"^4.3.6","tsup":"^8.5.1","vite":"^8.0.8","vitest":"^4.1.4","typescript":"^5.9.3","@types/node":"^25.6.0","better-auth":"^1.6.5","@biomejs/biome":"^2.4.12","@streamsdk/typescript":"^1.0.6"},"peerDependencies":{"zod":"^3.24.0 || ^4.0.0","better-auth":"^1.4.0","@streamsdk/typescript":"^1.0.6"},"_npmOperationalInternal":{"tmp":"tmp/better-auth-streampay_0.1.4_1776433948920_0.380894995825404","host":"s3://npm-registry-packages-npm-production"}},"0.1.5":{"name":"better-auth-streampay","version":"0.1.5","keywords":["better-auth","better-auth-plugin","streampay","stream-pay","payments","subscriptions","saudi-arabia","fintech"],"license":"MIT","_id":"better-auth-streampay@0.1.5","maintainers":[{"name":"ali-cooking","email":"ali77dhamen@hotmail.com"}],"homepage":"https://github.com/y0u-0/better-auth-streampay#readme","bugs":{"url":"https://github.com/y0u-0/better-auth-streampay/issues"},"dist":{"shasum":"731b2b19ddc16f65f4da3c323ae7dd3488f8c222","tarball":"https://registry.npmjs.org/better-auth-streampay/-/better-auth-streampay-0.1.5.tgz","fileCount":17,"integrity":"sha512-XnNaKvbiOI2NA3u0ljaaNyB1vddZIA6eQWb9B+DZRSFrrGoWnUNxr3XOCUuXOnGFhj1C/qbQWsA2YKSjv6K14A==","signatures":[{"sig":"MEUCIFIBQAzjSxk/jhQXKn/6NcTLNVi9D3Mx8JFvJu7eqlAcAiEAnyN3f4KaquRIFN21Jf+5Psub8zyKPJ/AhcIdrVIsFZA=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":418657},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","engines":{"node":">=18"},"exports":{".":{"import":{"types":"./dist/index.d.ts","default":"./dist/index.js"},"require":{"types":"./dist/index.d.cts","default":"./dist/index.cjs"}},"./client":{"import":{"types":"./dist/client.d.ts","default":"./dist/client.js"},"require":{"types":"./dist/client.d.cts","default":"./dist/client.cjs"}}},"gitHead":"abfee07dbd28c705e1eb08777184e0ba2ecb420e","scripts":{"dev":"tsup --watch","lint":"biome check ./src ./tests","test":"vitest run","build":"tsup","format":"biome format --write ./src ./tests","typecheck":"tsc --noEmit","test:watch":"vitest","test:coverage":"vitest run --coverage"},"_npmUser":{"name":"ali-cooking","email":"ali77dhamen@hotmail.com"},"repository":{"url":"git+https://github.com/y0u-0/better-auth-streampay.git","type":"git"},"_npmVersion":"10.9.4","description":"Community Better Auth plugin for StreamPay — consumers, checkout, portal, subscriptions, and signed webhooks. Not affiliated with Stream.","directories":{},"sideEffects":false,"_nodeVersion":"22.21.1","_hasShrinkwrap":false,"devDependencies":{"msw":"^2.13.3","zod":"^4.3.6","tsup":"^8.5.1","vite":"^8.0.8","vitest":"^4.1.4","typescript":"^5.9.3","@types/node":"^25.6.0","better-auth":"^1.6.5","@biomejs/biome":"^2.4.12","@streamsdk/typescript":"^1.0.6"},"peerDependencies":{"zod":"^3.24.0 || ^4.0.0","better-auth":"^1.4.0","@streamsdk/typescript":"^1.0.6"},"_npmOperationalInternal":{"tmp":"tmp/better-auth-streampay_0.1.5_1776435601726_0.72394779733906","host":"s3://npm-registry-packages-npm-production"}},"0.2.0":{"name":"better-auth-streampay","version":"0.2.0","keywords":["better-auth","better-auth-plugin","streampay","stream-pay","payments","subscriptions","saudi-arabia","fintech"],"license":"MIT","_id":"better-auth-streampay@0.2.0","maintainers":[{"name":"ali-cooking","email":"ali77dhamen@hotmail.com"}],"homepage":"https://github.com/y0u-0/better-auth-streampay#readme","bugs":{"url":"https://github.com/y0u-0/better-auth-streampay/issues"},"dist":{"shasum":"12e55abe45d858a6c2e3a7a315691b3e4ddefa94","tarball":"https://registry.npmjs.org/better-auth-streampay/-/better-auth-streampay-0.2.0.tgz","fileCount":17,"integrity":"sha512-/M5nU2Hr9nI8DXDrDQqlyyQ/uulDPPjgUsZkorpoXKD357rrTmwqngTgqC0xx/pqurOHA2miF+jdyc2gCBPrAw==","signatures":[{"sig":"MEYCIQDwSwu1B9W8jyX897t4Xn/c6y8dIf+xRtTofZJBaJissQIhAKTxnhGuzjS3RBxZ/11s8Kk6K5D4YnyFy25UeX0qxB5v","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":419016},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","engines":{"node":">=18"},"exports":{".":{"import":{"types":"./dist/index.d.ts","default":"./dist/index.js"},"require":{"types":"./dist/index.d.cts","default":"./dist/index.cjs"}},"./client":{"import":{"types":"./dist/client.d.ts","default":"./dist/client.js"},"require":{"types":"./dist/client.d.cts","default":"./dist/client.cjs"}}},"gitHead":"37c3d49c1a3c4f2819a3e9692f59d95ae823cdc5","scripts":{"dev":"tsup --watch","lint":"biome check ./src ./tests","test":"vitest run","build":"tsup","format":"biome format --write ./src ./tests","typecheck":"tsc --noEmit","test:watch":"vitest","test:coverage":"vitest run --coverage","prepublishOnly":"bun run build && bun run typecheck"},"_npmUser":{"name":"ali-cooking","email":"ali77dhamen@hotmail.com"},"repository":{"url":"git+https://github.com/y0u-0/better-auth-streampay.git","type":"git"},"_npmVersion":"10.9.4","description":"Community Better Auth plugin for StreamPay — consumers, checkout, portal, subscriptions, and signed webhooks. Not affiliated with Stream.","directories":{},"sideEffects":false,"_nodeVersion":"22.21.1","_hasShrinkwrap":false,"devDependencies":{"msw":"^2.13.3","zod":"^4.3.6","tsup":"^8.5.1","vite":"^8.0.8","vitest":"^4.1.4","typescript":"^5.9.3","@types/node":"^25.6.0","better-auth":"^1.6.5","@biomejs/biome":"^2.4.12","@streamsdk/typescript":"^1.0.6"},"peerDependencies":{"zod":"^3.24.0 || ^4.0.0","better-auth":"^1.4.0","@streamsdk/typescript":"^1.0.6"},"_npmOperationalInternal":{"tmp":"tmp/better-auth-streampay_0.2.0_1776459037098_0.6971255110083645","host":"s3://npm-registry-packages-npm-production"}},"1.0.0":{"name":"better-auth-streampay","version":"1.0.0","keywords":["better-auth","better-auth-plugin","streampay","stream-pay","payments","subscriptions","saudi-arabia","fintech"],"license":"MIT","_id":"better-auth-streampay@1.0.0","maintainers":[{"name":"ali-cooking","email":"ali77dhamen@hotmail.com"}],"homepage":"https://github.com/Genie-sa/better-auth-streampay#readme","bugs":{"url":"https://github.com/Genie-sa/better-auth-streampay/issues"},"dist":{"shasum":"0f60565aafeee6481f61108bafce19b74d1c5aef","tarball":"https://registry.npmjs.org/better-auth-streampay/-/better-auth-streampay-1.0.0.tgz","fileCount":17,"integrity":"sha512-Phgguu8faV8/Uyphk4306VykBUS/hFIwjk9Ju6D+XcenkZXAV19UqRzkmzi9zzhoKuyKJbI8AB2CuuX0pioo0g==","signatures":[{"sig":"MEYCIQD9aXkWlL00ObtMVjz8ASN+6cFeCvULQ7ePrOmEPie4rAIhAI0tiuB8g1tD3tPhLBB+n5PyblTJhaw/OXKPoHboiQ8c","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":490741},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","engines":{"node":">=18"},"exports":{".":{"import":{"types":"./dist/index.d.ts","default":"./dist/index.js"},"require":{"types":"./dist/index.d.cts","default":"./dist/index.cjs"}},"./client":{"import":{"types":"./dist/client.d.ts","default":"./dist/client.js"},"require":{"types":"./dist/client.d.cts","default":"./dist/client.cjs"}}},"gitHead":"73ca68e101e8833310f5822c13f212e708aa92b6","scripts":{"dev":"tsup --watch","lint":"biome check ./src ./tests","test":"vitest run","build":"tsup","format":"biome format --write ./src ./tests","typecheck":"tsc --noEmit","test:watch":"vitest","test:coverage":"vitest run --coverage","prepublishOnly":"bun run build && bun run typecheck"},"_npmUser":{"name":"ali-cooking","email":"ali77dhamen@hotmail.com"},"repository":{"url":"git+https://github.com/Genie-sa/better-auth-streampay.git","type":"git"},"_npmVersion":"10.9.4","description":"Community Better Auth plugin for StreamPay — consumers, checkout, portal, subscriptions, and signed webhooks. Not affiliated with Stream.","directories":{},"sideEffects":false,"_nodeVersion":"22.21.1","_hasShrinkwrap":false,"devDependencies":{"msw":"^2.13.3","zod":"^4.3.6","tsup":"^8.5.1","vite":"^8.0.8","vitest":"^4.1.4","typescript":"^5.9.3","@types/node":"^25.6.0","better-auth":"^1.6.5","@biomejs/biome":"^2.4.12","@streamsdk/typescript":"^1.0.6"},"peerDependencies":{"zod":"^3.24.0 || ^4.0.0","better-auth":"^1.4.0","@streamsdk/typescript":"^1.0.6"},"_npmOperationalInternal":{"tmp":"tmp/better-auth-streampay_1.0.0_1776629148781_0.6745164215408299","host":"s3://npm-registry-packages-npm-production"}},"1.1.5":{"name":"better-auth-streampay","version":"1.1.5","keywords":["better-auth","better-auth-plugin","streampay","stream-pay","payments","subscriptions","saudi-arabia","fintech"],"license":"MIT","_id":"better-auth-streampay@1.1.5","maintainers":[{"name":"ali-cooking","email":"ali77dhamen@hotmail.com"}],"homepage":"https://github.com/Genie-sa/better-auth-streampay#readme","bugs":{"url":"https://github.com/Genie-sa/better-auth-streampay/issues"},"dist":{"shasum":"dd5fca8360dfcebf661e8ded79edd99cc0fca235","tarball":"https://registry.npmjs.org/better-auth-streampay/-/better-auth-streampay-1.1.5.tgz","fileCount":17,"integrity":"sha512-dnbqY6uOSGXGBsfMSc3tFleKUOokEb1x2z2j+djDRiSsCtWe5RhkHkEecOrJ4BPmBIxQFtEyVyKekN72nmh7mg==","signatures":[{"sig":"MEUCIBZEO6pZJLnnj2EzbhNyvMOted6fmsTgxvS8vWhHqUk8AiEA2R0+WuKrRHKPF1p9s5tKs9bdQD6a8eGbiKJZrYQ+mow=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":1652028},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","engines":{"node":">=18"},"exports":{".":{"import":{"types":"./dist/index.d.ts","default":"./dist/index.js"},"require":{"types":"./dist/index.d.cts","default":"./dist/index.cjs"}},"./client":{"import":{"types":"./dist/client.d.ts","default":"./dist/client.js"},"require":{"types":"./dist/client.d.cts","default":"./dist/client.cjs"}}},"gitHead":"7eefe3c97d3c44bf6109e7edd91987292788464b","scripts":{"dev":"tsup --watch","lint":"biome check ./src ./tests","test":"vitest run --exclude tests/live/**/*.test.ts","build":"tsup","format":"biome format --write ./src ./tests","prepare":"lefthook install","test:live":"STREAMPAY_LIVE=1 vitest run tests/live/**/*.test.ts","typecheck":"tsc --noEmit","test:watch":"vitest --exclude tests/live/**/*.test.ts","test:coverage":"vitest run --coverage --exclude tests/live/**/*.test.ts","prepublishOnly":"pnpm run build && pnpm run typecheck","test:live:write":"STREAMPAY_LIVE=1 STREAMPAY_LIVE_WRITE=1 vitest run tests/live/**/*.test.ts"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:5e49ccb1-1028-450b-8157-c9f1cab973b7"}},"repository":{"url":"git+https://github.com/Genie-sa/better-auth-streampay.git","type":"git"},"_npmVersion":"11.11.0","description":"Community Better Auth plugin for StreamPay — consumers, checkout, portal, subscriptions, and signed webhooks. Not affiliated with Stream.","directories":{},"sideEffects":false,"_nodeVersion":"24.14.1","_hasShrinkwrap":false,"devDependencies":{"msw":"^2.13.3","zod":"^4.3.6","tsup":"^8.5.1","vite":"^8.0.8","vitest":"^4.1.4","lefthook":"^2.1.6","typescript":"^5.9.3","@types/node":"^25.6.0","better-auth":"^1.6.5","@biomejs/biome":"^2.4.12","@streamsdk/typescript":"^1.0.6"},"peerDependencies":{"zod":"^3.24.0 || ^4.0.0","better-auth":"^1.4.0","@streamsdk/typescript":"^1.0.6"},"_npmOperationalInternal":{"tmp":"tmp/better-auth-streampay_1.1.5_1777155174680_0.12060581470750154","host":"s3://npm-registry-packages-npm-production"}},"1.1.6":{"name":"better-auth-streampay","version":"1.1.6","keywords":["better-auth","better-auth-plugin","streampay","stream-pay","payments","subscriptions","saudi-arabia","fintech"],"license":"MIT","_id":"better-auth-streampay@1.1.6","maintainers":[{"name":"ali-cooking","email":"ali77dhamen@hotmail.com"}],"homepage":"https://github.com/Genie-sa/better-auth-streampay#readme","bugs":{"url":"https://github.com/Genie-sa/better-auth-streampay/issues"},"dist":{"shasum":"2f0f85631e92a42b941e5e5c82e358989ba3f087","tarball":"https://registry.npmjs.org/better-auth-streampay/-/better-auth-streampay-1.1.6.tgz","fileCount":17,"integrity":"sha512-2vvVQqbjcWr2RSG+cwuZGy7gjCr8M7rXe6zMf/Is5N6Au5BTm3KgDJQNYQY0UzDuRXI2HLTI7fSsLvBX9VHQOw==","signatures":[{"sig":"MEQCIGTaALi6TpK7En9YuqB9VPl8ELsNl+KKoJ5hO3T+6Z7uAiBNdNteZw3xwm8G6U8tmqGt98uc5Hwwkvmq0Z0aA9VlPg==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":1657056},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","engines":{"node":">=18"},"exports":{".":{"import":{"types":"./dist/index.d.ts","default":"./dist/index.js"},"require":{"types":"./dist/index.d.cts","default":"./dist/index.cjs"}},"./client":{"import":{"types":"./dist/client.d.ts","default":"./dist/client.js"},"require":{"types":"./dist/client.d.cts","default":"./dist/client.cjs"}}},"gitHead":"b9db71724ded3f9aa5d3353dbfc08248a29592d3","scripts":{"dev":"tsup --watch","lint":"biome check ./src ./tests","test":"vitest run --exclude tests/live/**/*.test.ts","build":"tsup","format":"biome format --write ./src ./tests","prepare":"lefthook install","test:live":"STREAMPAY_LIVE=1 vitest run tests/live/**/*.test.ts","typecheck":"tsc --noEmit","test:watch":"vitest --exclude tests/live/**/*.test.ts","test:coverage":"vitest run --coverage --exclude tests/live/**/*.test.ts","prepublishOnly":"pnpm run build && pnpm run typecheck","test:live:write":"STREAMPAY_LIVE=1 STREAMPAY_LIVE_WRITE=1 vitest run tests/live/**/*.test.ts"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:5e49ccb1-1028-450b-8157-c9f1cab973b7"}},"repository":{"url":"git+https://github.com/Genie-sa/better-auth-streampay.git","type":"git"},"_npmVersion":"11.11.0","description":"Community Better Auth plugin for StreamPay — consumers, checkout, portal, subscriptions, and signed webhooks. Not affiliated with Stream.","directories":{},"sideEffects":false,"_nodeVersion":"24.14.1","_hasShrinkwrap":false,"devDependencies":{"msw":"^2.13.3","zod":"^4.3.6","tsup":"^8.5.1","vite":"^8.0.8","vitest":"^4.1.4","lefthook":"^2.1.6","pkg-pr-new":"^0.0.66","typescript":"^5.9.3","@types/node":"^25.6.0","better-auth":"^1.6.5","@biomejs/biome":"^2.4.12","@streamsdk/typescript":"^1.0.6"},"peerDependencies":{"zod":"^3.24.0 || ^4.0.0","better-auth":"^1.4.0","@streamsdk/typescript":"^1.0.6"},"_npmOperationalInternal":{"tmp":"tmp/better-auth-streampay_1.1.6_1777675212297_0.3272604263342094","host":"s3://npm-registry-packages-npm-production"}},"1.2.0":{"name":"better-auth-streampay","version":"1.2.0","keywords":["better-auth","better-auth-plugin","streampay","stream-pay","payments","subscriptions","saudi-arabia","fintech"],"license":"MIT","_id":"better-auth-streampay@1.2.0","maintainers":[{"name":"ali-cooking","email":"ali77dhamen@hotmail.com"}],"homepage":"https://github.com/Genie-sa/better-auth-streampay#readme","bugs":{"url":"https://github.com/Genie-sa/better-auth-streampay/issues"},"dist":{"shasum":"92f4b32e64c9247a45fcaa18b514400e5f3cd3e5","tarball":"https://registry.npmjs.org/better-auth-streampay/-/better-auth-streampay-1.2.0.tgz","fileCount":17,"integrity":"sha512-jwSeG+SL/0pvGQMJsjp+H1RshlSU9zCjSdMKmU2rzvIaQuNurOE3Ibfh6/hu+PuX8ixch9B5eSP0Gh1OgC2KGA==","signatures":[{"sig":"MEQCIAgOsjvz2AlXo42r0zI/pX6pDaGPGp/kFJczJj0F4Iz6AiAMiga3nTzMOJdqAbK9XQM3k+FoFctkf4w+ZMpCouTZhg==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":1753208},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","engines":{"node":">=18"},"exports":{".":{"import":{"types":"./dist/index.d.ts","default":"./dist/index.js"},"require":{"types":"./dist/index.d.cts","default":"./dist/index.cjs"}},"./client":{"import":{"types":"./dist/client.d.ts","default":"./dist/client.js"},"require":{"types":"./dist/client.d.cts","default":"./dist/client.cjs"}}},"gitHead":"d3faa0a74a0bb8d86432588073088e2c64a1225c","scripts":{"dev":"tsup --watch","lint":"biome check ./src ./tests","test":"vitest run --exclude tests/live/**/*.test.ts","build":"tsup","format":"biome format --write ./src ./tests","prepare":"lefthook install","test:live":"STREAMPAY_LIVE=1 vitest run tests/live/**/*.test.ts","typecheck":"tsc --noEmit","test:watch":"vitest --exclude tests/live/**/*.test.ts","test:coverage":"vitest run --coverage --exclude tests/live/**/*.test.ts","prepublishOnly":"pnpm run build && pnpm run typecheck","test:live:write":"STREAMPAY_LIVE=1 STREAMPAY_LIVE_WRITE=1 vitest run tests/live/**/*.test.ts"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:5e49ccb1-1028-450b-8157-c9f1cab973b7"}},"repository":{"url":"git+https://github.com/Genie-sa/better-auth-streampay.git","type":"git"},"_npmVersion":"11.11.0","description":"Community Better Auth plugin for StreamPay — consumers, checkout, portal, subscriptions, and signed webhooks. Not affiliated with Stream.","directories":{},"sideEffects":false,"_nodeVersion":"24.14.1","_hasShrinkwrap":false,"devDependencies":{"msw":"^2.13.3","zod":"^4.3.6","tsup":"^8.5.1","vite":"^8.0.8","vitest":"^4.1.4","lefthook":"^2.1.6","pkg-pr-new":"^0.0.66","typescript":"^5.9.3","@types/node":"^25.6.0","better-auth":"^1.6.5","@biomejs/biome":"^2.4.12","@streamsdk/typescript":"^1.0.6"},"peerDependencies":{"zod":"^3.24.0 || ^4.0.0","better-auth":"^1.4.0","@streamsdk/typescript":"^1.0.6"},"_npmOperationalInternal":{"tmp":"tmp/better-auth-streampay_1.2.0_1777749014743_0.833492036859663","host":"s3://npm-registry-packages-npm-production"}},"1.2.1":{"name":"better-auth-streampay","version":"1.2.1","keywords":["better-auth","better-auth-plugin","streampay","stream-pay","payments","subscriptions","saudi-arabia","fintech"],"license":"MIT","_id":"better-auth-streampay@1.2.1","maintainers":[{"name":"ali-cooking","email":"ali77dhamen@hotmail.com"}],"homepage":"https://github.com/Genie-sa/better-auth-streampay#readme","bugs":{"url":"https://github.com/Genie-sa/better-auth-streampay/issues"},"dist":{"shasum":"6189c60d0c5edcc5a5689966661eddb894e7c0ad","tarball":"https://registry.npmjs.org/better-auth-streampay/-/better-auth-streampay-1.2.1.tgz","fileCount":17,"integrity":"sha512-pnsRfvd1ZFbwGivCZjxkbUxBwPAXPau+121S79KvcnNwx9/aCnDFJVktO0ye0CFnwulQpEO8l2uOzj+DVM/YeA==","signatures":[{"sig":"MEQCIC2fFLBgCkrUI0AiwFR2o+BP+GK14H1tVVoHV06LzCs7AiBqpqEk9Hi+0OcYtfkWe9dgyvlQ1ssL3R8gchlvTinc4g==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":1765370},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","engines":{"node":">=18"},"exports":{".":{"import":{"types":"./dist/index.d.ts","default":"./dist/index.js"},"require":{"types":"./dist/index.d.cts","default":"./dist/index.cjs"}},"./client":{"import":{"types":"./dist/client.d.ts","default":"./dist/client.js"},"require":{"types":"./dist/client.d.cts","default":"./dist/client.cjs"}}},"gitHead":"58f6aa78ea844014f4b0ca97e8263479ccae5d9e","scripts":{"dev":"tsup --watch","lint":"biome check ./src ./tests","test":"vitest run --exclude tests/live/**/*.test.ts","build":"tsup","format":"biome format --write ./src ./tests","prepare":"lefthook install","test:live":"STREAMPAY_LIVE=1 vitest run tests/live/**/*.test.ts","typecheck":"tsc --noEmit","test:watch":"vitest --exclude tests/live/**/*.test.ts","test:coverage":"vitest run --coverage --exclude tests/live/**/*.test.ts","prepublishOnly":"pnpm run build && pnpm run typecheck","test:live:write":"STREAMPAY_LIVE=1 STREAMPAY_LIVE_WRITE=1 vitest run tests/live/**/*.test.ts"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:5e49ccb1-1028-450b-8157-c9f1cab973b7"}},"repository":{"url":"git+https://github.com/Genie-sa/better-auth-streampay.git","type":"git"},"_npmVersion":"11.12.1","description":"Community Better Auth plugin for StreamPay — consumers, checkout, portal, subscriptions, and signed webhooks. Not affiliated with Stream.","directories":{},"sideEffects":false,"_nodeVersion":"24.15.0","_hasShrinkwrap":false,"devDependencies":{"msw":"^2.13.3","zod":"^4.3.6","tsup":"^8.5.1","vite":"^8.0.8","vitest":"^4.1.4","lefthook":"^2.1.6","pkg-pr-new":"^0.0.66","typescript":"^5.9.3","@types/node":"^25.6.0","better-auth":"^1.6.5","@biomejs/biome":"^2.4.12","@streamsdk/typescript":"^1.0.6"},"peerDependencies":{"zod":"^3.24.0 || ^4.0.0","better-auth":"^1.4.0","@streamsdk/typescript":"^1.0.6"},"_npmOperationalInternal":{"tmp":"tmp/better-auth-streampay_1.2.1_1778787902640_0.20003280405436863","host":"s3://npm-registry-packages-npm-production"}},"1.3.0":{"name":"better-auth-streampay","version":"1.3.0","keywords":["better-auth","better-auth-plugin","streampay","stream-pay","payments","subscriptions","saudi-arabia","fintech"],"license":"MIT","_id":"better-auth-streampay@1.3.0","maintainers":[{"name":"ali-cooking","email":"ali77dhamen@hotmail.com"}],"homepage":"https://github.com/Genie-sa/better-auth-streampay#readme","bugs":{"url":"https://github.com/Genie-sa/better-auth-streampay/issues"},"dist":{"shasum":"c45097853c7341b7f78ec73442be721b5fa11464","tarball":"https://registry.npmjs.org/better-auth-streampay/-/better-auth-streampay-1.3.0.tgz","fileCount":17,"integrity":"sha512-G3/X6IHGkn9qZ/0Be9W3X6KmRb9t1O4KuDncbL42wAxAx0n+aCPxfB2JGJ46Jj35bRiMvwuk38v/BBGYZFWjaw==","signatures":[{"sig":"MEQCIC/eEa1UlvKEwsPCCxK+L9508WzeNaf7nT/xDWqJqTIIAiBrmF+SUbp4VmrMsWF2OMu4NYeBYBl/NL6POVjjp8GPIw==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":1678802},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","engines":{"node":">=18"},"exports":{".":{"import":{"types":"./dist/index.d.ts","default":"./dist/index.js"},"require":{"types":"./dist/index.d.cts","default":"./dist/index.cjs"}},"./client":{"import":{"types":"./dist/client.d.ts","default":"./dist/client.js"},"require":{"types":"./dist/client.d.cts","default":"./dist/client.cjs"}}},"gitHead":"139a43656904a8a5e6a7799588d626178ea22b8a","scripts":{"dev":"tsup --watch","lint":"biome check ./src ./tests","test":"vitest run --exclude tests/live/**/*.test.ts","build":"tsup","format":"biome format --write ./src ./tests","prepare":"lefthook install","test:live":"STREAMPAY_LIVE=1 vitest run tests/live","typecheck":"tsc --noEmit","test:watch":"vitest --exclude tests/live/**/*.test.ts","test:coverage":"vitest run --coverage --exclude tests/live/**/*.test.ts","prepublishOnly":"pnpm run build && pnpm run typecheck","test:live:write":"STREAMPAY_LIVE=1 STREAMPAY_LIVE_WRITE=1 vitest run tests/live"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:5e49ccb1-1028-450b-8157-c9f1cab973b7"}},"repository":{"url":"git+https://github.com/Genie-sa/better-auth-streampay.git","type":"git"},"_npmVersion":"11.13.0","description":"Community Better Auth plugin for StreamPay — consumers, checkout, portal, subscriptions, and signed webhooks. Not affiliated with Stream.","directories":{},"sideEffects":false,"_nodeVersion":"24.16.0","_hasShrinkwrap":false,"devDependencies":{"msw":"^2.13.3","zod":"^4.3.6","tsup":"^8.5.1","vite":"^8.0.8","vitest":"^4.1.4","lefthook":"^2.1.6","pkg-pr-new":"^0.0.66","typescript":"^5.9.3","@types/node":"^25.6.0","better-auth":"^1.6.5","@biomejs/biome":"^2.4.12","@streamsdk/typescript":"^1.0.6"},"peerDependencies":{"zod":"^3.24.0 || ^4.0.0","better-auth":"^1.4.0","@streamsdk/typescript":"^1.0.6"},"_npmOperationalInternal":{"tmp":"tmp/better-auth-streampay_1.3.0_1781084984599_0.5322582057642147","host":"s3://npm-registry-packages-npm-production"}},"2.0.0":{"name":"better-auth-streampay","version":"2.0.0","keywords":["better-auth","better-auth-plugin","streampay","stream-pay","payments","payment-gateway","subscriptions","recurring-payments","checkout","billing","webhooks","typescript","saudi-arabia","saudi-payments","fintech"],"license":"MIT","_id":"better-auth-streampay@2.0.0","maintainers":[{"name":"ali-cooking","email":"ali77dhamen@hotmail.com"}],"homepage":"https://github.com/Genie-sa/better-auth-streampay#readme","bugs":{"url":"https://github.com/Genie-sa/better-auth-streampay/issues"},"dist":{"shasum":"d8f4758ce6165b4ab0c944c590f3347fbf8c2f6f","tarball":"https://registry.npmjs.org/better-auth-streampay/-/better-auth-streampay-2.0.0.tgz","fileCount":17,"integrity":"sha512-aXcrUReoJ5Yl1xdAj92coaxW5Vx4m2kPpGhkp7gbFILI+Q//xody3s8DWADC6zyM2nZy23fxz0Gh+WKjzIYGVg==","signatures":[{"sig":"MEUCIQDCIg+rZaz8v+lRhH8NHEQxQKtUp7sq4UhrL4O1V0pGxQIgOOUi7nOCgb6uVNBXyQ35J+glx8sg4hetWcgVMAT6aFM=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/better-auth-streampay@2.0.0","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":2314231},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","engines":{"node":">=20.19.0"},"exports":{".":{"import":{"types":"./dist/index.d.ts","default":"./dist/index.js"},"require":{"types":"./dist/index.d.cts","default":"./dist/index.cjs"}},"./client":{"import":{"types":"./dist/client.d.ts","default":"./dist/client.js"},"require":{"types":"./dist/client.d.cts","default":"./dist/client.cjs"}}},"gitHead":"96ed8e9dad2732073438ee12359722642fb58e32","scripts":{"dev":"tsup --watch","lint":"biome check ./src ./tests","test":"vitest run --exclude tests/live/**/*.test.ts","build":"tsup","check":"pnpm lint && pnpm typecheck && pnpm test && pnpm build","format":"biome format --write ./src ./tests","prepare":"lefthook install","release":"pnpm build && changeset publish","changeset":"changeset","test:live":"STREAMPAY_LIVE=1 vitest run tests/live","typecheck":"tsc --noEmit","test:watch":"vitest --exclude tests/live/**/*.test.ts","test:coverage":"vitest run --coverage --exclude tests/live/**/*.test.ts","prepublishOnly":"pnpm run check","test:live:write":"STREAMPAY_LIVE=1 STREAMPAY_LIVE_WRITE=1 vitest run tests/live","version-packages":"changeset version"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:5e49ccb1-1028-450b-8157-c9f1cab973b7"}},"repository":{"url":"git+https://github.com/Genie-sa/better-auth-streampay.git","type":"git"},"_npmVersion":"11.5.1","description":"Community Better Auth plugin for StreamPay with consumers, checkout, portal, subscriptions, and signed webhooks. Not affiliated with Stream.","directories":{},"sideEffects":false,"_nodeVersion":"24.18.0","_hasShrinkwrap":false,"devDependencies":{"msw":"^2.13.3","zod":"^4.4.3","tsup":"^8.5.1","vite":"^8.0.8","vitest":"^4.1.4","lefthook":"^2.1.6","pkg-pr-new":"^0.0.66","typescript":"^5.9.3","@types/node":"^25.6.0","better-auth":"^1.6.23","@biomejs/biome":"^2.4.12","@changesets/cli":"^2.31.0","@streamsdk/typescript":"^1.1.3"},"peerDependencies":{"zod":"^3.24.0 || ^4.0.0","better-auth":"^1.5.0","@streamsdk/typescript":"^1.1.3"},"_npmOperationalInternal":{"tmp":"tmp/better-auth-streampay_2.0.0_1783714962563_0.5376523537706888","host":"s3://npm-registry-packages-npm-production"}},"2.1.0":{"name":"better-auth-streampay","version":"2.1.0","keywords":["better-auth","better-auth-plugin","streampay","stream-pay","payments","payment-gateway","subscriptions","recurring-payments","checkout","billing","webhooks","typescript","saudi-arabia","saudi-payments","fintech"],"license":"MIT","_id":"better-auth-streampay@2.1.0","maintainers":[{"name":"ali-cooking","email":"ali77dhamen@hotmail.com"}],"homepage":"https://github.com/Genie-sa/better-auth-streampay#readme","bugs":{"url":"https://github.com/Genie-sa/better-auth-streampay/issues"},"dist":{"shasum":"04765c1b9980e9e377c0d4250b9b63205bf1730c","tarball":"https://registry.npmjs.org/better-auth-streampay/-/better-auth-streampay-2.1.0.tgz","fileCount":17,"integrity":"sha512-3VjIEXj3plbhLFZhy0tt9PxeSA4guWMJ1t1uT+CtX4gKnWIkk2ul5w9wFTzRTP5BwUu37ALGAX9UuAeVChcHrg==","signatures":[{"sig":"MEUCIQCXK5G4UH+h7g4fCKha2WlH1z89KfO4QPBEGAcl00Cb3gIgGYdOrENtUwSjVcegItQG7qOqE5f10XiRTZ5EWY236/Q=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/better-auth-streampay@2.1.0","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":2369310},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","engines":{"node":">=20.19.0"},"exports":{".":{"import":{"types":"./dist/index.d.ts","default":"./dist/index.js"},"require":{"types":"./dist/index.d.cts","default":"./dist/index.cjs"}},"./client":{"import":{"types":"./dist/client.d.ts","default":"./dist/client.js"},"require":{"types":"./dist/client.d.cts","default":"./dist/client.cjs"}}},"gitHead":"0e2a21e0567c284a4a8a65e3fbabdb046b1e4152","scripts":{"dev":"tsup --watch","lint":"biome check ./src ./tests","test":"vitest run --exclude tests/live/**/*.test.ts","build":"tsup","check":"pnpm lint && pnpm typecheck && pnpm test && pnpm build","format":"biome format --write ./src ./tests","prepare":"lefthook install","release":"pnpm build && changeset publish","changeset":"changeset","test:live":"STREAMPAY_LIVE=1 vitest run tests/live","typecheck":"tsc --noEmit","test:watch":"vitest --exclude tests/live/**/*.test.ts","test:coverage":"vitest run --coverage --exclude tests/live/**/*.test.ts","prepublishOnly":"pnpm run check","test:live:write":"STREAMPAY_LIVE=1 STREAMPAY_LIVE_WRITE=1 vitest run tests/live","version-packages":"changeset version"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:5e49ccb1-1028-450b-8157-c9f1cab973b7"}},"repository":{"url":"git+https://github.com/Genie-sa/better-auth-streampay.git","type":"git"},"_npmVersion":"11.5.1","description":"Community Better Auth plugin for StreamPay with consumers, checkout, portal, subscriptions, and signed webhooks. Not affiliated with Stream.","directories":{},"sideEffects":false,"_nodeVersion":"24.18.0","_hasShrinkwrap":false,"devDependencies":{"msw":"^2.13.3","zod":"^4.4.3","tsup":"^8.5.1","vite":"^8.0.8","vitest":"^4.1.4","lefthook":"^2.1.6","pkg-pr-new":"^0.0.66","typescript":"^5.9.3","@types/node":"^25.6.0","better-auth":"^1.6.23","@biomejs/biome":"^2.4.12","@changesets/cli":"^2.31.0","@streamsdk/typescript":"^1.1.3"},"peerDependencies":{"zod":"^3.24.0 || ^4.0.0","better-auth":"^1.5.0","@streamsdk/typescript":"^1.1.3"},"_npmOperationalInternal":{"tmp":"tmp/better-auth-streampay_2.1.0_1784730146468_0.35144074215401844","host":"s3://npm-registry-packages-npm-production"}},"2.2.0":{"name":"better-auth-streampay","version":"2.2.0","keywords":["better-auth","better-auth-plugin","streampay","stream-pay","payments","payment-gateway","subscriptions","recurring-payments","checkout","billing","webhooks","typescript","saudi-arabia","saudi-payments","fintech"],"license":"MIT","_id":"better-auth-streampay@2.2.0","maintainers":[{"name":"ali-cooking","email":"ali77dhamen@hotmail.com"}],"homepage":"https://github.com/Genie-sa/better-auth-streampay#readme","bugs":{"url":"https://github.com/Genie-sa/better-auth-streampay/issues"},"dist":{"shasum":"6963f89eb467d9438660d737d0c9876f52e8b831","tarball":"https://registry.npmjs.org/better-auth-streampay/-/better-auth-streampay-2.2.0.tgz","fileCount":17,"integrity":"sha512-hre5XI26f+Abp99wTYc+a1C/5rIywftiSwNjBqzD0eOS2BN2JScphNeL4SJ3D6lQDTmQz+ULOTnXBvFzC3dwSg==","signatures":[{"sig":"MEUCIQCowTygu6yWrw317XaEL8LdLafWC0tZWnKLoJZIcLBXmQIgYif3xt9fK6rW4kXE0Rnn+ki7YFl6HyIGTNiHa9+XRT0=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/better-auth-streampay@2.2.0","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":2597464},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","engines":{"node":">=20.19.0"},"exports":{".":{"import":{"types":"./dist/index.d.ts","default":"./dist/index.js"},"require":{"types":"./dist/index.d.cts","default":"./dist/index.cjs"}},"./client":{"import":{"types":"./dist/client.d.ts","default":"./dist/client.js"},"require":{"types":"./dist/client.d.cts","default":"./dist/client.cjs"}}},"gitHead":"df983bce6d04ccfc7cb9fd4dd922d639c867762c","scripts":{"dev":"tsup --watch","lint":"biome check ./src ./tests","test":"vitest run --exclude tests/live/**/*.test.ts","build":"tsup","check":"pnpm lint && pnpm typecheck && pnpm test && pnpm build","format":"biome format --write ./src ./tests","prepare":"lefthook install","release":"pnpm build && changeset publish","changeset":"changeset","test:live":"STREAMPAY_LIVE=1 vitest run tests/live","typecheck":"tsc --noEmit","test:watch":"vitest --exclude tests/live/**/*.test.ts","test:coverage":"vitest run --coverage --exclude tests/live/**/*.test.ts","prepublishOnly":"pnpm run check","test:live:write":"STREAMPAY_LIVE=1 STREAMPAY_LIVE_WRITE=1 vitest run tests/live","version-packages":"changeset version"},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:5e49ccb1-1028-450b-8157-c9f1cab973b7"}},"repository":{"url":"git+https://github.com/Genie-sa/better-auth-streampay.git","type":"git"},"_npmVersion":"11.5.1","description":"Community Better Auth plugin for StreamPay with consumers, checkout, portal, subscriptions, and signed webhooks. Not affiliated with Stream.","directories":{},"sideEffects":false,"_nodeVersion":"24.18.0","_hasShrinkwrap":false,"devDependencies":{"msw":"^2.13.3","zod":"^4.4.3","tsup":"^8.5.1","vite":"^8.0.8","vitest":"^4.1.4","lefthook":"^2.1.6","pkg-pr-new":"^0.0.66","typescript":"^5.9.3","@types/node":"^25.6.0","better-auth":"^1.6.23","@biomejs/biome":"^2.4.12","@changesets/cli":"^2.31.0","@streamsdk/typescript":"^1.1.3"},"peerDependencies":{"zod":"^3.24.0 || ^4.0.0","better-auth":"^1.5.0","@streamsdk/typescript":"^1.1.3"},"_npmOperationalInternal":{"tmp":"tmp/better-auth-streampay_2.2.0_1785333397018_0.8247985745665927","host":"s3://npm-registry-packages-npm-production"}},"2.2.1":{"name":"better-auth-streampay","version":"2.2.1","description":"Community Better Auth plugin for StreamPay with consumers, checkout, portal, subscriptions, and signed webhooks. Not affiliated with Stream.","license":"MIT","type":"module","sideEffects":false,"engines":{"node":">=20.19.0"},"main":"./dist/index.cjs","module":"./dist/index.js","types":"./dist/index.d.ts","exports":{".":{"import":{"types":"./dist/index.d.ts","default":"./dist/index.js"},"require":{"types":"./dist/index.d.cts","default":"./dist/index.cjs"}},"./client":{"import":{"types":"./dist/client.d.ts","default":"./dist/client.js"},"require":{"types":"./dist/client.d.cts","default":"./dist/client.cjs"}}},"keywords":["better-auth","better-auth-plugin","streampay","stream-pay","payments","payment-gateway","subscriptions","recurring-payments","checkout","billing","webhooks","typescript","saudi-arabia","saudi-payments","fintech"],"repository":{"type":"git","url":"git+https://github.com/Genie-sa/better-auth-streampay.git"},"scripts":{"build":"tsup","prepublishOnly":"pnpm run check","dev":"tsup --watch","test":"vitest run --exclude tests/live/**/*.test.ts","test:live":"STREAMPAY_LIVE=1 vitest run tests/live","test:live:write":"STREAMPAY_LIVE=1 STREAMPAY_LIVE_WRITE=1 vitest run tests/live","test:watch":"vitest --exclude tests/live/**/*.test.ts","test:coverage":"vitest run --coverage --exclude tests/live/**/*.test.ts","typecheck":"tsc --noEmit","lint":"biome check ./src ./tests","format":"biome format --write ./src ./tests","check":"pnpm lint && pnpm typecheck && pnpm test && pnpm build","changeset":"changeset","version-packages":"changeset version","release":"pnpm build && changeset publish","prepare":"lefthook install"},"peerDependencies":{"@streamsdk/typescript":"^1.1.3","better-auth":"^1.5.0","zod":"^3.24.0 || ^4.0.0"},"devDependencies":{"@biomejs/biome":"^2.4.12","@changesets/cli":"^2.31.0","@streamsdk/typescript":"^1.1.3","@types/node":"^25.6.0","better-auth":"^1.6.23","lefthook":"^2.1.6","msw":"^2.13.3","pkg-pr-new":"^0.0.66","tsup":"^8.5.1","typescript":"^5.9.3","vite":"^8.0.8","vitest":"^4.1.4","zod":"^4.4.3"},"_id":"better-auth-streampay@2.2.1","gitHead":"ceb5ddecc6c5e2e6f4efa4062d6c1be4fa2935e1","bugs":{"url":"https://github.com/Genie-sa/better-auth-streampay/issues"},"homepage":"https://github.com/Genie-sa/better-auth-streampay#readme","_nodeVersion":"24.19.0","_npmVersion":"11.5.1","dist":{"integrity":"sha512-lJvjbB3sQElvH+BFytafCP8kac1obZdMX4xMhls0XjhQKfbaFZHUCC66zbTlBt1TcE2eofj0igh03uLh5GfYXA==","shasum":"20d406e62f03c04455edc2c077eb9796e738d1d5","tarball":"https://registry.npmjs.org/better-auth-streampay/-/better-auth-streampay-2.2.1.tgz","fileCount":17,"unpackedSize":2594594,"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/better-auth-streampay@2.2.1","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIDdchAuaKDfbvsK8mJQM4/3ip+HL13WHzoaWL+1Vc9LcAiEA8dErCwi1iK5LD/dKpdA3HJ9Efsidc/p/ufIIengxCCw="}]},"_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"oidc:5e49ccb1-1028-450b-8157-c9f1cab973b7"}},"directories":{},"maintainers":[{"name":"ali-cooking","email":"ali77dhamen@hotmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/better-auth-streampay_2.2.1_1786958012440_0.7846830292224942"},"_hasShrinkwrap":false}},"time":{"created":"2026-04-16T15:14:58.578Z","modified":"2026-08-17T09:13:32.996Z","0.1.0":"2026-04-16T15:14:58.829Z","0.1.1":"2026-04-16T15:19:07.837Z","0.1.2":"2026-04-16T15:36:02.044Z","0.1.3":"2026-04-16T16:09:45.724Z","0.1.4":"2026-04-17T13:52:29.108Z","0.1.5":"2026-04-17T14:20:01.868Z","0.2.0":"2026-04-17T20:50:37.237Z","1.0.0":"2026-04-19T20:05:48.956Z","1.1.5":"2026-04-25T22:12:54.847Z","1.1.6":"2026-05-01T22:40:12.475Z","1.2.0":"2026-05-02T19:10:14.910Z","1.2.1":"2026-05-14T19:45:02.853Z","1.3.0":"2026-06-10T09:49:44.837Z","2.0.0":"2026-07-10T20:22:42.762Z","2.1.0":"2026-07-22T14:22:26.612Z","2.2.0":"2026-07-29T13:56:37.198Z","2.2.1":"2026-08-17T09:13:32.606Z"},"bugs":{"url":"https://github.com/Genie-sa/better-auth-streampay/issues"},"license":"MIT","homepage":"https://github.com/Genie-sa/better-auth-streampay#readme","keywords":["better-auth","better-auth-plugin","streampay","stream-pay","payments","payment-gateway","subscriptions","recurring-payments","checkout","billing","webhooks","typescript","saudi-arabia","saudi-payments","fintech"],"repository":{"type":"git","url":"git+https://github.com/Genie-sa/better-auth-streampay.git"},"description":"Community Better Auth plugin for StreamPay with consumers, checkout, portal, subscriptions, and signed webhooks. Not affiliated with Stream.","maintainers":[{"name":"ali-cooking","email":"ali77dhamen@hotmail.com"}],"readme":"# better-auth-streampay\n\nAdd StreamPay payments and subscriptions to a Better Auth app.\n\n## Agent skill\n\nInstall the included integration skill:\n\n```bash\nnpx skills add Genie-sa/better-auth-streampay\n```\n\nThen ask your coding agent to add StreamPay to your Better Auth app.\n\nThe plugin can:\n\n- create StreamPay consumers\n- open hosted checkout\n- show a billing portal\n- manage subscriptions\n- expose admin billing actions\n- verify and handle signed webhooks\n\n## Install\n\n```bash\npnpm add better-auth-streampay @streamsdk/typescript\n```\n\nRequired versions:\n\n- `better-auth ^1.5.0`\n- `@streamsdk/typescript ^1.1.3`\n- `zod ^3.24.0 || ^4.0.0`\n\n## Basic setup\n\nAdd your StreamPay API key:\n\n```bash\nSTREAMPAY_API_KEY=\nSTREAMPAY_WEBHOOK_SECRET=\n```\n\nCreate one SDK client and pass it to the plugin:\n\n```ts\nimport StreamSDK from \"@streamsdk/typescript\";\nimport { betterAuth } from \"better-auth\";\nimport {\n  checkout,\n  portal,\n  streampay,\n  subscriptions,\n  webhooks,\n} from \"better-auth-streampay\";\n\nconst streamPayClient = StreamSDK.init(process.env.STREAMPAY_API_KEY!);\n\nexport const auth = betterAuth({\n  plugins: [\n    streampay({\n      client: streamPayClient,\n      use: [\n        checkout(),\n        portal(),\n        subscriptions({\n          plans: [\n            {\n              name: \"pro\",\n              productId: \"your-recurring-product-id\",\n              priceInSmallestUnit: 9900,\n              billingInterval: \"MONTH\",\n              limits: { reports: true },\n            },\n          ],\n        }),\n        webhooks({\n          secret: process.env.STREAMPAY_WEBHOOK_SECRET!,\n        }),\n      ],\n    }),\n  ],\n});\n```\n\nOnly add the parts you use.\n\n## Database\n\nFor a new Better Auth managed database:\n\n```bash\nnpx auth@latest migrate --config path/to/auth.ts\n```\n\nFor Drizzle or Prisma:\n\n```bash\nnpx auth@latest generate --config path/to/auth.ts\n```\n\nReview the generated schema, then use your normal migration process. The plugin declares the\nschema but never changes your database at runtime. For an existing subscription table, backfill\n`seats` to `1` in the same migration.\n\n`streampayConsumerId` is unique. Before applying the generated unique index to an existing\ndatabase, resolve any duplicate non-null consumer IDs. Checkout fails closed when a consumer link\ncannot be stored safely.\n\n## Client setup\n\n```ts\nimport { createAuthClient } from \"better-auth/react\";\nimport { streampayClient } from \"better-auth-streampay/client\";\n\nexport const authClient = createAuthClient({\n  plugins: [streampayClient()],\n});\n```\n\nUse the matching Better Auth client for Vue, Svelte, or Solid.\n\n## Consumers\n\nBy default, the plugin creates a StreamPay consumer when the user first needs one. This keeps a\nStreamPay outage from blocking sign-up.\n\nTo create the consumer during sign-up:\n\n```ts\nstreampay({\n  client: streamPayClient,\n  createConsumerOnSignUp: true,\n  use: [],\n});\n```\n\nTo reuse an existing StreamPay consumer after a verified email match:\n\n```ts\nstreampay({\n  client: streamPayClient,\n  createConsumerOnSignUp: true,\n  claimExistingConsumerBy: [\"email\"],\n  use: [],\n});\n```\n\nOnly enable reuse when your app verifies the matching email or phone number.\n\n## Checkout\n\n```ts\ncheckout({\n  products: [\n    { slug: \"starter\", productId: \"product-id\" },\n  ],\n  successUrl: \"/billing/success\",\n  failureUrl: \"/billing/failed\",\n  authenticatedUsersOnly: true,\n});\n```\n\nOpen checkout:\n\n```ts\nconst { data } = await authClient.checkout({\n  slug: \"starter\",\n  redirect: false,\n});\n\nwindow.location.href = data.url;\n```\n\nYou can also pass StreamPay product IDs directly with `products`.\n\n### Server-authoritative checkout\n\nFor a store, derive product IDs, quantities, coupons, expiry, and redirect URLs on the server:\n\n```ts\nimport { APIError } from \"better-auth/api\";\n\ncheckout({\n  authenticatedUsersOnly: true,\n\n  resolveCheckout: async ({ user, body }) => {\n    const order = await loadAuthorizedOrder(user?.id, body.referenceId);\n    if (!order) {\n      throw new APIError(\"FORBIDDEN\", {\n        code: \"ORDER_NOT_AVAILABLE\",\n        message: \"This order is not available for checkout.\",\n      });\n    }\n\n    return {\n      products: [{ productId: order.productId, quantity: order.quantity }],\n      successUrl: `https://shop.example.com/orders/${order.id}?checkout=success`,\n      failureUrl: `https://shop.example.com/orders/${order.id}?checkout=failed`,\n      maxNumberOfPayments: 1,\n      validUntil: order.validUntil,\n      metadata: { flow: \"store\" },\n    };\n  },\n\n  onCheckoutCreated: async ({ referenceId, paymentLinkId, payload }) => {\n    await saveOrderPaymentLink({ referenceId, paymentLinkId, payload });\n  },\n});\n```\n\nThe client then sends only app-owned reference data:\n\n```ts\nawait authClient.checkout({ referenceId: order.id, redirect: false });\n```\n\nConfiguring `resolveCheckout` automatically makes product, pricing, coupon, expiry, metadata, and\nredirect URL fields server-only. Requests that include those fields are rejected; without a\nresolver, the existing client-driven checkout behavior is unchanged.\n\nInvalid values returned by `resolveCheckout` produce a generic 500 response. Validation details are\nwritten to the server log without echoing the invalid values to the client.\n\nIf `onCheckoutCreated` throws, checkout returns an error and the plugin attempts to deactivate the\nnew payment link. Deactivation is best effort, so webhook handling should still reconcile unexpected\nlinks. Relative success and failure URLs resolve against the auth server; use absolute URLs when the\nstorefront has a different origin.\n\n## Billing portal\n\n`portal()` adds three signed-in user actions:\n\n- `state`\n- `subscriptions`\n- `invoices`\n\n```ts\nconst state = await authClient.consumer.state();\nconst subscriptions = await authClient.consumer.subscriptions.list();\nconst invoices = await authClient.consumer.invoices.list();\n```\n\n## Subscriptions\n\n```ts\nsubscriptions({\n  plans: [\n    {\n      name: \"pro-monthly\",\n      productId: \"product-id\",\n      priceInSmallestUnit: 9900,\n      currency: \"SAR\",\n      billingInterval: \"MONTH\",\n      billingIntervalCount: 1,\n      trialPeriodDays: 7,\n      group: \"main\",\n      seatBilling: {\n        default: 3,\n        minimum: 1,\n        maximum: 100,\n      },\n      limits: { projects: 50, reports: true },\n    },\n  ],\n\n  onSubscriptionActivated: async ({ subscription, user }) => {\n    // Run app-specific work here.\n  },\n});\n```\n\nPlan names and product IDs must be unique. Prices use the smallest currency unit. For SAR,\n`9900` means `99.00 SAR`.\n\n`priceInSmallestUnit` is the price per seat. `seatBilling` controls billed quantity; `limits`\ncontrols application access. Set `customerEditable: true` with explicit minimum and maximum bounds\nto let customers change quantity in hosted checkout.\n\nThe plugin gives one trial per user and plan group by default. Use `isTrialEligible` when your\napp needs a stricter or more flexible rule.\n\n### Start checkout\n\n```ts\nconst { data } = await authClient.subscription.upgrade({\n  plan: \"pro-monthly\",\n  seats: 5,\n});\n\nwindow.location.href = data.url;\n```\n\nOn the success page:\n\n```ts\nawait authClient.subscription.success({\n  query: { subscriptionId: data.subscriptionId },\n});\n```\n\nThen refresh the subscription data used by your UI.\n\n### Manage a subscription\n\n```ts\nawait authClient.subscription.changePlan({\n  subscriptionId,\n  plan: \"pro-yearly\",\n  seats: 8, // optional; defaults to the current quantity\n});\n\nawait authClient.subscription.updateSeats({\n  subscriptionId,\n  seats: 12,\n});\n\nawait authClient.subscription.pendingChange.cancel({ subscriptionId });\n\nawait authClient.subscription.cancel({\n  subscriptionId,\n  cancelAtPeriodEnd: true,\n});\n\nawait authClient.subscription.uncancel({ subscriptionId });\n```\n\nStreamPay applies quantity and plan changes at period end. Read the active quantity from `seats`\nand the scheduled quantity from `pendingSeats`. The older\n`authClient.subscription.changePlan.cancel()` action remains available.\n\nStreamPay cancels an active subscription at the end of its current period. Trial and inactive\nsubscriptions are canceled at once.\n\n### Freeze a subscription\n\n```ts\nconst { data: freeze } = await authClient.subscription.freeze({\n  subscriptionId,\n  freezeStartDatetime: new Date().toISOString(),\n  freezeEndDatetime: null,\n});\n\nawait authClient.subscription.unfreeze({ subscriptionId });\n\nawait authClient.subscription.freeze.cancel({\n  subscriptionId,\n  freezeId: freeze.id!,\n});\n```\n\n### Read access and limits\n\n```ts\nconst current = await authClient.subscription.current({\n  query: { group: \"main\" },\n});\n\nconst feature = await authClient.subscription.hasFeature({\n  query: { feature: \"reports\", group: \"main\" },\n});\n\nconst projects = await authClient.subscription.checkLimit({\n  query: { feature: \"projects\", count: 4, group: \"main\" },\n});\n```\n\n`checkLimit` reads configured entitlements. Use `current.data?.seats` for licensed-member counts.\n\nPass `group` for grouped plans. Leave it out only for a plan without a group.\n\nSee [the subscription data model](docs/subscriptions.md) for columns, lifecycle, and migration\ndetails.\n\nBy default, `active`, `trialing`, `frozen`, and `past_due` subscriptions can use plan\nfeatures. Change this with `accessStatuses`.\n\n## Server-side calls\n\nEvery checkout, portal, subscription, and admin action is also available on `auth.api`. Types\ncome from Better Auth.\n\nBrowser calls follow the route path, such as `authClient.subscription.cancel`. Server calls use\nthe endpoint name, such as `auth.api.cancelSubscription`.\n\n```ts\nimport { headers } from \"next/headers\";\n\nconst current = await auth.api.currentSubscription({\n  query: { group: \"main\" },\n  headers: await headers(),\n});\n\nawait auth.api.cancelSubscription({\n  body: { subscriptionId, cancelAtPeriodEnd: true },\n  headers: await headers(),\n});\n```\n\nPass the request headers so Better Auth can read the session.\n\nWebhook delivery is not an `auth.api` action. It uses the raw HTTP body to verify the signature.\n\n## Cross-account access\n\nUser actions use the signed-in user's ID by default.\n\nTo manage an organization or another app-owned reference, add `authorizeReference`:\n\n```ts\nsubscriptions({\n  plans,\n  authorizeReference: async ({ user, referenceId, referenceType, action }) => {\n    return canManageBilling(user, referenceId, referenceType, action);\n  },\n});\n```\n\nWithout this callback, cross-account actions return `FORBIDDEN`.\n\n## Admin\n\n`admin()` adds billing actions for payments, subscriptions, freezes, consumers, invoices,\nproducts, coupons, payment links, and webhook retries.\n\n```ts\nimport { admin } from \"better-auth-streampay\";\n\nadmin({\n  adminRoles: [\"admin\", \"billing\"],\n  isAdmin: async (user) => user.email.endsWith(\"@example.com\"),\n});\n```\n\nCalls use names such as:\n\n- `auth.api.adminListPayments`\n- `auth.api.adminGetSubscription`\n- `auth.api.adminCreateProduct`\n- `auth.api.adminReplayWebhookEvent`\n\nThe IDE shows the body, query, and response types for every action.\n\nMake sure your Better Auth route accepts `GET`, `POST`, `PATCH`, `PUT`, and `DELETE`.\n\n## Webhooks\n\nRegister this URL in the StreamPay dashboard:\n\n```text\nhttps://your-app.com/api/auth/streampay/webhooks\n```\n\nThen add the handlers you need:\n\n```ts\nwebhooks({\n  secret: process.env.STREAMPAY_WEBHOOK_SECRET!,\n\n  onPaymentSucceeded: async (event) => {},\n  onPaymentFailed: async (event) => {},\n  onSubscriptionActivated: async (event) => {},\n  onSubscriptionCanceled: async (event) => {},\n  onPayload: async (event) => {},\n});\n```\n\nThe plugin:\n\n- checks the webhook signature\n- rejects old signatures\n- deduplicates subscription sync and lifecycle callbacks\n- retries temporary failures\n- stores failed subscription events for admin replay\n\nThe StreamPay SDK does not export webhook payload types. This package provides checked event\ntypes based on StreamPay's documented payloads.\n\nTo rotate a secret:\n\n```ts\nwebhooks({\n  secret: [\n    process.env.STREAMPAY_WEBHOOK_SECRET!,\n    process.env.STREAMPAY_WEBHOOK_SECRET_OLD!,\n  ],\n});\n```\n\nRemove the old secret after StreamPay uses the new one.\n\n## What owns each job\n\nStreamPay owns:\n\n- charges\n- invoices\n- subscription state\n- trials\n- renewal attempts\n- cancellation timing\n\nThe plugin owns:\n\n- Better Auth access checks\n- local subscription rows\n- plan features and limits\n- webhook checks and retries\n- checkout recovery\n\nDo not edit subscription rows by hand. Let provider responses and webhooks update them.\n\n## Errors\n\nErrors use stable codes:\n\n```ts\nimport { $ERROR_CODES } from \"better-auth-streampay\";\n\nif (error.code === $ERROR_CODES.SUBSCRIPTION_ALREADY_ACTIVE.code) {\n  // Show the current plan.\n}\n```\n\nCommon codes include:\n\n- `VALIDATION_ERROR`\n- `FORBIDDEN`\n- `NOT_FOUND`\n- `SUBSCRIPTION_ALREADY_ACTIVE`\n- `SUBSCRIPTION_INVALID_STATE`\n- `SUBSCRIPTION_PLAN_CHANGE_ALREADY_SCHEDULED`\n- `WEBHOOK_REPLAY_IN_PROGRESS`\n\n## Useful exports\n\n```ts\nimport {\n  StreamPayAmount,\n  checkLimit,\n  findConsumerByExternalId,\n  formatStreamPayError,\n  hasFeature,\n  parseStreamPayError,\n  verifyWebhook,\n} from \"better-auth-streampay\";\n```\n\n## License\n\nMIT\n","readmeFilename":"README.md"}