Skip to content

Commit e9d79f7

Browse files
committed
Update README.md
1 parent 043e255 commit e9d79f7

File tree

1 file changed

+13
-3
lines changed

1 file changed

+13
-3
lines changed

README.md

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,15 @@
11
# OpenAPI Generator for TypeScript client library using Fetch API and API interfaces
22

3+
## Features
4+
5+
* Generates code that resembles plain `fetch` calls
6+
* Supports `anyOf`-polymorphism with union types and discriminators
7+
* Implements `enum` with union types
8+
* Supports `query` parameter options `explode` and `style`
9+
* Supports `securitySchemes`
10+
* Support blob response types
11+
* Generated code have no eslint or prettier warnings except long lines
12+
313
## Overview
414

515
This is a plugin to [OpenApi Generator](https://openapi-generator.tech/) which generates Typescript client libraries from openapi specifications using the native `fetch` method. The generated code has no dependencies.
@@ -39,11 +49,11 @@ export class PetApi extends BaseAPI implements PetApiInterface {
3949
security: petstore_auth;
4050
}): Promise<void> {
4151
return await this.POST(
42-
"/pet",
43-
{},
44-
{body: params.petDto, contentType: "application/json"},
52+
this.basePath + "/pet",
53+
JSON.stringify(params.petDto),
4554
{
4655
...params.security?.headers(),
56+
"Content-Type": "application/json",
4757
}
4858
);
4959
}

0 commit comments

Comments
 (0)