GET /api/images/:id
id 即画廊搜索结果返回的 ID。公开端点,无需认证;响应会做短暂缓存。
获取自己的生成结果请轮询状态端点。本端点只返回画廊精选内容。
路径参数
string
必填
画廊图片 ID。
响应
boolean
object
画廊图片字段:
| 字段 | 类型 | 说明 |
|---|---|---|
id | string | 画廊图片 ID |
text | string | 原始提示词——可能是纯文本,也可能是结构化 JSON prompt,要复用请自行解析 |
prompt_ready | boolean | 该图是否有可用的提示词 |
prompt_segments | array | null | 当提示词包含多个带标签的部分时,返回结构化分段;单段提示词为 null |
media_urls | string[] | 完整图片 URL 数组 |
thumbnail_url | string | 缩略图 URL(通常与 media_urls[0] 相同) |
image_width | number | null | 图片宽度(像素) |
image_height | number | null | 图片高度(像素) |
model | string | null | 标注该作品出自哪个模型的标签。粒度不统一:部分取值是粗粒度家族名("nanobanana" / "gptimage" / "midjourney" / "other"),部分则是精确的模型 ID(如 "flux2-klein" / "seedream-4.5");随着新模型上线还会出现新取值。请当作展示/筛选标签使用——不要假定它可以直接传给 /api/generate/v2,生成用的 ID 请以模型列表为准 |
sref | string | null | Midjourney 风格码(如有)——复用它即可套用同款风格;非 Midjourney 图片为 null |
created_at | string | ISO 8601 时间戳(信息性字段) |
likes / views / retweets | number | 原帖互动指标 |
author_username / author_display_name / author_avatar_url | string | 原作者信息——如需展示署名可使用,否则忽略 |
示例
curl https://www.meigen.ai/api/images/2009629483448627597
{
"success": true,
"data": {
"id": "2009629483448627597",
"text": "A serene Japanese garden with cherry blossoms",
"media_urls": ["https://images.meigen.ai/tweets/2009629483448627597/0.jpg"],
"thumbnail_url": "https://images.meigen.ai/tweets/2009629483448627597/0.jpg",
"image_width": 1650,
"image_height": 2048,
"model": "midjourney",
"created_at": "2026-01-09T14:13:00+00:00",
"likes": 113,
"views": 9266,
"retweets": 8,
"author_username": "creator",
"author_display_name": "Creator Name",
"author_avatar_url": "https://pbs.twimg.com/profile_images/.../normal.jpg"
}
}
404 Not Found
{ "success": false, "error": "Image not found" }