Preview images and favicons
Set the image used for shared links and the icon shown in the browser tab.
Upload a share image or favicon
Send ogImageFile and logoImageFile as separate multipart binary parts. Use JPG, JPEG, PNG, GIF, or WebP. These features require a paid plan.
| Field | Purpose | Limit |
|---|---|---|
ogImageFile |
Open Graph image shown when a link is shared | 300 KiB |
logoImageFile |
Favicon shown in the browser tab | 64 × 64 pixels |
curl --fail-with-body -X PUT https://ext.tiiny.host/v1/upload \
-H "x-api-key: $TIINY_API_KEY" \
-F 'domain=example.tiiny.site' \
-F 'ogImageFile=@share.png' -F 'logoImageFile=@favicon.png'
For an owned project, image-only updates keep existing content files. File extensions and decoded image formats are validated.
Remove a custom image
Send {"removeOgImage":true} in settings to restore the default share image, or {"removeLogo":true} to remove the custom favicon. Do not send a removal flag with its corresponding binary file in the same request.
| Field error | Reason |
|---|---|
INVALID_IMAGE_FORMAT |
Unsupported or unreadable image. |
IMAGE_TOO_LARGE |
Share image exceeds 300 KiB. |
INVALID_IMAGE_DIMENSIONS |
Favicon is larger than 64 pixels in either direction. |
CONFLICTING_IMAGE_SETTINGS |
Matching file and removal flag sent together. |
See Project settings for the request format.