@hey-api/openapi-ts 0.86.10 → 0.86.11

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.
package/dist/index.d.cts CHANGED
@@ -1,4 +1,4 @@
1
- import { A as AccessLevel, C as PluginHandler, D as Comments, E as MaybeArray, F as types_d_exports, I as __export, M as FunctionTypeParameter, N as ObjectValue, O as ImportExportItemObject, P as SyntaxKindKeyword, S as Client$2, T as LazyOrAsync, _ as OpenApiRequestBodyObject, c as ExpressionTransformer, d as Client$7, f as Operation, g as OpenApiParameterObject, h as OpenApiOperationObject, i as UserConfig, j as FunctionParameter, k as tsNodeToString, l as DefinePlugin, m as OpenApiMetaObject, o as IR, p as OpenApi, s as TypeTransformer, t as LegacyIR, u as Plugin, v as OpenApiResponseObject, w as StringCase, x as Logger, y as OpenApiSchemaObject } from "./types-Cm9EOTQ7.cjs";
1
+ import { A as AccessLevel, C as PluginHandler, D as Comments, E as MaybeArray, F as types_d_exports, I as __export, M as FunctionTypeParameter, N as ObjectValue, O as ImportExportItemObject, P as SyntaxKindKeyword, S as Client$2, T as LazyOrAsync, _ as OpenApiRequestBodyObject, c as ExpressionTransformer, d as Client$7, f as Operation, g as OpenApiParameterObject, h as OpenApiOperationObject, i as UserConfig, j as FunctionParameter, k as tsNodeToString, l as DefinePlugin, m as OpenApiMetaObject, o as IR, p as OpenApi, s as TypeTransformer, t as LegacyIR, u as Plugin, v as OpenApiResponseObject, w as StringCase, x as Logger, y as OpenApiSchemaObject } from "./types-Bxdq98WE.cjs";
2
2
  import * as typescript0 from "typescript";
3
3
  import ts from "typescript";
4
4
  import { HttpClient, HttpErrorResponse, HttpHeaders, HttpRequest, HttpResponse } from "@angular/common/http";
package/dist/index.d.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  import { n as __export } from "./chunk-C-EqMg7d.js";
2
- import { A as AccessLevel, C as PluginHandler, D as Comments, E as MaybeArray, F as types_d_exports, M as FunctionTypeParameter, N as ObjectValue, O as ImportExportItemObject, P as SyntaxKindKeyword, S as Client$2, T as LazyOrAsync, _ as OpenApiRequestBodyObject, c as ExpressionTransformer, d as Client$7, f as Operation, g as OpenApiParameterObject, h as OpenApiOperationObject, i as UserConfig, j as FunctionParameter, k as tsNodeToString, l as DefinePlugin, m as OpenApiMetaObject, o as IR, p as OpenApi, s as TypeTransformer, t as LegacyIR, u as Plugin, v as OpenApiResponseObject, w as StringCase, x as Logger, y as OpenApiSchemaObject } from "./types-BDC4ckIh.js";
2
+ import { A as AccessLevel, C as PluginHandler, D as Comments, E as MaybeArray, F as types_d_exports, M as FunctionTypeParameter, N as ObjectValue, O as ImportExportItemObject, P as SyntaxKindKeyword, S as Client$2, T as LazyOrAsync, _ as OpenApiRequestBodyObject, c as ExpressionTransformer, d as Client$7, f as Operation, g as OpenApiParameterObject, h as OpenApiOperationObject, i as UserConfig, j as FunctionParameter, k as tsNodeToString, l as DefinePlugin, m as OpenApiMetaObject, o as IR, p as OpenApi, s as TypeTransformer, t as LegacyIR, u as Plugin, v as OpenApiResponseObject, w as StringCase, x as Logger, y as OpenApiSchemaObject } from "./types-CFT9BYmF.js";
3
3
  import "@hey-api/codegen-core";
4
4
  import * as typescript0 from "typescript";
5
5
  import ts from "typescript";
@@ -1,4 +1,4 @@
1
- import { a as Input, b as parseOpenApiSpec, i as UserConfig, n as WatchValues, r as Config, x as Logger } from "./types-Cm9EOTQ7.cjs";
1
+ import { a as Input, b as parseOpenApiSpec, i as UserConfig, n as WatchValues, r as Config, x as Logger } from "./types-Bxdq98WE.cjs";
2
2
  import { getResolvedInput } from "@hey-api/json-schema-ref-parser";
3
3
 
4
4
  //#region src/config/init.d.ts
@@ -1,4 +1,4 @@
1
- import { a as Input, b as parseOpenApiSpec, i as UserConfig, n as WatchValues, r as Config, x as Logger } from "./types-BDC4ckIh.js";
1
+ import { a as Input, b as parseOpenApiSpec, i as UserConfig, n as WatchValues, r as Config, x as Logger } from "./types-CFT9BYmF.js";
2
2
  import { getResolvedInput } from "@hey-api/json-schema-ref-parser";
3
3
 
4
4
  //#region src/config/init.d.ts
package/dist/run.cjs CHANGED
@@ -1,3 +1,3 @@
1
1
  #!/usr/bin/env node
2
- const e=require(`./getSpec-ekNG3x72.cjs`),t=require(`./src-Cu5Xi-FZ.cjs`);let n=require(`commander`);n=e.R(n);var r=`0.86.10`,i={"openapi-ts":`./bin/run.js`};const a=e=>e===`true`?!0:e===`false`?!1:e,o=(e,t)=>{for(let n of t){let t=e[n];if(typeof t==`string`){let r=a(t);delete e[n],e[n]=r}}return e},s=async()=>{let e=new n.Command().name(Object.keys(i)[0]).usage(`[options]`).version(r).option(`-c, --client <value>`,`HTTP client to generate [@hey-api/client-axios, @hey-api/client-fetch, @hey-api/client-next, @hey-api/client-nuxt, legacy/angular, legacy/axios, legacy/fetch, legacy/node, legacy/xhr]`).option(`-d, --debug`,`Set log level to debug`).option(`--dry-run [value]`,`Skip writing files to disk?`).option(`-e, --experimental-parser [value]`,`Opt-in to the experimental parser?`).option(`-f, --file [value]`,`Path to the config file`).option(`-i, --input <value>`,`OpenAPI specification (path, url, or string content)`).option(`-l, --logs [value]`,`Logs folder`).option(`-o, --output <value>`,`Output folder`).option(`-p, --plugins [value...]`,`List of plugins you'd like to use`).option(`--base [value]`,`DEPRECATED. Manually set base in OpenAPI config instead of inferring from server value`).option(`-s, --silent`,`Set log level to silent`).option(`--no-log-file`,`Disable writing a log file. Works like --silent but without suppressing console output`).option(`-w, --watch [value]`,`Regenerate the client when the input file changes?`).option(`--exportCore [value]`,`DEPRECATED. Write core files to disk`).option(`--name <value>`,`DEPRECATED. Custom client class name`).option(`--request <value>`,`DEPRECATED. Path to custom request file`).option(`--useOptions [value]`,`DEPRECATED. Use options instead of arguments?`).parse(process.argv).opts(),s;try{s=o(e,[`dryRun`,`experimentalParser`,`exportCore`,`logFile`,`useOptions`]),s.file&&(s.configFile=s.file,delete s.file),e.plugins===!0?s.plugins=[]:e.plugins?s.plugins=e.plugins:s.client&&(s.plugins=[`@hey-api/typescript`,`@hey-api/sdk`]),s.client&&(s.plugins.push(s.client),delete s.client),s.logs=s.logs?{path:s.logs}:{},s.debug||a(process.env.DEBUG)?(s.logs.level=`debug`,delete s.debug):s.silent&&(s.logs.level=`silent`,delete s.silent),s.logs.file=s.logFile,delete s.logFile,typeof e.watch==`string`&&(s.watch=Number.parseInt(e.watch,10)),Object.keys(s.logs).length||delete s.logs,(await t.r(s))[0]?.config.input.some(e=>e.watch&&e.watch.enabled)||process.exit(0)}catch{process.exit(1)}};s();
2
+ const e=require(`./getSpec-ekNG3x72.cjs`),t=require(`./src-Cu5Xi-FZ.cjs`);let n=require(`commander`);n=e.R(n);var r=`0.86.11`,i={"openapi-ts":`./bin/run.js`};const a=e=>e===`true`?!0:e===`false`?!1:e,o=(e,t)=>{for(let n of t){let t=e[n];if(typeof t==`string`){let r=a(t);delete e[n],e[n]=r}}return e},s=async()=>{let e=new n.Command().name(Object.keys(i)[0]).usage(`[options]`).version(r).option(`-c, --client <value>`,`HTTP client to generate [@hey-api/client-axios, @hey-api/client-fetch, @hey-api/client-next, @hey-api/client-nuxt, legacy/angular, legacy/axios, legacy/fetch, legacy/node, legacy/xhr]`).option(`-d, --debug`,`Set log level to debug`).option(`--dry-run [value]`,`Skip writing files to disk?`).option(`-e, --experimental-parser [value]`,`Opt-in to the experimental parser?`).option(`-f, --file [value]`,`Path to the config file`).option(`-i, --input <value>`,`OpenAPI specification (path, url, or string content)`).option(`-l, --logs [value]`,`Logs folder`).option(`-o, --output <value>`,`Output folder`).option(`-p, --plugins [value...]`,`List of plugins you'd like to use`).option(`--base [value]`,`DEPRECATED. Manually set base in OpenAPI config instead of inferring from server value`).option(`-s, --silent`,`Set log level to silent`).option(`--no-log-file`,`Disable writing a log file. Works like --silent but without suppressing console output`).option(`-w, --watch [value]`,`Regenerate the client when the input file changes?`).option(`--exportCore [value]`,`DEPRECATED. Write core files to disk`).option(`--name <value>`,`DEPRECATED. Custom client class name`).option(`--request <value>`,`DEPRECATED. Path to custom request file`).option(`--useOptions [value]`,`DEPRECATED. Use options instead of arguments?`).parse(process.argv).opts(),s;try{s=o(e,[`dryRun`,`experimentalParser`,`exportCore`,`logFile`,`useOptions`]),s.file&&(s.configFile=s.file,delete s.file),e.plugins===!0?s.plugins=[]:e.plugins?s.plugins=e.plugins:s.client&&(s.plugins=[`@hey-api/typescript`,`@hey-api/sdk`]),s.client&&(s.plugins.push(s.client),delete s.client),s.logs=s.logs?{path:s.logs}:{},s.debug||a(process.env.DEBUG)?(s.logs.level=`debug`,delete s.debug):s.silent&&(s.logs.level=`silent`,delete s.silent),s.logs.file=s.logFile,delete s.logFile,typeof e.watch==`string`&&(s.watch=Number.parseInt(e.watch,10)),Object.keys(s.logs).length||delete s.logs,(await t.r(s))[0]?.config.input.some(e=>e.watch&&e.watch.enabled)||process.exit(0)}catch{process.exit(1)}};s();
3
3
  //# sourceMappingURL=run.cjs.map
