upload_file
Upload local files, URLs, or base64 data to get a public URL for using in AI generation tools (image, video, audio). Files stored for 3 days.
Instructions
Upload a file to kie.ai and get a public URL back. Use this to upload local images/audio/video before passing them to generation tools (image-to-image, image-to-video, reference/ingredient inputs). PREFER file_path for local files. Files expire after 3 days (kie temp storage).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| file_url | No | URL of file to upload — must be PUBLICLY reachable by kie.ai servers (no localhost/private IPs, no auth-gated or expired links). For local files use file_path | |
| file_name | No | Custom filename (optional) | |
| file_path | No | Absolute path to a local file on the machine running this MCP server (the normal case for stdio setups). The server reads and streams the bytes itself — reliable at any size, unlike base64_data. PREFERRED for local files. | |
| base64_data | No | Base64-encoded file data — raw base64 or a full data: URI. Whitespace and base64url are normalized and the data:<mime>;base64, prefix is stripped automatically (its MIME infers the extension if file_name is omitted). WARNING: payloads above ~10-12K chars (observed ceiling ~11.7K, #68) are silently truncated in transit as a tool argument — use file_path for local files; base64_data is a fallback for remote/HTTP-mode callers with small payloads. | |
| upload_path | No | Storage directory (e.g. "images", "audio", "video") | uploads |