Skip to main content
Glama
Cyreslab-AI

Nessus MCP Server

start_scan

Initiate a vulnerability scan on a target IP or hostname using specified scan types like basic-network-scan, web-app-scan, or compliance-scan to identify security risks.

Instructions

Start a new vulnerability scan against a target

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
scan_typeYesType of scan to run (basic-network-scan, web-app-scan, compliance-scan)
targetYesTarget IP address or hostname to scan

Implementation Reference

  • Main handler function for the 'start_scan' MCP tool. Validates input (target and scan_type), calls the underlying startScan API function, formats the response as MCP content, and handles errors.
    export const startScanToolHandler = async (args: Record<string, unknown>) => {
      try {
        // Validate arguments
        const targetSchema = z.string().min(1);
        const scanTypeSchema = z.enum(['basic-network-scan', 'web-app-scan', 'compliance-scan']);
    
        const target = validateTarget(args.target);
        const scanType = validateScanType(args.scan_type);
    
        // Start the scan
        const result = await startScan(target, scanType);
    
        return {
          content: [
            {
              type: 'text',
              text: JSON.stringify(result, null, 2)
            }
          ]
        };
      } catch (error) {
        const mcpError = handleNessusApiError(error);
        return {
          content: [
            {
              type: 'text',
              text: `Error: ${mcpError.message}`
            }
          ],
          isError: true
        };
      }
    };
  • Schema definition for the 'start_scan' tool, specifying name, description, and input schema with required target and scan_type parameters.
    export const startScanToolSchema = {
      name: 'start_scan',
      description: 'Start a new vulnerability scan against a target',
      inputSchema: {
        type: 'object',
        properties: {
          target: {
            type: 'string',
            description: 'Target IP address or hostname to scan'
          },
          scan_type: {
            type: 'string',
            description: 'Type of scan to run (basic-network-scan, web-app-scan, compliance-scan)'
          }
        },
        required: ['target', 'scan_type']
      }
    };
  • src/index.ts:99-100 (registration)
    Registration/dispatch of the 'start_scan' tool handler in the main tool call switch statement.
    case 'start_scan':
      return await startScanToolHandler(args);
  • src/index.ts:75-83 (registration)
    Registration of the 'start_scan' tool schema in the list of available tools returned by ListToolsRequest.
    tools: [
      listScanTemplatesToolSchema,
      startScanToolSchema,
      getScanStatusToolSchema,
      getScanResultsToolSchema,
      listScansToolSchema,
      getVulnerabilityDetailsToolSchema,
      searchVulnerabilitiesToolSchema
    ]
  • Underlying helper function called by the handler to start the scan. Currently implements mock mode creating a mock scan ID and queuing status.
    export const startScan = async (target: string, scanType: string) => {
      if (config.useMock) {
        const scanId = createMockScan(target, scanType);
        return {
          scan_id: scanId,
          status: "queued",
          message: "Scan queued successfully"
        };
      }
    
      // 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 initiates a scan but lacks details on permissions required, whether it's asynchronous, rate limits, or what happens if a scan is already running. This is inadequate for a mutation tool with zero 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 that directly states the tool's purpose without any fluff or redundancy. It is front-loaded and appropriately sized for the task.

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 starting a scan (a mutation operation) and the lack of annotations and output schema, the description is incomplete. It does not explain what the tool returns (e.g., a scan ID, status), error conditions, or behavioral traits, leaving significant gaps for the agent.

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 schema description coverage is 100%, so the input schema already documents both parameters ('scan_type' and 'target') thoroughly. The description adds no additional meaning beyond implying these parameters are used to start the scan, meeting the baseline for high schema coverage.

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 action ('Start a new vulnerability scan') and the target ('against a target'), which is specific and unambiguous. However, it does not explicitly differentiate from sibling tools like 'list_scans' or 'get_scan_results', which are read-only operations, though this is implied by the verb 'Start'.

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. It does not mention prerequisites (e.g., needing a target configured), exclusions, or comparisons to siblings like 'list_scan_templates' or 'search_vulnerabilities', leaving the agent to infer usage context.

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