Skip to main content
Glama

Draw a network diagram

pwhois_map
Read-onlyIdempotent

Draw a network diagram / show the BGP path for an IP address, prefix or ASN: providers on the left, the network in the middle, downstream networks and prefixes on the right, enriched by Prefix WhoIs. Use for requests like 'draw a network diagram of AS15169', 'show me the BGP path to 8.8.8.8', 'display the network path for 2001:4860::/32'. Also for 'show me a network diagram' and 'map this ASN'. Returns the chart as a PNG image block (format=svg: no image block), a summary with a hosted image link, the interactive map link and a link that reproduces this exact look, an ARTIFACT_HTML text block (a self-contained page with the chart as SVG), and the counts in structuredContent. Clients differ. claude.ai chat and Claude Cowork do not display tool images: publish the ARTIFACT_HTML block as an HTML artifact, verbatim, then give the links. Claude Code receives the PNG as a saved file ('[Image: source: ]'): show that file to the user with the client's file tool (e.g. SendUserFile) or publish the ARTIFACT_HTML as an artifact. API clients that render image blocks need nothing more. Give the user both links and the attribution. Costs 5 queries per chart. Method: see pwhois.org/maps/credits.who#methodology.

Example tool call

This call uses example arguments supplied in the tool’s input schema.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "query": "AS15169"
    },
    "name": "pwhois_map"
  }
}

Input Schema

NameRequiredDescriptionDefault
fontNoLabel font. Default Nunito Sans.
queryYesWhat to draw: an IPv4/IPv6 address, a CIDR prefix, or an AS number (AS15169 or 15169). A hostname is resolved to its address first.
widthNoImage width in pixels.
familyNoAddress family to draw for an AS. An address or prefix sets its own.
formatNoImage format: PNG by default; svg on request. If the server cannot make a PNG right now, the SVG is returned with a note.png
presetNoColors: nightwire (violet on near-black), phosphor (teal glow), ember (amber and coral), paper (light, for documents and print), mono (grayscale).nightwire
collectorsNoAlso draw the networks whose sessions feed pWhois's route collectors (vantage points). Off by default: they show where routes are observed from, not who the network connects to.
downstreamNoFor an AS: also draw the networks behind it (direct downstream customers and their prefixes, bounded). Ignored for addresses and prefixes.

Output Schema

