# upload_post_image

> Upload a cover or inline content image for an existing Blogizi post (base64).

HTML version: https://blogizi.com/docs/mcp-upload-post-image
Markdown version: https://blogizi.com/docs/mcp-upload-post-image.md

Upload a cover or inline content image for an existing post. Create the post first with [draft_post](/docs/mcp-draft-post) so you have a `postId` or `slug`.

## Arguments

| Name | Required | Notes |
| --- | --- | --- |
| `type` | Yes | `cover` (saved on the post) or `content` (returns a markdown snippet) |
| `filename` | Yes | e.g. `diagram.png` |
| `contentBase64` | Yes | Raw base64 bytes (data-URL prefix optional) |
| `postId` or `slug` | Yes | Identify the post |
| `alt` | No | Alt text for the returned markdown (content only) |
| `projectSlug` | When multi-project | Same as other tools |

Limits: cover max 2MB, content max 5MB. PNG/JPG/WebP/SVG. Recommended cover size: 1200×630 px.

## Workflow

1. `draft_post` → get `post.id`
2. `upload_post_image` with `type=content`
3. `update_post` with `content` including the returned `markdown` field

For covers, step 2 with `type=cover` is enough — the image is stored on the post immediately.

HTTP equivalent: [Upload post image](/docs/api-upload-image).
