Skip to content

Commit c6e5d51

Browse files
committed
update config
1 parent 37412df commit c6e5d51

31 files changed

Lines changed: 1498 additions & 32 deletions

bin/configs/typescript-fetch-oneOf.yaml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,3 +2,9 @@ generatorName: typescript-fetch
22
outputDir: samples/client/petstore/typescript-fetch/builds/oneOf
33
inputSpec: modules/openapi-generator/src/test/resources/3_0/typescript-fetch/oneOf.yaml
44
templateDir: modules/openapi-generator/src/main/resources/typescript-fetch
5+
additionalProperties:
6+
npmVersion: 1.0.0
7+
npmName: '@openapitools/typescript-fetch-petstore'
8+
npmRepository: https://skimdb.npmjs.com/registry
9+
snapshot: false
10+
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
wwwroot/*.js
2+
node_modules
3+
typings
4+
dist
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
README.md
Lines changed: 19 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
1-
apis/DefaultApi.ts
2-
apis/index.ts
1+
.gitignore
2+
.npmignore
3+
README.md
34
docs/DefaultApi.md
45
docs/OneOfPrimitiveTypes.md
56
docs/OneOfPrimitiveTypesValue.md
@@ -10,15 +11,19 @@ docs/TestArrayResponse.md
1011
docs/TestB.md
1112
docs/TestDiscriminatorResponse.md
1213
docs/TestResponse.md
13-
index.ts
14-
models/OneOfPrimitiveTypes.ts
15-
models/OneOfPrimitiveTypesValue.ts
16-
models/OptionOne.ts
17-
models/OptionTwo.ts
18-
models/TestA.ts
19-
models/TestArrayResponse.ts
20-
models/TestB.ts
21-
models/TestDiscriminatorResponse.ts
22-
models/TestResponse.ts
23-
models/index.ts
24-
runtime.ts
14+
package.json
15+
src/apis/DefaultApi.ts
16+
src/apis/index.ts
17+
src/index.ts
18+
src/models/OneOfPrimitiveTypes.ts
19+
src/models/OneOfPrimitiveTypesValue.ts
20+
src/models/OptionOne.ts
21+
src/models/OptionTwo.ts
22+
src/models/TestA.ts
23+
src/models/TestArrayResponse.ts
24+
src/models/TestB.ts
25+
src/models/TestDiscriminatorResponse.ts
26+
src/models/TestResponse.ts
27+
src/models/index.ts
28+
src/runtime.ts
29+
tsconfig.json
Lines changed: 117 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,117 @@
1+
# @openapitools/typescript-fetch-petstore@1.0.0
2+
3+
A TypeScript SDK client for the localhost API.
4+
5+
## Usage
6+
7+
First, install the SDK from npm.
8+
9+
```bash
10+
npm install @openapitools/typescript-fetch-petstore --save
11+
```
12+
13+
Next, try it out.
14+
15+
16+
```ts
17+
import {
18+
Configuration,
19+
DefaultApi,
20+
} from '@openapitools/typescript-fetch-petstore';
21+
import type { TestRequest } from '@openapitools/typescript-fetch-petstore';
22+
23+
async function example() {
24+
console.log("🚀 Testing @openapitools/typescript-fetch-petstore SDK...");
25+
const api = new DefaultApi();
26+
27+
try {
28+
const data = await api.test();
29+
console.log(data);
30+
} catch (error) {
31+
console.error(error);
32+
}
33+
}
34+
35+
// Run the test
36+
example().catch(console.error);
37+
```
38+
39+
40+
## Documentation
41+
42+
### API Endpoints
43+
44+
All URIs are relative to *http://localhost:3000*
45+
46+
| Class | Method | HTTP request | Description
47+
| ----- | ------ | ------------ | -------------
48+
*DefaultApi* | [**test**](docs/DefaultApi.md#test) | **GET** /test |
49+
*DefaultApi* | [**testArray**](docs/DefaultApi.md#testarray) | **GET** /test-array |
50+
*DefaultApi* | [**testDiscriminator**](docs/DefaultApi.md#testdiscriminator) | **GET** /test-discriminator |
51+
52+
53+
### Models
54+
55+
- [OneOfPrimitiveTypes](docs/OneOfPrimitiveTypes.md)
56+
- [OneOfPrimitiveTypesValue](docs/OneOfPrimitiveTypesValue.md)
57+
- [OptionOne](docs/OptionOne.md)
58+
- [OptionTwo](docs/OptionTwo.md)
59+
- [TestA](docs/TestA.md)
60+
- [TestArrayResponse](docs/TestArrayResponse.md)
61+
- [TestB](docs/TestB.md)
62+
- [TestDiscriminatorResponse](docs/TestDiscriminatorResponse.md)
63+
- [TestResponse](docs/TestResponse.md)
64+
65+
### Authorization
66+
67+
Endpoints do not require authorization.
68+
69+
70+
## About
71+
72+
This TypeScript SDK client supports the [Fetch API](https://fetch.spec.whatwg.org/)
73+
and is automatically generated by the
74+
[OpenAPI Generator](https://openapi-generator.tech) project:
75+
76+
- API version: `1.0.0`
77+
- Package version: `1.0.0`
78+
- Generator version: `7.20.0-SNAPSHOT`
79+
- Build package: `org.openapitools.codegen.languages.TypeScriptFetchClientCodegen`
80+
81+
The generated npm module supports the following:
82+
83+
- Environments
84+
* Node.js
85+
* Webpack
86+
* Browserify
87+
- Language levels
88+
* ES5 - you must have a Promises/A+ library installed
89+
* ES6
90+
- Module systems
91+
* CommonJS
92+
* ES6 module system
93+
94+
95+
## Development
96+
97+
### Building
98+
99+
To build the TypeScript source code, you need to have Node.js and npm installed.
100+
After cloning the repository, navigate to the project directory and run:
101+
102+
```bash
103+
npm install
104+
npm run build
105+
```
106+
107+
### Publishing
108+
109+
Once you've built the package, you can publish it to npm:
110+
111+
```bash
112+
npm publish
113+
```
114+
115+
## License
116+
117+
[]()

samples/client/petstore/typescript-fetch/builds/oneOf/docs/DefaultApi.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,11 @@ All URIs are relative to *http://localhost:3000*
2222
import {
2323
Configuration,
2424
DefaultApi,
25-
} from '';
26-
import type { TestRequest } from '';
25+
} from '@openapitools/typescript-fetch-petstore';
26+
import type { TestRequest } from '@openapitools/typescript-fetch-petstore';
2727

2828
async function example() {
29-
console.log("🚀 Testing SDK...");
29+
console.log("🚀 Testing @openapitools/typescript-fetch-petstore SDK...");
3030
const api = new DefaultApi();
3131

3232
try {
@@ -79,11 +79,11 @@ No authorization required
7979
import {
8080
Configuration,
8181
DefaultApi,
82-
} from '';
83-
import type { TestArrayRequest } from '';
82+
} from '@openapitools/typescript-fetch-petstore';
83+
import type { TestArrayRequest } from '@openapitools/typescript-fetch-petstore';
8484

8585
async function example() {
86-
console.log("🚀 Testing SDK...");
86+
console.log("🚀 Testing @openapitools/typescript-fetch-petstore SDK...");
8787
const api = new DefaultApi();
8888

8989
try {
@@ -136,11 +136,11 @@ No authorization required
136136
import {
137137
Configuration,
138138
DefaultApi,
139-
} from '';
140-
import type { TestDiscriminatorRequest } from '';
139+
} from '@openapitools/typescript-fetch-petstore';
140+
import type { TestDiscriminatorRequest } from '@openapitools/typescript-fetch-petstore';
141141

142142
async function example() {
143-
console.log("🚀 Testing SDK...");
143+
console.log("🚀 Testing @openapitools/typescript-fetch-petstore SDK...");
144144
const api = new DefaultApi();
145145

146146
try {

samples/client/petstore/typescript-fetch/builds/oneOf/docs/OneOfPrimitiveTypes.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ Name | Type
1111
## Example
1212

1313
```typescript
14-
import type { OneOfPrimitiveTypes } from ''
14+
import type { OneOfPrimitiveTypes } from '@openapitools/typescript-fetch-petstore'
1515

1616
// TODO: Update the object below with actual values
1717
const example = {

samples/client/petstore/typescript-fetch/builds/oneOf/docs/OneOfPrimitiveTypesValue.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ Name | Type
1111
## Example
1212

1313
```typescript
14-
import type { OneOfPrimitiveTypesValue } from ''
14+
import type { OneOfPrimitiveTypesValue } from '@openapitools/typescript-fetch-petstore'
1515

1616
// TODO: Update the object below with actual values
1717
const example = {

samples/client/petstore/typescript-fetch/builds/oneOf/docs/OptionOne.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ Name | Type
1111
## Example
1212

1313
```typescript
14-
import type { OptionOne } from ''
14+
import type { OptionOne } from '@openapitools/typescript-fetch-petstore'
1515

1616
// TODO: Update the object below with actual values
1717
const example = {

samples/client/petstore/typescript-fetch/builds/oneOf/docs/OptionTwo.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ Name | Type
1111
## Example
1212

1313
```typescript
14-
import type { OptionTwo } from ''
14+
import type { OptionTwo } from '@openapitools/typescript-fetch-petstore'
1515

1616
// TODO: Update the object below with actual values
1717
const example = {

0 commit comments

Comments
 (0)