package/dist/run.cjs.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"run.cjs","names":["Command","pkg.bin","pkg.version","userConfig: Record<string, unknown>","createClient"],"sources":["../package.json","../src/cli.ts","../src/run.ts"],"sourcesContent":["{\n \"name\": \"@hey-api/openapi-ts\",\n \"version\": \"0.86.10\",\n \"description\": \"🚀 The OpenAPI to TypeScript codegen. Generate clients, SDKs, validators, and more.\",\n \"homepage\": \"https://heyapi.dev/\",\n \"repository\": {\n \"type\": \"git\",\n \"url\": \"git+https://github.com/hey-api/openapi-ts.git\"\n },\n \"bugs\": {\n \"url\": \"https://github.com/hey-api/openapi-ts/issues\"\n },\n \"license\": \"MIT\",\n \"author\": {\n \"email\": \"lubos@heyapi.dev\",\n \"name\": \"Hey API\",\n \"url\": \"https://heyapi.dev\"\n },\n \"funding\": \"https://github.com/sponsors/hey-api\",\n \"keywords\": [\n \"angular\",\n \"axios\",\n \"codegen\",\n \"fetch\",\n \"generator\",\n \"http\",\n \"javascript\",\n \"json\",\n \"next\",\n \"next.js\",\n \"node\",\n \"nuxt\",\n \"ofetch\",\n \"openapi\",\n \"rest\",\n \"swagger\",\n \"typescript\",\n \"xhr\",\n \"yaml\"\n ],\n \"type\": \"module\",\n \"main\": \"./dist/index.cjs\",\n \"module\": \"./dist/index.js\",\n \"types\": \"./dist/index.d.ts\",\n \"exports\": {\n \".\": {\n \"import\": {\n \"types\": \"./dist/index.d.ts\",\n \"default\": \"./dist/index.js\"\n },\n \"require\": {\n \"types\": \"./dist/index.d.cts\",\n \"default\": \"./dist/index.cjs\"\n }\n },\n \"./internal\": {\n \"import\": {\n \"types\": \"./dist/internal.d.ts\",\n \"default\": \"./dist/internal.js\"\n },\n \"require\": {\n \"types\": \"./dist/internal.d.cts\",\n \"default\": \"./dist/internal.cjs\"\n }\n },\n \"./package.json\": \"./package.json\"\n },\n \"bin\": {\n \"openapi-ts\": \"./bin/run.js\"\n },\n \"files\": [\n \"bin\",\n \"dist\",\n \"LICENSE.md\",\n \"README.md\"\n ],\n \"scripts\": {\n \"build\": \"tsdown && pnpm check-exports\",\n \"check-exports\": \"attw --pack . --profile node16\",\n \"dev\": \"tsdown --watch\",\n \"handlebars\": \"node src/legacy/handlebars/handlebars.cjs\",\n \"prepublishOnly\": \"pnpm build\",\n \"test:coverage\": \"vitest run --coverage\",\n \"test:update\": \"vitest watch --update\",\n \"test:watch\": \"vitest watch\",\n \"test\": \"vitest run\",\n \"typecheck\": \"tsc --noEmit\"\n },\n \"engines\": {\n \"node\": \">=20.19.0\"\n },\n \"dependencies\": {\n \"@hey-api/codegen-core\": \"workspace:^0.3.2\",\n \"@hey-api/json-schema-ref-parser\": \"1.2.1\",\n \"ansi-colors\": \"4.1.3\",\n \"c12\": \"3.3.1\",\n \"color-support\": \"1.1.3\",\n \"commander\": \"14.0.1\",\n \"handlebars\": \"4.7.8\",\n \"open\": \"10.2.0\",\n \"semver\": \"7.7.2\"\n },\n \"peerDependencies\": {\n \"typescript\": \">=5.5.3\"\n },\n \"devDependencies\": {\n \"@angular/common\": \"19.2.15\",\n \"@angular/compiler\": \"19.2.15\",\n \"@angular/compiler-cli\": \"19.2.15\",\n \"@angular/core\": \"19.2.15\",\n \"@angular/platform-browser\": \"19.2.15\",\n \"@angular/platform-browser-dynamic\": \"19.2.15\",\n \"@angular/router\": \"19.2.15\",\n \"@config/vite-base\": \"workspace:*\",\n \"@types/bun\": \"1.3.1\",\n \"@types/cross-spawn\": \"6.0.6\",\n \"@types/semver\": \"7.7.1\",\n \"axios\": \"1.8.2\",\n \"cross-spawn\": \"7.0.6\",\n \"eslint\": \"9.17.0\",\n \"glob\": \"11.0.3\",\n \"nuxt\": \"3.14.1592\",\n \"ofetch\": \"1.4.1\",\n \"prettier\": \"3.4.2\",\n \"rxjs\": \"7.8.2\",\n \"typescript\": \"5.9.3\",\n \"vue\": \"3.5.13\",\n \"yaml\": \"2.8.0\",\n \"zone.js\": \"0.15.1\"\n }\n}\n","import type { OptionValues } from 'commander';\nimport { Command } from 'commander';\n\nimport { createClient } from '~/index';\n\nimport pkg from '../package.json' assert { type: 'json' };\n\nconst stringToBoolean = (\n value: string | undefined,\n): boolean | string | undefined => {\n if (value === 'true') return true;\n if (value === 'false') return false;\n return value;\n};\n\nconst processParams = (\n obj: OptionValues,\n booleanKeys: ReadonlyArray<string>,\n): OptionValues => {\n for (const key of booleanKeys) {\n const value = obj[key];\n if (typeof value === 'string') {\n const parsedValue = stringToBoolean(value);\n delete obj[key];\n obj[key] = parsedValue;\n }\n }\n return obj;\n};\n\nexport const runCli = async (): Promise<void> => {\n const params = new Command()\n .name(Object.keys(pkg.bin)[0]!)\n .usage('[options]')\n .version(pkg.version)\n .option(\n '-c, --client <value>',\n 'HTTP client to generate [@hey-api/client-axios, @hey-api/client-fetch, @hey-api/client-next, @hey-api/client-nuxt, legacy/angular, legacy/axios, legacy/fetch, legacy/node, legacy/xhr]',\n )\n .option('-d, --debug', 'Set log level to debug')\n .option('--dry-run [value]', 'Skip writing files to disk?')\n .option(\n '-e, --experimental-parser [value]',\n 'Opt-in to the experimental parser?',\n )\n .option('-f, --file [value]', 'Path to the config file')\n .option(\n '-i, --input <value>',\n 'OpenAPI specification (path, url, or string content)',\n )\n .option('-l, --logs [value]', 'Logs folder')\n .option('-o, --output <value>', 'Output folder')\n .option('-p, --plugins [value...]', \"List of plugins you'd like to use\")\n .option(\n '--base [value]',\n 'DEPRECATED. Manually set base in OpenAPI config instead of inferring from server value',\n )\n .option('-s, --silent', 'Set log level to silent')\n .option(\n '--no-log-file',\n 'Disable writing a log file. Works like --silent but without suppressing console output',\n )\n .option(\n '-w, --watch [value]',\n 'Regenerate the client when the input file changes?',\n )\n .option('--exportCore [value]', 'DEPRECATED. Write core files to disk')\n .option('--name <value>', 'DEPRECATED. Custom client class name')\n .option('--request <value>', 'DEPRECATED. Path to custom request file')\n .option(\n '--useOptions [value]',\n 'DEPRECATED. Use options instead of arguments?',\n )\n .parse(process.argv)\n .opts();\n\n let userConfig: Record<string, unknown>;\n\n try {\n userConfig = processParams(params, [\n 'dryRun',\n 'experimentalParser',\n 'exportCore',\n 'logFile',\n 'useOptions',\n ]);\n\n if (userConfig.file) {\n userConfig.configFile = userConfig.file;\n delete userConfig.file;\n }\n\n if (params.plugins === true) {\n userConfig.plugins = [];\n } else if (params.plugins) {\n userConfig.plugins = params.plugins;\n } else if (userConfig.client) {\n userConfig.plugins = ['@hey-api/typescript', '@hey-api/sdk'];\n }\n\n if (userConfig.client) {\n (userConfig.plugins as Array<string>).push(userConfig.client as string);\n delete userConfig.client;\n }\n\n userConfig.logs = userConfig.logs\n ? {\n path: userConfig.logs,\n }\n : {};\n\n if (userConfig.debug || stringToBoolean(process.env.DEBUG)) {\n (userConfig.logs as Record<string, unknown>).level = 'debug';\n delete userConfig.debug;\n } else if (userConfig.silent) {\n (userConfig.logs as Record<string, unknown>).level = 'silent';\n delete userConfig.silent;\n }\n\n (userConfig.logs as Record<string, unknown>).file = userConfig.logFile;\n delete userConfig.logFile;\n\n if (typeof params.watch === 'string') {\n userConfig.watch = Number.parseInt(params.watch, 10);\n }\n\n if (!Object.keys(userConfig.logs as Record<string, unknown>).length) {\n delete userConfig.logs;\n }\n\n const context = await createClient(\n userConfig as unknown as Required<Parameters<typeof createClient>>[0],\n );\n if (\n !context[0]?.config.input.some(\n (input) => input.watch && input.watch.enabled,\n )\n ) {\n process.exit(0);\n }\n } catch {\n process.exit(1);\n }\n};\n","#!/usr/bin/env node\n\nimport { runCli } from '~/cli';\n\nrunCli();\n"],"mappings":";oHAEa,YAiEJ,CACL,aAAc,eACf,CC9DH,MAAM,EACJ,GAEI,IAAU,OAAe,GACzB,IAAU,QAAgB,GACvB,EAGH,GACJ,EACA,IACiB,CACjB,IAAK,IAAM,KAAO,EAAa,CAC7B,IAAM,EAAQ,EAAI,GAClB,GAAI,OAAO,GAAU,SAAU,CAC7B,IAAM,EAAc,EAAgB,EAAM,CAC1C,OAAO,EAAI,GACX,EAAI,GAAO,GAGf,OAAO,GAGI,EAAS,SAA2B,CAC/C,IAAM,EAAS,IAAIA,EAAAA,SAAS,CACzB,KAAK,OAAO,KAAKC,EAAQ,CAAC,GAAI,CAC9B,MAAM,YAAY,CAClB,QAAQC,EAAY,CACpB,OACC,uBACA,0LACD,CACA,OAAO,cAAe,yBAAyB,CAC/C,OAAO,oBAAqB,8BAA8B,CAC1D,OACC,oCACA,qCACD,CACA,OAAO,qBAAsB,0BAA0B,CACvD,OACC,sBACA,uDACD,CACA,OAAO,qBAAsB,cAAc,CAC3C,OAAO,uBAAwB,gBAAgB,CAC/C,OAAO,2BAA4B,oCAAoC,CACvE,OACC,iBACA,yFACD,CACA,OAAO,eAAgB,0BAA0B,CACjD,OACC,gBACA,yFACD,CACA,OACC,sBACA,qDACD,CACA,OAAO,uBAAwB,uCAAuC,CACtE,OAAO,iBAAkB,uCAAuC,CAChE,OAAO,oBAAqB,0CAA0C,CACtE,OACC,uBACA,gDACD,CACA,MAAM,QAAQ,KAAK,CACnB,MAAM,CAELC,EAEJ,GAAI,CACF,EAAa,EAAc,EAAQ,CACjC,SACA,qBACA,aACA,UACA,aACD,CAAC,CAEE,EAAW,OACb,EAAW,WAAa,EAAW,KACnC,OAAO,EAAW,MAGhB,EAAO,UAAY,GACrB,EAAW,QAAU,EAAE,CACd,EAAO,QAChB,EAAW,QAAU,EAAO,QACnB,EAAW,SACpB,EAAW,QAAU,CAAC,sBAAuB,eAAe,EAG1D,EAAW,SACZ,EAAW,QAA0B,KAAK,EAAW,OAAiB,CACvE,OAAO,EAAW,QAGpB,EAAW,KAAO,EAAW,KACzB,CACE,KAAM,EAAW,KAClB,CACD,EAAE,CAEF,EAAW,OAAS,EAAgB,QAAQ,IAAI,MAAM,EACvD,EAAW,KAAiC,MAAQ,QACrD,OAAO,EAAW,OACT,EAAW,SACnB,EAAW,KAAiC,MAAQ,SACrD,OAAO,EAAW,QAGnB,EAAW,KAAiC,KAAO,EAAW,QAC/D,OAAO,EAAW,QAEd,OAAO,EAAO,OAAU,WAC1B,EAAW,MAAQ,OAAO,SAAS,EAAO,MAAO,GAAG,EAGjD,OAAO,KAAK,EAAW,KAAgC,CAAC,QAC3D,OAAO,EAAW,MAGJ,MAAMC,EAAAA,EACpB,EACD,EAEU,IAAI,OAAO,MAAM,KACvB,GAAU,EAAM,OAAS,EAAM,MAAM,QACvC,EAED,QAAQ,KAAK,EAAE,MAEX,CACN,QAAQ,KAAK,EAAE,GCzInB,GAAQ"}
1
+ {"version":3,"file":"run.cjs","names":["Command","pkg.bin","pkg.version","userConfig: Record<string, unknown>","createClient"],"sources":["../package.json","../src/cli.ts","../src/run.ts"],"sourcesContent":["{\n \"name\": \"@hey-api/openapi-ts\",\n \"version\": \"0.86.11\",\n \"description\": \"🚀 The OpenAPI to TypeScript codegen. Generate clients, SDKs, validators, and more.\",\n \"homepage\": \"https://heyapi.dev/\",\n \"repository\": {\n \"type\": \"git\",\n \"url\": \"git+https://github.com/hey-api/openapi-ts.git\"\n },\n \"bugs\": {\n \"url\": \"https://github.com/hey-api/openapi-ts/issues\"\n },\n \"license\": \"MIT\",\n \"author\": {\n \"email\": \"lubos@heyapi.dev\",\n \"name\": \"Hey API\",\n \"url\": \"https://heyapi.dev\"\n },\n \"funding\": \"https://github.com/sponsors/hey-api\",\n \"keywords\": [\n \"angular\",\n \"axios\",\n \"codegen\",\n \"fetch\",\n \"generator\",\n \"http\",\n \"javascript\",\n \"json\",\n \"next\",\n \"next.js\",\n \"node\",\n \"nuxt\",\n \"ofetch\",\n \"openapi\",\n \"rest\",\n \"swagger\",\n \"typescript\",\n \"xhr\",\n \"yaml\"\n ],\n \"type\": \"module\",\n \"main\": \"./dist/index.cjs\",\n \"module\": \"./dist/index.js\",\n \"types\": \"./dist/index.d.ts\",\n \"exports\": {\n \".\": {\n \"import\": {\n \"types\": \"./dist/index.d.ts\",\n \"default\": \"./dist/index.js\"\n },\n \"require\": {\n \"types\": \"./dist/index.d.cts\",\n \"default\": \"./dist/index.cjs\"\n }\n },\n \"./internal\": {\n \"import\": {\n \"types\": \"./dist/internal.d.ts\",\n \"default\": \"./dist/internal.js\"\n },\n \"require\": {\n \"types\": \"./dist/internal.d.cts\",\n \"default\": \"./dist/internal.cjs\"\n }\n },\n \"./package.json\": \"./package.json\"\n },\n \"bin\": {\n \"openapi-ts\": \"./bin/run.js\"\n },\n \"files\": [\n \"bin\",\n \"dist\",\n \"LICENSE.md\",\n \"README.md\"\n ],\n \"scripts\": {\n \"build\": \"tsdown && pnpm check-exports\",\n \"check-exports\": \"attw --pack . --profile node16\",\n \"dev\": \"tsdown --watch\",\n \"handlebars\": \"node src/legacy/handlebars/handlebars.cjs\",\n \"prepublishOnly\": \"pnpm build\",\n \"test:coverage\": \"vitest run --coverage\",\n \"test:update\": \"vitest watch --update\",\n \"test:watch\": \"vitest watch\",\n \"test\": \"vitest run\",\n \"typecheck\": \"tsc --noEmit\"\n },\n \"engines\": {\n \"node\": \">=20.19.0\"\n },\n \"dependencies\": {\n \"@hey-api/codegen-core\": \"workspace:^0.3.2\",\n \"@hey-api/json-schema-ref-parser\": \"1.2.1\",\n \"ansi-colors\": \"4.1.3\",\n \"c12\": \"3.3.1\",\n \"color-support\": \"1.1.3\",\n \"commander\": \"14.0.1\",\n \"handlebars\": \"4.7.8\",\n \"open\": \"10.2.0\",\n \"semver\": \"7.7.2\"\n },\n \"peerDependencies\": {\n \"typescript\": \">=5.5.3\"\n },\n \"devDependencies\": {\n \"@angular/common\": \"19.2.15\",\n \"@angular/compiler\": \"19.2.15\",\n \"@angular/compiler-cli\": \"19.2.15\",\n \"@angular/core\": \"19.2.15\",\n \"@angular/platform-browser\": \"19.2.15\",\n \"@angular/platform-browser-dynamic\": \"19.2.15\",\n \"@angular/router\": \"19.2.15\",\n \"@config/vite-base\": \"workspace:*\",\n \"@types/bun\": \"1.3.1\",\n \"@types/cross-spawn\": \"6.0.6\",\n \"@types/semver\": \"7.7.1\",\n \"axios\": \"1.8.2\",\n \"cross-spawn\": \"7.0.6\",\n \"eslint\": \"9.17.0\",\n \"glob\": \"11.0.3\",\n \"nuxt\": \"3.14.1592\",\n \"ofetch\": \"1.4.1\",\n \"prettier\": \"3.4.2\",\n \"rxjs\": \"7.8.2\",\n \"typescript\": \"5.9.3\",\n \"vue\": \"3.5.13\",\n \"yaml\": \"2.8.0\",\n \"zone.js\": \"0.15.1\"\n }\n}\n","import type { OptionValues } from 'commander';\nimport { Command } from 'commander';\n\nimport { createClient } from '~/index';\n\nimport pkg from '../package.json' assert { type: 'json' };\n\nconst stringToBoolean = (\n value: string | undefined,\n): boolean | string | undefined => {\n if (value === 'true') return true;\n if (value === 'false') return false;\n return value;\n};\n\nconst processParams = (\n obj: OptionValues,\n booleanKeys: ReadonlyArray<string>,\n): OptionValues => {\n for (const key of booleanKeys) {\n const value = obj[key];\n if (typeof value === 'string') {\n const parsedValue = stringToBoolean(value);\n delete obj[key];\n obj[key] = parsedValue;\n }\n }\n return obj;\n};\n\nexport const runCli = async (): Promise<void> => {\n const params = new Command()\n .name(Object.keys(pkg.bin)[0]!)\n .usage('[options]')\n .version(pkg.version)\n .option(\n '-c, --client <value>',\n 'HTTP client to generate [@hey-api/client-axios, @hey-api/client-fetch, @hey-api/client-next, @hey-api/client-nuxt, legacy/angular, legacy/axios, legacy/fetch, legacy/node, legacy/xhr]',\n )\n .option('-d, --debug', 'Set log level to debug')\n .option('--dry-run [value]', 'Skip writing files to disk?')\n .option(\n '-e, --experimental-parser [value]',\n 'Opt-in to the experimental parser?',\n )\n .option('-f, --file [value]', 'Path to the config file')\n .option(\n '-i, --input <value>',\n 'OpenAPI specification (path, url, or string content)',\n )\n .option('-l, --logs [value]', 'Logs folder')\n .option('-o, --output <value>', 'Output folder')\n .option('-p, --plugins [value...]', \"List of plugins you'd like to use\")\n .option(\n '--base [value]',\n 'DEPRECATED. Manually set base in OpenAPI config instead of inferring from server value',\n )\n .option('-s, --silent', 'Set log level to silent')\n .option(\n '--no-log-file',\n 'Disable writing a log file. Works like --silent but without suppressing console output',\n )\n .option(\n '-w, --watch [value]',\n 'Regenerate the client when the input file changes?',\n )\n .option('--exportCore [value]', 'DEPRECATED. Write core files to disk')\n .option('--name <value>', 'DEPRECATED. Custom client class name')\n .option('--request <value>', 'DEPRECATED. Path to custom request file')\n .option(\n '--useOptions [value]',\n 'DEPRECATED. Use options instead of arguments?',\n )\n .parse(process.argv)\n .opts();\n\n let userConfig: Record<string, unknown>;\n\n try {\n userConfig = processParams(params, [\n 'dryRun',\n 'experimentalParser',\n 'exportCore',\n 'logFile',\n 'useOptions',\n ]);\n\n if (userConfig.file) {\n userConfig.configFile = userConfig.file;\n delete userConfig.file;\n }\n\n if (params.plugins === true) {\n userConfig.plugins = [];\n } else if (params.plugins) {\n userConfig.plugins = params.plugins;\n } else if (userConfig.client) {\n userConfig.plugins = ['@hey-api/typescript', '@hey-api/sdk'];\n }\n\n if (userConfig.client) {\n (userConfig.plugins as Array<string>).push(userConfig.client as string);\n delete userConfig.client;\n }\n\n userConfig.logs = userConfig.logs\n ? {\n path: userConfig.logs,\n }\n : {};\n\n if (userConfig.debug || stringToBoolean(process.env.DEBUG)) {\n (userConfig.logs as Record<string, unknown>).level = 'debug';\n delete userConfig.debug;\n } else if (userConfig.silent) {\n (userConfig.logs as Record<string, unknown>).level = 'silent';\n delete userConfig.silent;\n }\n\n (userConfig.logs as Record<string, unknown>).file = userConfig.logFile;\n delete userConfig.logFile;\n\n if (typeof params.watch === 'string') {\n userConfig.watch = Number.parseInt(params.watch, 10);\n }\n\n if (!Object.keys(userConfig.logs as Record<string, unknown>).length) {\n delete userConfig.logs;\n }\n\n const context = await createClient(\n userConfig as unknown as Required<Parameters<typeof createClient>>[0],\n );\n if (\n !context[0]?.config.input.some(\n (input) => input.watch && input.watch.enabled,\n )\n ) {\n process.exit(0);\n }\n } catch {\n process.exit(1);\n }\n};\n","#!/usr/bin/env node\n\nimport { runCli } from '~/cli';\n\nrunCli();\n"],"mappings":";oHAEa,YAiEJ,CACL,aAAc,eACf,CC9DH,MAAM,EACJ,GAEI,IAAU,OAAe,GACzB,IAAU,QAAgB,GACvB,EAGH,GACJ,EACA,IACiB,CACjB,IAAK,IAAM,KAAO,EAAa,CAC7B,IAAM,EAAQ,EAAI,GAClB,GAAI,OAAO,GAAU,SAAU,CAC7B,IAAM,EAAc,EAAgB,EAAM,CAC1C,OAAO,EAAI,GACX,EAAI,GAAO,GAGf,OAAO,GAGI,EAAS,SAA2B,CAC/C,IAAM,EAAS,IAAIA,EAAAA,SAAS,CACzB,KAAK,OAAO,KAAKC,EAAQ,CAAC,GAAI,CAC9B,MAAM,YAAY,CAClB,QAAQC,EAAY,CACpB,OACC,uBACA,0LACD,CACA,OAAO,cAAe,yBAAyB,CAC/C,OAAO,oBAAqB,8BAA8B,CAC1D,OACC,oCACA,qCACD,CACA,OAAO,qBAAsB,0BAA0B,CACvD,OACC,sBACA,uDACD,CACA,OAAO,qBAAsB,cAAc,CAC3C,OAAO,uBAAwB,gBAAgB,CAC/C,OAAO,2BAA4B,oCAAoC,CACvE,OACC,iBACA,yFACD,CACA,OAAO,eAAgB,0BAA0B,CACjD,OACC,gBACA,yFACD,CACA,OACC,sBACA,qDACD,CACA,OAAO,uBAAwB,uCAAuC,CACtE,OAAO,iBAAkB,uCAAuC,CAChE,OAAO,oBAAqB,0CAA0C,CACtE,OACC,uBACA,gDACD,CACA,MAAM,QAAQ,KAAK,CACnB,MAAM,CAELC,EAEJ,GAAI,CACF,EAAa,EAAc,EAAQ,CACjC,SACA,qBACA,aACA,UACA,aACD,CAAC,CAEE,EAAW,OACb,EAAW,WAAa,EAAW,KACnC,OAAO,EAAW,MAGhB,EAAO,UAAY,GACrB,EAAW,QAAU,EAAE,CACd,EAAO,QAChB,EAAW,QAAU,EAAO,QACnB,EAAW,SACpB,EAAW,QAAU,CAAC,sBAAuB,eAAe,EAG1D,EAAW,SACZ,EAAW,QAA0B,KAAK,EAAW,OAAiB,CACvE,OAAO,EAAW,QAGpB,EAAW,KAAO,EAAW,KACzB,CACE,KAAM,EAAW,KAClB,CACD,EAAE,CAEF,EAAW,OAAS,EAAgB,QAAQ,IAAI,MAAM,EACvD,EAAW,KAAiC,MAAQ,QACrD,OAAO,EAAW,OACT,EAAW,SACnB,EAAW,KAAiC,MAAQ,SACrD,OAAO,EAAW,QAGnB,EAAW,KAAiC,KAAO,EAAW,QAC/D,OAAO,EAAW,QAEd,OAAO,EAAO,OAAU,WAC1B,EAAW,MAAQ,OAAO,SAAS,EAAO,MAAO,GAAG,EAGjD,OAAO,KAAK,EAAW,KAAgC,CAAC,QAC3D,OAAO,EAAW,MAGJ,MAAMC,EAAAA,EACpB,EACD,EAEU,IAAI,OAAO,MAAM,KACvB,GAAU,EAAM,OAAS,EAAM,MAAM,QACvC,EAED,QAAQ,KAAK,EAAE,MAEX,CACN,QAAQ,KAAK,EAAE,GCzInB,GAAQ"}
package/dist/run.js CHANGED
@@ -1,3 +1,3 @@
1
1
  #!/usr/bin/env node