NameRequiredDescriptionDefault
costYesQueries charged for this chart.
kindYes
noteNo
bytesNoSize of the PNG image block (0 when there is none).
edgesYes
emptyNo
nodesYesNodes drawn (networks, prefixes, addresses, bundles).
queryYesThe focus in normal form: AS15169, 8.8.8.8, 8.8.8.0/24.
widthNo
cachedNo
familyYes
formatYespng: a PNG image block leads the answer; svg: no image block, the chart is the SVG inside the ARTIFACT_HTML block; none: nothing routed, nothing drawn.
heightNo
png_fitNooriginal | quantized | scaled:<width> (how the PNG was fitted under the size limit).
sampledYesTrue when a size cap cut the routing data (large networks).
networksNo
warningsNoWhat the drawing left out or shrank (e.g. "drawn counts reduced to keep labels legible at 1200 px"); the full data is on the interactive map.
allowanceNoDaily allowance after this call.
image_urlNoHosted PNG of this chart (https://pwhois.org/maps/<id>.png); null if the look could not be stored.
permalinkYesInteractive map of the same focus on pwhois.org.
share_urlNoInteractive map with this exact look (preset, font, layout); null if it could not be stored.
svg_bytesNo
collectorsNoWhether the collector vantage points were drawn.
downstreamNoFor an AS with downstream=true: the networks behind it.
queried_asNoThe hostname you passed, when it was resolved.
rasterizerNoWhat converted the drawing to PNG.
attributionNo
artifact_bytesNo
collector_peersNoHow many networks feed the route collectors with this network's routes (always counted, drawn only with collectors=true).
artifact_includedNoWhether the ARTIFACT_HTML text block is in the answer.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / preset / description
      Previous value: -"Colours: nightwire (violet on near-black), phosphor (teal glow), ember (amber and coral), paper (light, for documents and print), mono (grayscale)."New value: +"Colors: nightwire (violet on near-black), phosphor (teal glow), ember (amber and coral), paper (light, for documents and print), mono (grayscale)."
  2. Changed7 schema fields changed
    • addedOutput schema / properties / artifact_bytes
      Added value: +{
      +  "type": "integer"
      +}
    • addedOutput schema / properties / artifact_included
      Added value: +{
      +  "description": "Whether the ARTIFACT_HTML text block is in the answer.",
      +  "type": "boolean"
      +}
    • addedOutput schema / properties / bytes
      Added value: +{
      +  "description": "Size of the PNG image block (0 when there is none).",
      +  "type": "integer"
      +}
    • changedOutput schema / properties / format / description
      Previous value: -"What the image block holds. none: nothing routed, nothing drawn."New value: +"png: a PNG image block leads the answer; svg: no image block, the chart is the SVG inside the ARTIFACT_HTML block; none: nothing routed, nothing drawn."
    • addedOutput schema / properties / image_url
      Added value: +{
      +  "description": "Hosted PNG of this chart (https://pwhois.org/maps/<id>.png); null if the look could not be stored.",
      +  "type": [
      +    "string",
      +    "null"
      +  ]
      +}
    • addedOutput schema / properties / png_fit
      Added value: +{
      +  "description": "original | quantized | scaled:<width> (how the PNG was fitted under the size limit).",
      +  "type": "string"
      +}
    • addedOutput schema / properties / svg_bytes
      Added value: +{
      +  "type": "integer"
      +}
  3. Changed3 schema fields changed
    • addedInput schema / properties / collectors
      Added value: +{
      +  "default": false,
      +  "description": "Also draw the networks whose sessions feed pWhois's route collectors (vantage points). Off by default: they show where routes are observed from, not who the network connects to.",
      +  "type": "boolean"
      +}
    • addedOutput schema / properties / collector_peers
      Added value: +{
      +  "description": "How many networks feed the route collectors with this network's routes (always counted, drawn only with collectors=true).",
      +  "type": [
      +    "integer",
      +    "null"
      +  ]
      +}
    • addedOutput schema / properties / collectors
      Added value: +{
      +  "description": "Whether the collector vantage points were drawn.",
      +  "type": "boolean"
      +}
  4. Added

TDQS

A4.4/5.0
Behavior5/5

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

Annotations already declare readOnlyHint, openWorldHint, and idempotentHint, but the description adds substantial context beyond them: output formats, client-specific rendering behavior, artifact instructions, attribution requirements, and query cost. This is unusually transparent for an agent deciding how to invoke and present results.

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 description is front-loaded with purpose and examples, then moves through outputs, client handling, and cost in a logical order. It is longer than typical but largely justified by the tool's multi-output and client-dependent behavior, though some details could be tightened.

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?

Given the tool's complexity, the description covers the key behavioral details an agent needs: what is drawn, how outputs differ by client, what to publish, what links to surface, and the query cost. The output schema exists, but the description still adds essential invocation and presentation context.

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 input schema has 100% description coverage and already documents all eight parameters in detail. The description adds little parameter-specific meaning beyond noting that format=svg produces no image block, so the baseline 3 is appropriate.

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 and resource: draw a network diagram / show the BGP path for an IP, prefix, or ASN. It describes the visual layout and gives concrete request examples, making it clearly distinct from sibling lookup/info tools.

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?

It explicitly lists when to use the tool through example requests such as 'draw a network diagram of AS15169' and 'show me the BGP path to 8.8.8.8'. It does not name when-not-to-use conditions or sibling alternatives, so it falls short of a full 5.

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