Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
19 changes: 19 additions & 0 deletions .speakeasy/overlays/intern-chat-json-response.overlay.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
overlay: 1.0.0
x-speakeasy-jsonpath: rfc9535
info:
title: Give the intern chat completion a JSON 200 sibling for the Python generator
version: 0.0.0
actions:
- target: $.paths["/interns/{internId}/chat/completions"].post.responses["200"].content
description: >-
The public spec declares only a text/event-stream 200 for this operation.
With sseFlatResponse enabled, the Python generator annotates the method as
returning the flattened chunk while emitting an EventStream body, which
fails pyright and mypy and blocks every release. Declaring a JSON
representation of the same chunk restores the supported SSE-overload
shape so the generated method is typed as the union. The server still
streams every response.
update:
application/json:
schema:
$ref: '#/components/schemas/InternChatCompletionChunk'
1 change: 1 addition & 0 deletions .speakeasy/workflow.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ sources:
- location: .speakeasy/overlays/boolean-query-params.overlay.yaml
- location: .speakeasy/overlays/fix-nullable-pagination.overlay.yaml
- location: .speakeasy/overlays/deprecated-beta-responses-alias.overlay.yaml
- location: .speakeasy/overlays/intern-chat-json-response.overlay.yaml
output: .speakeasy/out.openapi.yaml
registry:
location: registry.speakeasyapi.dev/openrouter/sdk/open-router-chat-completions-api
Expand Down
Loading