Business plan

Metadata removal API

The same cleaning the website does, as one HTTP request. Send a photo, video, PDF, Office file, audio file or RAW photo and get the clean copy back, with a report of what was removed. There is also an MCP server, so an AI assistant can do it for you.

The API is part of Business, $49 a month. See plans or, if you are on Business, create a key.

Authentication

Create a key under API keys in your account and send it in the Authorization header. A key works until a few days after the billing period it was made in. After each renewal, create a new one.

Authorization: Bearer mr_live_...

Clean a file

POST https://www.trymetadatalab.com/api/v1/clean returns the cleaned file. There are three ways to send the file.

As a form upload

curl -X POST https://www.trymetadatalab.com/api/v1/clean \
  -H "Authorization: Bearer $API_KEY" \
  -F "file=@photo.jpg" \
  -o photo-clean.jpg

From a link

curl -X POST https://www.trymetadatalab.com/api/v1/clean \
  -H "Authorization: Bearer $API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"url": "https://example.com/video.mp4"}' \
  -o video-clean.mp4

As raw bytes

curl -X POST "https://www.trymetadatalab.com/api/v1/clean?filename=report.pdf" \
  -H "Authorization: Bearer $API_KEY" \
  --data-binary @report.pdf \
  -o report-clean.pdf

The answer carries three headers: X-Metadata-Kind (the file type), X-Metadata-Found (how many details were removed) and X-Metadata-Left (what a second scan still found, normally 0).

Get a JSON report

Add ?format=json and the answer is JSON, with the cleaned file in file_base64.

{
  "file_name": "photo-clean.jpg",
  "kind": "jpeg",
  "bytes_before": 30461,
  "bytes_after": 29869,
  "found": [
    { "group": "location", "label": "GPS location", "value": "37.77490, -122.41940" },
    { "group": "device", "label": "Camera or phone", "value": "Apple iPhone 15 Pro" }
  ],
  "left": [],
  "clean": true,
  "notes": [],
  "content_type": "image/jpeg",
  "file_base64": "..."
}

Inspect a file

POST https://www.trymetadatalab.com/api/v1/inspect takes a file the same three ways and returns the list of metadata as JSON. Nothing is changed.

curl -X POST https://www.trymetadatalab.com/api/v1/inspect \
  -H "Authorization: Bearer $API_KEY" \
  -F "file=@photo.jpg"

Limits

Errors

Errors are JSON with a code and a message you can show to a person.

{ "error": { "code": "encrypted", "message": "This PDF is locked with a password. Remove the password, then clean it." } }
StatusMeaning
400No file in the request, or a link that cannot be fetched
401Missing, wrong or expired API key
413The file is over the size limit
415The file type is not supported
422The file is damaged or locked with a password

Use it from Claude, ChatGPT or Cursor

The MCP server lets an assistant inspect and clean files when you ask it to. It has two tools, inspect_file and clean_file, and takes a file as a public link or as base64 content.

Server address: https://www.trymetadatalab.com/api/mcp (Streamable HTTP). It uses the same API key, sent as a Bearer token.

Claude Code

claude mcp add --transport http metadata-remover https://www.trymetadatalab.com/api/mcp \
  --header "Authorization: Bearer $API_KEY"

Cursor and other clients

{
  "mcpServers": {
    "metadata-remover": {
      "url": "https://www.trymetadatalab.com/api/mcp",
      "headers": { "Authorization": "Bearer mr_live_..." }
    }
  }
}

Then ask in plain words, for example: “Check what metadata this photo has” or “Remove the metadata from the file at this link.” Clean files up to 3 MB come back inside the chat. For larger ones the assistant gets the report and you download the file with the API.

What happens to files sent to the API

On the website, files never leave your device. The API is different by nature: the file reaches our server, is cleaned in memory and is returned in the same request. It is not written to disk, not logged and not kept after the answer is sent.

Built with Leapd