2
- import"./getSpec-NJ6vig64.js";import{r as e}from"./src-C4Q2-7Ic.js";import{Command as t}from"commander";var n=`0.86.10`,r={"openapi-ts":`./bin/run.js`};const i=e=>e===`true`?!0:e===`false`?!1:e,a=(e,t)=>{for(let n of t){let t=e[n];if(typeof t==`string`){let r=i(t);delete e[n],e[n]=r}}return e};(async()=>{let o=new t().name(Object.keys(r)[0]).usage(`[options]`).version(n).option(`-c, --client <value>`,`HTTP client to generate [@hey-api/client-axios, @hey-api/client-fetch, @hey-api/client-next, @hey-api/client-nuxt, legacy/angular, legacy/axios, legacy/fetch, legacy/node, legacy/xhr]`).option(`-d, --debug`,`Set log level to debug`).option(`--dry-run [value]`,`Skip writing files to disk?`).option(`-e, --experimental-parser [value]`,`Opt-in to the experimental parser?`).option(`-f, --file [value]`,`Path to the config file`).option(`-i, --input <value>`,`OpenAPI specification (path, url, or string content)`).option(`-l, --logs [value]`,`Logs folder`).option(`-o, --output <value>`,`Output folder`).option(`-p, --plugins [value...]`,`List of plugins you'd like to use`).option(`--base [value]`,`DEPRECATED. Manually set base in OpenAPI config instead of inferring from server value`).option(`-s, --silent`,`Set log level to silent`).option(`--no-log-file`,`Disable writing a log file. Works like --silent but without suppressing console output`).option(`-w, --watch [value]`,`Regenerate the client when the input file changes?`).option(`--exportCore [value]`,`DEPRECATED. Write core files to disk`).option(`--name <value>`,`DEPRECATED. Custom client class name`).option(`--request <value>`,`DEPRECATED. Path to custom request file`).option(`--useOptions [value]`,`DEPRECATED. Use options instead of arguments?`).parse(process.argv).opts(),s;try{s=a(o,[`dryRun`,`experimentalParser`,`exportCore`,`logFile`,`useOptions`]),s.file&&(s.configFile=s.file,delete s.file),o.plugins===!0?s.plugins=[]:o.plugins?s.plugins=o.plugins:s.client&&(s.plugins=[`@hey-api/typescript`,`@hey-api/sdk`]),s.client&&(s.plugins.push(s.client),delete s.client),s.logs=s.logs?{path:s.logs}:{},s.debug||i(process.env.DEBUG)?(s.logs.level=`debug`,delete s.debug):s.silent&&(s.logs.level=`silent`,delete s.silent),s.logs.file=s.logFile,delete s.logFile,typeof o.watch==`string`&&(s.watch=Number.parseInt(o.watch,10)),Object.keys(s.logs).length||delete s.logs,(await e(s))[0]?.config.input.some(e=>e.watch&&e.watch.enabled)||process.exit(0)}catch{process.exit(1)}})();export{};
2
+ import"./getSpec-NJ6vig64.js";import{r as e}from"./src-C4Q2-7Ic.js";import{Command as t}from"commander";var n=`0.86.11`,r={"openapi-ts":`./bin/run.js`};const i=e=>e===`true`?!0:e===`false`?!1:e,a=(e,t)=>{for(let n of t){let t=e[n];if(typeof t==`string`){let r=i(t);delete e[n],e[n]=r}}return e};(async()=>{let o=new t().name(Object.keys(r)[0]).usage(`[options]`).version(n).option(`-c, --client <value>`,`HTTP client to generate [@hey-api/client-axios, @hey-api/client-fetch, @hey-api/client-next, @hey-api/client-nuxt, legacy/angular, legacy/axios, legacy/fetch, legacy/node, legacy/xhr]`).option(`-d, --debug`,`Set log level to debug`).option(`--dry-run [value]`,`Skip writing files to disk?`).option(`-e, --experimental-parser [value]`,`Opt-in to the experimental parser?`).option(`-f, --file [value]`,`Path to the config file`).option(`-i, --input <value>`,`OpenAPI specification (path, url, or string content)`).option(`-l, --logs [value]`,`Logs folder`).option(`-o, --output <value>`,`Output folder`).option(`-p, --plugins [value...]`,`List of plugins you'd like to use`).option(`--base [value]`,`DEPRECATED. Manually set base in OpenAPI config instead of inferring from server value`).option(`-s, --silent`,`Set log level to silent`).option(`--no-log-file`,`Disable writing a log file. Works like --silent but without suppressing console output`).option(`-w, --watch [value]`,`Regenerate the client when the input file changes?`).option(`--exportCore [value]`,`DEPRECATED. Write core files to disk`).option(`--name <value>`,`DEPRECATED. Custom client class name`).option(`--request <value>`,`DEPRECATED. Path to custom request file`).option(`--useOptions [value]`,`DEPRECATED. Use options instead of arguments?`).parse(process.argv).opts(),s;try{s=a(o,[`dryRun`,`experimentalParser`,`exportCore`,`logFile`,`useOptions`]),s.file&&(s.configFile=s.file,delete s.file),o.plugins===!0?s.plugins=[]:o.plugins?s.plugins=o.plugins:s.client&&(s.plugins=[`@hey-api/typescript`,`@hey-api/sdk`]),s.client&&(s.plugins.push(s.client),delete s.client),s.logs=s.logs?{path:s.logs}:{},s.debug||i(process.env.DEBUG)?(s.logs.level=`debug`,delete s.debug):s.silent&&(s.logs.level=`silent`,delete s.silent),s.logs.file=s.logFile,delete s.logFile,typeof o.watch==`string`&&(s.watch=Number.parseInt(o.watch,10)),Object.keys(s.logs).length||delete s.logs,(await e(s))[0]?.config.input.some(e=>e.watch&&e.watch.enabled)||process.exit(0)}catch{process.exit(1)}})();export{};
3
3
  //# sourceMappingURL=run.js.map
