Skip to main content
Glama

get_cwe_weakness

Look up Common Weakness Enumeration (CWE) data by ID or get all weaknesses to analyze vulnerability information.

Instructions

Get CWE weaknesses by ID(s) or all weaknesses

Args: ids: Comma-separated CWE IDs or "all" to retrieve all weaknesses Examples: "79", "CWE-89,125", "all"

Returns: Dictionary with "Weaknesses" array or error information

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idsYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior3/5

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

No annotations are present, so the description carries the transparency burden. It discloses that the return is a dictionary with a 'Weaknesses' array or error information and documents accepted input formats. However, it does not address permissions, rate limits, or behavior on invalid IDs beyond returning an error.

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 compact and front-loaded with a one-sentence summary, followed by clearly labeled Args and Returns sections. Every element adds useful information without redundancy.

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

Completeness4/5

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

For a simple single-parameter retrieval tool with an output schema, the description covers the input format, return shape, and error possibility. It lacks explicit usage boundaries relative to sibling tools, but it is otherwise sufficiently complete.

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

Parameters5/5

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

The schema only defines ids as a required string, but the description adds essential semantics: comma-separated CWE IDs, the special value 'all', and concrete example formats like 'CWE-89,125'. This fully compensates for the low schema coverage.

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 uses a specific verb 'Get' with a clear resource 'CWE weaknesses' and scopes it by ID(s) or all. This distinguishes it from sibling tools for categories, views, parents, descendants, etc.

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

Usage Guidelines3/5

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

The description implies usage by saying it retrieves weaknesses by IDs or all, but it does not explicitly state when to prefer this over get_cwe_info or other siblings, nor does it provide exclusions or alternatives.

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/Bilel-Eljaamii/cwe-search_mcp'

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