Skip to main content
Glama
badchars

osint-mcp-server

by badchars

geoip_batch

Geolocate multiple IP addresses simultaneously to identify geographic locations of network endpoints for reconnaissance and analysis.

Instructions

Batch geolocate up to 100 IP addresses at once. Uses ip-api.com (free, no API key).

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
ipsYesIP addresses to geolocate (max 100)

Implementation Reference

  • The core logic for the 'geoip_batch' tool, which sends a POST request to ip-api.com/batch.
    export async function geoipBatch(ips: string[]): Promise<GeoIpResult[]> {
      if (ips.length === 0) return [];
      const batch = ips.slice(0, 100);
    
      await limiter.acquire();
      const res = await fetch("http://ip-api.com/batch", {
        method: "POST",
        headers: { "Content-Type": "application/json" },
        body: JSON.stringify(
          batch.map((ip) => ({
            query: ip,
            fields: "status,message,query,country,countryCode,region,regionName,city,zip,lat,lon,timezone,isp,org,as,asname,mobile,proxy,hosting",
          })),
        ),
      });
      if (!res.ok) throw new Error(`ip-api.com batch returned ${res.status}`);
      return res.json();
    }
  • The tool definition and registration for 'geoip_batch' within the protocol tools collection.
    const geoipBatchTool: ToolDef = {
      name: "geoip_batch",
      description: "Batch geolocate up to 100 IP addresses at once. Uses ip-api.com (free, no API key).",
      schema: {
        ips: z.array(z.string()).describe("IP addresses to geolocate (max 100)"),
      },
      execute: async (args) => json(await geoipBatch(args.ips as string[])),
    };
  • The input schema for 'geoip_batch' defining the expected list of IP addresses.
    schema: {
      ips: z.array(z.string()).describe("IP addresses to geolocate (max 100)"),
    },
Behavior3/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It usefully adds context about the external service (ip-api.com), cost (free), and authentication (no API key), which aren't in the schema. However, it doesn't mention rate limits, error handling, or what the output looks like (e.g., format, fields), leaving gaps for a tool with no output schema.

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 extremely concise—two sentences with zero waste. The first sentence states the core functionality and constraint, and the second adds important behavioral context. Every word earns its place, and it's front-loaded with the primary purpose.

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

Completeness3/5

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

Given the tool's moderate complexity (batch operation, external service), no annotations, and no output schema, the description is incomplete. It covers the what and some behavioral context but lacks details on output format, error cases, or rate limits, which are crucial for an agent to use it effectively. It's adequate but has clear gaps.

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

Parameters4/5

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

Schema description coverage is 100%, so the schema already documents the 'ips' parameter fully. The description adds marginal value by reinforcing the max 100 limit, but doesn't provide additional semantic context beyond what's in the schema. With 0 parameters requiring extra explanation, a baseline of 4 is appropriate as it doesn't detract.

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 clearly states the specific action ('Batch geolocate'), resource ('IP addresses'), and scope ('up to 100 at once'), distinguishing it from sibling tools like geoip_lookup which presumably handles single IP lookups. The purpose is unambiguous and differentiated.

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 provides clear context for when to use this tool (batch processing up to 100 IPs) and mentions the service provider (ip-api.com) and that it's free with no API key. However, it doesn't explicitly state when NOT to use it or mention alternatives like geoip_lookup for single IP lookups, though the batch nature implies the distinction.

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/badchars/osint-mcp-server'

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