{"id":16227656,"url":"https://github.com/leafoftree/node-chrome-webstore","last_synced_at":"2026-02-12T21:31:28.533Z","repository":{"id":42223964,"uuid":"157816864","full_name":"leafOfTree/node-chrome-webstore","owner":"leafOfTree","description":"A node module to update / publish chrome extension automatically.","archived":false,"fork":false,"pushed_at":"2022-12-02T16:34:30.000Z","size":1003,"stargazers_count":1,"open_issues_count":5,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-10-03T22:49:52.895Z","etag":null,"topics":["chrome","extension","node","webstore"],"latest_commit_sha":null,"homepage":"","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/leafOfTree.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-11-16T05:24:37.000Z","updated_at":"2021-05-10T06:40:24.000Z","dependencies_parsed_at":"2023-01-22T13:30:25.961Z","dependency_job_id":null,"html_url":"https://github.com/leafOfTree/node-chrome-webstore","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/leafOfTree/node-chrome-webstore","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leafOfTree%2Fnode-chrome-webstore","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leafOfTree%2Fnode-chrome-webstore/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leafOfTree%2Fnode-chrome-webstore/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leafOfTree%2Fnode-chrome-webstore/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/leafOfTree","download_url":"https://codeload.github.com/leafOfTree/node-chrome-webstore/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/leafOfTree%2Fnode-chrome-webstore/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29381756,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-12T20:34:40.886Z","status":"ssl_error","status_checked_at":"2026-02-12T20:23:00.490Z","response_time":55,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.6:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["chrome","extension","node","webstore"],"created_at":"2024-10-10T12:53:27.534Z","updated_at":"2026-02-12T21:31:28.508Z","avatar_url":"https://github.com/leafOfTree.png","language":"JavaScript","readme":"# node chrome webstore\n\nUpdate and publish chrome extension automatically.\n\n## Prepare\n\nIf you have `refresh_token`, you can visit [Subsequent calls](#subsequent-calls) directly.\n\nElse please follow [Using the Chrome Web Store Publish API][0] instructions and come back when you get `client id`, `client secret` and `code`.\n\n\u003e Code can only be used once, mainly use refresh token later.\n\n## Installation\n\n    npm i node-chrome-webstore\n\n## Usage\n\n### First call\n\nSave refresh token and use it in subsequent calls\n\n```javascript\nconst webstore = require('node-chrome-webstore');\n\nconst client_id = '';\nconst client_secret = '';\nconst code = '';\n\nwebstore.auth({\n  client_id,\n  client_secret,\n  code,\n});\n\nwebstore.items.getRefreshToken().then((token) =\u003e {\n  console.log(token); // save it\n});\n```\n### Subsequent calls\n\n```javascript\nconst webstore = require('node-chrome-webstore');\n\nconst client_id = '';\nconst client_secret = '';\nconst refresh_token = '';\nconst itemId = '';\nconst zipPath = '';\n\nwebstore.auth({\n  client_id,\n  client_secret,\n  refresh_token,\n});\n\n// update\nwebstore.items.update(itemId, zipPath).then(res =\u003e {\n    console.log(res);\n});\n\n// publish\nwebstore.items.publish(itemId).then(res =\u003e {\n    console.log(res);\n});\n```\n\n### With dotenv example\n\n[dotenv][1] can help to save auth info to `.env` in project root.\n\n\u003e Strongly recommend against committing your `.env` file to version control. It should be in `.gitignore`.\n\n`.env`\n\n```bash\nclient_id=9867219971\nclient_secret=5d21TdajfIcK\nrefresh_token=1/jBtQRAjjy\ncode=4/lgAZRFXy\nitemId=eppeghhopeo\nzipPath=path/to/zip\n```\n\nRead auth info from `.env`\n\n```javascript\nconst webstore = require('node-chrome-webstore');\n\nrequire('dotenv').config();\n\nconst {\n  client_id,\n  client_secret,\n  refresh_token,\n  itemId,\n  zipPath,\n} = process.env;\n\nwebstore.auth({\n  client_id,\n  client_secret,\n  refresh_token,\n});\n\nwebstore.items.update(itemId, zipPath).then((res) =\u003e {\n  if (res.uploadState === 'SUCCESS') {\n    webstore.items.publish(itemId).then((res) =\u003e {\n      console.log(res);\n    });\n  } else {\n    console.log(res);\n  }\n});\n```\n\n## Development\n\n### Test\n\n    npm test\n\n[0]: https://developer.chrome.com/webstore/using_webstore_api\n[1]: https://github.com/motdotla/dotenv\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fleafoftree%2Fnode-chrome-webstore","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fleafoftree%2Fnode-chrome-webstore","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fleafoftree%2Fnode-chrome-webstore/lists"}