package/dist/run.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"run.js","names":["pkg.bin","pkg.version","userConfig: Record<string, unknown>"],"sources":["../package.json","../src/cli.ts","../src/run.ts"],"sourcesContent":["{\n \"name\": \"@hey-api/openapi-ts\",\n \"version\": \"0.86.10\",\n \"description\": \"🚀 The OpenAPI to TypeScript codegen. Generate clients, SDKs, validators, and more.\",\n \"homepage\": \"https://heyapi.dev/\",\n \"repository\": {\n \"type\": \"git\",\n \"url\": \"git+https://github.com/hey-api/openapi-ts.git\"\n },\n \"bugs\": {\n \"url\": \"https://github.com/hey-api/openapi-ts/issues\"\n },\n \"license\": \"MIT\",\n \"author\": {\n \"email\": \"lubos@heyapi.dev\",\n \"name\": \"Hey API\",\n \"url\": \"https://heyapi.dev\"\n },\n \"funding\": \"https://github.com/sponsors/hey-api\",\n \"keywords\": [\n \"angular\",\n \"axios\",\n \"codegen\",\n \"fetch\",\n \"generator\",\n \"http\",\n \"javascript\",\n \"json\",\n \"next\",\n \"next.js\",\n \"node\",\n \"nuxt\",\n \"ofetch\",\n \"openapi\",\n \"rest\",\n \"swagger\",\n \"typescript\",\n \"xhr\",\n \"yaml\"\n ],\n \"type\": \"module\",\n \"main\": \"./dist/index.cjs\",\n \"module\": \"./dist/index.js\",\n \"types\": \"./dist/index.d.ts\",\n \"exports\": {\n \".\": {\n \"import\": {\n \"types\": \"./dist/index.d.ts\",\n \"default\": \"./dist/index.js\"\n },\n \"require\": {\n \"types\": \"./dist/index.d.cts\",\n \"default\": \"./dist/index.cjs\"\n }\n },\n \"./internal\": {\n \"import\": {\n \"types\": \"./dist/internal.d.ts\",\n \"default\": \"./dist/internal.js\"\n },\n \"require\": {\n \"types\": \"./dist/internal.d.cts\",\n \"default\": \"./dist/internal.cjs\"\n }\n },\n \"./package.json\": \"./package.json\"\n },\n \"bin\": {\n \"openapi-ts\": \"./bin/run.js\"\n },\n \"files\": [\n \"bin\",\n \"dist\",\n \"LICENSE.md\",\n \"README.md\"\n ],\n \"scripts\": {\n \"build\": \"tsdown && pnpm check-exports\",\n \"check-exports\": \"attw --pack . --profile node16\",\n \"dev\": \"tsdown --watch\",\n \"handlebars\": \"node src/legacy/handlebars/handlebars.cjs\",\n \"prepublishOnly\": \"pnpm build\",\n \"test:coverage\": \"vitest run --coverage\",\n \"test:update\": \"vitest watch --update\",\n \"test:watch\": \"vitest watch\",\n \"test\": \"vitest run\",\n \"typecheck\": \"tsc --noEmit\"\n },\n \"engines\": {\n \"node\": \">=20.19.0\"\n },\n \"dependencies\": {\n \"@hey-api/codegen-core\": \"workspace:^0.3.2\",\n \"@hey-api/json-schema-ref-parser\": \"1.2.1\",\n \"ansi-colors\": \"4.1.3\",\n \"c12\": \"3.3.1\",\n \"color-support\": \"1.1.3\",\n \"commander\": \"14.0.1\",\n \"handlebars\": \"4.7.8\",\n \"open\": \"10.2.0\",\n \"semver\": \"7.7.2\"\n },\n \"peerDependencies\": {\n \"typescript\": \">=5.5.3\"\n },\n \"devDependencies\": {\n \"@angular/common\": \"19.2.15\",\n \"@angular/compiler\": \"19.2.15\",\n \"@angular/compiler-cli\": \"19.2.15\",\n \"@angular/core\": \"19.2.15\",\n \"@angular/platform-browser\": \"19.2.15\",\n \"@angular/platform-browser-dynamic\": \"19.2.15\",\n \"@angular/router\": \"19.2.15\",\n \"@config/vite-base\": \"workspace:*\",\n \"@types/bun\": \"1.3.1\",\n \"@types/cross-spawn\": \"6.0.6\",\n \"@types/semver\": \"7.7.1\",\n \"axios\": \"1.8.2\",\n \"cross-spawn\": \"7.0.6\",\n \"eslint\": \"9.17.0\",\n \"glob\": \"11.0.3\",\n \"nuxt\": \"3.14.1592\",\n \"ofetch\": \"1.4.1\",\n \"prettier\": \"3.4.2\",\n \"rxjs\": \"7.8.2\",\n \"typescript\": \"5.9.3\",\n \"vue\": \"3.5.13\",\n \"yaml\": \"2.8.0\",\n \"zone.js\": \"0.15.1\"\n }\n}\n","import type { OptionValues } from 'commander';\nimport { Command } from 'commander';\n\nimport { createClient } from '~/index';\n\nimport pkg from '../package.json' assert { type: 'json' };\n\nconst stringToBoolean = (\n value: string | undefined,\n): boolean | string | undefined => {\n if (value === 'true') return true;\n if (value === 'false') return false;\n return value;\n};\n\nconst processParams = (\n obj: OptionValues,\n booleanKeys: ReadonlyArray<string>,\n): OptionValues => {\n for (const key of booleanKeys) {\n const value = obj[key];\n if (typeof value === 'string') {\n const parsedValue = stringToBoolean(value);\n delete obj[key];\n obj[key] = parsedValue;\n }\n }\n return obj;\n};\n\nexport const runCli = async (): Promise<void> => {\n const params = new Command()\n .name(Object.keys(pkg.bin)[0]!)\n .usage('[options]')\n .version(pkg.version)\n .option(\n '-c, --client <value>',\n 'HTTP client to generate [@hey-api/client-axios, @hey-api/client-fetch, @hey-api/client-next, @hey-api/client-nuxt, legacy/angular, legacy/axios, legacy/fetch, legacy/node, legacy/xhr]',\n )\n .option('-d, --debug', 'Set log level to debug')\n .option('--dry-run [value]', 'Skip writing files to disk?')\n .option(\n '-e, --experimental-parser [value]',\n 'Opt-in to the experimental parser?',\n )\n .option('-f, --file [value]', 'Path to the config file')\n .option(\n '-i, --input <value>',\n 'OpenAPI specification (path, url, or string content)',\n )\n .option('-l, --logs [value]', 'Logs folder')\n .option('-o, --output <value>', 'Output folder')\n .option('-p, --plugins [value...]', \"List of plugins you'd like to use\")\n .option(\n '--base [value]',\n 'DEPRECATED. Manually set base in OpenAPI config instead of inferring from server value',\n )\n .option('-s, --silent', 'Set log level to silent')\n .option(\n '--no-log-file',\n 'Disable writing a log file. Works like --silent but without suppressing console output',\n )\n .option(\n '-w, --watch [value]',\n 'Regenerate the client when the input file changes?',\n )\n .option('--exportCore [value]', 'DEPRECATED. Write core files to disk')\n .option('--name <value>', 'DEPRECATED. Custom client class name')\n .option('--request <value>', 'DEPRECATED. Path to custom request file')\n .option(\n '--useOptions [value]',\n 'DEPRECATED. Use options instead of arguments?',\n )\n .parse(process.argv)\n .opts();\n\n let userConfig: Record<string, unknown>;\n\n try {\n userConfig = processParams(params, [\n 'dryRun',\n 'experimentalParser',\n 'exportCore',\n 'logFile',\n 'useOptions',\n ]);\n\n if (userConfig.file) {\n userConfig.configFile = userConfig.file;\n delete userConfig.file;\n }\n\n if (params.plugins === true) {\n userConfig.plugins = [];\n } else if (params.plugins) {\n userConfig.plugins = params.plugins;\n } else if (userConfig.client) {\n userConfig.plugins = ['@hey-api/typescript', '@hey-api/sdk'];\n }\n\n if (userConfig.client) {\n (userConfig.plugins as Array<string>).push(userConfig.client as string);\n delete userConfig.client;\n }\n\n userConfig.logs = userConfig.logs\n ? {\n path: userConfig.logs,\n }\n : {};\n\n if (userConfig.debug || stringToBoolean(process.env.DEBUG)) {\n (userConfig.logs as Record<string, unknown>).level = 'debug';\n delete userConfig.debug;\n } else if (userConfig.silent) {\n (userConfig.logs as Record<string, unknown>).level = 'silent';\n delete userConfig.silent;\n }\n\n (userConfig.logs as Record<string, unknown>).file = userConfig.logFile;\n delete userConfig.logFile;\n\n if (typeof params.watch === 'string') {\n userConfig.watch = Number.parseInt(params.watch, 10);\n }\n\n if (!Object.keys(userConfig.logs as Record<string, unknown>).length) {\n delete userConfig.logs;\n }\n\n const context = await createClient(\n userConfig as unknown as Required<Parameters<typeof createClient>>[0],\n );\n if (\n !context[0]?.config.input.some(\n (input) => input.watch && input.watch.enabled,\n )\n ) {\n process.exit(0);\n }\n } catch {\n process.exit(1);\n }\n};\n","#!/usr/bin/env node\n\nimport { runCli } from '~/cli';\n\nrunCli();\n"],"mappings":";8GAEa,YAiEJ,CACL,aAAc,eACf,CC9DH,MAAM,EACJ,GAEI,IAAU,OAAe,GACzB,IAAU,QAAgB,GACvB,EAGH,GACJ,EACA,IACiB,CACjB,IAAK,IAAM,KAAO,EAAa,CAC7B,IAAM,EAAQ,EAAI,GAClB,GAAI,OAAO,GAAU,SAAU,CAC7B,IAAM,EAAc,EAAgB,EAAM,CAC1C,OAAO,EAAI,GACX,EAAI,GAAO,GAGf,OAAO,IAGa,SAA2B,CAC/C,IAAM,EAAS,IAAI,GAAS,CACzB,KAAK,OAAO,KAAKA,EAAQ,CAAC,GAAI,CAC9B,MAAM,YAAY,CAClB,QAAQC,EAAY,CACpB,OACC,uBACA,0LACD,CACA,OAAO,cAAe,yBAAyB,CAC/C,OAAO,oBAAqB,8BAA8B,CAC1D,OACC,oCACA,qCACD,CACA,OAAO,qBAAsB,0BAA0B,CACvD,OACC,sBACA,uDACD,CACA,OAAO,qBAAsB,cAAc,CAC3C,OAAO,uBAAwB,gBAAgB,CAC/C,OAAO,2BAA4B,oCAAoC,CACvE,OACC,iBACA,yFACD,CACA,OAAO,eAAgB,0BAA0B,CACjD,OACC,gBACA,yFACD,CACA,OACC,sBACA,qDACD,CACA,OAAO,uBAAwB,uCAAuC,CACtE,OAAO,iBAAkB,uCAAuC,CAChE,OAAO,oBAAqB,0CAA0C,CACtE,OACC,uBACA,gDACD,CACA,MAAM,QAAQ,KAAK,CACnB,MAAM,CAELC,EAEJ,GAAI,CACF,EAAa,EAAc,EAAQ,CACjC,SACA,qBACA,aACA,UACA,aACD,CAAC,CAEE,EAAW,OACb,EAAW,WAAa,EAAW,KACnC,OAAO,EAAW,MAGhB,EAAO,UAAY,GACrB,EAAW,QAAU,EAAE,CACd,EAAO,QAChB,EAAW,QAAU,EAAO,QACnB,EAAW,SACpB,EAAW,QAAU,CAAC,sBAAuB,eAAe,EAG1D,EAAW,SACZ,EAAW,QAA0B,KAAK,EAAW,OAAiB,CACvE,OAAO,EAAW,QAGpB,EAAW,KAAO,EAAW,KACzB,CACE,KAAM,EAAW,KAClB,CACD,EAAE,CAEF,EAAW,OAAS,EAAgB,QAAQ,IAAI,MAAM,EACvD,EAAW,KAAiC,MAAQ,QACrD,OAAO,EAAW,OACT,EAAW,SACnB,EAAW,KAAiC,MAAQ,SACrD,OAAO,EAAW,QAGnB,EAAW,KAAiC,KAAO,EAAW,QAC/D,OAAO,EAAW,QAEd,OAAO,EAAO,OAAU,WAC1B,EAAW,MAAQ,OAAO,SAAS,EAAO,MAAO,GAAG,EAGjD,OAAO,KAAK,EAAW,KAAgC,CAAC,QAC3D,OAAO,EAAW,MAGJ,MAAM,EACpB,EACD,EAEU,IAAI,OAAO,MAAM,KACvB,GAAU,EAAM,OAAS,EAAM,MAAM,QACvC,EAED,QAAQ,KAAK,EAAE,MAEX,CACN,QAAQ,KAAK,EAAE,KCzIX"}
1
+ {"version":3,"file":"run.js","names":["pkg.bin","pkg.version","userConfig: Record<string, unknown>"],"sources":["../package.json","../src/cli.ts","../src/run.ts"],"sourcesContent":["{\n \"name\": \"@hey-api/openapi-ts\",\n \"version\": \"0.86.11\",\n \"description\": \"🚀 The OpenAPI to TypeScript codegen. Generate clients, SDKs, validators, and more.\",\n \"homepage\": \"https://heyapi.dev/\",\n \"repository\": {\n \"type\": \"git\",\n \"url\": \"git+https://github.com/hey-api/openapi-ts.git\"\n },\n \"bugs\": {\n \"url\": \"https://github.com/hey-api/openapi-ts/issues\"\n },\n \"license\": \"MIT\",\n \"author\": {\n \"email\": \"lubos@heyapi.dev\",\n \"name\": \"Hey API\",\n \"url\": \"https://heyapi.dev\"\n },\n \"funding\": \"https://github.com/sponsors/hey-api\",\n \"keywords\": [\n \"angular\",\n \"axios\",\n \"codegen\",\n \"fetch\",\n \"generator\",\n \"http\",\n \"javascript\",\n \"json\",\n \"next\",\n \"next.js\",\n \"node\",\n \"nuxt\",\n \"ofetch\",\n \"openapi\",\n \"rest\",\n \"swagger\",\n \"typescript\",\n \"xhr\",\n \"yaml\"\n ],\n \"type\": \"module\",\n \"main\": \"./dist/index.cjs\",\n \"module\": \"./dist/index.js\",\n \"types\": \"./dist/index.d.ts\",\n \"exports\": {\n \".\": {\n \"import\": {\n \"types\": \"./dist/index.d.ts\",\n \"default\": \"./dist/index.js\"\n },\n \"require\": {\n \"types\": \"./dist/index.d.cts\",\n \"default\": \"./dist/index.cjs\"\n }\n },\n \"./internal\": {\n \"import\": {\n \"types\": \"./dist/internal.d.ts\",\n \"default\": \"./dist/internal.js\"\n },\n \"require\": {\n \"types\": \"./dist/internal.d.cts\",\n \"default\": \"./dist/internal.cjs\"\n }\n },\n \"./package.json\": \"./package.json\"\n },\n \"bin\": {\n \"openapi-ts\": \"./bin/run.js\"\n },\n \"files\": [\n \"bin\",\n \"dist\",\n \"LICENSE.md\",\n \"README.md\"\n ],\n \"scripts\": {\n \"build\": \"tsdown && pnpm check-exports\",\n \"check-exports\": \"attw --pack . --profile node16\",\n \"dev\": \"tsdown --watch\",\n \"handlebars\": \"node src/legacy/handlebars/handlebars.cjs\",\n \"prepublishOnly\": \"pnpm build\",\n \"test:coverage\": \"vitest run --coverage\",\n \"test:update\": \"vitest watch --update\",\n \"test:watch\": \"vitest watch\",\n \"test\": \"vitest run\",\n \"typecheck\": \"tsc --noEmit\"\n },\n \"engines\": {\n \"node\": \">=20.19.0\"\n },\n \"dependencies\": {\n \"@hey-api/codegen-core\": \"workspace:^0.3.2\",\n \"@hey-api/json-schema-ref-parser\": \"1.2.1\",\n \"ansi-colors\": \"4.1.3\",\n \"c12\": \"3.3.1\",\n \"color-support\": \"1.1.3\",\n \"commander\": \"14.0.1\",\n \"handlebars\": \"4.7.8\",\n \"open\": \"10.2.0\",\n \"semver\": \"7.7.2\"\n },\n \"peerDependencies\": {\n \"typescript\": \">=5.5.3\"\n },\n \"devDependencies\": {\n \"@angular/common\": \"19.2.15\",\n \"@angular/compiler\": \"19.2.15\",\n \"@angular/compiler-cli\": \"19.2.15\",\n \"@angular/core\": \"19.2.15\",\n \"@angular/platform-browser\": \"19.2.15\",\n \"@angular/platform-browser-dynamic\": \"19.2.15\",\n \"@angular/router\": \"19.2.15\",\n \"@config/vite-base\": \"workspace:*\",\n \"@types/bun\": \"1.3.1\",\n \"@types/cross-spawn\": \"6.0.6\",\n \"@types/semver\": \"7.7.1\",\n \"axios\": \"1.8.2\",\n \"cross-spawn\": \"7.0.6\",\n \"eslint\": \"9.17.0\",\n \"glob\": \"11.0.3\",\n \"nuxt\": \"3.14.1592\",\n \"ofetch\": \"1.4.1\",\n \"prettier\": \"3.4.2\",\n \"rxjs\": \"7.8.2\",\n \"typescript\": \"5.9.3\",\n \"vue\": \"3.5.13\",\n \"yaml\": \"2.8.0\",\n \"zone.js\": \"0.15.1\"\n }\n}\n","import type { OptionValues } from 'commander';\nimport { Command } from 'commander';\n\nimport { createClient } from '~/index';\n\nimport pkg from '../package.json' assert { type: 'json' };\n\nconst stringToBoolean = (\n value: string | undefined,\n): boolean | string | undefined => {\n if (value === 'true') return true;\n if (value === 'false') return false;\n return value;\n};\n\nconst processParams = (\n obj: OptionValues,\n booleanKeys: ReadonlyArray<string>,\n): OptionValues => {\n for (const key of booleanKeys) {\n const value = obj[key];\n if (typeof value === 'string') {\n const parsedValue = stringToBoolean(value);\n delete obj[key];\n obj[key] = parsedValue;\n }\n }\n return obj;\n};\n\nexport const runCli = async (): Promise<void> => {\n const params = new Command()\n .name(Object.keys(pkg.bin)[0]!)\n .usage('[options]')\n .version(pkg.version)\n .option(\n '-c, --client <value>',\n 'HTTP client to generate [@hey-api/client-axios, @hey-api/client-fetch, @hey-api/client-next, @hey-api/client-nuxt, legacy/angular, legacy/axios, legacy/fetch, legacy/node, legacy/xhr]',\n )\n .option('-d, --debug', 'Set log level to debug')\n .option('--dry-run [value]', 'Skip writing files to disk?')\n .option(\n '-e, --experimental-parser [value]',\n 'Opt-in to the experimental parser?',\n )\n .option('-f, --file [value]', 'Path to the config file')\n .option(\n '-i, --input <value>',\n 'OpenAPI specification (path, url, or string content)',\n )\n .option('-l, --logs [value]', 'Logs folder')\n .option('-o, --output <value>', 'Output folder')\n .option('-p, --plugins [value...]', \"List of plugins you'd like to use\")\n .option(\n '--base [value]',\n 'DEPRECATED. Manually set base in OpenAPI config instead of inferring from server value',\n )\n .option('-s, --silent', 'Set log level to silent')\n .option(\n '--no-log-file',\n 'Disable writing a log file. Works like --silent but without suppressing console output',\n )\n .option(\n '-w, --watch [value]',\n 'Regenerate the client when the input file changes?',\n )\n .option('--exportCore [value]', 'DEPRECATED. Write core files to disk')\n .option('--name <value>', 'DEPRECATED. Custom client class name')\n .option('--request <value>', 'DEPRECATED. Path to custom request file')\n .option(\n '--useOptions [value]',\n 'DEPRECATED. Use options instead of arguments?',\n )\n .parse(process.argv)\n .opts();\n\n let userConfig: Record<string, unknown>;\n\n try {\n userConfig = processParams(params, [\n 'dryRun',\n 'experimentalParser',\n 'exportCore',\n 'logFile',\n 'useOptions',\n ]);\n\n if (userConfig.file) {\n userConfig.configFile = userConfig.file;\n delete userConfig.file;\n }\n\n if (params.plugins === true) {\n userConfig.plugins = [];\n } else if (params.plugins) {\n userConfig.plugins = params.plugins;\n } else if (userConfig.client) {\n userConfig.plugins = ['@hey-api/typescript', '@hey-api/sdk'];\n }\n\n if (userConfig.client) {\n (userConfig.plugins as Array<string>).push(userConfig.client as string);\n delete userConfig.client;\n }\n\n userConfig.logs = userConfig.logs\n ? {\n path: userConfig.logs,\n }\n : {};\n\n if (userConfig.debug || stringToBoolean(process.env.DEBUG)) {\n (userConfig.logs as Record<string, unknown>).level = 'debug';\n delete userConfig.debug;\n } else if (userConfig.silent) {\n (userConfig.logs as Record<string, unknown>).level = 'silent';\n delete userConfig.silent;\n }\n\n (userConfig.logs as Record<string, unknown>).file = userConfig.logFile;\n delete userConfig.logFile;\n\n if (typeof params.watch === 'string') {\n userConfig.watch = Number.parseInt(params.watch, 10);\n }\n\n if (!Object.keys(userConfig.logs as Record<string, unknown>).length) {\n delete userConfig.logs;\n }\n\n const context = await createClient(\n userConfig as unknown as Required<Parameters<typeof createClient>>[0],\n );\n if (\n !context[0]?.config.input.some(\n (input) => input.watch && input.watch.enabled,\n )\n ) {\n process.exit(0);\n }\n } catch {\n process.exit(1);\n }\n};\n","#!/usr/bin/env node\n\nimport { runCli } from '~/cli';\n\nrunCli();\n"],"mappings":";8GAEa,YAiEJ,CACL,aAAc,eACf,CC9DH,MAAM,EACJ,GAEI,IAAU,OAAe,GACzB,IAAU,QAAgB,GACvB,EAGH,GACJ,EACA,IACiB,CACjB,IAAK,IAAM,KAAO,EAAa,CAC7B,IAAM,EAAQ,EAAI,GAClB,GAAI,OAAO,GAAU,SAAU,CAC7B,IAAM,EAAc,EAAgB,EAAM,CAC1C,OAAO,EAAI,GACX,EAAI,GAAO,GAGf,OAAO,IAGa,SAA2B,CAC/C,IAAM,EAAS,IAAI,GAAS,CACzB,KAAK,OAAO,KAAKA,EAAQ,CAAC,GAAI,CAC9B,MAAM,YAAY,CAClB,QAAQC,EAAY,CACpB,OACC,uBACA,0LACD,CACA,OAAO,cAAe,yBAAyB,CAC/C,OAAO,oBAAqB,8BAA8B,CAC1D,OACC,oCACA,qCACD,CACA,OAAO,qBAAsB,0BAA0B,CACvD,OACC,sBACA,uDACD,CACA,OAAO,qBAAsB,cAAc,CAC3C,OAAO,uBAAwB,gBAAgB,CAC/C,OAAO,2BAA4B,oCAAoC,CACvE,OACC,iBACA,yFACD,CACA,OAAO,eAAgB,0BAA0B,CACjD,OACC,gBACA,yFACD,CACA,OACC,sBACA,qDACD,CACA,OAAO,uBAAwB,uCAAuC,CACtE,OAAO,iBAAkB,uCAAuC,CAChE,OAAO,oBAAqB,0CAA0C,CACtE,OACC,uBACA,gDACD,CACA,MAAM,QAAQ,KAAK,CACnB,MAAM,CAELC,EAEJ,GAAI,CACF,EAAa,EAAc,EAAQ,CACjC,SACA,qBACA,aACA,UACA,aACD,CAAC,CAEE,EAAW,OACb,EAAW,WAAa,EAAW,KACnC,OAAO,EAAW,MAGhB,EAAO,UAAY,GACrB,EAAW,QAAU,EAAE,CACd,EAAO,QAChB,EAAW,QAAU,EAAO,QACnB,EAAW,SACpB,EAAW,QAAU,CAAC,sBAAuB,eAAe,EAG1D,EAAW,SACZ,EAAW,QAA0B,KAAK,EAAW,OAAiB,CACvE,OAAO,EAAW,QAGpB,EAAW,KAAO,EAAW,KACzB,CACE,KAAM,EAAW,KAClB,CACD,EAAE,CAEF,EAAW,OAAS,EAAgB,QAAQ,IAAI,MAAM,EACvD,EAAW,KAAiC,MAAQ,QACrD,OAAO,EAAW,OACT,EAAW,SACnB,EAAW,KAAiC,MAAQ,SACrD,OAAO,EAAW,QAGnB,EAAW,KAAiC,KAAO,EAAW,QAC/D,OAAO,EAAW,QAEd,OAAO,EAAO,OAAU,WAC1B,EAAW,MAAQ,OAAO,SAAS,EAAO,MAAO,GAAG,EAGjD,OAAO,KAAK,EAAW,KAAgC,CAAC,QAC3D,OAAO,EAAW,MAGJ,MAAM,EACpB,EACD,EAEU,IAAI,OAAO,MAAM,KACvB,GAAU,EAAM,OAAS,EAAM,MAAM,QACvC,EAED,QAAQ,KAAK,EAAE,MAEX,CACN,QAAQ,KAAK,EAAE,KCzIX"}
@@ -7401,7 +7401,7 @@ declare class PluginInstance<T$1 extends Plugin.Types = Plugin.Types> {
7401
7401
  * This ensures, for example, that schemas are always processed before
7402
7402
  * operations, which may reference them.
7403
7403
  *
7404
- * @template T - The event type(s) to yield. Defaults to all event types.
7404
+ * @template TKind - The event type(s) to yield. Defaults to all event types.
7405
7405
  * @param events - The event types to walk over. If none are provided, all event types are included.
7406
7406
  * @param callback - Function to execute for each event.
7407
7407
  *
@@ -7415,8 +7415,8 @@ declare class PluginInstance<T$1 extends Plugin.Types = Plugin.Types> {
7415
7415
  * }
7416
7416
  * });
