OpenAI chat format (Chat Completions + Gemini image)
Standard OpenAI Chat Completions, with chat-style prompts driving Gemini image generation.Basics
- Endpoint:
POST /v1/chat/completions - Auth:
Bearer Token - Content-Type:
application/json
Request body
Response
200 OKRequest example
Response example
Tips
- Extracting images:
contentoften embeds—parse the data URI for display. - extra_body: Standard OpenAI SDK extension slot for vendor options without breaking the protocol.
- Mock: For local tests,
http://127.0.0.1:4523/mock/7707339.

