Documentation IndexFetch the complete documentation index at: /llms.txtUse this file to discover all available pages before exploring further.
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
cURL
curl --request POST \ --url https://vip.xmsmartlink.com/v1beta/models/gemini-2.5-flash-image:generateContent \ --header 'Content-Type: application/json' \ --header 'x-goog-api-key: <api-key>' \ --data ' { "contents": [ { "role": "user", "parts": [ { "text": "Draw a cute cat" } ] } ], "generationConfig": { "responseModalities": [ "IMAGE" ] } } '
{ "candidates": [ { "content": { "role": "model", "parts": [ { "inline_data": { "mime_type": "image/png", "data": "<BASE64_IMAGE_DATA>" } } ] }, "finishReason": "STOP" } ] }
Gemini-2.5-Flash-Image 图片生成接口。高级输出尺寸建议使用 Pro 图片模型。
Gemini 官方格式认证请求头。
多轮内容(role + parts),可携带图片进行编辑。
Show child attributes
Gemini 图片生成响应,包含内联 base64 图片数据。