7417
7417
  */
7418
- forEach<T extends IrTopLevelKind = IrTopLevelKind>(...args: [...events: ReadonlyArray<T$1>, callback: (event: WalkEvent<T$1>) => void]): void;
7419
- forEach<T extends IrTopLevelKind = IrTopLevelKind>(...args: [...events: ReadonlyArray<T$1>, callback: (event: WalkEvent<T$1>) => void, options: WalkOptions<T$1>]): void;
7418
+ forEach<TKind extends IrTopLevelKind = IrTopLevelKind>(...args: [...events: ReadonlyArray<TKind>, callback: (event: WalkEvent<TKind>) => void]): void;
7419
+ forEach<TKind extends IrTopLevelKind = IrTopLevelKind>(...args: [...events: ReadonlyArray<TKind>, callback: (event: WalkEvent<TKind>) => void, options: WalkOptions<TKind>]): void;
7420
7420
  /**
7421
7421
  * Retrieves a registered plugin instance by its name from the context. This
7422
7422
  * allows plugins to access other plugins that have been registered in the
@@ -7425,7 +7425,7 @@ declare class PluginInstance<T$1 extends Plugin.Types = Plugin.Types> {
7425
7425
  * @param name Plugin name as defined in the configuration.
7426
7426
  * @returns The plugin instance if found, undefined otherwise.
7427
7427
  */
