@hey-api/openapi-ts 0.78.3 → 0.79.1

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/README.md CHANGED
@@ -8,22 +8,23 @@
8
8
 
9
9
  <p align="center">
10
10
  <a href="https://opensource.org/license/mit" rel="nofollow"><img src="https://img.shields.io/github/license/hey-api/openapi-ts" alt="MIT License"></a>
11
- <a href="https://github.com/hey-api/openapi-ts/actions?query=branch%3Amain"><img src="https://img.shields.io/github/last-commit/hey-api/openapi-ts" alt="Last commit" /></a>
11
+ <a href="https://npmjs.com/package/@hey-api/openapi-ts" rel="nofollow"><img src="https://img.shields.io/npm/dm/%40hey-api%2Fopenapi-ts?label=npm" alt="npm downloads"></a>
12
+ <a href="https://github.com/hey-api/openapi-ts" rel="nofollow"><img src="https://img.shields.io/github/stars/hey-api/openapi-ts?style=flat&logo=github&label=GitHub&color=54C82D" alt="GitHub stars" /></a>
12
13
  <a href="https://github.com/hey-api/openapi-ts/actions?query=branch%3Amain"><img src="https://github.com/hey-api/openapi-ts/actions/workflows/ci.yml/badge.svg?event=push&branch=main" alt="CI status" /></a>
13
- <a href="https://github.com/hey-api/openapi-ts/issues" rel="nofollow"><img src="https://img.shields.io/github/issues/hey-api/openapi-ts" alt="Number of open issues"></a>
14
- <a href="https://app.codecov.io/gh/hey-api/openapi-ts/tree/main"><img src="https://codecov.io/gh/hey-api/openapi-ts/branch/main/graph/badge.svg" alt="Test coverage" /></a>
15
14
  </p>
16
15
 
17
16
  <p align="center">
18
17
  <a href="https://stackblitz.com/edit/hey-api-example?file=openapi-ts.config.ts,src%2Fclient%2Fschemas.gen.ts,src%2Fclient%2Fsdk.gen.ts,src%2Fclient%2Ftypes.gen.ts">Demo</a>
19
18
  <span>&nbsp;•&nbsp;</span>
20
- <a href="https://heyapi.dev">Documentation</a>
19
+ <a href="https://heyapi.dev">Docs</a>
21
20
  <span>&nbsp;•&nbsp;</span>
22
21
  <a href="https://github.com/hey-api/openapi-ts/issues">Issues</a>
23
22
  <span>&nbsp;•&nbsp;</span>
24
23
  <a href="https://github.com/orgs/hey-api/discussions/1495">Roadmap</a>
25
24
  <span>&nbsp;•&nbsp;</span>
26
- <a href="https://npmjs.com/package/@hey-api/openapi-ts">npm</a>
25
+ <a href="https://heyapi.dev/openapi-ts/community/contributing">Contribute</a>
26
+ <span>&nbsp;•&nbsp;</span>
27
+ <a href="https://heyapi.dev/openapi-ts/community/spotlight#core-team">Join Core Team</a>
27
28
  </p>
28
29
 
29
30
  <br/>
@@ -44,9 +45,15 @@ Hey API is an ecosystem of products helping you build better APIs. Superpower yo
44
45
 
45
46
  [Sign In](https://app.heyapi.dev) to Hey API Platform.
46
47
 
48
+ ## Contributing
49
+
50
+ Want to see your code in products used by millions?
51
+
52
+ Start with our [Contributing](https://heyapi.dev/openapi-ts/community/contributing) guide and release your first feature.
53
+
47
54
  ## Sponsors
48
55
 
49
- Love Hey API? Become our [sponsor](https://github.com/sponsors/hey-api).
56
+ Help Hey API stay around for the long haul by becoming a [sponsor](https://github.com/sponsors/hey-api).
50
57
 
51
58
  <h3 align="center">Gold</h3>
52
59
 
@@ -63,7 +70,7 @@ Love Hey API? Become our [sponsor](https://github.com/sponsors/hey-api).
63
70
  </picture>
64
71
  </a>
65
72
  <br/>
66
- Generate best-in-class SDKs.
73
+ Best-in-class SDKs and MCP for your API.
67
74
  <br/>
68
75
  <a href="https://kutt.it/pkEZyc" style="text-decoration:none;" target="_blank">
69
76
  stainless.com
@@ -135,31 +142,45 @@ Congratulations on creating your first client! 🎉 You can learn more about the
135
142
 
136
143
  ## Installation
137
144
 
145
+ You can download `@hey-api/openapi-ts` from npm using your favorite package manager.
146
+
138
147
  #### npm
139
148
 
140
149
  ```sh
141
- npm install @hey-api/openapi-ts -D
150
+ npm install @hey-api/openapi-ts -D -E
142
151
  ```
143
152
 
144
153
  #### pnpm
145
154
 
146
155
  ```sh
147
- pnpm add @hey-api/openapi-ts -D
156
+ pnpm add @hey-api/openapi-ts -D -E
148
157
  ```
149
158
 
150
159
  #### yarn
151
160
 
152
161
  ```sh
153
- yarn add @hey-api/openapi-ts -D
162
+ yarn add @hey-api/openapi-ts -D -E
154
163
  ```
155
164
 
156
165
  #### bun
157
166
 
158
167
  ```sh
159
- bun add @hey-api/openapi-ts -D
168
+ bun add @hey-api/openapi-ts -D -E
160
169
  ```
161
170
 
162
- We recommend pinning an exact version so you can safely upgrade when you're ready. This package is in [initial development](https://semver.org/spec/v0.1.0.html#spec-item-5) and its API might change before v1.
171
+ ### Versioning
172
+
173
+ This package does NOT follow the [semantic versioning](https://semver.org/) strategy. Please pin an exact version so you can safely upgrade when you're ready.
174
+
175
+ Due to the nature of the package, we use the following versioning strategy.
176
+
177
+ - `1.x.x`: significant breaking changes, reserved for v1 release
178
+ - `x.1.x`: breaking changes
179
+ - `x.x.1`: new features, bug fixes, and non-breaking changes
180
+
181
+ We publish [migration notes](https://heyapi.dev/openapi-ts/migrating) for every breaking release. You might not be impacted by a breaking release if you don't use the affected plugin(s).
182
+
183
+ ## Usage
163
184
 
164
185
  ### CLI
165
186
 
@@ -175,7 +196,7 @@ The above script can be executed by running `npm run openapi-ts` or equivalent c
175
196
 
176
197
  ### Node.js
177
198
 
178
- You can also generate clients programmatically by importing `@hey-api/openapi-ts` in a TypeScript file.
199
+ You can also generate output programmatically by importing `@hey-api/openapi-ts` in a TypeScript file.
179
200
 
180
201
  ```ts
181
202
  import { createClient } from '@hey-api/openapi-ts';
package/bin/index.cjs CHANGED
@@ -93,6 +93,14 @@ async function start() {
93
93
  'useOptions',
94
94
  ]);
95
95
 
96
+ const isInteractive =
97
+ process.stdin.isTTY &&
98
+ process.stdout.isTTY &&
99
+ !process.env.CI &&
100
+ !process.env.NO_INTERACTIVE &&
101
+ !process.env.NO_INTERACTION;
102
+ userConfig.interactive = isInteractive;
103
+
96
104
  if (params.plugins === true) {
97
105
  userConfig.plugins = [];
98
106
  } else if (params.plugins) {