Skip to content

README quickstart examples pass model/messages directly instead of the chatRequest wrapper #852

Description

@slegarraga

While reading through the README quickstart I noticed the chat.send() examples call send({ model, messages }), but the SDK's Chat.send() expects a single { chatRequest: { model, messages } } wrapper. Running the snippets as printed fails with a type error.

Suggested fix: wrap the payload in the README's non-streaming and streaming examples:

const completion = await client.chat.send({
  chatRequest: { model: "openai/gpt-5-mini", messages: [...] },
});

Happy to verify against the latest published version if useful.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions