Create media upload
create_uploadReturns a private, short-lived upload URL for a file that has no public HTTPS link (a carousel PDF, an image, or an mp4). The file is sent with an HTTP PUT of its raw bytes to upload_url using the returned headers; the returned upload_id is then accepted by save_draft as media: [{ upload_id }] (an image item can add alt_text there), with id to attach it to an existing draft or scheduled post. The URL expires soon (expires_in gives the seconds left; it can be as little as 60), so upload right away. Limits: images 5MB, video 75KB–200MB mp4, PDF 100MB.
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": {
"type": "<type>"
},
"name": "create_upload"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| type | Yes | What you will upload: image (jpeg, png, webp, gif), video (mp4), or document (pdf). | |
| size_bytes | No | Optional file size in bytes, checked against the limit before you upload. | |
| content_type | No | Optional MIME type, for example image/png, video/mp4, or application/pdf. Defaults from type. |