generate_image
Generate an AI image for a specific content suggestion. Costs 50 credits. When called without a customPrompt, the API automatically uses the suggestion's stored imagePrompts[imageIndex] — no need to pass the prompt manually. Call this after generate_content once the user picks a suggestion. For carousel posts, use imageIndex for each slide (0-based).
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | Suggestion ID to generate an image for (from generate_content) | |
| imageIndex | No | Image slide index (0-based). Use 0 for single images, 0-N for carousel slides. Defaults to 0. | |
| customPrompt | No | Optional custom image prompt. If omitted, uses the auto-generated prompt from the suggestion's Content DNA analysis. |