Format Conversion
Infer JSON Schema from worksheet headers and sample rows with types, enum candidates, and basic constraints
Call this tool from your code in three languages.
# 1) Upload each file first → returns { filePath }
curl -X POST 'https://api.elysiatools.com/upload/xlsx-sheet-to-json-schema' \
-F 'file=@/path/to/excelFile.ext'
# 2) Call the tool with the returned filePath values
curl -X POST 'https://api.elysiatools.com/en/api/tools/xlsx-sheet-to-json-schema' \
-F 'excelFile=/public/samples/xlsx/workbook-sales.xlsx' \
-F 'sheetName=Sheet1' \
-F 'headerRow=1' \
-F 'sampleSize=100' \
-F 'enumMaxDistinct=10' \
-F 'requiredThreshold=0.98' \
-F 'schemaTitle=SalesRecord'Send a POST request with your inputs as JSON. File parameters require a separate upload first.
POST https://api.elysiatools.com/en/api/tools/xlsx-sheet-to-json-schema| Name | Type | Required | Description |
|---|---|---|---|
| excelFile | fileupload required | Yes | — |
| sheetName | text | No | — |
| headerRow | number | No | — |
| sampleSize | number | No | — |
| enumMaxDistinct | number | No | — |
| requiredThreshold | range | No | — |
| schemaTitle | text | 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-xlsx-sheet-to-json-schema": {
"name": "xlsx-sheet-to-json-schema",
"description": "Infer JSON Schema from worksheet headers and sample rows with types, enum candidates, and basic constraints",
"baseUrl": "https://api.elysiatools.com/mcp/sse?toolId=xlsx-sheet-to-json-schema",
"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": "xlsx-sheet-to-json-schema",
"arguments": {
"excelFile": "/public/samples/xlsx/workbook-sales.xlsx",
"sheetName": "Sheet1",
"headerRow": 1,
"sampleSize": 100,
"enumMaxDistinct": 10,
"requiredThreshold": 0.98,
"schemaTitle": "SalesRecord"
}
}
}Questions or issues? Contact [email protected]