@redocly/cli 2.41.1 → 2.42.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (73) hide show
  1. package/README.md +15 -0
  2. package/THIRD_PARTY_NOTICES +7 -6
  3. package/lib/chunks/32XCOMOR.js +7 -0
  4. package/lib/chunks/4S2W4DOH.js +7 -0
  5. package/lib/chunks/55GMSQDD.js +7 -0
  6. package/lib/chunks/62KMHHXM.js +93 -0
  7. package/lib/chunks/7J6QXKSL.js +59 -0
  8. package/lib/chunks/7TEHO26G.js +3132 -0
  9. package/lib/chunks/AE6JGTY4.js +7 -0
  10. package/lib/chunks/B62AKN6U.js +7 -0
  11. package/lib/chunks/BZ7PKRCP.js +2317 -0
  12. package/lib/chunks/D5T6ETPZ.js +8 -0
  13. package/lib/chunks/DNYSY7SK.js +8 -0
  14. package/lib/chunks/E2UJUSIU.js +11 -0
  15. package/lib/chunks/ECZUPR2N.js +7 -0
  16. package/lib/chunks/EU6GURJZ.js +7 -0
  17. package/lib/chunks/F4DGJH6G.js +8 -0
  18. package/lib/chunks/GELB6SHC.js +22 -0
  19. package/lib/chunks/HJ6KJBQG.js +9 -0
  20. package/lib/chunks/HXR6INJN.js +22 -0
  21. package/lib/chunks/IP2FG3VC.js +19 -0
  22. package/lib/chunks/KLY5RV3W.js +7 -0
  23. package/lib/chunks/LSG6IYBM.js +47 -0
  24. package/lib/chunks/NEWT5A6S.js +159 -0
  25. package/lib/chunks/O6MCQRCP.js +59 -0
  26. package/lib/chunks/O6PRCLSV.js +13 -0
  27. package/lib/chunks/OFAMJNQ6.js +7 -0
  28. package/lib/chunks/P26PQ2RU.js +7 -0
  29. package/lib/chunks/QQOKWPJZ.js +184 -0
  30. package/lib/chunks/RFWIIJFG.js +7 -0
  31. package/lib/chunks/RS5PUOTT.js +18 -0
  32. package/lib/chunks/SPVQTYE2.js +7 -0
  33. package/lib/chunks/TXOARWFE.js +7 -0
  34. package/lib/chunks/UPPWQBGX.js +7 -0
  35. package/lib/chunks/UYZXI3NO.js +7 -0
  36. package/lib/chunks/WZXA5XPB.js +7 -0
  37. package/lib/chunks/XYO6U5CE.js +31 -0
  38. package/lib/chunks/ZGSJFP2Z.js +8 -0
  39. package/lib/index.js +226 -13883
  40. package/package.json +1 -1
  41. package/lib/chunks/4FB5ZIPP.js +0 -1133
  42. package/lib/chunks/5ILQMFXK.js +0 -59
  43. package/lib/chunks/64PJUTGH.js +0 -79
  44. package/lib/chunks/A6JSOHCP.js +0 -41
  45. package/lib/chunks/AIT3U3JT.js +0 -22
  46. package/lib/chunks/CUWLBJXP.js +0 -17
  47. package/lib/chunks/FO6BDVGE.js +0 -25
  48. package/lib/chunks/GCAYTKJY.js +0 -681
  49. package/lib/chunks/HFIKZEXG.js +0 -175
  50. package/lib/chunks/ICPYP2LP.js +0 -401
  51. package/lib/chunks/JR2DXWZO.js +0 -17799
  52. package/lib/chunks/KWQEC5JF.js +0 -16
  53. package/lib/chunks/LZNQHR3A.js +0 -2416
  54. package/lib/chunks/OFNDHNJR.js +0 -1756
  55. package/lib/chunks/OYU4O47C.js +0 -13374
  56. package/lib/chunks/PU67EGEM.js +0 -496
  57. package/lib/chunks/Q7LC24EZ.js +0 -528
  58. package/lib/chunks/RLUKQFWZ.js +0 -92591
  59. package/lib/chunks/TS33ZDKX.js +0 -35
  60. package/lib/chunks/UQJWXLNC.js +0 -3614
  61. package/lib/chunks/UUU33DK3.js +0 -125
  62. package/lib/chunks/UV3RHVRI.js +0 -25
  63. package/lib/chunks/VUDTNFRL.js +0 -42
  64. package/lib/chunks/VXIQEZPR.js +0 -2564
  65. package/lib/chunks/W7G5WVPB.js +0 -44
  66. package/lib/chunks/XB6C62FW.js +0 -18497
  67. package/lib/chunks/XHPY6UJF.js +0 -1638
  68. package/lib/chunks/Y6DTFCLS.js +0 -15
  69. package/lib/chunks/Y7LKQTQ4.js +0 -414
  70. package/lib/chunks/YPFS42IW.js +0 -92
  71. package/lib/chunks/Z2I5YXYN.js +0 -20272
  72. package/lib/chunks/Z3EJWJEX.js +0 -39325
  73. package/lib/chunks/ZK3QRKL5.js +0 -129
