upload_image
Upload an ad creative image via HTTPS URL or base64 data to obtain a file_id for use in ad creation. Supports chat_card ads by uploading before creating the ad.
Instructions
Upload a creative image for ads. Provide EITHER image_url (https) OR image_base64 (data). image_url is SSRF-guarded (https only, no private hosts). Returns file_id to use in create_ad creative.file_id. For chat_card ads, upload first then create_ad.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| filename | No | Filename for base64 upload (e.g., creative.png). | |
| image_url | No | Public https URL of image. SSRF-checked. | |
| image_base64 | No | Base64-encoded image bytes (alternative to image_url). Do NOT include data: prefix — just raw base64. | |
| ad_account_id | No | Optional ad account ID override. |