Skip to main content

Demo chat

The demo chat endpoint lets you interact with AI models without signing up or deploying an agent. Requests are rate-limited by IP address.

List available models

No authentication required. Returns the list of models available in demo mode.

Response (200)

FieldTypeDescription
modelsarrayAvailable demo models
models[].idstringModel identifier to use in POST requests
models[].namestringHuman-readable model name
models[].providerstringAI provider name
modestringAlways demo
messagestringWelcome message

Send a demo message

No authentication required. Rate-limited by IP address.

Request body

FieldTypeRequiredDescription
messagestringYesMessage to send
modelstringNoModel ID from the models list. Defaults to xiaomi/mimo-v2-pro.
modestringNoChat mode identifier
conversationarrayNoPrevious conversation messages for context. Only user-role messages are retained (max 4000 characters each).

Example request

Response (200)

FieldTypeDescription
idstringResponse identifier from the AI provider
modelstringModel ID that served the request
messagestringAI response content
usageobjectToken usage statistics
usage.prompt_tokensnumberInput tokens consumed
usage.completion_tokensnumberOutput tokens generated
usage.total_tokensnumberTotal tokens used
donebooleanAlways true (non-streaming)

Error responses

StatusErrorDescription
400Message requiredThe message field is missing from the request body
429Too many requestsIP-based rate limit exceeded
503Demo unavailable — service not configured.The demo service is not configured on the server
variesAI service error. Please try again.The upstream AI provider returned an error. The HTTP status code is passed through from the provider (for example, 402 for quota issues or 422 for invalid model parameters).
500Failed to get responseAn unexpected error occurred
The demo endpoint uses a fixed max token limit of 1024 and does not support streaming. For full chat capabilities, use the AI chat endpoint with a subscription plan.
Every successful demo chat request automatically logs token usage and cost to the usage tracking system. Demo requests are recorded with userId: "demo" and agentId: "demo-chat", and are visible in the cost dashboard.

Examples

List models

Send a message

Send with conversation history