Skip to main content
Glama

Second Wind AI

security group will not delete

security-group-delete-dependency-plan
Read-onlyIdempotent

Send the network interfaces that carry a security group and the groups whose rules reference it. Identifies the owner of every dependent object (Bedrock AgentCore, Lambda, VPC endpoints, load balancers, EKS, ECS, RDS, EFS and more), which ones you can delete now, which need the owning service to release them, and which AWS holds for hours. Returns the ordered commands and how to keep Terraform or CloudFormation from failing meanwhile. Use when the error reads: DependencyViolation: resource sg- has a dependent object | aws_security_group: Still destroying... for many minutes | Security group deletion fails in a stack delete. Covers: Works from supplied describe-network-interfaces and describe-security-groups output for one group in one Region. Does not call AWS and does not inspect peered VPCs in other accounts. Price: 4.00 USDC on Base via x402, charged only when the case is solved.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "security_group_id": "<security_group_id>",
      "network_interfaces": "<network_interfaces>"
    },
    "name": "security-group-delete-dependency-plan"
  }
}

Input Schema

NameRequiredDescriptionDefault
toolNo
group_nameNo
security_group_idYes
network_interfacesYesNetworkInterfaces from: aws ec2 describe-network-interfaces --filters Name=group-id,Values=SG_ID
referencing_groupsNoSecurityGroups from both: aws ec2 describe-security-groups --filters Name=ip-permission.group-id,Values=SG_ID and the same with Name=egress.ip-permission.group-id

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.3/5.0
Behavior5/5

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

The annotations already declare readOnlyHint=true and openWorldHint=false, but the description adds substantive behavior the annotations cannot convey: it performs no AWS calls, is bounded to one group in one Region, ignores cross-account peering, and classifies dependents into three actionable buckets (deletable now, needs the owning service to release, held by AWS for hours). It also discloses the commercial model up front — 4.00 USDC on Base via x402, charged only when the case is solved — which is exactly the kind of non-schema behavior an agent needs before invoking.

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

Conciseness4/5

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

The content is front-loaded and well ordered: inputs, what is computed, trigger errors, scope limits, then pricing. The pipe-delimited error signatures keep the when-to-use block compact. The first sentence is a long run-on that packs inputs, dependent-service list, and three outcome classes together, costing some readability.

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?

With no output schema, the description does the work of describing the return: dependency owners, deletability classification, ordered commands, and Terraform/CloudFormation mitigation guidance. Given the bounded, offline, single-Region analysis, an agent has enough to decide and call correctly. The gaps are the unexplained `tool` and `group_name` parameters and no indication of the response's structure or size.

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 only 40%, so the description must carry weight; it does explain the two required inputs conceptually (network interfaces carrying the group, and groups whose rules reference it) and the one-Region/one-group constraint. However, it never explains the `tool` enum (terraform/cloudformation/cdk/cli) or what `group_name` is for, leaving two of five parameters without added meaning. It also doesn't clarify that referencing groups must cover both ingress and egress rules, which only the schema notes.

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 states a concrete resource and outcome: it identifies owners of dependent objects and returns ordered remediation commands for a security group that will not delete. It is distinguishable from the sibling recovery/plan tools by its narrow scope (security group deletion dependencies) and by the explicit error signatures it answers. It loses a point only because the opening sentence leads with the inputs to supply rather than a direct verb+resource statement of what the tool does.

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

Usage Guidelines5/5

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

It gives explicit trigger conditions in the form of exact error strings ('DependencyViolation: resource sg-<id> has a dependent object', 'aws_security_group: Still destroying...', stack-delete failure), which is unusually actionable routing guidance. It also states the boundaries: it works from supplied describe-network-interfaces and describe-security-groups output for one group in one Region, does not call AWS, and does not inspect peered VPCs in other accounts.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources