Skip to main content
Glama
zoomeye-ai

ZoomEye MCP Server

Official
by zoomeye-ai

zoomeye_vuldb_by_id

Search for detailed vulnerability information by CVE, CNVD, or CNNVD ID and receive comprehensive, formatted security vulnerability details.

Instructions

Search for detailed vulnerability information by vulnerability ID and return formatted results.

Use this tool to retrieve comprehensive security vulnerability details from the vulnerability
database using a vulnerability identifier (CVE, CNVD, CNNVD). Results include:

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
cve_idYesA valid vulnerability identifier, eg: CVE-XXXX-XXXX,CNVD-XXXX-XXXX,CNNVD-XXXX-XXXX

Implementation Reference

  • Handler function `zoomeye_query_vuldb_by_id` that creates a ZoomeyeService and calls `query_vulnerability_by_id(cve_id)`.
    def zoomeye_query_vuldb_by_id(cve_id: str):
        """Search for vulnerabilities by ID. eg: CVE-XXXX-XXXX,CNVD-XXXX-XXXX,CNNVD-XXXX-XXXX"""
        service = ZoomeyeService()
        return service.query_vulnerability_by_id(cve_id)
  • ZoomeyeService.query_vulnerability_by_id() method – makes a GET request to https://api.zoomeye.ai/v2/vuldb/{cve_id} with the API key and returns the JSON response.
    async def query_vulnerability_by_id(self, cve_id: str):
        """Query vulnerability by ID.
        Args:
            cve_id (str): The CVE ID to query.
        Returns:
            dict: The API response data.
        Raises:
            ValueError: If API key is not provided or API request fails.
        """
        url = "https://api.zoomeye.ai/v2/vuldb/{}".format(cve_id)
        headers = {"API-KEY": self.key, "Content-Type": "application/json"}
        try:
            client = await self.get_client()
            async with client:
                response = await client.get(url, headers=headers)
                response.raise_for_status()  # Raise exception for HTTP errors
                return response.json()
        except httpx.HTTPError as e:
            raise ValueError(f"Error querying ZoomEye API: {str(e)}")
        except json.JSONDecodeError:
            raise ValueError("Invalid JSON response from ZoomEye API")
  • Enum definition ZoomeyeTools.ZOOMEYE_VULDB_BY_ID = "zoomeye_vuldb_by_id" – declares the tool identifier string.
    class ZoomeyeTools(str, Enum):
        ZOOMEYE_SEARCH = "zoomeye_search"
        """Search query for ZoomEye."""
        ZOOMEYE_VULDB_BY_ID = "zoomeye_vuldb_by_id"
        """Query vulnerability by ID."""
  • Tool registration inside list_tools() – defines the tool's name, description, and input schema (requires 'cve_id' string).
            Tool(
                name=ZoomeyeTools.ZOOMEYE_VULDB_BY_ID,
                description="""Search for detailed vulnerability information by vulnerability ID and return formatted results.
    
    Use this tool to retrieve comprehensive security vulnerability details from the vulnerability
    database using a vulnerability identifier (CVE, CNVD, CNNVD). Results include:""",
                inputSchema={
                    "type": "object",
                    "properties": {
                        "cve_id": {
                            "type": "string",
                            "description": "A valid vulnerability identifier, eg: CVE-XXXX-XXXX,CNVD-XXXX-XXXX,CNNVD-XXXX-XXXX",
                        }
                    },
                    "required": ["cve_id"],
                },
            ),
  • Tool call dispatch: case ZoomeyeTools.ZOOMEYE_VULDB_BY_ID – extracts cve_id from arguments, validates it, then calls zoomeye_service.query_vulnerability_by_id(cve_id).
    case ZoomeyeTools.ZOOMEYE_VULDB_BY_ID:
        cve_id = arguments.get("cve_id")
        if not cve_id:
            raise ValueError("Missing required argument: cve_id")
        result = await zoomeye_service.query_vulnerability_by_id(cve_id)
Behavior2/5

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

With no annotations provided, the description must fully disclose behavioral traits. It indicates a read-only operation (search/retrieve), but fails to describe output format, pagination, rate limits, or any side effects. The abrupt end ('Results include:') leaves the agent guessing what the tool returns, which is a significant gap for transparency.

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

Conciseness2/5

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

The description is short, but it is incomplete, ending with 'Results include:' without any continuation. This disrupts the structure and leaves the description unfinished. Every sentence should be complete and purposeful, and this one fails to deliver its intended content.

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

Completeness1/5

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

Given no output schema, the description should explain the return values comprehensively. It starts listing results but cuts off, providing zero information about what the formatted results contain. This is a major omission for a tool that only has one parameter and no other documentation.

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

Parameters3/5

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

The input schema has 100% coverage, with the parameter 'cve_id' described and examples given. The description repeats this information without adding substantial new meaning. Baseline is 3, and since no extra semantics are provided, the score remains at 3.

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

Purpose4/5

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

The description clearly states 'Search for detailed vulnerability information by vulnerability ID', specifying the verb and resource. It lists the accepted ID formats (CVE, CNVD, CNNVD), which helps the agent understand the tool's scope. However, it does not differentiate from sibling tools like 'zoomeye_search' or 'zoomeye_vuldb_by_keyword', and the incomplete sentence 'Results include:' slightly reduces clarity.

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?

The description says 'Use this tool to retrieve...' but provides no guidance on when to use it versus alternatives, such as the sibling tool 'zoomeye_vuldb_by_keyword'. There is no mention of prerequisites, limitations, or exclusions, leaving the agent to infer usage context without explicit advice.

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/zoomeye-ai/mcp_zoomeye'

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