Skip to content

Commit d08b7d5

Browse files
authored
feat(generator): Add "application/vnd.api+json" media type. (#307)
* Add "application/vnd.api+json" content type. * Add changelog entry for new media type.
1 parent aa6972c commit d08b7d5

File tree

2 files changed

+2
-0
lines changed

2 files changed

+2
-0
lines changed

CHANGELOG.md

+1
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
1616
- `none` will not create a project folder at all, only the inner package folder (which won't be inner anymore)
1717
- Attempt to detect and alert users if they are using an unsupported version of OpenAPI (#281).
1818
- Fixes `Enum` deserialization when the value is `UNSET`.
19+
- Add handling of application/vnd.api+json media type.
1920

2021
### Changes
2122

openapi_python_client/parser/responses.py

+1
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@ class Response:
2020

2121
_SOURCE_BY_CONTENT_TYPE = {
2222
"application/json": "response.json()",
23+
"application/vnd.api+json": "response.json()",
2324
"application/octet-stream": "response.content",
2425
"text/html": "response.text",
2526
}

0 commit comments

Comments
 (0)