Media
Remove green screen or any colored background from video and replace with another video
Call this tool from your code in three languages.
# 1) Upload each file first → returns { filePath }
curl -X POST 'https://api.elysiatools.com/upload/video-chroma-key' \
-F 'file=@/path/to/foregroundVideo.ext'
curl -X POST 'https://api.elysiatools.com/upload/video-chroma-key' \
-F 'file=@/path/to/backgroundVideo.ext'
# 2) Call the tool with the returned filePath values
curl -X POST 'https://api.elysiatools.com/en/api/tools/video-chroma-key' \
-F 'foregroundVideo=/path/to/file.ext' \
-F 'backgroundVideo=/path/to/file.ext' \
-F 'color=green' \
-F 'customColor=0x00FF00' \
-F 'similarity=0.15' \
-F 'blend=0.1' \
-F 'outputFormat=mp4'Send a POST request with your inputs as JSON. File parameters require a separate upload first.
POST https://api.elysiatools.com/en/api/tools/video-chroma-key| Name | Type | Required | Description |
|---|---|---|---|
| foregroundVideo | fileupload required | Yes | — |
| backgroundVideo | fileupload required | Yes | — |
| color | select | No | — |
| customColor | text | No | Custom color in hex format (e.g., 0x00FF00 for green) |
| similarity | range | No | Color similarity threshold (0.01-1). Lower = more exact color match, Higher = more colors removed |
| blend | range | No | Blend factor for edges (0-1). Higher = softer edges, Lower = harder edges |
| outputFormat | select | No | — |
File result
{
"filePath": "/public/processing/randomid.ext",
"fileName": "output.ext",
"contentType": "application/octet-stream",
"size": 1024,
"metadata": {
"key": "value"
},
"error": "Error message (optional)",
"message": "Notification message (optional)"
}Add this tool to your Model Context Protocol server so AI agents can list and call it.
Add this block to your MCP client configuration:
{
"mcpServers": {
"elysiatools-video-chroma-key": {
"name": "video-chroma-key",
"description": "Remove green screen or any colored background from video and replace with another video",
"baseUrl": "https://api.elysiatools.com/mcp/sse?toolId=video-chroma-key",
"command": "",
"args": [],
"env": {},
"isActive": true,
"type": "sse"
}
}
}After connecting to the SSE endpoint, list the exposed tools:
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/list"
}Invoke the tool by its id, passing arguments built from its parameters:
{
"jsonrpc": "2.0",
"id": 2,
"method": "tools/call",
"params": {
"name": "video-chroma-key",
"arguments": {
"foregroundVideo": "https://example.com/file.ext",
"backgroundVideo": "https://example.com/file.ext",
"color": "green",
"customColor": "0x00FF00",
"similarity": 0.15,
"blend": 0.1,
"outputFormat": "mp4"
}
}
}Questions or issues? Contact [email protected]