Skip to main content
Glama

get_dashboard_data

Retrieve dashboard data for specific chart types to visualize threat models, security components, and mitigations from the Devici API.

Instructions

Get dashboard data for a specific chart type

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
chart_typeYes
limitNo
pageNo
startNo
endNo
project_idNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Implementation Reference

  • MCP tool handler function for 'get_dashboard_data', registered via @mcp.tool() decorator. It creates an API client context and delegates to the client's get_dashboard_data method, returning the result as string.
    @mcp.tool()
    async def get_dashboard_data(chart_type: str, limit: int = 20, page: int = 0, start: str = None, end: str = None, project_id: str = None) -> str:
        """Get dashboard data for a specific chart type"""
        async with create_client_from_env() as client:
            result = await client.get_dashboard_data(
                chart_type=chart_type,
                limit=limit,
                page=page,
                start=start,
                end=end,
                project_id=project_id
            )
            return str(result)
  • Helper method in the DeviciAPIClient class that constructs query parameters and makes an authenticated GET request to the '/dashboard/' endpoint to fetch the data.
    async def get_dashboard_data(
        self, 
        chart_type: str, 
        limit: int = 20, 
        page: int = 0,
        start: Optional[str] = None,
        end: Optional[str] = None,
        project_id: Optional[str] = None
    ) -> List[Dict[str, Any]]:
        """Get dashboard data by specific chart type."""
        params = {
            "limit": limit,
            "page": page,
            "type": chart_type
        }
        if start:
            params["start"] = start
        if end:
            params["end"] = end
        if project_id:
            params["projectId"] = project_id
            
        return await self._make_request("GET", "/dashboard/", params=params)
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations provided, the description carries the full burden of behavioral disclosure. It mentions 'Get dashboard data', implying a read-only operation, but doesn't specify authentication needs, rate limits, error handling, or what the output contains. This is inadequate for a tool with 6 parameters and no annotation coverage.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, efficient sentence with no wasted words. It's appropriately sized and front-loaded, clearly stating the core purpose without unnecessary details.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's complexity (6 parameters, 1 required) and the presence of an output schema, the description is partially complete. It covers the basic purpose but lacks details on parameter usage, behavioral traits, and differentiation from siblings. The output schema mitigates some gaps, but overall it's minimal for a data-fetching tool.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must compensate for undocumented parameters. It only mentions 'chart_type' implicitly, without explaining what chart types are available or how other parameters like 'limit', 'page', 'start', 'end', and 'project_id' affect the data retrieval. This adds minimal value beyond the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose3/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states the tool's purpose ('Get dashboard data for a specific chart type'), which is clear but vague. It specifies the verb ('Get') and resource ('dashboard data'), but doesn't distinguish it from siblings like 'get_dashboard_types' or explain what 'dashboard data' entails. This leaves ambiguity about what exactly is retrieved.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance is provided on when to use this tool versus alternatives. It doesn't mention siblings like 'get_dashboard_types' (which might list available chart types) or other data-fetching tools, nor does it specify prerequisites or exclusions. The description implies usage only by stating the required parameter 'chart_type'.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/sdelements/devici-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server