{"_id":"@bafe-pkmdd/central-auth-sdk","_rev":"17-3c6f6543f3e933a6b34327cd9d9e1b4e","name":"@bafe-pkmdd/central-auth-sdk","dist-tags":{"latest":"0.7.3"},"versions":{"0.1.0":{"name":"@bafe-pkmdd/central-auth-sdk","version":"0.1.0","keywords":["central-auth","jwt","authentication","token-refresh","jwks"],"license":"MIT","_id":"@bafe-pkmdd/central-auth-sdk@0.1.0","maintainers":[{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"}],"homepage":"https://github.com/BAFE-PKMDD/central-auth-sdk#readme","bugs":{"url":"https://github.com/BAFE-PKMDD/central-auth-sdk/issues"},"dist":{"shasum":"13f1288008af5b72769ddad68be5bbfaa1297028","tarball":"https://registry.npmjs.org/@bafe-pkmdd/central-auth-sdk/-/central-auth-sdk-0.1.0.tgz","fileCount":34,"integrity":"sha512-wqcqW8NfOa1rYrdEyzvvQxxkltEoHK0+nZk6XlCxs1J6F1n+NNmarXctpki+Kn6MC/0aqOE417yB46sA5Mqkaw==","signatures":[{"sig":"MEYCIQCxCIzTvYIt6AgE31qeq+gaJcnGckj+Yp3sE0eoAK2RSAIhANguSkeCdudC0u5YTsE5qlK43I0jFschv+zvZ/ddiroL","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":104010},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","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/index.d.ts","default":"./dist/client/index.js"},"require":{"types":"./dist/client/index.d.cts","default":"./dist/client/index.cjs"}},"./server":{"import":{"types":"./dist/server/index.d.ts","default":"./dist/server/index.js"},"require":{"types":"./dist/server/index.d.cts","default":"./dist/server/index.cjs"}}},"gitHead":"ac867fb69e8562e11e6fea5809bc51099e6919ea","scripts":{"build":"tsup","clean":"rm -rf dist","typecheck":"tsc --noEmit","prepublishOnly":"bun run build"},"_npmUser":{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"},"repository":{"url":"git+https://github.com/BAFE-PKMDD/central-auth-sdk.git","type":"git"},"_npmVersion":"10.9.3","description":"Framework-agnostic JavaScript SDK for Central Auth — token management, JWT verification, and refresh flow utilities.","directories":{},"_nodeVersion":"22.20.0","dependencies":{"jose":"^6.0.11"},"_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.4.0","typescript":"~5.7.2"},"_npmOperationalInternal":{"tmp":"tmp/central-auth-sdk_0.1.0_1772363634686_0.028079117638786455","host":"s3://npm-registry-packages-npm-production"}},"0.2.0":{"name":"@bafe-pkmdd/central-auth-sdk","version":"0.2.0","keywords":["central-auth","jwt","authentication","token-refresh","jwks"],"license":"MIT","_id":"@bafe-pkmdd/central-auth-sdk@0.2.0","maintainers":[{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"}],"homepage":"https://github.com/BAFE-PKMDD/central-auth-sdk#readme","bugs":{"url":"https://github.com/BAFE-PKMDD/central-auth-sdk/issues"},"dist":{"shasum":"b9b319c22b59b531aebde9308ea2362832f98e6a","tarball":"https://registry.npmjs.org/@bafe-pkmdd/central-auth-sdk/-/central-auth-sdk-0.2.0.tgz","fileCount":34,"integrity":"sha512-c49IPWjotzu5qXMWmeONWq8hHS8hKxG9lm/EOlxN98Wztcggcy6RTsD337ylgsraL7xYWeeHlEmznAt9EOPP+A==","signatures":[{"sig":"MEUCIQCd9W58FDMoLIEMjhiPvykztEb/gsizYuPRfprIR0KWIQIgJtCUhiLV76Nqa+WBRt6zhld3aL+HJxgIamQQu//sDpo=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":123184},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","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/index.d.ts","default":"./dist/client/index.js"},"require":{"types":"./dist/client/index.d.cts","default":"./dist/client/index.cjs"}},"./server":{"import":{"types":"./dist/server/index.d.ts","default":"./dist/server/index.js"},"require":{"types":"./dist/server/index.d.cts","default":"./dist/server/index.cjs"}}},"gitHead":"bd8f3fd157f1cf97576da932792d7c8ff266c104","scripts":{"build":"tsup","clean":"rm -rf dist","typecheck":"tsc --noEmit","prepublishOnly":"bun run build"},"_npmUser":{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"},"repository":{"url":"git+https://github.com/BAFE-PKMDD/central-auth-sdk.git","type":"git"},"_npmVersion":"10.9.3","description":"Framework-agnostic JavaScript SDK for Central Auth — token management, JWT verification, and refresh flow utilities.","directories":{},"_nodeVersion":"22.20.0","dependencies":{"jose":"^6.0.11"},"_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.4.0","typescript":"~5.7.2"},"_npmOperationalInternal":{"tmp":"tmp/central-auth-sdk_0.2.0_1772450850734_0.22689051414962025","host":"s3://npm-registry-packages-npm-production"}},"0.3.0":{"name":"@bafe-pkmdd/central-auth-sdk","version":"0.3.0","keywords":["central-auth","jwt","authentication","token-refresh","jwks"],"license":"MIT","_id":"@bafe-pkmdd/central-auth-sdk@0.3.0","maintainers":[{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"}],"homepage":"https://github.com/BAFE-PKMDD/central-auth-sdk#readme","bugs":{"url":"https://github.com/BAFE-PKMDD/central-auth-sdk/issues"},"dist":{"shasum":"1ae349ecc0c9fcc127bf1d9bdccc9ab6e797ae9b","tarball":"https://registry.npmjs.org/@bafe-pkmdd/central-auth-sdk/-/central-auth-sdk-0.3.0.tgz","fileCount":34,"integrity":"sha512-L+/gaRrdcn/UFnoN4rRq25V8X3EdFXhp+DN32FLsCJxUmWIDS05gDGJaRE0V/lZA0vl9J8MVly8F6uDggxkggQ==","signatures":[{"sig":"MEQCICdqfIogMAO/lPVZPGqctl1yuN5Tnv2nvjmRfJjVUnQ/AiBfZA5jHI98HSfyO/bys7IyFEy0I1Cr2enC1kNnkxc0sw==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":123390},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","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/index.d.ts","default":"./dist/client/index.js"},"require":{"types":"./dist/client/index.d.cts","default":"./dist/client/index.cjs"}},"./server":{"import":{"types":"./dist/server/index.d.ts","default":"./dist/server/index.js"},"require":{"types":"./dist/server/index.d.cts","default":"./dist/server/index.cjs"}}},"gitHead":"b543a1cad42f9da8438929862dfd9785119578eb","scripts":{"build":"tsup","clean":"rm -rf dist","typecheck":"tsc --noEmit","prepublishOnly":"bun run build"},"_npmUser":{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"},"repository":{"url":"git+https://github.com/BAFE-PKMDD/central-auth-sdk.git","type":"git"},"_npmVersion":"10.9.3","description":"Framework-agnostic JavaScript SDK for Central Auth — token management, JWT verification, and refresh flow utilities.","directories":{},"_nodeVersion":"22.20.0","dependencies":{"jose":"^6.0.11"},"_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.4.0","typescript":"~5.7.2"},"_npmOperationalInternal":{"tmp":"tmp/central-auth-sdk_0.3.0_1772630351601_0.5239437918395393","host":"s3://npm-registry-packages-npm-production"}},"0.4.0":{"name":"@bafe-pkmdd/central-auth-sdk","version":"0.4.0","keywords":["central-auth","jwt","authentication","token-refresh","jwks"],"license":"MIT","_id":"@bafe-pkmdd/central-auth-sdk@0.4.0","maintainers":[{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"}],"homepage":"https://github.com/BAFE-PKMDD/central-auth-sdk#readme","bugs":{"url":"https://github.com/BAFE-PKMDD/central-auth-sdk/issues"},"dist":{"shasum":"6ee864b819ed5f950f55491b5f2044187401d77a","tarball":"https://registry.npmjs.org/@bafe-pkmdd/central-auth-sdk/-/central-auth-sdk-0.4.0.tgz","fileCount":34,"integrity":"sha512-SMwTjfBEd0iPgwr3dv8CQe/Rc9e0O2BdpoIk1bEcdbkqiqPlnPmQeqbHxtenm7oR1j3DCagGq/dDCOF4GjjpFw==","signatures":[{"sig":"MEYCIQDJvyO2+7TW5hOiBCMTYAwn5HWs21r7tvJ6cChCFc4AaAIhAPpQt7zHvNqkfME5Usl8O+Xd0mbGTxGwunC8871zyvw7","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":123642},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","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/index.d.ts","default":"./dist/client/index.js"},"require":{"types":"./dist/client/index.d.cts","default":"./dist/client/index.cjs"}},"./server":{"import":{"types":"./dist/server/index.d.ts","default":"./dist/server/index.js"},"require":{"types":"./dist/server/index.d.cts","default":"./dist/server/index.cjs"}}},"gitHead":"c1a3d10c6fc9c886a10faf16365fbf1a5ed8b5d5","scripts":{"build":"tsup","clean":"rm -rf dist","typecheck":"tsc --noEmit","prepublishOnly":"bun run build"},"_npmUser":{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"},"repository":{"url":"git+https://github.com/BAFE-PKMDD/central-auth-sdk.git","type":"git"},"_npmVersion":"10.9.3","description":"Framework-agnostic JavaScript SDK for Central Auth — token management, JWT verification, and refresh flow utilities.","directories":{},"_nodeVersion":"22.20.0","dependencies":{"jose":"^6.0.11"},"_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.4.0","typescript":"~5.7.2"},"_npmOperationalInternal":{"tmp":"tmp/central-auth-sdk_0.4.0_1772631514844_0.6725695228620232","host":"s3://npm-registry-packages-npm-production"}},"0.5.0":{"name":"@bafe-pkmdd/central-auth-sdk","version":"0.5.0","keywords":["central-auth","jwt","authentication","token-refresh","jwks"],"license":"MIT","_id":"@bafe-pkmdd/central-auth-sdk@0.5.0","maintainers":[{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"}],"homepage":"https://github.com/BAFE-PKMDD/central-auth-sdk#readme","bugs":{"url":"https://github.com/BAFE-PKMDD/central-auth-sdk/issues"},"dist":{"shasum":"1dbe2e061ceee0537784a056903c031d59718768","tarball":"https://registry.npmjs.org/@bafe-pkmdd/central-auth-sdk/-/central-auth-sdk-0.5.0.tgz","fileCount":34,"integrity":"sha512-dgBcPNFJTLcP5j9AzxW4bjby1tZA1UEAwMQfX3cc/LrAWw87HTZGdQg+A3tVBA4IayV8m+Du2x+HTOKs1gZoKg==","signatures":[{"sig":"MEQCIEURjiMrxT+ZOSIVrjPhfaUnF0uKRrS8pkpqISczENm5AiABqcK9QhI2BeGvur70iYbZJBpXsTJ2PrSQzFaAH7B6uQ==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":124234},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","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/index.d.ts","default":"./dist/client/index.js"},"require":{"types":"./dist/client/index.d.cts","default":"./dist/client/index.cjs"}},"./server":{"import":{"types":"./dist/server/index.d.ts","default":"./dist/server/index.js"},"require":{"types":"./dist/server/index.d.cts","default":"./dist/server/index.cjs"}}},"gitHead":"36b3fbc4c48816a949505f42625dda7871799307","scripts":{"build":"tsup","clean":"rm -rf dist","typecheck":"tsc --noEmit","prepublishOnly":"bun run build"},"_npmUser":{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"},"repository":{"url":"git+https://github.com/BAFE-PKMDD/central-auth-sdk.git","type":"git"},"_npmVersion":"10.9.3","description":"Framework-agnostic JavaScript SDK for Central Auth — token management, JWT verification, and refresh flow utilities.","directories":{},"_nodeVersion":"22.20.0","dependencies":{"jose":"^6.0.11"},"_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.4.0","typescript":"~5.7.2"},"_npmOperationalInternal":{"tmp":"tmp/central-auth-sdk_0.5.0_1772701780663_0.6797168505848474","host":"s3://npm-registry-packages-npm-production"}},"0.5.1":{"name":"@bafe-pkmdd/central-auth-sdk","version":"0.5.1","keywords":["central-auth","jwt","authentication","token-refresh","jwks"],"license":"MIT","_id":"@bafe-pkmdd/central-auth-sdk@0.5.1","maintainers":[{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"}],"homepage":"https://github.com/BAFE-PKMDD/central-auth-sdk#readme","bugs":{"url":"https://github.com/BAFE-PKMDD/central-auth-sdk/issues"},"dist":{"shasum":"10e8a1ae4738ce40d4db3e45f901d8e5f9c570f9","tarball":"https://registry.npmjs.org/@bafe-pkmdd/central-auth-sdk/-/central-auth-sdk-0.5.1.tgz","fileCount":34,"integrity":"sha512-KdqZFWopuHwa4s/Fw946Gc+s8HjH+iJxFF4SHs8YNxssl85SQQFuxhsIvLFUZJTh9WkPwA3HbUVdKTnbgf9+2g==","signatures":[{"sig":"MEUCICdlB/XWQkSapatYcQc4EcmjnXK5LsyqQK62mMnaTm0cAiEAz35h+mNky8V0ADKiLfp/KpgKZ8NZXIhsv4PBTuL6hUM=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":124696},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","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/index.d.ts","default":"./dist/client/index.js"},"require":{"types":"./dist/client/index.d.cts","default":"./dist/client/index.cjs"}},"./server":{"import":{"types":"./dist/server/index.d.ts","default":"./dist/server/index.js"},"require":{"types":"./dist/server/index.d.cts","default":"./dist/server/index.cjs"}}},"gitHead":"0b814987b2c3a81d3f1ef5572d4e97981683df10","scripts":{"build":"tsup","clean":"rm -rf dist","typecheck":"tsc --noEmit","prepublishOnly":"bun run build"},"_npmUser":{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"},"repository":{"url":"git+https://github.com/BAFE-PKMDD/central-auth-sdk.git","type":"git"},"_npmVersion":"10.9.3","description":"Framework-agnostic JavaScript SDK for Central Auth — token management, JWT verification, and refresh flow utilities.","directories":{},"_nodeVersion":"22.20.0","dependencies":{"jose":"^6.0.11"},"_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.4.0","typescript":"~5.7.2"},"_npmOperationalInternal":{"tmp":"tmp/central-auth-sdk_0.5.1_1773147981830_0.24148258110526788","host":"s3://npm-registry-packages-npm-production"}},"0.5.2":{"name":"@bafe-pkmdd/central-auth-sdk","version":"0.5.2","keywords":["central-auth","jwt","authentication","token-refresh","jwks"],"license":"MIT","_id":"@bafe-pkmdd/central-auth-sdk@0.5.2","maintainers":[{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"}],"homepage":"https://github.com/BAFE-PKMDD/central-auth-sdk#readme","bugs":{"url":"https://github.com/BAFE-PKMDD/central-auth-sdk/issues"},"dist":{"shasum":"8d285a0574701464a6452858093f095578e6f512","tarball":"https://registry.npmjs.org/@bafe-pkmdd/central-auth-sdk/-/central-auth-sdk-0.5.2.tgz","fileCount":34,"integrity":"sha512-KBCZw64sDaE574wuwbw5qWtJPmJ31nKF1OszYkOG/7L28LfQENZR7nAtmX3jzstBGPiMbx3Ew3Z8LZTQe45JRw==","signatures":[{"sig":"MEQCIAVXVlGZp4o3RJNu278JAJXR4ExAbVVcurxVxMjAF6WCAiAUO2OVYByy5WxlFA7yCAr+gpqO3if0guVS3XZrPHNZ4A==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":129147},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","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/index.d.ts","default":"./dist/client/index.js"},"require":{"types":"./dist/client/index.d.cts","default":"./dist/client/index.cjs"}},"./server":{"import":{"types":"./dist/server/index.d.ts","default":"./dist/server/index.js"},"require":{"types":"./dist/server/index.d.cts","default":"./dist/server/index.cjs"}}},"gitHead":"b40769ad38d260065dc25d3f0212c8d9416c0c43","scripts":{"build":"tsup","clean":"rm -rf dist","typecheck":"tsc --noEmit","prepublishOnly":"bun run build"},"_npmUser":{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"},"repository":{"url":"git+https://github.com/BAFE-PKMDD/central-auth-sdk.git","type":"git"},"_npmVersion":"10.9.3","description":"Framework-agnostic JavaScript SDK for Central Auth — token management, JWT verification, and refresh flow utilities.","directories":{},"_nodeVersion":"22.20.0","dependencies":{"jose":"^6.0.11"},"_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.4.0","typescript":"~5.7.2"},"_npmOperationalInternal":{"tmp":"tmp/central-auth-sdk_0.5.2_1773923886839_0.8489924614982605","host":"s3://npm-registry-packages-npm-production"}},"0.5.3":{"name":"@bafe-pkmdd/central-auth-sdk","version":"0.5.3","keywords":["central-auth","jwt","authentication","token-refresh","jwks"],"license":"MIT","_id":"@bafe-pkmdd/central-auth-sdk@0.5.3","maintainers":[{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"}],"homepage":"https://github.com/BAFE-PKMDD/central-auth-sdk#readme","bugs":{"url":"https://github.com/BAFE-PKMDD/central-auth-sdk/issues"},"dist":{"shasum":"9c50f6e76882d883d7835665a01f13eb24b77ce8","tarball":"https://registry.npmjs.org/@bafe-pkmdd/central-auth-sdk/-/central-auth-sdk-0.5.3.tgz","fileCount":34,"integrity":"sha512-2WiJS4f8lmw49zK4pgkSmJcgDVsGkutpnilrbuP62uTpuME53rNr9wQVldtwN9Xi8FKRlPxxvf8TCRJ47hdgdQ==","signatures":[{"sig":"MEUCIFT+go+AG0OYQua2hdvl3lAVbTi+7Yk39vKffFft8uMwAiEA+pyek8pY72uBlPhYUX5V2gjKAGYyc2u7HE8YrUUdeZ4=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":129545},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","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/index.d.ts","default":"./dist/client/index.js"},"require":{"types":"./dist/client/index.d.cts","default":"./dist/client/index.cjs"}},"./server":{"import":{"types":"./dist/server/index.d.ts","default":"./dist/server/index.js"},"require":{"types":"./dist/server/index.d.cts","default":"./dist/server/index.cjs"}}},"gitHead":"e737fa6e518d59e14f7c6f8dee52352cbeab0df4","scripts":{"build":"tsup","clean":"rm -rf dist","typecheck":"tsc --noEmit","prepublishOnly":"bun run build"},"_npmUser":{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"},"repository":{"url":"git+https://github.com/BAFE-PKMDD/central-auth-sdk.git","type":"git"},"_npmVersion":"10.9.3","description":"Framework-agnostic JavaScript SDK for Central Auth — token management, JWT verification, and refresh flow utilities.","directories":{},"_nodeVersion":"22.20.0","dependencies":{"jose":"^6.0.11"},"_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.4.0","typescript":"~5.7.2"},"_npmOperationalInternal":{"tmp":"tmp/central-auth-sdk_0.5.3_1774500187299_0.2400934429530912","host":"s3://npm-registry-packages-npm-production"}},"0.5.4":{"name":"@bafe-pkmdd/central-auth-sdk","version":"0.5.4","keywords":["central-auth","jwt","authentication","token-refresh","jwks"],"license":"MIT","_id":"@bafe-pkmdd/central-auth-sdk@0.5.4","maintainers":[{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"}],"homepage":"https://github.com/BAFE-PKMDD/central-auth-sdk#readme","bugs":{"url":"https://github.com/BAFE-PKMDD/central-auth-sdk/issues"},"dist":{"shasum":"0ca1ffd93de850aced0552afb7fedfbfbf8cd70a","tarball":"https://registry.npmjs.org/@bafe-pkmdd/central-auth-sdk/-/central-auth-sdk-0.5.4.tgz","fileCount":34,"integrity":"sha512-wNEEEcukoQpaiOLixHPuP7caNIjWRQAThyd0eoIre3I2Wg+qL9xwUivgxUqAHFd/fXHDzR2qtymGbRH1oAq7fg==","signatures":[{"sig":"MEUCIQD/TOkIUrc1zr6bCTnMZpdvm4ToRzAeDq7AmQ+umgtaagIgDZbsuRWCB1K3zF1bV+EH0AQRflP+LVPsl9stk8gPrvU=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":137942},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","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/index.d.ts","default":"./dist/client/index.js"},"require":{"types":"./dist/client/index.d.cts","default":"./dist/client/index.cjs"}},"./server":{"import":{"types":"./dist/server/index.d.ts","default":"./dist/server/index.js"},"require":{"types":"./dist/server/index.d.cts","default":"./dist/server/index.cjs"}}},"gitHead":"3425e70a4b27417c9bab2d473b7cc91f93755673","scripts":{"build":"tsup","clean":"rm -rf dist","typecheck":"tsc --noEmit","prepublishOnly":"bun run build"},"_npmUser":{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"},"repository":{"url":"git+https://github.com/BAFE-PKMDD/central-auth-sdk.git","type":"git"},"_npmVersion":"10.9.3","description":"Framework-agnostic JavaScript SDK for Central Auth — token management, JWT verification, and refresh flow utilities.","directories":{},"_nodeVersion":"22.20.0","dependencies":{"jose":"^6.0.11"},"_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.4.0","typescript":"~5.7.2"},"_npmOperationalInternal":{"tmp":"tmp/central-auth-sdk_0.5.4_1776216835064_0.5269960123398252","host":"s3://npm-registry-packages-npm-production"}},"0.6.0":{"name":"@bafe-pkmdd/central-auth-sdk","version":"0.6.0","keywords":["central-auth","jwt","authentication","token-refresh","jwks"],"license":"MIT","_id":"@bafe-pkmdd/central-auth-sdk@0.6.0","maintainers":[{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"}],"homepage":"https://github.com/BAFE-PKMDD/central-auth-sdk#readme","bugs":{"url":"https://github.com/BAFE-PKMDD/central-auth-sdk/issues"},"dist":{"shasum":"f570e7558a809a5ecf6102b7a91fee91a4b16016","tarball":"https://registry.npmjs.org/@bafe-pkmdd/central-auth-sdk/-/central-auth-sdk-0.6.0.tgz","fileCount":34,"integrity":"sha512-2JRgz9hm+QfONZqPCo43c74NUULnGmu10EDirUSZo39jaMdF6wmH5YKyFgRWSBJhPH1LjmXHr9R+HcGwp288pQ==","signatures":[{"sig":"MEQCICas3HH6FYSh+IPxLKhb2TXEhrQhzwlsvlRL+t5yrhShAiACdEjdrR2nFNhijqnNvwc6J19C5bTGVMXq5mJKIc+3wQ==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":139218},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","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/index.d.ts","default":"./dist/client/index.js"},"require":{"types":"./dist/client/index.d.cts","default":"./dist/client/index.cjs"}},"./server":{"import":{"types":"./dist/server/index.d.ts","default":"./dist/server/index.js"},"require":{"types":"./dist/server/index.d.cts","default":"./dist/server/index.cjs"}}},"gitHead":"80e40d169316ce46e0b9e0cefca9a24d6fc68007","scripts":{"build":"tsup","clean":"rm -rf dist","typecheck":"tsc --noEmit","prepublishOnly":"bun run build"},"_npmUser":{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"},"repository":{"url":"git+https://github.com/BAFE-PKMDD/central-auth-sdk.git","type":"git"},"_npmVersion":"10.9.3","description":"Framework-agnostic JavaScript SDK for Central Auth — token management, JWT verification, and refresh flow utilities.","directories":{},"_nodeVersion":"22.20.0","dependencies":{"jose":"^6.0.11"},"_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.4.0","typescript":"~5.7.2"},"_npmOperationalInternal":{"tmp":"tmp/central-auth-sdk_0.6.0_1778719953570_0.9328255615123071","host":"s3://npm-registry-packages-npm-production"}},"0.6.1":{"name":"@bafe-pkmdd/central-auth-sdk","version":"0.6.1","keywords":["central-auth","jwt","authentication","token-refresh","jwks"],"license":"MIT","_id":"@bafe-pkmdd/central-auth-sdk@0.6.1","maintainers":[{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"}],"homepage":"https://github.com/BAFE-PKMDD/central-auth-sdk#readme","bugs":{"url":"https://github.com/BAFE-PKMDD/central-auth-sdk/issues"},"dist":{"shasum":"99eeb13274ca690587d945fb1e45b33c6fc912d5","tarball":"https://registry.npmjs.org/@bafe-pkmdd/central-auth-sdk/-/central-auth-sdk-0.6.1.tgz","fileCount":34,"integrity":"sha512-AsHX5L6vCMeRr4vmHYygTiX6GTgM5b4O6rnHZAdwnrbUKmQYve9kKvS0qk8HTA3BJCz+4J333Vh2b/W7vU7oLg==","signatures":[{"sig":"MEUCIQCO7hHf/ECfS9NpIUmXAGRK1o9AUMcE8cPUoU8mPAVV7QIgdISBLG3KT0BQxZ2Yp7u5r18lKRPIT8icklsdB5Lb0tE=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":139758},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","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/index.d.ts","default":"./dist/client/index.js"},"require":{"types":"./dist/client/index.d.cts","default":"./dist/client/index.cjs"}},"./server":{"import":{"types":"./dist/server/index.d.ts","default":"./dist/server/index.js"},"require":{"types":"./dist/server/index.d.cts","default":"./dist/server/index.cjs"}}},"gitHead":"89c538218ce393185b19ac61db3132e613c3be67","scripts":{"build":"tsup","clean":"rm -rf dist","typecheck":"tsc --noEmit","prepublishOnly":"bun run build"},"_npmUser":{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"},"repository":{"url":"git+https://github.com/BAFE-PKMDD/central-auth-sdk.git","type":"git"},"_npmVersion":"10.9.3","description":"Framework-agnostic JavaScript SDK for Central Auth — token management, JWT verification, and refresh flow utilities.","directories":{},"_nodeVersion":"22.20.0","dependencies":{"jose":"^6.0.11"},"_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.4.0","typescript":"~5.7.2"},"_npmOperationalInternal":{"tmp":"tmp/central-auth-sdk_0.6.1_1778742312917_0.8708656784656048","host":"s3://npm-registry-packages-npm-production"}},"0.6.2":{"name":"@bafe-pkmdd/central-auth-sdk","version":"0.6.2","keywords":["central-auth","jwt","authentication","token-refresh","jwks"],"license":"MIT","_id":"@bafe-pkmdd/central-auth-sdk@0.6.2","maintainers":[{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"}],"homepage":"https://github.com/BAFE-PKMDD/central-auth-sdk#readme","bugs":{"url":"https://github.com/BAFE-PKMDD/central-auth-sdk/issues"},"dist":{"shasum":"6c0c09f4ad2d9f2ef5e49fccdfa2d77b3b392f8c","tarball":"https://registry.npmjs.org/@bafe-pkmdd/central-auth-sdk/-/central-auth-sdk-0.6.2.tgz","fileCount":34,"integrity":"sha512-QvXfuPBkNejgG6HKoBvpYFNUC0yWwOnTLnRGAsVwstfrAZjrXAEXq7vqwQrwqxCVmbvN1593ecZYxXQOxlZmjg==","signatures":[{"sig":"MEYCIQDj9EixNHjeXpE48Gd1quVaF4Fvx/SYJJrWDg+f+lSqjwIhAODjpq/6JDWWk0lQscXzZsTXtgpDsK+WZl+v4hFIwB/E","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":140998},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","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/index.d.ts","default":"./dist/client/index.js"},"require":{"types":"./dist/client/index.d.cts","default":"./dist/client/index.cjs"}},"./server":{"import":{"types":"./dist/server/index.d.ts","default":"./dist/server/index.js"},"require":{"types":"./dist/server/index.d.cts","default":"./dist/server/index.cjs"}}},"gitHead":"fe674b975e43f70cb0dcb8fe10700b3bde426799","scripts":{"build":"tsup","clean":"rm -rf dist","typecheck":"tsc --noEmit","prepublishOnly":"bun run build"},"_npmUser":{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"},"repository":{"url":"git+https://github.com/BAFE-PKMDD/central-auth-sdk.git","type":"git"},"_npmVersion":"11.16.0","description":"Framework-agnostic JavaScript SDK for Central Auth — token management, JWT verification, and refresh flow utilities.","directories":{},"_nodeVersion":"24.18.0","dependencies":{"jose":"^6.0.11"},"_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.4.0","typescript":"~5.7.2"},"_npmOperationalInternal":{"tmp":"tmp/central-auth-sdk_0.6.2_1786081357120_0.22629343290326287","host":"s3://npm-registry-packages-npm-production"}},"0.6.3":{"name":"@bafe-pkmdd/central-auth-sdk","version":"0.6.3","keywords":["central-auth","jwt","authentication","token-refresh","jwks"],"license":"MIT","_id":"@bafe-pkmdd/central-auth-sdk@0.6.3","maintainers":[{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"}],"homepage":"https://github.com/BAFE-PKMDD/central-auth-sdk#readme","bugs":{"url":"https://github.com/BAFE-PKMDD/central-auth-sdk/issues"},"dist":{"shasum":"d51c4ec519da084f6a10773146e05d2897b39d90","tarball":"https://registry.npmjs.org/@bafe-pkmdd/central-auth-sdk/-/central-auth-sdk-0.6.3.tgz","fileCount":34,"integrity":"sha512-We5lNXPLs82hzauPxgWjm4Bbyw8W80wHrt7SwwEKrC2FDi7N3C1kIq2nokFomfjsZsCd4Bhu9a+hJ5Hh5NWdkg==","signatures":[{"sig":"MEYCIQCxBPi78OHc1nz6LnokDcOIBG8WNv/nb/byj2vgQt4aGAIhAJP7r4zQHc0yUZd1yZCCDAGsnjKAy1H2UF/qKWOc8++T","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":141288},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","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/index.d.ts","default":"./dist/client/index.js"},"require":{"types":"./dist/client/index.d.cts","default":"./dist/client/index.cjs"}},"./server":{"import":{"types":"./dist/server/index.d.ts","default":"./dist/server/index.js"},"require":{"types":"./dist/server/index.d.cts","default":"./dist/server/index.cjs"}}},"gitHead":"82de348e117b2c7ee9e9d039b7e8d4840d752b85","scripts":{"build":"tsup","clean":"rm -rf dist","typecheck":"tsc --noEmit","prepublishOnly":"bun run build"},"_npmUser":{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"},"repository":{"url":"git+https://github.com/BAFE-PKMDD/central-auth-sdk.git","type":"git"},"_npmVersion":"11.16.0","description":"Framework-agnostic JavaScript SDK for Central Auth — token management, JWT verification, and refresh flow utilities.","directories":{},"_nodeVersion":"24.18.0","dependencies":{"jose":"^6.0.11"},"_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.4.0","typescript":"~5.7.2"},"_npmOperationalInternal":{"tmp":"tmp/central-auth-sdk_0.6.3_1786628275194_0.2638505237419382","host":"s3://npm-registry-packages-npm-production"}},"0.6.4":{"name":"@bafe-pkmdd/central-auth-sdk","version":"0.6.4","keywords":["central-auth","jwt","authentication","token-refresh","jwks"],"license":"MIT","_id":"@bafe-pkmdd/central-auth-sdk@0.6.4","maintainers":[{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"}],"homepage":"https://github.com/BAFE-PKMDD/central-auth-sdk#readme","bugs":{"url":"https://github.com/BAFE-PKMDD/central-auth-sdk/issues"},"dist":{"shasum":"20af9f79e9d93e4bcd8dfdadfcc634371f0367d5","tarball":"https://registry.npmjs.org/@bafe-pkmdd/central-auth-sdk/-/central-auth-sdk-0.6.4.tgz","fileCount":34,"integrity":"sha512-OaFmCAYzlO7Ue2szAcqlBCrTYuW4PqoJEJ1sp06qqG382vqsu6DM6tyYPGmvSD7SXsELwZoMhkfdNC4mY4BArA==","signatures":[{"sig":"MEUCIFuPFB/QefjL4MP0I5MkvOffCC3B26XKh57scVj9/Z9ZAiEAt7t9gIvpxAGE29+u1U0Qy+AgowaW5BfT7nQ217dNoQk=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":141908},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","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/index.d.ts","default":"./dist/client/index.js"},"require":{"types":"./dist/client/index.d.cts","default":"./dist/client/index.cjs"}},"./server":{"import":{"types":"./dist/server/index.d.ts","default":"./dist/server/index.js"},"require":{"types":"./dist/server/index.d.cts","default":"./dist/server/index.cjs"}}},"gitHead":"72671659a6e2839fb3e17dafaa35f6945b8853bb","scripts":{"build":"tsup","clean":"rm -rf dist","typecheck":"tsc --noEmit","prepublishOnly":"bun run build"},"_npmUser":{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"},"repository":{"url":"git+https://github.com/BAFE-PKMDD/central-auth-sdk.git","type":"git"},"_npmVersion":"11.16.0","description":"Framework-agnostic JavaScript SDK for Central Auth — token management, JWT verification, and refresh flow utilities.","directories":{},"_nodeVersion":"24.18.0","dependencies":{"jose":"^6.0.11"},"_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.4.0","typescript":"~5.7.2"},"_npmOperationalInternal":{"tmp":"tmp/central-auth-sdk_0.6.4_1786629712471_0.5459730686775934","host":"s3://npm-registry-packages-npm-production"}},"0.7.1":{"name":"@bafe-pkmdd/central-auth-sdk","version":"0.7.1","keywords":["central-auth","jwt","authentication","token-refresh","jwks"],"license":"MIT","_id":"@bafe-pkmdd/central-auth-sdk@0.7.1","maintainers":[{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"}],"homepage":"https://github.com/BAFE-PKMDD/central-auth-sdk#readme","bugs":{"url":"https://github.com/BAFE-PKMDD/central-auth-sdk/issues"},"dist":{"shasum":"3803dbdbf5c403ba1947a649d82e36e8b30dfb81","tarball":"https://registry.npmjs.org/@bafe-pkmdd/central-auth-sdk/-/central-auth-sdk-0.7.1.tgz","fileCount":34,"integrity":"sha512-9T2NCb/mLpFnmQ/z52T4AXWMwBf2pBOSro//eOGovDatbEd5Kl7z8P5nb4H3pdsa3ZF169INgxTqL4qUahrxBQ==","signatures":[{"sig":"MEUCIF3kzVqjPeWDGxNA8//QEESANDJ3Ej/btprNFTSWr7B1AiEAjGvfo0FWwp2omAZdGnFyLc1vASvcOruIEb0QLF4Jo6g=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"},{"sig":"MEUCIGq63HMKjlRYPgd98gO5ZRVtydgPBIcuazTQc2a/qJzlAiEAnguVMulYQG/MkE4KidIMVU/UJVyLWoMB3loEyRSyHa0=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":145356},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","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/index.d.ts","default":"./dist/client/index.js"},"require":{"types":"./dist/client/index.d.cts","default":"./dist/client/index.cjs"}},"./server":{"import":{"types":"./dist/server/index.d.ts","default":"./dist/server/index.js"},"require":{"types":"./dist/server/index.d.cts","default":"./dist/server/index.cjs"}}},"gitHead":"d03933b16fd746b475e3a396004627897e0bdac0","scripts":{"build":"tsup","clean":"rm -rf dist","typecheck":"tsc --noEmit","prepublishOnly":"bun run build"},"_npmUser":{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"},"repository":{"url":"git+https://github.com/BAFE-PKMDD/central-auth-sdk.git","type":"git"},"_npmVersion":"11.17.0","description":"Framework-agnostic JavaScript SDK for Central Auth — token management, JWT verification, and refresh flow utilities.","directories":{},"_nodeVersion":"24.19.0","dependencies":{"jose":"^6.0.11"},"_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.4.0","typescript":"~5.7.2"},"_npmOperationalInternal":{"tmp":"tmp/central-auth-sdk_0.7.1_1789625232323_0.6049178906018531","host":"s3://npm-registry-packages-npm-production"}},"0.7.2":{"name":"@bafe-pkmdd/central-auth-sdk","version":"0.7.2","keywords":["central-auth","jwt","authentication","token-refresh","jwks"],"license":"MIT","_id":"@bafe-pkmdd/central-auth-sdk@0.7.2","maintainers":[{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"}],"homepage":"https://github.com/BAFE-PKMDD/central-auth-sdk#readme","bugs":{"url":"https://github.com/BAFE-PKMDD/central-auth-sdk/issues"},"dist":{"shasum":"3f3a41d98569401425fcecfba05d6db94a109a1c","tarball":"https://registry.npmjs.org/@bafe-pkmdd/central-auth-sdk/-/central-auth-sdk-0.7.2.tgz","fileCount":34,"integrity":"sha512-FpL6/7mKk5ugF4zLEzKi2TE8NbPKDtBaBOQ+UMNXXGcgBTHGUvGRtgyIVBWUP4igXikvKjbmeQTO33giCKEZaA==","signatures":[{"sig":"MEUCIGUZ3AvuKGNAEGnUjA20YpOjy/sfPAUQCZDq8M5Ft/ltAiEA+2APPsymIAaJxVrXu65yga1R+huOgx2mTBjbCKTVemQ=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"},{"sig":"MEQCID+2wDVIjYa95Id9+N059YAn1Kw2nCtNcCTGbXzBQwFIAiA6F8/BGdCKzxFGYjCv4JshvHlLnnHtbOXXnyql/enB8A==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":146132},"main":"./dist/index.cjs","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","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/index.d.ts","default":"./dist/client/index.js"},"require":{"types":"./dist/client/index.d.cts","default":"./dist/client/index.cjs"}},"./server":{"import":{"types":"./dist/server/index.d.ts","default":"./dist/server/index.js"},"require":{"types":"./dist/server/index.d.cts","default":"./dist/server/index.cjs"}}},"gitHead":"d03933b16fd746b475e3a396004627897e0bdac0","scripts":{"build":"tsup","clean":"rm -rf dist","typecheck":"tsc --noEmit","prepublishOnly":"bun run build"},"_npmUser":{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"},"repository":{"url":"git+https://github.com/BAFE-PKMDD/central-auth-sdk.git","type":"git"},"_npmVersion":"11.17.0","description":"Framework-agnostic JavaScript SDK for Central Auth — token management, JWT verification, and refresh flow utilities.","directories":{},"_nodeVersion":"24.19.0","dependencies":{"jose":"^6.0.11"},"_hasShrinkwrap":false,"readmeFilename":"README.md","devDependencies":{"tsup":"^8.4.0","typescript":"~5.7.2"},"_npmOperationalInternal":{"tmp":"tmp/central-auth-sdk_0.7.2_1789626710906_0.8449053547414818","host":"s3://npm-registry-packages-npm-production"}},"0.7.3":{"_id":"@bafe-pkmdd/central-auth-sdk@0.7.3","bugs":{"url":"https://github.com/BAFE-PKMDD/central-auth-sdk/issues"},"dist":{"shasum":"db321d92483dc511823d7a778c5c30ce41c19c63","tarball":"https://registry.npmjs.org/@bafe-pkmdd/central-auth-sdk/-/central-auth-sdk-0.7.3.tgz","fileCount":34,"integrity":"sha512-+CvP2nQuCPhUv2CB9xIcrFWxSO9DQhLOcR77de9LyWuRilQGPSOAQgUYg3F+vwCUuSG6zift25A3erCgaFtrLw==","signatures":[{"sig":"MEUCIQC+Mmoqff4WQN719b3nYCDpBHZuA21AAbc/6B/Hoc7zjAIgTqHFT3cp4Cslt4DSlo5GURNCMbGyjoL+LqF/uGhLAzs=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"},{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIQC5nzYbBhg2ZGM0nVtJ4ni/Hau9Z91SS8Ti51/1l3G+tAIgAwNWkhke0RG0m94PTEbvBg2EM3iUC7hMHwXMc5Bh2aU="}],"unpackedSize":146132},"main":"./dist/index.cjs","name":"@bafe-pkmdd/central-auth-sdk","type":"module","types":"./dist/index.d.ts","module":"./dist/index.js","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/index.d.ts","default":"./dist/client/index.js"},"require":{"types":"./dist/client/index.d.cts","default":"./dist/client/index.cjs"}},"./server":{"import":{"types":"./dist/server/index.d.ts","default":"./dist/server/index.js"},"require":{"types":"./dist/server/index.d.cts","default":"./dist/server/index.cjs"}}},"gitHead":"d0cca82cd23acbfea167268a2d4eeed5918cb229","license":"MIT","scripts":{"build":"tsup","clean":"rm -rf dist","typecheck":"tsc --noEmit","prepublishOnly":"bun run build"},"version":"0.7.3","_npmUser":{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"},"homepage":"https://github.com/BAFE-PKMDD/central-auth-sdk#readme","keywords":["central-auth","jwt","authentication","token-refresh","jwks"],"repository":{"url":"git+https://github.com/BAFE-PKMDD/central-auth-sdk.git","type":"git"},"_npmVersion":"11.17.0","description":"Framework-agnostic JavaScript SDK for Central Auth — token management, JWT verification, and refresh flow utilities.","directories":{},"maintainers":[{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"}],"_nodeVersion":"24.19.0","dependencies":{"jose":"^6.0.11"},"_hasShrinkwrap":false,"devDependencies":{"tsup":"^8.4.0","typescript":"~5.7.2"},"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/central-auth-sdk_0.7.3_1789626749065_0.41272474916046464"}}},"time":{"created":"2026-03-01T11:13:54.599Z","modified":"2026-09-17T06:32:29.419Z","0.1.0":"2026-03-01T11:13:54.839Z","0.2.0":"2026-03-02T11:27:30.887Z","0.3.0":"2026-03-04T13:19:11.758Z","0.4.0":"2026-03-04T13:38:35.016Z","0.5.0":"2026-03-05T09:09:40.800Z","0.5.1":"2026-03-10T13:06:21.971Z","0.5.2":"2026-03-19T12:38:06.975Z","0.5.3":"2026-03-26T04:43:07.439Z","0.5.4":"2026-04-15T01:33:55.226Z","0.6.0":"2026-05-14T00:52:33.723Z","0.6.1":"2026-05-14T07:05:13.054Z","0.6.2":"2026-08-07T05:42:37.271Z","0.6.3":"2026-08-13T13:37:55.348Z","0.6.4":"2026-08-13T14:01:52.626Z","0.7.1":"2026-09-17T06:07:12.435Z","0.7.2":"2026-09-17T06:31:50.988Z","0.7.3":"2026-09-17T06:32:29.176Z"},"bugs":{"url":"https://github.com/BAFE-PKMDD/central-auth-sdk/issues"},"license":"MIT","homepage":"https://github.com/BAFE-PKMDD/central-auth-sdk#readme","keywords":["central-auth","jwt","authentication","token-refresh","jwks"],"repository":{"url":"git+https://github.com/BAFE-PKMDD/central-auth-sdk.git","type":"git"},"description":"Framework-agnostic JavaScript SDK for Central Auth — token management, JWT verification, and refresh flow utilities.","maintainers":[{"name":"mis_support","email":"mis_support@bafe.da.gov.ph"}],"readme":"# @bafe-pkmdd/central-auth-sdk\r\n\r\nA framework-agnostic JavaScript/TypeScript SDK for applications integrating with **Central Auth** — the centralized authentication service.\r\n\r\nThis SDK provides:\r\n\r\n- **Client SDK** — Token storage, JWT decode, and automatic refresh flow (works with React, Vue, Svelte, vanilla JS, etc.)\r\n- **Server SDK** — JWT verification via JWKS and token refresh proxy helpers (works with Express, Fastify, Hono, Koa, etc.)\r\n\r\n---\r\n\r\n## Installation\r\n\r\n```bash\r\n# npm\r\nnpm install @bafe-pkmdd/central-auth-sdk\r\n\r\n# bun\r\nbun add @bafe-pkmdd/central-auth-sdk\r\n\r\n# yarn\r\nyarn add @bafe-pkmdd/central-auth-sdk\r\n\r\n# pnpm\r\npnpm add @bafe-pkmdd/central-auth-sdk\r\n```\r\n\r\n---\r\n\r\n## Prerequisites\r\n\r\nBefore using this SDK, you need:\r\n\r\n1. A running **Central Auth** instance\r\n2. A registered **application** in Central Auth with:\r\n   - A `CLIENT_ID`\r\n   - A `CLIENT_SECRET` (server-side only)\r\n   - An allowed **redirect URI** (e.g., `http://localhost:5173/callback`)\r\n\r\n---\r\n\r\n## Environment Variables\r\n\r\nSet these environment variables in your **server** application. Never expose these to the browser.\r\n\r\n| Variable | Description | Example |\r\n|---|---|---|\r\n| `CENTRAL_AUTH_URL` | Full URL of the Central Auth instance | `https://auth.example.com` |\r\n| `CLIENT_ID` | OAuth client ID from Central Auth app registration | `myapp_abc123def456` |\r\n| `CLIENT_SECRET` | OAuth client secret (⚠️ **server-side only**) | `sk_live_...` |\r\n\r\nFor local development, your `.env` file should look like:\r\n\r\n```env\r\nCENTRAL_AUTH_URL=http://localhost:3000\r\nCLIENT_ID=myapp_abc123def456\r\nCLIENT_SECRET=your_client_secret_here\r\n```\r\n\r\n> **⚠️ Security Note:** `CLIENT_SECRET` must NEVER be exposed to the browser. The SDK's architecture enforces this by having the client call your server's refresh proxy, which attaches the secret server-side.\r\n\r\n---\r\n\r\n## Quick Start\r\n\r\n### 1. Set up the server (token verification + refresh proxy)\r\n\r\n```ts\r\n// server.ts — works with any framework (Express, Fastify, Hono, etc.)\r\nimport {\r\n  verifyAccessToken,\r\n  extractBearerToken,\r\n  proxyTokenRefresh,\r\n} from '@bafe-pkmdd/central-auth-sdk/server'\r\n\r\n// ─── Token Refresh Proxy ────────────────────────────────\r\n// This endpoint keeps CLIENT_SECRET server-side.\r\n// The browser sends only the refresh_token.\r\n\r\n// Express example:\r\napp.post('/auth/refresh', async (req, res) => {\r\n  try {\r\n    const result = await proxyTokenRefresh({\r\n      centralAuthUrl: process.env.CENTRAL_AUTH_URL!,\r\n      clientId: process.env.CLIENT_ID!,\r\n      clientSecret: process.env.CLIENT_SECRET!,\r\n      refreshToken: req.body.refresh_token,\r\n    })\r\n    res.json(result)\r\n  } catch (err) {\r\n    res.status(401).json({ error: err.message })\r\n  }\r\n})\r\n\r\n// ─── JWT Verification Middleware ─────────────────────────\r\n// Protects your API routes by verifying JWTs against Central Auth's JWKS.\r\n\r\napp.use('/api', async (req, res, next) => {\r\n  const token = extractBearerToken(req.headers.authorization)\r\n\r\n  if (!token) {\r\n    return res.status(401).json({ error: 'Missing Authorization header' })\r\n  }\r\n\r\n  const result = await verifyAccessToken(token, {\r\n    centralAuthUrl: process.env.CENTRAL_AUTH_URL!,\r\n  })\r\n\r\n  if (!result.success) {\r\n    const status = result.isExpired ? 401 : 403\r\n    return res.status(status).json({\r\n      error: result.error,\r\n      isExpired: result.isExpired,\r\n    })\r\n  }\r\n\r\n  // result.payload is typed as JWTPayload\r\n  req.user = result.payload\r\n  next()\r\n})\r\n```\r\n\r\n### 2. Set up the client (token storage + refresh flow)\r\n\r\n```ts\r\n// auth.ts — works with any frontend framework\r\nimport {\r\n  setToken,\r\n  setRefreshToken,\r\n  setTokenExpiry,\r\n  getToken,\r\n  getTokenTtl,\r\n  removeTokens,\r\n  decodeToken,\r\n  isAuthenticated,\r\n  createRefreshFlow,\r\n} from '@bafe-pkmdd/central-auth-sdk/client'\r\n\r\n// Create the refresh flow once at app level\r\nexport const auth = createRefreshFlow({\r\n  // URL of YOUR server's refresh proxy (not Central Auth directly)\r\n  refreshEndpoint: 'http://localhost:4000/auth/refresh',\r\n  // Central Auth instance URL (used for logout redirect)\r\n  centralAuthUrl: 'https://auth.example.com',\r\n  // Your app's client ID from Central Auth\r\n  clientId: 'myapp_abc123',\r\n  // Optional: how many seconds before expiry to refresh (default: 30)\r\n  refreshBufferSeconds: 30,\r\n  // Called when auto-refresh fails (e.g. refresh token revoked)\r\n  onLogout: () => {\r\n    window.location.href = '/login'\r\n  },\r\n})\r\n```\r\n\r\n### 3. Handle the OAuth callback\r\n\r\nAfter the user logs in via Central Auth, they're redirected back to your app with `token` and `refresh_token` in the URL query parameters.\r\n\r\n```ts\r\n// callback handler — works with any router\r\nfunction handleCallback() {\r\n  const params = new URLSearchParams(window.location.search)\r\n  const token = params.get('token')\r\n  const refreshToken = params.get('refresh_token')\r\n\r\n  if (token) {\r\n    // Store tokens\r\n    setToken(token)\r\n\r\n    if (refreshToken) {\r\n      setRefreshToken(refreshToken)\r\n      const ttl = getTokenTtl(token)\r\n      setTokenExpiry(ttl)\r\n      auth.schedule(ttl) // Start proactive refresh timer\r\n    }\r\n\r\n    // Decode user info from JWT (no verification — display only)\r\n    const user = decodeToken(token)\r\n    console.log('Logged in as:', user?.email)\r\n\r\n    // Redirect to dashboard\r\n    window.history.replaceState({}, '', '/dashboard')\r\n  }\r\n}\r\n```\r\n\r\n### 4. Initialize on page load\r\n\r\n```ts\r\n// main.ts or App entry point\r\nif (isAuthenticated()) {\r\n  auth.init() // Resumes refresh timer or refreshes if expired\r\n}\r\n```\r\n\r\n### 5. Logout\r\n\r\n```ts\r\nfunction handleLogout() {\r\n  // Full logout: stops timer, clears tokens, revokes refresh token,\r\n  // signs out central-auth session, then redirects back.\r\n  auth.logout()\r\n\r\n  // Optionally specify where to redirect after logout:\r\n  // auth.logout('https://myapp.com/goodbye')\r\n}\r\n```\r\n\r\n---\r\n\r\n## API Reference\r\n\r\n### Client SDK (`@bafe-pkmdd/central-auth-sdk/client`)\r\n\r\n#### Token Storage\r\n\r\n| Function | Signature | Description |\r\n|---|---|---|\r\n| `configureStorage` | `(prefix: string) => void` | Set a custom localStorage key prefix (default: `central_auth`) |\r\n| `getToken` | `() => string \\| null` | Retrieve stored access token |\r\n| `setToken` | `(token: string) => void` | Store access token |\r\n| `getRefreshToken` | `() => string \\| null` | Retrieve stored refresh token |\r\n| `setRefreshToken` | `(token: string) => void` | Store refresh token |\r\n| `setTokenExpiry` | `(expiresIn: number) => void` | Store expiry time (seconds from now) |\r\n| `getTokenExpiry` | `() => number` | Get stored expiry (Unix ms timestamp) |\r\n| `removeTokens` | `() => void` | Clear all auth data from localStorage |\r\n| `isAuthenticated` | `() => boolean` | Returns `true` if an access token exists |\r\n\r\n#### JWT Decode\r\n\r\n| Function | Signature | Description |\r\n|---|---|---|\r\n| `decodeToken` | `(token: string) => Record<string, unknown> \\| null` | Decode JWT payload (⚠️ no verification, display only) |\r\n| `getTokenTtl` | `(token: string) => number` | Seconds remaining until token expiry |\r\n\r\n#### Refresh Flow\r\n\r\n| Function | Signature | Description |\r\n|---|---|---|\r\n| `createRefreshFlow` | `(config: RefreshFlowConfig) => RefreshFlowInstance` | Create a managed refresh flow |\r\n\r\n**`RefreshFlowConfig`**:\r\n\r\n```ts\r\n{\r\n  refreshEndpoint: string       // URL of your server's refresh proxy\r\n  centralAuthUrl: string        // Central Auth instance URL (for logout redirect)\r\n  clientId: string              // OAuth client ID (passed to logout redirect)\r\n  refreshBufferSeconds?: number // Seconds before expiry to refresh (default: 30)\r\n  onLogout?: () => void         // Called when auto-refresh fails\r\n}\r\n```\r\n\r\n**Returned instance methods**:\r\n\r\n| Method | Description |\r\n|---|---|\r\n| `refresh()` | Manually trigger a token refresh. Returns `Promise<boolean>`. |\r\n| `schedule(expiresIn)` | Schedule the next refresh `expiresIn` seconds from now. |\r\n| `init()` | Initialize on page load — refreshes immediately if expired, or schedules if valid. |\r\n| `stop()` | Stop the auto-refresh timer. |\r\n| `logout(redirectTo?)` | Full logout: stops timer, clears tokens, and redirects to Central Auth to revoke the session. |\r\n\r\n---\r\n\r\n### Server SDK (`@bafe-pkmdd/central-auth-sdk/server`)\r\n\r\n#### JWKS\r\n\r\n| Function | Signature | Description |\r\n|---|---|---|\r\n| `createJWKS` | `(centralAuthUrl: string) => JWKSKeySet` | Create a JWKS remote key set for JWT verification |\r\n\r\n#### Token Verification\r\n\r\n| Function | Signature | Description |\r\n|---|---|---|\r\n| `extractBearerToken` | `(authHeader?: string \\| null) => string \\| null` | Extract JWT from `Authorization: Bearer ...` header |\r\n| `verifyAccessToken` | `(token: string, config: VerifyTokenConfig) => Promise<VerifyTokenResult>` | Verify JWT against Central Auth JWKS |\r\n\r\n**`VerifyTokenConfig`**:\r\n\r\n```ts\r\n{\r\n  centralAuthUrl: string           // Central Auth instance URL\r\n  jwks?: JWKSKeySet                // Optional pre-created JWKS (for caching)\r\n}\r\n```\r\n\r\n**`VerifyTokenResult`** (discriminated union):\r\n\r\n```ts\r\n// Success\r\n{ success: true, payload: JWTPayload }\r\n\r\n// Failure\r\n{ success: false, error: string, isExpired: boolean }\r\n```\r\n\r\n#### Token Refresh Proxy\r\n\r\n| Function | Signature | Description |\r\n|---|---|---|\r\n| `proxyTokenRefresh` | `(config: TokenRefreshProxyConfig) => Promise<TokenRefreshResponse>` | Proxy a refresh request to Central Auth (keeps secrets server-side) |\r\n\r\n**`TokenRefreshProxyConfig`**:\r\n\r\n```ts\r\n{\r\n  centralAuthUrl: string   // Central Auth instance URL\r\n  clientId: string         // OAuth client ID\r\n  clientSecret: string     // OAuth client secret (SERVER-SIDE ONLY)\r\n  refreshToken: string     // Refresh token from the client\r\n}\r\n```\r\n\r\n**`TokenRefreshResponse`**:\r\n\r\n```ts\r\n{\r\n  access_token: string\r\n  refresh_token: string\r\n  token_type: string\r\n  expires_in: number\r\n}\r\n```\r\n\r\n#### Token Revoke Proxy\r\n\r\n| Function | Signature | Description |\r\n|---|---|---|\r\n| `proxyTokenRevoke` | `(config: TokenRevokeProxyConfig) => Promise<{ success: boolean }>` | Revoke a refresh token on Central Auth (server-to-server) |\r\n\r\n**`TokenRevokeProxyConfig`**:\r\n\r\n```ts\r\n{\r\n  centralAuthUrl: string   // Central Auth instance URL\r\n  clientId: string         // OAuth client ID\r\n  clientSecret: string     // OAuth client secret (SERVER-SIDE ONLY)\r\n  refreshToken: string     // Refresh token to revoke\r\n}\r\n```\r\n\r\n---\r\n\r\n### Shared Types (`@bafe-pkmdd/central-auth-sdk`)\r\n\r\n**`JWTPayload`** — Central Auth JWT claims:\r\n\r\n```ts\r\n{\r\n  sub: string                    // User ID\r\n  email: string                  // User email\r\n  name: string                   // Display name\r\n  role?: string                  // Global role\r\n  activeOrganizationId?: string  // Active org context\r\n  appRole?: {                    // App-specific RBAC role\r\n    name: string\r\n    color: string | null\r\n  } | null\r\n  permissions?: string[]         // Flat permission list (e.g. \"project:read\")\r\n  exp?: number                   // Expiry (Unix seconds)\r\n  iat?: number                   // Issued-at (Unix seconds)\r\n}\r\n```\r\n\r\n---\r\n\r\n## Framework Examples\r\n\r\n### Express.js\r\n\r\n```ts\r\nimport express from 'express'\r\nimport { verifyAccessToken, extractBearerToken, proxyTokenRefresh } from '@bafe-pkmdd/central-auth-sdk/server'\r\n\r\nconst app = express()\r\napp.use(express.json())\r\n\r\napp.post('/auth/refresh', async (req, res) => {\r\n  try {\r\n    const result = await proxyTokenRefresh({\r\n      centralAuthUrl: process.env.CENTRAL_AUTH_URL!,\r\n      clientId: process.env.CLIENT_ID!,\r\n      clientSecret: process.env.CLIENT_SECRET!,\r\n      refreshToken: req.body.refresh_token,\r\n    })\r\n    res.json(result)\r\n  } catch (err) {\r\n    res.status(401).json({ error: (err as Error).message })\r\n  }\r\n})\r\n\r\napp.use('/api', async (req, res, next) => {\r\n  const token = extractBearerToken(req.headers.authorization)\r\n  if (!token) return res.status(401).json({ error: 'Unauthorized' })\r\n\r\n  const result = await verifyAccessToken(token, {\r\n    centralAuthUrl: process.env.CENTRAL_AUTH_URL!,\r\n  })\r\n  if (!result.success) return res.status(401).json({ error: result.error })\r\n\r\n  req.user = result.payload\r\n  next()\r\n})\r\n\r\napp.get('/api/me', (req, res) => {\r\n  res.json({ user: req.user })\r\n})\r\n```\r\n\r\n### Hono\r\n\r\n```ts\r\nimport { Hono } from 'hono'\r\nimport { verifyAccessToken, extractBearerToken, proxyTokenRefresh } from '@bafe-pkmdd/central-auth-sdk/server'\r\n\r\nconst app = new Hono()\r\n\r\napp.post('/auth/refresh', async (c) => {\r\n  const body = await c.req.json()\r\n  try {\r\n    const result = await proxyTokenRefresh({\r\n      centralAuthUrl: process.env.CENTRAL_AUTH_URL!,\r\n      clientId: process.env.CLIENT_ID!,\r\n      clientSecret: process.env.CLIENT_SECRET!,\r\n      refreshToken: body.refresh_token,\r\n    })\r\n    return c.json(result)\r\n  } catch (err) {\r\n    return c.json({ error: (err as Error).message }, 401)\r\n  }\r\n})\r\n\r\napp.use('/api/*', async (c, next) => {\r\n  const token = extractBearerToken(c.req.header('Authorization'))\r\n  if (!token) return c.json({ error: 'Unauthorized' }, 401)\r\n\r\n  const result = await verifyAccessToken(token, {\r\n    centralAuthUrl: process.env.CENTRAL_AUTH_URL!,\r\n  })\r\n  if (!result.success) return c.json({ error: result.error }, 401)\r\n\r\n  c.set('user', result.payload)\r\n  await next()\r\n})\r\n```\r\n\r\n### Fastify\r\n\r\n```ts\r\nimport Fastify from 'fastify'\r\nimport { verifyAccessToken, extractBearerToken, proxyTokenRefresh } from '@bafe-pkmdd/central-auth-sdk/server'\r\n\r\nconst fastify = Fastify()\r\n\r\nfastify.post('/auth/refresh', async (request, reply) => {\r\n  try {\r\n    const result = await proxyTokenRefresh({\r\n      centralAuthUrl: process.env.CENTRAL_AUTH_URL!,\r\n      clientId: process.env.CLIENT_ID!,\r\n      clientSecret: process.env.CLIENT_SECRET!,\r\n      refreshToken: (request.body as any).refresh_token,\r\n    })\r\n    return result\r\n  } catch (err) {\r\n    reply.code(401).send({ error: (err as Error).message })\r\n  }\r\n})\r\n\r\nfastify.addHook('onRequest', async (request, reply) => {\r\n  if (!request.url.startsWith('/api')) return\r\n\r\n  const token = extractBearerToken(request.headers.authorization)\r\n  if (!token) return reply.code(401).send({ error: 'Unauthorized' })\r\n\r\n  const result = await verifyAccessToken(token, {\r\n    centralAuthUrl: process.env.CENTRAL_AUTH_URL!,\r\n  })\r\n  if (!result.success) return reply.code(401).send({ error: result.error })\r\n\r\n  request.user = result.payload\r\n})\r\n```\r\n\r\n### React (Client)\r\n\r\n```tsx\r\nimport { useEffect, useState } from 'react'\r\nimport {\r\n  setToken, setRefreshToken, setTokenExpiry,\r\n  getToken, getTokenTtl, removeTokens,\r\n  decodeToken, isAuthenticated, createRefreshFlow,\r\n} from '@bafe-pkmdd/central-auth-sdk/client'\r\n\r\nconst CENTRAL_AUTH_URL = 'https://auth.example.com'\r\nconst CLIENT_ID = 'myapp_abc123'\r\nconst CALLBACK_URL = 'http://localhost:5173/callback'\r\n\r\nconst auth = createRefreshFlow({\r\n  refreshEndpoint: '/auth/refresh',\r\n  centralAuthUrl: CENTRAL_AUTH_URL,\r\n  clientId: CLIENT_ID,\r\n  onLogout: () => { window.location.href = '/' },\r\n})\r\n\r\nfunction App() {\r\n  const [user, setUser] = useState(null)\r\n\r\n  useEffect(() => {\r\n    // Handle OAuth callback\r\n    if (window.location.pathname === '/callback') {\r\n      const params = new URLSearchParams(window.location.search)\r\n      const token = params.get('token')\r\n      const refreshToken = params.get('refresh_token')\r\n\r\n      if (token) {\r\n        setToken(token)\r\n        if (refreshToken) {\r\n          setRefreshToken(refreshToken)\r\n          const ttl = getTokenTtl(token)\r\n          setTokenExpiry(ttl)\r\n          auth.schedule(ttl)\r\n        }\r\n        setUser(decodeToken(token))\r\n        window.history.replaceState({}, '', '/dashboard')\r\n      }\r\n      return\r\n    }\r\n\r\n    // Resume session on page load\r\n    if (isAuthenticated()) {\r\n      setUser(decodeToken(getToken()!))\r\n      auth.init()\r\n    }\r\n  }, [])\r\n\r\n  const handleLogin = () => {\r\n    window.location.href =\r\n      `${CENTRAL_AUTH_URL}/auth/login?client_id=${CLIENT_ID}&redirect_to=${encodeURIComponent(CALLBACK_URL)}`\r\n  }\r\n\r\n  const handleLogout = () => {\r\n    auth.logout()\r\n  }\r\n\r\n  // ... render your app\r\n}\r\n```\r\n\r\n### Vue (Client)\r\n\r\n```ts\r\n// composables/use-auth.ts\r\nimport {\r\n  setToken, setRefreshToken, setTokenExpiry,\r\n  getToken, getTokenTtl, removeTokens,\r\n  decodeToken, isAuthenticated, createRefreshFlow,\r\n} from '@bafe-pkmdd/central-auth-sdk/client'\r\nimport { ref, onMounted } from 'vue'\r\n\r\nconst auth = createRefreshFlow({\r\n  refreshEndpoint: '/auth/refresh',\r\n  centralAuthUrl: import.meta.env.VITE_CENTRAL_AUTH_URL,\r\n  clientId: import.meta.env.VITE_CLIENT_ID,\r\n  onLogout: () => { window.location.href = '/login' },\r\n})\r\n\r\nexport function useAuth() {\r\n  const user = ref(null)\r\n\r\n  onMounted(() => {\r\n    if (isAuthenticated()) {\r\n      user.value = decodeToken(getToken()!)\r\n      auth.init()\r\n    }\r\n  })\r\n\r\n  function login(centralAuthUrl: string, clientId: string, callbackUrl: string) {\r\n    window.location.href =\r\n      `${centralAuthUrl}/auth/login?client_id=${clientId}&redirect_to=${encodeURIComponent(callbackUrl)}`\r\n  }\r\n\r\n  function logout() {\r\n    auth.logout()\r\n  }\r\n\r\n  return { user, login, logout, auth }\r\n}\r\n```\r\n\r\n---\r\n\r\n## Architecture\r\n\r\n```\r\n┌──────────────────────────────────────────────────┐\r\n│  Browser (React / Vue / Svelte / Vanilla)        │\r\n│                                                  │\r\n│  @bafe-pkmdd/central-auth-sdk/client                   │\r\n│  ┌────────────────┐  ┌─────────────────────────┐ │\r\n│  │ Token Storage   │  │ Refresh Flow            │ │\r\n│  │ (localStorage)  │  │ (auto-refresh timer)    │ │\r\n│  └────────────────┘  └────────┬────────────────┘ │\r\n│                               │ POST /auth/refresh│\r\n└───────────────────────────────┼──────────────────┘\r\n                                │\r\n┌───────────────────────────────▼──────────────────┐\r\n│  Your Backend (Express / Hono / Fastify / etc.)  │\r\n│                                                  │\r\n│  @bafe-pkmdd/central-auth-sdk/server                   │\r\n│  ┌─────────────────────┐  ┌────────────────────┐ │\r\n│  │ proxyTokenRefresh() │  │ verifyAccessToken() │ │\r\n│  │ (attaches secret)   │  │ (JWKS verification) │ │\r\n│  └─────────┬───────────┘  └──────────┬─────────┘ │\r\n│            │                         │            │\r\n└────────────┼─────────────────────────┼────────────┘\r\n             │                         │\r\n┌────────────▼─────────────────────────▼────────────┐\r\n│         Central Auth Service                       │\r\n│  POST /api/token/refresh    GET /api/auth/jwks     │\r\n└────────────────────────────────────────────────────┘\r\n```\r\n\r\n---\r\n\r\n## License\r\n\r\nMIT\r\n","readmeFilename":"README.md"}