7428
- getPlugin<T extends keyof PluginConfigMap>(name: T$1): T$1 extends any ? PluginInstance<PluginConfigMap[T$1]> | undefined : never;
7428
+ getPlugin<TName extends keyof PluginConfigMap>(name: TName): TName extends any ? PluginInstance<PluginConfigMap[TName]> | undefined : never;
7429
7429
  /**
7430
7430
  * Retrieves a registered plugin instance by its name from the context. This
7431
7431
  * allows plugins to access other plugins that have been registered in the
@@ -7434,7 +7434,7 @@ declare class PluginInstance<T$1 extends Plugin.Types = Plugin.Types> {
7434
7434
  * @param name Plugin name as defined in the configuration.
7435
7435
  * @returns The plugin instance if found, throw otherwise.
7436
7436
  */
7437
- getPluginOrThrow<T extends keyof PluginConfigMap>(name: T$1): T$1 extends any ? PluginInstance<PluginConfigMap[T$1]> : never;
7437
+ getPluginOrThrow<TName extends keyof PluginConfigMap>(name: TName): TName extends any ? PluginInstance<PluginConfigMap[TName]> : never;
7438
7438
  getSymbol(identifier: SymbolIdentifier): Symbol | undefined;
7439
7439
  hooks: {
7440
7440
  operation: {
@@ -14824,4 +14824,4 @@ interface WatchValues {
14824
14824
  }
14825
14825
  //#endregion
14826
14826
  export { AccessLevel as A, PluginHandler as C, Comments as D, MaybeArray as E, types_d_exports as F, __export as I, FunctionTypeParameter as M, ObjectValue as N, ImportExportItemObject as O, SyntaxKindKeyword as P, Client$2 as S, LazyOrAsync as T, OpenApiRequestBodyObject as _, Input as a, parseOpenApiSpec as b, ExpressionTransformer as c, Client as d, Operation as f, OpenApiParameterObject as g, OpenApiOperationObject as h, UserConfig$1 as i, FunctionParameter as j, tsNodeToString as k, DefinePlugin as l, OpenApiMetaObject as m, WatchValues as n, IR$1 as o, OpenApi$1 as p, Config$1 as r, TypeTransformer as s, LegacyIR as t, Plugin as u, OpenApiResponseObject as v, StringCase as w, Logger as x, OpenApiSchemaObject as y };
14827
- //# sourceMappingURL=types-Cm9EOTQ7.d.cts.map
14827
+ //# sourceMappingURL=types-Bxdq98WE.d.cts.map
@@ -7400,7 +7400,7 @@ declare class PluginInstance<T$1 extends Plugin.Types = Plugin.Types> {
7400
7400
  * This ensures, for example, that schemas are always processed before
7401
7401
  * operations, which may reference them.
7402
7402
  *
7403
- * @template T - The event type(s) to yield. Defaults to all event types.
7403
+ * @template TKind - The event type(s) to yield. Defaults to all event types.
7404
7404
  * @param events - The event types to walk over. If none are provided, all event types are included.
7405
7405
  * @param callback - Function to execute for each event.
7406
7406
  *
@@ -7414,8 +7414,8 @@ declare class PluginInstance<T$1 extends Plugin.Types = Plugin.Types> {
7414
7414
  * }
7415
7415
  * });
7416
7416
  */
7417
- forEach<T extends IrTopLevelKind = IrTopLevelKind>(...args: [...events: ReadonlyArray<T$1>, callback: (event: WalkEvent<T$1>) => void]): void;
7418
- forEach<T extends IrTopLevelKind = IrTopLevelKind>(...args: [...events: ReadonlyArray<T$1>, callback: (event: WalkEvent<T$1>) => void, options: WalkOptions<T$1>]): void;
7417
+ forEach<TKind extends IrTopLevelKind = IrTopLevelKind>(...args: [...events: ReadonlyArray<TKind>, callback: (event: WalkEvent<TKind>) => void]): void;
7418
+ forEach<TKind extends IrTopLevelKind = IrTopLevelKind>(...args: [...events: ReadonlyArray<TKind>, callback: (event: WalkEvent<TKind>) => void, options: WalkOptions<TKind>]): void;
7419
7419
  /**
7420
7420
  * Retrieves a registered plugin instance by its name from the context. This
7421
7421
  * allows plugins to access other plugins that have been registered in the
@@ -7424,7 +7424,7 @@ declare class PluginInstance<T$1 extends Plugin.Types = Plugin.Types> {
7424
7424
  * @param name Plugin name as defined in the configuration.
7425
7425
  * @returns The plugin instance if found, undefined otherwise.
7426
7426
  */
7427
- getPlugin<T extends keyof PluginConfigMap>(name: T$1): T$1 extends any ? PluginInstance<PluginConfigMap[T$1]> | undefined : never;
7427
+ getPlugin<TName extends keyof PluginConfigMap>(name: TName): TName extends any ? PluginInstance<PluginConfigMap[TName]> | undefined : never;
7428
7428
  /**
7429
7429
  * Retrieves a registered plugin instance by its name from the context. This
7430
7430
  * allows plugins to access other plugins that have been registered in the
@@ -7433,7 +7433,7 @@ declare class PluginInstance<T$1 extends Plugin.Types = Plugin.Types> {
7433
7433
  * @param name Plugin name as defined in the configuration.
7434
7434
  * @returns The plugin instance if found, throw otherwise.
7435
7435
  */
7436
- getPluginOrThrow<T extends keyof PluginConfigMap>(name: T$1): T$1 extends any ? PluginInstance<PluginConfigMap[T$1]> : never;
7436
+ getPluginOrThrow<TName extends keyof PluginConfigMap>(name: TName): TName extends any ? PluginInstance<PluginConfigMap[TName]> : never;
7437
7437
  getSymbol(identifier: SymbolIdentifier): Symbol | undefined;
7438
7438
  hooks: {
7439
7439
  operation: {
@@ -14823,4 +14823,4 @@ interface WatchValues {
14823
14823
  }
14824
14824
  //#endregion
14825
14825
  export { AccessLevel as A, PluginHandler as C, Comments as D, MaybeArray as E, types_d_exports as F, FunctionTypeParameter as M, ObjectValue as N, ImportExportItemObject as O, SyntaxKindKeyword as P, Client$2 as S, LazyOrAsync as T, OpenApiRequestBodyObject as _, Input as a, parseOpenApiSpec as b, ExpressionTransformer as c, Client as d, Operation as f, OpenApiParameterObject as g, OpenApiOperationObject as h, UserConfig$1 as i, FunctionParameter as j, tsNodeToString as k, DefinePlugin as l, OpenApiMetaObject as m, WatchValues as n, IR$1 as o, OpenApi$1 as p, Config$1 as r, TypeTransformer as s, LegacyIR as t, Plugin as u, OpenApiResponseObject as v, StringCase as w, Logger as x, OpenApiSchemaObject as y };
14826
- //# sourceMappingURL=types-BDC4ckIh.d.ts.map
14826
+ //# sourceMappingURL=types-CFT9BYmF.d.ts.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hey-api/openapi-ts",
3
- "version": "0.86.10",
3
+ "version": "0.86.11",
4
4
  "description": "🚀 The OpenAPI to TypeScript codegen. Generate clients, SDKs, validators, and more.",
5
5
  "homepage": "https://heyapi.dev/",
6
6
  "repository": {