AngeMedia API 示例
图片生成、图生图、异步视频任务、生成前路由与 Gateway API Key。
API 示例
生成图片:
curl -X POST http://localhost:9890/v1/images/generations \
-H "Content-Type: application/json" \
-d '{"prompt":"a cinematic orange cat wearing sunglasses on a neon city street","size":"1024x1024","response_format":"url"}'
通过 SiliconFlow/Kolors 做图生图:
curl -X POST http://localhost:9890/v1/images/generations \
-H "Content-Type: application/json" \
-d '{"model":"kolors","prompt":"keep the main subject and composition, convert the image into a clean cinematic poster style","image":"https://example.com/input.png","size":"1024x1024","response_format":"url"}'
提交 Agnes Video 任务:
curl -X POST http://localhost:9890/v1/videos \
-H "Content-Type: application/json" \
-d '{"model":"agnes-video-v2.0","prompt":"A cinematic shot of a cat walking through a neon rainy street, smooth camera tracking, filmic lighting.","width":1152,"height":768,"num_frames":121,"frame_rate":24}'
生成前路由:
curl -X POST http://localhost:9890/v1/media/route \
-H "Content-Type: application/json" \
-d '{"prompt":"Create a realistic commercial portrait with neon city lighting"}'
配置 GATEWAY_API_KEY 后,API-mode 请求应带:
Authorization: Bearer <GATEWAY_API_KEY>
Gateway API Key 不是管理员会话凭据。