Skip to main content
Glama
Cyreslab-AI

Nessus MCP Server

get_scan_status

Track and monitor the progress of active scans by retrieving their real-time status using the scan ID, ensuring efficient management of vulnerability assessments.

Instructions

Check the status of a running scan

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
scan_idYesID of the scan to check

Implementation Reference

  • The handler function for the 'get_scan_status' tool. It validates the scan_id argument, calls the getScanStatus helper, formats the response as JSON, and handles errors.
    export const getScanStatusToolHandler = async (args: Record<string, unknown>) => {
      try {
        // Validate arguments
        const scanId = validateScanId(args.scan_id);
    
        // Get scan status
        const status = await getScanStatus(scanId);
    
        return {
          content: [
            {
              type: 'text',
              text: JSON.stringify(status, null, 2)
            }
          ]
        };
      } catch (error) {
        const mcpError = handleNessusApiError(error);
        return {
          content: [
            {
              type: 'text',
              text: `Error: ${mcpError.message}`
            }
          ],
          isError: true
        };
      }
    };
  • The schema definition for the 'get_scan_status' tool, specifying the input requirements including the required 'scan_id' parameter.
    export const getScanStatusToolSchema = {
      name: 'get_scan_status',
      description: 'Check the status of a running scan',
      inputSchema: {
        type: 'object',
        properties: {
          scan_id: {
            type: 'string',
            description: 'ID of the scan to check'
          }
        },
        required: ['scan_id']
      }
    };
  • src/index.ts:101-102 (registration)
    The tool is registered in the main CallToolRequestHandler switch statement, dispatching calls to the getScanStatusToolHandler.
    case 'get_scan_status':
      return await getScanStatusToolHandler(args);
  • The core helper function getScanStatus that fetches the scan status, using mock data or throwing for real API (not implemented). Called by the tool handler.
    export const getScanStatus = async (scanId: string) => {
      if (config.useMock) {
        return getMockScanStatus(scanId);
      }
    
      // Real API implementation would go here
      throw new Error("Real API not implemented");
    };
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 states the tool checks status but doesn't describe what the status includes (e.g., progress percentage, state like 'running'/'completed'), whether it's read-only (implied but not explicit), or any rate limits or authentication needs. This leaves significant gaps for an agent to understand the tool's behavior.

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 that front-loads the core purpose without unnecessary words. Every part earns its place, making it highly concise and well-structured for quick comprehension.

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

Completeness2/5

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

Given the complexity of a scanning tool with no annotations and no output schema, the description is insufficient. It doesn't explain what status information is returned (e.g., progress, errors) or behavioral aspects like idempotency or error handling, leaving the agent with incomplete context for effective use.

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% description coverage, with the 'scan_id' parameter clearly documented. The description adds no additional semantic context beyond implying the scan must be 'running', which is minimal value. Baseline 3 is appropriate as the schema does the heavy lifting.

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 the tool's purpose with a specific verb ('Check') and resource ('status of a running scan'), making it immediately understandable. However, it doesn't explicitly differentiate from sibling tools like 'get_scan_results' or 'list_scans', which could provide similar status information in different contexts.

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 provides no guidance on when to use this tool versus alternatives like 'get_scan_results' or 'list_scans'. It mentions 'running scan' but doesn't clarify prerequisites (e.g., whether the scan must be actively executing) or exclusions (e.g., not for completed scans).

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

Related 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/Cyreslab-AI/nessus-mcp-server'

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