Attach post media
attach_post_mediaAttaches an image to an existing image_post or video_post that's waiting on media (base64, a public https URL, or an existing image library assetId). An image post gets the same headline/subhead/cta text placed on it that auto-generation would produce; a video post's key frame gets no text. Not for text_post/carousel, and not for one of the user's own verbatim posts — use create_adhoc_post's mediaLibraryAssetId for that instead (no text placed). The response's post.mediaLinks holds stable https links to the finished image — show the user what actually landed rather than just confirming it did.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| postId | Yes | The post's id, from list_posts. Must be an image_post or video_post with a brief already generated — not a text_post/carousel. | |
| brandId | Yes | The brand's id, from list_brands. | |
| imageUrl | No | A public https URL Rebbel fetches server-side (see upload_brand_image). Also banked into the brand's image library automatically. Exactly one of mediaLibraryAssetId/imageBase64/imageUrl is required. | |
| campaignId | Yes | An existing campaign's id, from list_campaigns or generate_campaign. | |
| imageBase64 | No | The image as a data URL (see upload_brand_image) — attaches it directly without a separate upload call first; also banked into the brand's image library automatically. Exactly one of mediaLibraryAssetId/imageBase64/imageUrl is required. | |
| mediaLibraryAssetId | No | An existing image library asset id, e.g. from upload_brand_image. Exactly one of mediaLibraryAssetId/imageBase64/imageUrl is required. |