Skip to content

Commit

Permalink
fix(cli): ingest responses with content type text/event-stream (#4768)
Browse files Browse the repository at this point in the history
  • Loading branch information
dsinghvi committed Sep 27, 2024
1 parent 0156c97 commit 7628cc0
Show file tree
Hide file tree
Showing 11 changed files with 5,547 additions and 3 deletions.
6 changes: 6 additions & 0 deletions fern/pages/changelogs/cli/2024-09-27.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
## 0.43.6
**`(fix):`** The OpenAPI importer now appropriately brings in responses that are under the `text/event-stream`
Content-Type if your endpoint is annotated with `x-fern-streaming`.
If your endpoint is not annotated with `x-fern-streaming`, then the response will be ignored.


4 changes: 4 additions & 0 deletions generators/typescript/sdk/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,10 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [0.40.6] - 2024-09-18

- Fix: The TypeScript SDK now supports specifying a custom contentType if one is specified.

## [0.40.5] - 2024-09-18

- Fix: The snippet templates for file upload are now accurate and also respect the feature
Expand Down
2 changes: 1 addition & 1 deletion generators/typescript/sdk/VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.40.5
0.40.6
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ export class GeneratedDefaultEndpointRequest implements GeneratedEndpointRequest
headers: this.getHeaders(context),
queryParameters: this.queryParams.getReferenceTo(context),
body: this.getSerializedRequestBodyWithNullCheck(context),
contentType: "application/json",
contentType: this.requestBody?.contentType ?? "application/json",
requestType: "json"
};
}
Expand Down
9 changes: 9 additions & 0 deletions packages/cli/cli/versions.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,12 @@
- changelogEntry:
- summary: |
The OpenAPI importer now appropriately brings in responses that are under the `text/event-stream`
Content-Type if your endpoint is annotated with `x-fern-streaming`.
If your endpoint is not annotated with `x-fern-streaming`, then the response will be ignored.
type: fix
irVersion: 53
version: 0.43.6

- changelogEntry:
- summary: |
If you use the `x-fern-streaming` extension and want to provide different descriptions
Expand Down
Loading

0 comments on commit 7628cc0

Please sign in to comment.