Skip to main content
Glama
alberthild

ShieldAPI MCP

by alberthild

shieldapi.scan_skill

Read-onlyIdempotent

Analyze AI agent skills for security risks including prompt injection, malicious code, and credential handling using static analysis across 8 risk categories. Returns risk scores and detailed findings.

Instructions

Scan an AI agent skill/plugin for security issues across 8 risk categories (Snyk ToxicSkills taxonomy). Checks for prompt injection, malicious code, suspicious downloads, credential handling, secret detection, third-party content, unverifiable dependencies, and financial access patterns. Static analysis only — no code execution. Returns risk score (0-100), severity-ranked findings with file locations, and human-readable summary.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
skillNoRaw SKILL.md content or skill name from ClawHub
filesNoAdditional code files to analyze (max 20 files)

Implementation Reference

  • The implementation of shieldapi.scan_skill tool, which registers the tool and handles the request by calling the ShieldAPI POST endpoint.
    server.tool(
      'shieldapi.scan_skill',
      'Scan an AI agent skill/plugin for security issues across 8 risk categories (Snyk ToxicSkills taxonomy). Checks for prompt injection, malicious code, suspicious downloads, credential handling, secret detection, third-party content, unverifiable dependencies, and financial access patterns. Static analysis only — no code execution. Returns risk score (0-100), severity-ranked findings with file locations, and human-readable summary.',
      {
        skill: z.string().optional().describe('Raw SKILL.md content or skill name from ClawHub'),
        files: z.array(z.object({
          name: z.string().describe('Filename including extension'),
          content: z.string().describe('File content as string'),
        })).optional().describe('Additional code files to analyze (max 20 files)'),
      },
      { title: 'Scan AI Skill/Plugin', readOnlyHint: true, destructiveHint: false, idempotentHint: true, openWorldHint: false },
      async (params) => {
        const body: Record<string, unknown> = {};
        if (params.skill) body.skill = params.skill;
        if (params.files) body.files = params.files;
        return formatResult(await callShieldApiPost('scan-skill', body));
      }
    );

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv3.0.0

TDQS

A4.3/5.0
Behavior4/5

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

Beyond the annotations (readOnlyHint, idempotentHint, etc.), the description adds meaningful behavior: static analysis only, no code execution, and a specific return format with risk score and severity-ranked findings. This gives the agent a concrete understanding of what the tool does without contradicting the annotations.

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 concise and front-loaded: the first sentence states purpose, the second lists the checks, the third defines behavioral constraints, and the fourth summarizes the output. Every sentence adds distinct value with no redundancy.

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

Completeness5/5

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

Even though there is no output schema, the description names the return components (risk score 0-100, findings with file locations, summary). It also covers the tool's scope, methodology, and limitations, making it sufficiently complete for an agent to select and invoke correctly.

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?

Schema description coverage is 100%, so both parameters are already well-documented in the schema. The description does not add parameter-specific guidance, but it does clarify the overall purpose and output. Baseline 3 is appropriate since the schema carries the parameter documentation load.

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

Purpose5/5

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

The description opens with a specific verb ('Scan'), identifies the resource ('AI agent skill/plugin'), and enumerates the exact risk categories and taxonomy. This clearly distinguishes it from sibling tools that check single entities like domains, emails, or URLs.

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

Usage Guidelines4/5

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

The description clearly conveys the intended use case: scanning AI agent skills/plugins. It also adds the important constraint that it is static analysis only, which signals when it is appropriate. It does not explicitly name alternative tools or state exclusions, but the context is clear enough.

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