{"_id":"@byteark/passport-clearkey-web-sdk","_rev":"4-7901688b0c4a352c749f3509e62381ac","name":"@byteark/passport-clearkey-web-sdk","dist-tags":{"latest":"0.4.1"},"versions":{"0.2.6":{"name":"@byteark/passport-clearkey-web-sdk","version":"0.2.6","author":"","license":"UNLICENSED","_id":"@byteark/passport-clearkey-web-sdk@0.2.6","maintainers":[{"name":"champjss","email":"champjss@gmail.com"},{"name":"tawanchai","email":"tawanchai_champ@hotmail.com"},{"name":"elvinxcs","email":"elvin@bstudio.click"},{"name":"nonth","email":"nonthz@gmail.com"},{"name":"magmagcup","email":"sirawich.d@gmail.com"},{"name":"cheemsdoge","email":"sprintf.null@gmail.com"},{"name":"maxmurray","email":"maxmurr.m@gmail.com"}],"dist":{"shasum":"81c80b34c6fe7c48f2180c57a128e52ccbad8c17","tarball":"https://registry.npmjs.org/@byteark/passport-clearkey-web-sdk/-/passport-clearkey-web-sdk-0.2.6.tgz","fileCount":14,"integrity":"sha512-4sEJL9bSk1r1GYgL4y7UX/In1Xhho7wQA4EW/CwvijZElGF1afna99Natcysd0D31aA0zx4JTpNwKAbdlyrqeQ==","signatures":[{"sig":"MEQCIBrVd6MzbaM6enkX1l00z4YLU+qFIZR2avWkDK1hL0gqAiAdd+lbe3qxrwNQSSAkhTAhdNmVqV5yA26Ut36QuNpc0g==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":24929},"main":"dist/index.js","_from":"file:byteark-passport-clearkey-web-sdk-0.2.6.tgz","types":"dist/index.d.ts","module":"dist/index.mjs","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.mjs","require":"./dist/index.js"},"./pure":{"types":"./dist/pure.d.ts","import":"./dist/pure.mjs","require":"./dist/pure.js"}},"scripts":{"build":"pnpm run clean && rollup -c rollup.config.mjs","clean":"rm -rf dist hosted/dist","build:all":"pnpm run build && pnpm run build:hosted","publish:cdn":"node scripts/publish.mjs","build:hosted":"rollup -c hosted/rollup.config.mjs"},"_npmUser":{"name":"cheemsdoge","email":"sprintf.null@gmail.com"},"_resolved":"/private/var/folders/y7/l5bqvrc97vb4z4v1mcfnm43w0000gn/T/477d235a308fdc127777ab23741f4dae/byteark-passport-clearkey-web-sdk-0.2.6.tgz","_integrity":"sha512-4sEJL9bSk1r1GYgL4y7UX/In1Xhho7wQA4EW/CwvijZElGF1afna99Natcysd0D31aA0zx4JTpNwKAbdlyrqeQ==","repository":{"url":"git+https://gitlab.inox.co.th/byteark/passport/passport-clearkey-web-sdk.git","type":"git"},"_npmVersion":"11.8.0","description":"Passport ClearKey Web SDK — cookie-based auth loader for HLS ClearKey playback","directories":{},"_nodeVersion":"24.13.1","_hasShrinkwrap":false,"devDependencies":{"rollup":"^4.0.0","mime-types":"^2.1.35","typescript":"~5.9.3","@aws-sdk/client-s3":"^3.700.0","@aws-sdk/lib-storage":"^3.700.0","@rollup/plugin-terser":"^0.4.4","rollup-plugin-typescript2":"^0.36.0"},"_npmOperationalInternal":{"tmp":"tmp/passport-clearkey-web-sdk_0.2.6_1771900026259_0.9310165125553673","host":"s3://npm-registry-packages-npm-production"}},"0.3.0":{"name":"@byteark/passport-clearkey-web-sdk","version":"0.3.0","author":"","license":"UNLICENSED","_id":"@byteark/passport-clearkey-web-sdk@0.3.0","maintainers":[{"name":"champjss","email":"champjss@gmail.com"},{"name":"tawanchai","email":"tawanchai_champ@hotmail.com"},{"name":"elvinxcs","email":"elvin@bstudio.click"},{"name":"nonth","email":"nonthz@gmail.com"},{"name":"magmagcup","email":"sirawich.d@gmail.com"},{"name":"cheemsdoge","email":"sprintf.null@gmail.com"},{"name":"maxmurray","email":"maxmurr.m@gmail.com"}],"dist":{"shasum":"465332e2f736c3c22d28bb572ba88c807f1e7f9b","tarball":"https://registry.npmjs.org/@byteark/passport-clearkey-web-sdk/-/passport-clearkey-web-sdk-0.3.0.tgz","fileCount":14,"integrity":"sha512-s/iWjFMqKy2sj3EPrT3gzH3AtZrSWxwDIVYIsabmuwX6SCahndDs03FBdthtUwhSA90a4+PCu2M7XP3ADMm1WQ==","signatures":[{"sig":"MEQCIC3PDfPuoBiNWZtP4FKfsngeeVUBgGIcI62AigHuhzOoAiAWIboUWpxh37x+GaH6LrzGQnhVGwgAymqiINnFgtUjEw==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":24809},"main":"dist/index.js","_from":"file:byteark-passport-clearkey-web-sdk-0.3.0.tgz","types":"dist/index.d.ts","module":"dist/index.mjs","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.mjs","require":"./dist/index.js"},"./pure":{"types":"./dist/pure.d.ts","import":"./dist/pure.mjs","require":"./dist/pure.js"}},"scripts":{"build":"pnpm run clean && rollup -c rollup.config.mjs","clean":"rm -rf dist hosted/dist","build:all":"pnpm run build && pnpm run build:hosted","publish:cdn":"node scripts/publish.mjs","build:hosted":"rollup -c hosted/rollup.config.mjs"},"_npmUser":{"name":"cheemsdoge","email":"sprintf.null@gmail.com"},"_resolved":"/private/var/folders/y7/l5bqvrc97vb4z4v1mcfnm43w0000gn/T/57627295dcef2d576d38fabc7ab8e520/byteark-passport-clearkey-web-sdk-0.3.0.tgz","_integrity":"sha512-s/iWjFMqKy2sj3EPrT3gzH3AtZrSWxwDIVYIsabmuwX6SCahndDs03FBdthtUwhSA90a4+PCu2M7XP3ADMm1WQ==","repository":{"url":"git+https://gitlab.inox.co.th/byteark/passport/passport-clearkey-web-sdk.git","type":"git"},"_npmVersion":"11.8.0","description":"Passport ClearKey Web SDK — cookie-based auth loader for HLS ClearKey playback","directories":{},"_nodeVersion":"24.13.1","_hasShrinkwrap":false,"devDependencies":{"rollup":"^4.0.0","mime-types":"^2.1.35","typescript":"~5.9.3","@aws-sdk/client-s3":"^3.700.0","@aws-sdk/lib-storage":"^3.700.0","@rollup/plugin-terser":"^0.4.4","rollup-plugin-typescript2":"^0.36.0"},"_npmOperationalInternal":{"tmp":"tmp/passport-clearkey-web-sdk_0.3.0_1772590794842_0.8046761111300238","host":"s3://npm-registry-packages-npm-production"}},"0.4.0":{"name":"@byteark/passport-clearkey-web-sdk","version":"0.4.0","author":"","license":"UNLICENSED","_id":"@byteark/passport-clearkey-web-sdk@0.4.0","maintainers":[{"name":"champjss","email":"champjss@gmail.com"},{"name":"tawanchai","email":"tawanchai_champ@hotmail.com"},{"name":"elvinxcs","email":"elvin@bstudio.click"},{"name":"nonth","email":"nonthz@gmail.com"},{"name":"magmagcup","email":"sirawich.d@gmail.com"},{"name":"cheemsdoge","email":"sprintf.null@gmail.com"},{"name":"maxmurray","email":"maxmurr.m@gmail.com"}],"dist":{"shasum":"72bef830bf08edfe727d2bbbc444293e37e62af2","tarball":"https://registry.npmjs.org/@byteark/passport-clearkey-web-sdk/-/passport-clearkey-web-sdk-0.4.0.tgz","fileCount":14,"integrity":"sha512-nF98+fZfK7Q97wBceTUeqXIrEGmRXzdwl+sxbs3Z4+e7tkkYIb7kqLlmQ0pqQMwbvNZtBWgmHDzFkSebC5C/bA==","signatures":[{"sig":"MEUCIQDpePSa1VTGYq4Qt8fPvte8syp4y3/R7bMQO2eRjS40RAIgbbo1PgtaonjP0VDkrTkrq0qGOr/GblIS2I3ihkS3WeU=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":12007},"main":"dist/index.js","_from":"file:byteark-passport-clearkey-web-sdk-0.4.0.tgz","types":"dist/index.d.ts","module":"dist/index.mjs","exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.mjs","require":"./dist/index.js"},"./pure":{"types":"./dist/pure.d.ts","import":"./dist/pure.mjs","require":"./dist/pure.js"}},"scripts":{"build":"pnpm run clean && rollup -c rollup.config.mjs","clean":"rm -rf dist hosted/dist","build:all":"pnpm run build && pnpm run build:hosted","publish:cdn":"node scripts/publish.mjs","build:hosted":"rollup -c hosted/rollup.config.mjs"},"_npmUser":{"name":"cheemsdoge","email":"sprintf.null@gmail.com"},"_resolved":"/private/var/folders/y7/l5bqvrc97vb4z4v1mcfnm43w0000gn/T/1abdb8634dc1fd07536e9de0124454a2/byteark-passport-clearkey-web-sdk-0.4.0.tgz","_integrity":"sha512-nF98+fZfK7Q97wBceTUeqXIrEGmRXzdwl+sxbs3Z4+e7tkkYIb7kqLlmQ0pqQMwbvNZtBWgmHDzFkSebC5C/bA==","repository":{"url":"git+https://gitlab.inox.co.th/byteark/passport/passport-clearkey-web-sdk.git","type":"git"},"_npmVersion":"11.8.0","description":"Passport ClearKey Web SDK — cookie-based auth loader for HLS ClearKey playback","directories":{},"_nodeVersion":"24.13.1","_hasShrinkwrap":false,"devDependencies":{"rollup":"^4.0.0","mime-types":"^2.1.35","typescript":"~5.9.3","@aws-sdk/client-s3":"^3.700.0","@aws-sdk/lib-storage":"^3.700.0","@rollup/plugin-terser":"^0.4.4","rollup-plugin-typescript2":"^0.36.0"},"_npmOperationalInternal":{"tmp":"tmp/passport-clearkey-web-sdk_0.4.0_1772674715026_0.9463931977642119","host":"s3://npm-registry-packages-npm-production"}},"0.4.1":{"name":"@byteark/passport-clearkey-web-sdk","version":"0.4.1","description":"Passport ClearKey Web SDK — cookie-based auth loader for HLS ClearKey playback","main":"dist/index.js","module":"dist/index.mjs","types":"dist/index.d.ts","exports":{".":{"import":"./dist/index.mjs","require":"./dist/index.js","types":"./dist/index.d.ts"},"./pure":{"import":"./dist/pure.mjs","require":"./dist/pure.js","types":"./dist/pure.d.ts"}},"repository":{"type":"git","url":"git+https://gitlab.inox.co.th/byteark/passport/passport-clearkey-web-sdk.git"},"author":"","license":"UNLICENSED","devDependencies":{"@aws-sdk/client-s3":"^3.700.0","@aws-sdk/lib-storage":"^3.700.0","@rollup/plugin-terser":"^0.4.4","mime-types":"^2.1.35","rollup":"^4.0.0","rollup-plugin-typescript2":"^0.36.0","typescript":"~5.9.3"},"scripts":{"build":"pnpm run clean && rollup -c rollup.config.mjs","build:hosted":"rollup -c hosted/rollup.config.mjs","build:all":"pnpm run build && pnpm run build:hosted","clean":"rm -rf dist hosted/dist","publish:cdn":"node scripts/publish.mjs"},"_id":"@byteark/passport-clearkey-web-sdk@0.4.1","_integrity":"sha512-rlhPXO+SlB1ndDIvsKFledzP4zMHnjlv7eDO/hNfebVO4POzF42gocTJxbZh3Yy7HBoZIYdM+zIk2L7kVLjfuA==","_resolved":"/private/var/folders/y7/l5bqvrc97vb4z4v1mcfnm43w0000gn/T/8ad0a6b95dd49c414a14a36287bd58d9/byteark-passport-clearkey-web-sdk-0.4.1.tgz","_from":"file:byteark-passport-clearkey-web-sdk-0.4.1.tgz","_nodeVersion":"24.13.1","_npmVersion":"11.8.0","dist":{"integrity":"sha512-rlhPXO+SlB1ndDIvsKFledzP4zMHnjlv7eDO/hNfebVO4POzF42gocTJxbZh3Yy7HBoZIYdM+zIk2L7kVLjfuA==","shasum":"00ef0273ae6cd9d1a964a87409ed8eab660dcfae","tarball":"https://registry.npmjs.org/@byteark/passport-clearkey-web-sdk/-/passport-clearkey-web-sdk-0.4.1.tgz","fileCount":14,"unpackedSize":12187,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIQCDeKYEMHlH+Mvl7szquQHaZHUqOrHLAIs/0OJ2Yb6ekAIgR3Hr6AvbDNxpl7VgHxhRVbMBa+Ph02E66j9F2fTWYrc="}]},"_npmUser":{"name":"cheemsdoge","email":"sprintf.null@gmail.com"},"directories":{},"maintainers":[{"name":"champjss","email":"champjss@gmail.com"},{"name":"tawanchai","email":"tawanchai_champ@hotmail.com"},{"name":"elvinxcs","email":"elvin@bstudio.click"},{"name":"nonth","email":"nonthz@gmail.com"},{"name":"magmagcup","email":"sirawich.d@gmail.com"},{"name":"cheemsdoge","email":"sprintf.null@gmail.com"},{"name":"maxmurray","email":"maxmurr.m@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/passport-clearkey-web-sdk_0.4.1_1772675814159_0.7092262834978469"},"_hasShrinkwrap":false}},"time":{"created":"2026-02-24T02:27:06.179Z","modified":"2026-03-05T01:56:54.484Z","0.2.6":"2026-02-24T02:27:06.407Z","0.3.0":"2026-03-04T02:19:55.009Z","0.4.0":"2026-03-05T01:38:35.175Z","0.4.1":"2026-03-05T01:56:54.297Z"},"license":"UNLICENSED","repository":{"type":"git","url":"git+https://gitlab.inox.co.th/byteark/passport/passport-clearkey-web-sdk.git"},"description":"Passport ClearKey Web SDK — cookie-based auth loader for HLS ClearKey playback","maintainers":[{"name":"champjss","email":"champjss@gmail.com"},{"name":"tawanchai","email":"tawanchai_champ@hotmail.com"},{"name":"elvinxcs","email":"elvin@bstudio.click"},{"name":"nonth","email":"nonthz@gmail.com"},{"name":"magmagcup","email":"sirawich.d@gmail.com"},{"name":"cheemsdoge","email":"sprintf.null@gmail.com"},{"name":"maxmurray","email":"maxmurr.m@gmail.com"}],"readme":"# @byteark/passport-clearkey-web-sdk\n\nLightweight wrapper for the Passport ClearKey Web SDK for HLS ClearKey playback.\n\n## Install\n\n```bash\nnpm install @byteark/passport-clearkey-web-sdk\n```\n\n## Setup\n\nAdd the hosted SDK script to your HTML **before** using this package.\nReplace `VERSION` with the version you want to use (e.g. `0.3.0`):\n\n```html\n<script src=\"https://byteark-sdk.st-th-1.byteark.com/passport-clearkey/web-sdk/VERSION/passport-web-sdk.js\"></script>\n```\n\n## Usage\n\n```js\nimport { loadPassportWebSDK } from '@byteark/passport-clearkey-web-sdk';\n\nconst sdk = await loadPassportWebSDK();\n\n// Initialize authentication\nconst result = await sdk.initAuth(jwt, keyServerBaseUrl);\n\n// Get the XHR setup function for hls.js\nconst xhrSetup = sdk.getXhrSetup();\n```\n\n## API\n\n### `loadPassportWebSDK(): Promise<PassportWebSDK | null>`\n\nReturns the `PassportWebSDK` instance from `window.PassportWebSDK`.\nResolves to `null` in server-side environments.\nThrows if the hosted SDK `<script>` tag has not been loaded.\n\n### `PassportWebSDK`\n\n| Method | Description |\n|---|---|\n| `initAuth(jwt, keyServerBaseUrl)` | Initialize cookie-based auth session |\n| `renewSession()` | Renew the current session |\n| `getXhrSetup()` | Returns an XHR setup function for hls.js `xhrSetup` config |\n| `destroy()` | Clean up the SDK instance |\n\n## License\n\nUNLICENSED\n","readmeFilename":"README.md"}