Upload template image
uploadTemplateImageUpload an image for templates, the way the template editor does, and get the public url to use in a template. Pass the picture in base64 as image with its type (image/png, image/jpeg, image/webp, image/gif, image/svg+xml), or an image in Files as fileId, up to 100MB. It is fitted into 1200 by 1800 pixels and stored in a form every mail client shows.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "uploadTemplateImage"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| crop | No | The part of the image to keep, each value a fraction of the whole from 0 to 1: x and y are its left and top edges, width and height its size. Leave it out to keep the whole image. | |
| image | No | The image in base64, or as a data: URL. Leave it out when you pass fileId instead. | |
| fileId | No | An image in Files to use instead of image: one the user attached in this chat, or one listFiles found. It can be up to 100MB. | |
| contentType | No | The type of the image, such as image/png. It is needed with image and taken from the file with fileId. |