{"id":28468587,"url":"https://github.com/cnwhy/axios-extra","last_synced_at":"2026-03-05T06:33:36.602Z","repository":{"id":57188606,"uuid":"164706491","full_name":"cnwhy/axios-extra","owner":"cnwhy","description":"Support for maximum concurrent settings and retry","archived":false,"fork":false,"pushed_at":"2023-10-11T10:04:11.000Z","size":17,"stargazers_count":8,"open_issues_count":0,"forks_count":3,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-10-21T02:36:56.654Z","etag":null,"topics":["axios","concurrent","queue","retry"],"latest_commit_sha":null,"homepage":null,"language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/cnwhy.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2019-01-08T18:10:13.000Z","updated_at":"2023-11-10T01:27:43.000Z","dependencies_parsed_at":"2023-10-11T11:42:57.255Z","dependency_job_id":"8113e36a-2548-4f29-957b-8140ef40cd16","html_url":"https://github.com/cnwhy/axios-extra","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/cnwhy/axios-extra","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cnwhy%2Faxios-extra","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cnwhy%2Faxios-extra/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cnwhy%2Faxios-extra/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cnwhy%2Faxios-extra/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cnwhy","download_url":"https://codeload.github.com/cnwhy/axios-extra/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cnwhy%2Faxios-extra/sbom","scorecard":{"id":294871,"data":{"date":"2025-08-11","repo":{"name":"github.com/cnwhy/axios-extra","commit":"50d3edb8052534fc70b112cf736c7175e0832da1"},"scorecard":{"version":"v5.2.1-40-gf6ed084d","commit":"f6ed084d17c9236477efd66e5b258b9d4cc7b389"},"score":3.4,"checks":[{"name":"Code-Review","score":0,"reason":"Found 0/14 approved changesets -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project requires human code review before pull requests (aka merge requests) are merged.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#code-review"}},{"name":"Dangerous-Workflow","score":10,"reason":"no dangerous workflow patterns detected","details":null,"documentation":{"short":"Determines if the project's GitHub Action workflows avoid dangerous patterns.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#dangerous-workflow"}},{"name":"Pinned-Dependencies","score":0,"reason":"dependency not pinned by hash detected -- score normalized to 0","details":["Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/test.yml:19: update your workflow using https://app.stepsecurity.io/secureworkflow/cnwhy/axios-extra/test.yml/master?enable=pin","Warn: GitHub-owned GitHubAction not pinned by hash: .github/workflows/test.yml:23: update your workflow using https://app.stepsecurity.io/secureworkflow/cnwhy/axios-extra/test.yml/master?enable=pin","Warn: third-party GitHubAction not pinned by hash: .github/workflows/test.yml:47: update your workflow using https://app.stepsecurity.io/secureworkflow/cnwhy/axios-extra/test.yml/master?enable=pin","Warn: npmCommand not pinned by hash: .github/workflows/test.yml:30","Info:   0 out of   2 GitHub-owned GitHubAction dependencies pinned","Info:   0 out of   1 third-party GitHubAction dependencies pinned","Info:   0 out of   1 npmCommand dependencies pinned"],"documentation":{"short":"Determines if the project has declared and pinned the dependencies of its build process.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#pinned-dependencies"}},{"name":"Maintained","score":0,"reason":"0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0","details":null,"documentation":{"short":"Determines if the project is \"actively maintained\".","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#maintained"}},{"name":"Token-Permissions","score":0,"reason":"detected GitHub workflow tokens with excessive permissions","details":["Warn: no topLevel permission defined: .github/workflows/test.yml:1","Info: no jobLevel write permissions found"],"documentation":{"short":"Determines if the project's workflows follow the principle of least privilege.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#token-permissions"}},{"name":"Binary-Artifacts","score":10,"reason":"no binaries found in the repo","details":null,"documentation":{"short":"Determines if the project has generated executable (binary) artifacts in the source repository.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#binary-artifacts"}},{"name":"Packaging","score":-1,"reason":"packaging workflow not detected","details":["Warn: no GitHub/GitLab publishing workflow detected."],"documentation":{"short":"Determines if the project is published as a package that others can easily download, install, easily update, and uninstall.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#packaging"}},{"name":"SAST","score":0,"reason":"no SAST tool detected","details":["Warn: no pull requests merged into dev branch"],"documentation":{"short":"Determines if the project uses static code analysis.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#sast"}},{"name":"CII-Best-Practices","score":0,"reason":"no effort to earn an OpenSSF best practices badge detected","details":null,"documentation":{"short":"Determines if the project has an OpenSSF (formerly CII) Best Practices Badge.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#cii-best-practices"}},{"name":"Security-Policy","score":0,"reason":"security policy file not detected","details":["Warn: no security policy file detected","Warn: no security file to analyze","Warn: no security file to analyze","Warn: no security file to analyze"],"documentation":{"short":"Determines if the project has published a security policy.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#security-policy"}},{"name":"Vulnerabilities","score":10,"reason":"0 existing vulnerabilities detected","details":null,"documentation":{"short":"Determines if the project has open, known unfixed vulnerabilities.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#vulnerabilities"}},{"name":"Fuzzing","score":0,"reason":"project is not fuzzed","details":["Warn: no fuzzer integrations found"],"documentation":{"short":"Determines if the project uses fuzzing.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#fuzzing"}},{"name":"License","score":10,"reason":"license file detected","details":["Info: project has a license file: LICENSE:0","Info: FSF or OSI recognized license: MIT License: LICENSE:0"],"documentation":{"short":"Determines if the project has defined a license.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#license"}},{"name":"Signed-Releases","score":-1,"reason":"no releases found","details":null,"documentation":{"short":"Determines if the project cryptographically signs release artifacts.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#signed-releases"}},{"name":"Branch-Protection","score":0,"reason":"branch protection not enabled on development/release branches","details":["Warn: branch protection not enabled for branch 'master'"],"documentation":{"short":"Determines if the default and release branches are protected with GitHub's branch protection settings.","url":"https://github.com/ossf/scorecard/blob/f6ed084d17c9236477efd66e5b258b9d4cc7b389/docs/checks.md#branch-protection"}}]},"last_synced_at":"2025-08-17T19:14:08.415Z","repository_id":57188606,"created_at":"2025-08-17T19:14:08.415Z","updated_at":"2025-08-17T19:14:08.415Z"},"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30112265,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-05T03:40:26.266Z","status":"ssl_error","status_checked_at":"2026-03-05T03:39:15.902Z","response_time":93,"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":["axios","concurrent","queue","retry"],"created_at":"2025-06-07T08:08:02.760Z","updated_at":"2026-03-05T06:33:36.566Z","avatar_url":"https://github.com/cnwhy.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# axios-extra\r\n\r\n[![Coverage Status](https://coveralls.io/repos/github/cnwhy/axios-extra/badge.svg?branch=master)](https://coveralls.io/github/cnwhy/axios-extra?branch=master) [![github test](https://github.com/cnwhy/axios-extra/workflows/test/badge.svg?branch=master)](https://github.com/cnwhy/axios-extra/actions/workflows/test.yml)\r\n\r\n通过 ES6 的`Proxy`对像, 让 [axios](https://github.com/axios/axios) 集成 [promise-queue-plus](https://github.com/cnwhy/promise-queue-plus), 使 `axios` 支持 **最大并发** 及 **出错重试** 的功能.\r\n\r\n\u003e 未添加任何 API, 你完全可以像使用 `axios` 那样使用 `axios-extra`;\r\n\u003e 由于使用了`Proxy`,请注意兼性.\r\n\r\n## API\r\n\r\n### axios.create(config)\r\n\r\n现在可以通过设置 `maxConcurrent` 和 `queueOptions` 属性, 设置最大并发及重试次数.\r\n\r\n```js\r\n// axios 并发为10, 自动重试为0\r\nconst axios = require('axios-extra'); //默认最大并发 10, 重试 0;\r\n\r\n// 创建一个 并发为1, 自动重试为3的 axios;\r\nlet axios1 = axios.create({\r\n\tmaxConcurrent:1, //并发为1\r\n\tqueueOptions: {\r\n\t\tretry:3, //请求失败时,最多会重试3次\r\n\t\tretryIsJump: true //是否立即重试, 否则将在请求队列尾部插入重试请求\r\n\t}\r\n});\r\n\r\nlet {stop, start, clear} = axios1.requestQueue; // 暴露内部的队列对像，可以使用 stop start clear 等 API;\r\n```\r\n\r\n\u003e 更多 `queueOptions` 配制可参看[这里](https://github.com/cnwhy/promise-queue-plus#queuepushpromisefun-args-options)\r\n\r\n### axios(config) 及 get|post|request|delete|head|options|put|patch\r\n\r\n`config`参数可以为某一次的请求设置 `queueOptions`;\r\n\r\n```js\r\naxios.get('https://www.google.com',{\r\n\tqueueOptions : {\r\n\t\tretry: 5\r\n\t}\r\n});\r\n```\r\n\r\n### `create(axios,maxConcurrent,queueOptions)` 扩展现有 `axios`\r\n\r\n扩展项目中现有 `axios`,保证 `axios` 版本.\r\n\r\n```js\r\nconst aec = require('axios-extra/create');\r\nconst axios = aec(requeir('axios'), 5, { retry: 5 });\r\n```","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcnwhy%2Faxios-extra","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcnwhy%2Faxios-extra","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcnwhy%2Faxios-extra/lists"}