Upload an image
upload_note_imageUpload an image to use in a Note (Add only and up): PNG, JPEG or WebP up to 5 MB
and 20 megapixels, as base64 (it passes through your own output, so keep it small or ask the
person to add a large one). ThreadPage never fetches a URL. For a Note that already exists,
pass its note_id; for a new Note, omit it and create the Note in the same Thread. Answers its
attachment_id; the same operation_id answers it again. Uploading does not add it to the
Note: then put it on its own line in the Note's Markdown:
, or a document block
{"type": "image", "attrs": {"attachmentId": "<attachment_id>", "alt": "…", "width": null}}.
For other files, use upload_note_file.
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": {
"operation_id": "<operation_id>",
"thread_id": "<thread_id>",
"mime_type": "<mime_type>",
"checksum": "<checksum>",
"data": "<data>"
},
"name": "upload_note_image"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| data | Yes | The image file as base64: PNG, JPEG or WebP, up to 5 MB. | |
| note_id | No | When the image goes in an existing Note: its id (required then). | |
| checksum | Yes | The lowercase hex SHA-256 of the image bytes (not of the base64). | |
| mime_type | Yes | "image/png", "image/jpeg" or "image/webp". | |
| thread_id | Yes | The Thread of the Note the image goes in. | |
| operation_id | Yes | A new UUID for each write. After a lost answer, send the identical call with the same one, or check get_operation before writing again. |