lmstudio-ai / lmstudio-ai/docs
For New /api/v1/chat API Docs say to use type: message for text input but it should be 'text'
- Dominant language
- MDX
- Stars
- 172
- Forks
- 128
- Avg merge
- 8m
- Merged PRs (30d)
- 1
Description
Send a chat request to the new API using this format as specified in the docs: https://lmstudio.ai/docs/developer/rest/chat
Received request: POST to /api/v1/chat with body {
"model": "google/gemma-4-e2b",
"input": [
{
"type": "message",
"content": "hi"
}
]
}
2026-09-06 12:52:44 [ERROR]
[LM STUDIO SERVER] {
"error": {
"message": "Invalid discriminator value. Expected 'text' | 'image'",
"type": "invalid_request",
"code": "invalid_union",
"param": "input"
}
}
Docs typo?
Contributor guide
Research direction
Open the chat API documentation page at https://lmstudio.ai/docs/developer/rest/chat and compare the documented input type with the server error. Change the text-input discriminator from "message" to "text", then verify that the example matches the accepted values and request format.
Written by the indexing model from the issue text.
Assessment
- Domain
- documentation
- Issue type
- Documentation
- Difficulty
- 1/5
- Estimated time
- Under an hour
- Activity status
- Active
- Clarity
- Clearly specified
- Newbie friendliness
- 90/100