Media
Convertit une page TIFF sélectionnée en PNG gris, RGB ou RGBA 16 bits par canal vérifié.
Appelez cet outil depuis votre code en trois langages.
# 1) Request a presigned URL → returns { uploadUrl, storageKey }
curl -X POST 'http://127.0.0.1:3003/api/upload/presign/tiff-to-16bit-png' \
-H 'Content-Type: application/json' \
-d '{"filename":"imageFile.ext","contentType":"application/octet-stream","size":12345}'
# 2) PUT the file bytes directly to the presigned uploadUrl
curl -X PUT '<presigned uploadUrl>' \
--data-binary @/path/to/file.ext
# 3) Call the tool, passing the returned storageKey for each file field
curl -X POST 'http://127.0.0.1:3003/fr/api/tools/tiff-to-16bit-png' \
-F 'imageFile=uploads/2026/01/01/your-tool-1700000000000-abc123.ext' \
-F 'channelMode=preserve' \
-F 'page=1' \
-F 'backgroundColor=#ffffff' \
-F 'preserveMetadata=true'Envoyez une requête POST avec vos entrées en JSON. Les paramètres de type fichier nécessitent un upload préalable.
POST http://127.0.0.1:3003/fr/api/tools/tiff-to-16bit-png| Nom | Type | Requis | Description |
|---|---|---|---|
| imageFile | fileupload requis | Oui | — |
| channelMode | select | Non | — |
| page | number | Non | — |
| backgroundColor | color | Non | — |
| preserveMetadata | checkbox | Non | — |
Résultat fichier
{
"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)"
}Ajoutez cet outil à votre serveur Model Context Protocol pour que les agents IA puissent le lister et l'appeler.
Ajoutez ce bloc à la configuration de votre client MCP :
{
"mcpServers": {
"elysiatools-tiff-to-16bit-png": {
"name": "tiff-to-16bit-png",
"description": "Convertit une page TIFF sélectionnée en PNG gris, RGB ou RGBA 16 bits par canal vérifié.",
"baseUrl": "http://127.0.0.1:3003/mcp/sse?toolId=tiff-to-16bit-png",
"command": "",
"args": [],
"env": {},
"isActive": true,
"type": "sse"
}
}
}Après connexion au point d'accès SSE, listez les outils exposés :
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/list"
}Appelez l'outil par son id ; les arguments sont construits à partir de ses paramètres :
{
"jsonrpc": "2.0",
"id": 2,
"method": "tools/call",
"params": {
"name": "tiff-to-16bit-png",
"arguments": {
"imageFile": "https://example.com/file.ext",
"channelMode": "preserve",
"page": 1,
"backgroundColor": "#ffffff",
"preserveMetadata": true
}
}
}Des questions ou un problème ? Contactez [email protected]