Upload Image
upload_imageSave one image in a Brand Library from either a public URL or a completed temporary upload.
The server validates the image, then reuses an exact match in the brand or
stores a new one. If your client can read the local file and make HTTP requests, first call
create_upload_urls, PUT the raw bytes as directed, and pass the
resulting upload_id here. In an MCP Apps client, call
open_upload_ui with only brand_session_id instead; its widget
completes the Library upload and returns final image IDs in widget context.
Read that context before using the images.
Pass exactly one of image_url or upload_id.
Args:
image_url: Public URL of the image to save.upload_id: Completed temporary upload containing the image to save.brand_session_id: Brand session ID that owns the Library image.
Returns the final image ID for generation references, edit references, edit subjects, or a Brand Skill primary-logo update.
Supported formats: PNG, JPEG, WebP, AVIF. Max file size: 10MB.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"brand_session_id": "<brand_session_id>"
},
"name": "upload_image"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| image_url | No | Public URL of the image to save in the Brand Library. The file must be PNG, JPEG, WebP, or AVIF and no larger than 10MB. Supply this URL or upload_id, but not both. | |
| llm_model | No | The model identifier you are running as, for example "claude-opus-4-8" or "gpt-5.2". Omit it or pass "unknown" if you are not certain; the tool runs the same either way. Recorded only for the server developer's analytics. | |
| upload_id | No | Completed temporary upload containing the image to save in this Brand Library. Obtain its ID from create_upload_urls or get_file_picker_handoff, and supply it instead of image_url. | |
| brand_session_id | Yes | Brand session ID of the brand that owns this image. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | Image ID of the saved Library image. | |
| width | Yes | Width in pixels. | |
| height | Yes | Height in pixels. | |
| existing | Yes | True when the brand already held this exact image and it was reused. | |
| mime_type | Yes | MIME type of the stored image. |