Chat Completion
POST/v1/chat/completions
info
Feel free to use the Nillion2025 as a test Bearer Token
Generate a chat completion response from the AI model.
- req: Chat completion request containing messages and model specifications
 - user: Authenticated user information (through HTTP Bearer header)
 - Returns: Full chat response with model output, usage statistics, and cryptographic signature
 
Request Requirements
- Must include non-empty list of messages
 - Must specify a model
 - Supports multiple message formats (system, user, assistant)
 
Response Components
- Model-generated text completion
 - Token usage metrics
 - Cryptographically signed response for verification
 
Processing Steps
- Validate input request parameters
 - Prepare messages for model processing
 - Generate AI model response
 - Track and update token usage
 - Cryptographically sign the response
 
Potential HTTP Errors
- 400 Bad Request:
- Missing messages list
 - No model specified
 
 - 500 Internal Server Error:
- Model fails to generate a response
 
 
Request
Responses
- 200
 - 422
 
Successful Response
Validation Error