Create a chat completion.
Set stream: true to receive Server-Sent Events instead of a single JSON response. The optional X-Conversation-Id request header reuses a server-side session across turns when --conversations-max is non-zero.
Headers
Stable identifier used to look up a cached session.
Request body
Response
OK. Either a JSON ChatCompletion or a text/event-stream of chat.completion.chunk events.
Changes
Changed in 4 of the 6 revisions of this API.215
- ○
added the new optional request property
new-optional-request-property
- ○
- ○
added the non-success response with the status
response-non-success-status-added
- ○
- ▲
response property
choices/items/message/contentlist-of-types was widened by adding typesarrayto media typeapplication/jsonof response200response-property-list-of-types-widened
- ○
request property
//list-of-types was widened by adding typesarrayto media typeapplication/jsonrequest-property-list-of-types-widened
- ▲
- ▲
request property
//list-of-types was narrowed by removing typesarrayfrom media typeapplication/jsonrequest-property-list-of-types-narrowed
- ●
removed the request property
request-property-removed
- ○
removed the non-success response with the status
response-non-success-status-removed
- ○
response property
choices/items/message/contentlist-of-types was narrowed by removing typesarrayfrom media typeapplication/jsonof response200response-property-list-of-types-narrowed
This revision also has 1 change that name no endpoint, such as unreferenced schemas being removed. See the revision's changelog
- ▲