If you clean files all the time, clicking in a browser gets old. MetadataTools.io exposes the same cleaners over a simple HTTP API and over the Model Context Protocol (MCP), so scripts, upload pipelines and AI assistants can do the work. This guide gives the outline; the exact fields are in the API docs.
What you can call
| Endpoint | Cleans | Notes |
|---|---|---|
| POST /api/v1/clean/image | JPEG, PNG, WebP | Bytes in, clean bytes out |
| POST /api/v1/clean/pdf | Same shape | |
| POST /api/v1/clean/document | DOCX, XLSX, PPTX, ODF, EPUB, SVG, GIF, ZIP | The name of the file tells the cleaner what to do |
| POST /api/v1/clean/audio | MP3, M4A, FLAC, WAV, OGG and more | Runs ffmpeg on the server |
| POST /api/v1/clean/photo | HEIC, HEIF, JPEG XL | Runs ExifTool on the server |
| POST /api/v1/inspect | Any file | Read-only: lists every tag |
A typical call
curl -X POST https://metadatatools.io/api/v1/clean/document \
-H "Authorization: Bearer $KEY" \
-H "X-Filename: report.docx" \
--data-binary @report.docx \
-o report-clean.docx -D headers.txtThe response body is the clean file. The response headers say what was removed and what remains, so a script can fail a build if a flagged field is still present.
Keys, limits and privacy
- Create a key in your dashboard after you sign up. Keys are shown once; store them as a secret, not in code.
- Calls use your daily allowance and plan limits, the same as the website.
- Files are processed in memory or in a temporary folder and deleted within minutes.
- Never put a key in a web page or a mobile app.
For AI assistants
The MCP server lets assistants such as Claude, Cursor or ChatGPT clean and inspect files you give them. Ask for what you want in plain words, for example: remove the metadata from this PDF and tell me what was removed. See the guide on using it with assistants for setup.