Data Visualization
Gráfico de comparación objetivo vs real con líneas de objetivo, valores reales y rangos de comparación
Llama a esta herramienta desde tu código en tres lenguajes.
curl -X POST 'https://api.elysiatools.com/es/api/tools/bullet-chart' \
-H 'Content-Type: application/json' \
-d '{"bulletData":"JSON format example:\n[{"title": "Sales Completion Rate", "subtitle": "2024 Q1", "value": 85, "target": 100, "ranges": {"poor": 60, "satisfactory": 80, "good": 95, "excellent": 100}, "unit": "%", "format": "percentage"},\n{"title": "Customer Satisfaction", "subtitle": "This Month Survey", "value": 4.2, "target": 4.5, "ranges": {"poor": 3.0, "satisfactory": 3.8, "good": 4.3, "excellent": 4.8}, "unit": "points", "format": "number"}]","chartTitle":"Performance Dashboard","orientation":"horizontal","showLabels":true,"showGrid":false,"colorScheme":"blue","animationDuration":"1000"}'Envía una petición POST con tus entradas en JSON. Los parámetros de tipo archivo requieren una subida previa.
POST https://api.elysiatools.com/es/api/tools/bullet-chart| Nombre | Tipo | Obligatorio | Descripción |
|---|---|---|---|
| bulletData | textarea | Sí | Datos del gráfico de bala en formato JSON incluyendo títulos, valores, objetivos y rangos |
| chartTitle | text | No | Título principal del gráfico de bala |
| orientation | select | No | — |
| showLabels | checkbox | No | Si mostrar etiquetas de valor |
| showGrid | checkbox | No | Si mostrar líneas de cuadrícula de fondo |
| colorScheme | select | No | — |
| animationDuration | text | No | Duración de la animación en milisegundos |
Resultado HTML
{
"result": "<div>Processed HTML content</div>",
"error": "Error message (optional)",
"message": "Notification message (optional)",
"metadata": {
"key": "value"
}
}Añade esta herramienta a tu servidor Model Context Protocol para que los agentes de IA puedan listarla y llamarla.
Añade este bloque a la configuración de tu cliente MCP:
{
"mcpServers": {
"elysiatools-bullet-chart": {
"name": "bullet-chart",
"description": "Gráfico de comparación objetivo vs real con líneas de objetivo, valores reales y rangos de comparación",
"baseUrl": "https://api.elysiatools.com/mcp/sse?toolId=bullet-chart",
"command": "",
"args": [],
"env": {},
"isActive": true,
"type": "sse"
}
}
}Tras conectar al endpoint SSE, lista las herramientas expuestas:
{
"jsonrpc": "2.0",
"id": 1,
"method": "tools/list"
}Invoca la herramienta por su id; los argumentos se construyen a partir de sus parámetros:
{
"jsonrpc": "2.0",
"id": 2,
"method": "tools/call",
"params": {
"name": "bullet-chart",
"arguments": {
"bulletData": "JSON format example:\n[{"title": "Sales Completion Rate", "subtitle": "2024 Q1", "value": 85, "target": 100, "ranges": {"poor": 60, "satisfactory": 80, "good": 95, "excellent": 100}, "unit": "%", "format": "percentage"},\n{"title": "Customer Satisfaction", "subtitle": "This Month Survey", "value": 4.2, "target": 4.5, "ranges": {"poor": 3.0, "satisfactory": 3.8, "good": 4.3, "excellent": 4.8}, "unit": "points", "format": "number"}]",
"chartTitle": "Performance Dashboard",
"orientation": "horizontal",
"showLabels": true,
"showGrid": false,
"colorScheme": "blue",
"animationDuration": "1000"
}
}
}¿Dudas o problemas? Contacta con [email protected]