package/README.md CHANGED
@@ -139,6 +139,21 @@ Respect is Redocly's community-edition product. Looking for something more? We a
139
139
 
140
140
  Learn more about [Respect](https://redocly.com/respect) and [get started with API contract testing](https://redocly.com/docs/respect/get-started).
141
141
 
142
+ ### Generate a TypeScript client
143
+
144
+ > ⚠️ **Experimental** — flags, output, and configuration may change in any minor release until declared stable.
145
+
146
+ Turn an OpenAPI description (3.0/3.1/3.2 or Swagger 2.0) into a typed TypeScript client with the `generate-client` command.
147
+ The emitted client has zero runtime dependencies and runs in browsers, Node, Bun, Deno, and edge runtimes.
148
+
149
+ ```sh
150
+ redocly generate-client openapi.yaml --output src/client.ts
151
+ ```
152
+
153
+ Inline types plus a typed client instance and one async function per operation, with auth, opt-in abort-aware retries, middleware, and typed Server-Sent Events.
154
+ The same command can also emit Zod schemas, TanStack Query / SWR hooks, MSW mocks, and more via `--generator`.
155
+ For detailed information, read the [ `generate-client` docs](./docs/@v2/commands/generate-client.md).
156
+
142
157
  ### Transform an OpenAPI description
143
158
 
144
159
  If your OpenAPI description isn't everything you hoped it would be, enhance it with the Redocly [decorators](https://redocly.com/docs/cli/decorators) feature.
@@ -229,6 +229,7 @@ Packages:
229
229
  @opentelemetry/semantic-conventions@1.41.1 — copyright owner or entity authorized by
230
230
  better-ajv-errors@2.0.3 — Copyright 2018 Atlassian Pty Ltd
231
231
  jsonpath-rfc9535@1.3.0 — copyright owner or entity authorized by
232
+ typescript@6.0.2 — copyright owner or entity authorized by the copyright owner that is granting the License.
232
233
  yaml-ast-parser@0.0.43
233
234
 
234
235
  License text:
@@ -648,14 +649,14 @@ Packages:
648
649
  @redocly/ajv@8.18.3 — Copyright (c) 2015-2021 Evgeny Poberezkin
649
650
  @redocly/cli-otel@0.3.4 — Copyright 2025 Redocly Inc, all rights reserved.
650
651
  @redocly/config@0.22.0 — Copyright 2024 Redocly Inc.
651
- @redocly/config@0.52.0 — Copyright 2024 Redocly Inc.
652
- @redocly/openapi-core@1.34.17
652
+ @redocly/config@0.53.0 — Copyright 2024 Redocly Inc.
653
+ @redocly/openapi-core@1.34.18
653
654
  agent-base@7.1.4 — Copyright (c) 2013 Nathan Rajlich <nathan@tootallnate.net>
654
655
  ajv-formats@3.0.1 — Copyright (c) 2020 Evgeny Poberezkin
655
656
  ajv@8.20.0 — Copyright (c) 2015-2021 Evgeny Poberezkin
656
657
  ansi-styles@4.3.0
657
658
  balanced-match@1.0.2 — Copyright (c) 2013 Julian Gruber &lt;julian@juliangruber.com&gt;
658
- brace-expansion@2.1.2 — Copyright (c) 2013 Julian Gruber <julian@juliangruber.com>
659
+ brace-expansion@2.1.3 — Copyright (c) 2013 Julian Gruber <julian@juliangruber.com>
659
660
  call-me-maybe@1.0.2 — Copyright (c) 2015 Eric McCarthy
660
661
  chalk@4.1.2
661
662
  classnames@2.5.1 — Copyright (c) 2018 Jed Watson
@@ -677,8 +678,8 @@ Packages:
677
678
  https-proxy-agent@7.0.6 — Copyright (c) 2013 Nathan Rajlich <nathan@tootallnate.net>
678
679
  js-levenshtein@1.1.6 — Copyright (c) 2017 Gustaf Andersson
679
680
  js-tokens@4.0.0 — Copyright (c) 2014, 2015, 2016, 2017, 2018 Simon Lydell
680
- js-yaml@4.2.0 — Copyright (C) 2011-2015 by Vitaly Puzrin
681
- js-yaml@5.2.1 — Copyright (C) 2011-2015 by Vitaly Puzrin
681
+ js-yaml@4.3.0 — Copyright (C) 2011-2015 by Vitaly Puzrin
682
+ js-yaml@5.2.2 — Copyright (C) 2011-2015 by Vitaly Puzrin
682
683
  json-pointer@0.6.2 — Copyright (c) 2016 Manuel Stofer
683
684
  json-schema-traverse@1.0.0 — Copyright (c) 2017 Evgeny Poberezkin
684
685
  jsonpointer@5.0.1 — Copyright (c) 2011-2015 Jan Lehnardt <jan@apache.org> & Marc Bachmann <https://github.com/marcbachmann>
@@ -690,7 +691,7 @@ Packages:
690
691
  mobx@6.12.3 — Copyright (c) 2015 Michel Weststrate
691
692
  ms@2.1.3
692
693
  object-assign@4.1.1
693
- openapi-sampler@1.7.1 — Copyright (c) 2017 Roman Hotsiy <gotsijroman@gmail.com>
694
+ openapi-sampler@1.7.4 — Copyright (c) 2017 Roman Hotsiy <gotsijroman@gmail.com>
694
695
  outdent@0.8.0 — Copyright (c) 2016 Andrew Bradley
695
696
  perfect-scrollbar@1.5.6 — Copyright (c) 2012-2019 Hyunje Jun, MDBootstrap.com and other contributors
696
697
  picomatch@4.0.4 — Copyright (c) 2017-present, Jon Schlinkert.
@@ -0,0 +1,7 @@
1
+ import { createRequire as __createRequire } from 'node:module';
2
+ import { fileURLToPath as __fileURLToPath } from 'node:url';
3
+ import { dirname as __pathDirname } from 'node:path';
4
+ const require = __createRequire(import.meta.url);
5
+ var __filename = __fileURLToPath(import.meta.url);
6
+ var __dirname = __pathDirname(__filename);
7
+ import{a as R,c as f}from"./RFWIIJFG.js";var a=f((M,O)=>{"use strict";O.exports=(e,s=process.argv)=>{let i=e.startsWith("-")?"":e.length===1?"-":"--",o=s.indexOf(i+e),l=s.indexOf("--");return o!==-1&&(l===-1||o<l)}});var I=f((_,p)=>{"use strict";var E=R("os"),C=R("tty"),t=a(),{env:r}=process,n;t("no-color")||t("no-colors")||t("color=false")||t("color=never")?n=0:(t("color")||t("colors")||t("color=true")||t("color=always"))&&(n=1);"FORCE_COLOR"in r&&(r.FORCE_COLOR==="true"?n=1:r.FORCE_COLOR==="false"?n=0:n=r.FORCE_COLOR.length===0?1:Math.min(parseInt(r.FORCE_COLOR,10),3));function u(e){return e===0?!1:{level:e,hasBasic:!0,has256:e>=2,has16m:e>=3}}function c(e,s){if(n===0)return 0;if(t("color=16m")||t("color=full")||t("color=truecolor"))return 3;if(t("color=256"))return 2;if(e&&!s&&n===void 0)return 0;let i=n||0;if(r.TERM==="dumb")return i;if(process.platform==="win32"){let o=E.release().split(".");return Number(o[0])>=10&&Number(o[2])>=10586?Number(o[2])>=14931?3:2:1}if("CI"in r)return["TRAVIS","CIRCLECI","APPVEYOR","GITLAB_CI","GITHUB_ACTIONS","BUILDKITE"].some(o=>o in r)||r.CI_NAME==="codeship"?1:i;if("TEAMCITY_VERSION"in r)return/^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(r.TEAMCITY_VERSION)?1:0;if(r.COLORTERM==="truecolor")return 3;if("TERM_PROGRAM"in r){let o=parseInt((r.TERM_PROGRAM_VERSION||"").split(".")[0],10);switch(r.TERM_PROGRAM){case"iTerm.app":return o>=3?3:2;case"Apple_Terminal":return 2}}return/-256(color)?$/i.test(r.TERM)?2:/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(r.TERM)||"COLORTERM"in r?1:i}function T(e){let s=c(e,e&&e.isTTY);return u(s)}p.exports={supportsColor:T,stdout:u(c(!0,C.isatty(1))),stderr:u(c(!0,C.isatty(2)))}});export{I as a};
@@ -0,0 +1,7 @@
1
+ import { createRequire as __createRequire } from 'node:module';
2
+ import { fileURLToPath as __fileURLToPath } from 'node:url';
3
+ import { dirname as __pathDirname } from 'node:path';
4
+ const require = __createRequire(import.meta.url);
5
+ var __filename = __fileURLToPath(import.meta.url);
6
+ var __dirname = __pathDirname(__filename);
7
+ import{h as a}from"./HXR6INJN.js";import"./P26PQ2RU.js";import"./RS5PUOTT.js";import"./TXOARWFE.js";import"./O6MCQRCP.js";import"./32XCOMOR.js";import"./QQOKWPJZ.js";import"./NEWT5A6S.js";import"./RFWIIJFG.js";export{a as RedoclyOAuthClient};
@@ -0,0 +1,7 @@
1
+ import { createRequire as __createRequire } from 'node:module';
2
+ import { fileURLToPath as __fileURLToPath } from 'node:url';
3
+ import { dirname as __pathDirname } from 'node:path';
4
+ const require = __createRequire(import.meta.url);
5
+ var __filename = __fileURLToPath(import.meta.url);
6
+ var __dirname = __pathDirname(__filename);
7
+ import{a as g}from"./AE6JGTY4.js";import{b as o,c as u}from"./KLY5RV3W.js";import{a as s,c as a,f as d}from"./RFWIIJFG.js";var _=a(e=>{Object.defineProperty(e,"__esModule",{value:!0});e.getMachineId=void 0;var n=s("process"),h=g(),y=(u(),d(o));async function E(){let c="QUERY HKEY_LOCAL_MACHINE\\SOFTWARE\\Microsoft\\Cryptography /v MachineGuid",t="%windir%\\System32\\REG.exe";n.arch==="ia32"&&"PROCESSOR_ARCHITEW6432"in n.env&&(t="%windir%\\sysnative\\cmd.exe /c "+t);try{let r=(await(0,h.execAsync)(`${t} ${c}`)).stdout.split("REG_SZ");if(r.length===2)return r[1].trim()}catch(i){y.diag.debug(`error reading machine id: ${i}`)}}e.getMachineId=E});export default _();