Upload an image
upload_imageUpload an image and get back the URL the editor stores: put it in a content block as <img src="…" alt="…">, or pass it to create_page or edit_page as bannerImage. Requires a ROLA bearer token, as create_page does. Send the file base64-encoded, at most 3.4 MB before encoding (the whole request must stay under 4.5 MB), as JPEG, PNG, GIF, WebP, or AVIF. The format is read from the bytes, not from contentType or the name; the image is stored as WebP at most 1600px wide, without its metadata.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| data | Yes | The image file, base64-encoded; a `data:` URL prefix is accepted | |
| filename | Yes | File name, e.g. "validator-map.png" | |
| contentType | Yes | MIME type, e.g. "image/png" |