Skip to main content
Glama

ASN Lookup

asn_lookup
Read-only

Look up an autonomous system by number, such as AS15169, or by an IP address it holds: name, country and one page of its IPv4 and IPv6 prefixes, derived from IPtoASN.

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": {
      "target": "<target>"
    },
    "name": "asn_lookup"
  }
}

Input Schema

NameRequiredDescriptionDefault
limitNoPrefixes per page, in each address family
offsetNoPrefixes to skip in each family; pass next_offset of the previous page
targetYesAS number, such as AS15169 or 15169, or a public IPv4 or IPv6 address, such as 8.8.8.8

Output Schema

NameRequiredDescriptionDefault
asnYes
limitYesMost prefixes of each family on this page: the limit argument, 50 by default.
offsetYesItems skipped: the offset argument, 0 by default.
prefixYesThe IPtoASN prefix that holds the address. null for an AS target.
targetYesThe target in canonical form: the address, or AS and the number.
creditsYes
asn_nameYesThe name IPtoASN gives the AS.
asn_countryYesThe two-letter country where the AS is registered. null when IPtoASN names none.
next_offsetYesoffset plus the length of the longer list on this page. The next page starts there. When it is not below the larger of ipv4_prefix_count and ipv6_prefix_count, this page is the last.
ipv4_prefixesYesThis page of IPv4 prefixes in CIDR form, in address order.
ipv6_prefixesYesThis page of IPv6 prefixes in CIDR form, in address order.
ipv4_prefix_countYesAll IPv4 prefixes of the AS, before paging.
ipv6_prefix_countYesAll IPv6 prefixes of the AS, before paging.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A3.5/5.0
Behavior3/5

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

Annotations already declare readOnlyHint=true and openWorldHint=false, so the safety profile is covered. The description adds two useful pieces beyond that: the data source ('derived from IPtoASN') and that prefix output is paginated to one page per address family. It says nothing about data freshness, rate limits, or what happens when an IP maps to no AS, which are the remaining behavioral gaps.

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?

One front-loaded sentence with no filler; the input forms and the payload contents arrive before the provenance clause. It is information-dense to the point of being slightly crammed, but nothing is wasted.

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?

An output schema exists, so return-value detail is not required, and the description still gives a useful preview of the payload (name, country, prefixes). It covers input forms, result shape, source, and pagination scope, leaving only edge-case behavior unaddressed.

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%: target, limit, and offset are all documented in the schema, including the next_offset paging convention and the per-family cap. The description's 'one page of its IPv4 and IPv6 prefixes' merely restates that, adding no syntax or format guidance beyond the schema.

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?

States a specific verb and resource ('look up an autonomous system') and enumerates the accepted key forms (AS number like AS15169, or an IP address the AS holds), plus what the result contains. It implicitly separates itself from ip_lookup by framing the IP form as a lookup of the AS that holds it, but never names a sibling explicitly.

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?

Usage is only implied: an agent can infer this is the tool for ASN/prefix data, and the 'IP address it holds' phrasing hints at the ip_lookup versus asn_lookup split. There is no explicit statement of when not to use it, no prerequisites, and no named alternative.

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.