Skip to main content
Glama

Query Ip Location

query_ip_location

查询 IPv4 地址的归属地和运营商信息。ip为空时尝试取调用方IP。返回归属地(国家/省份/城市)、经纬度、时区、运营商、AS编号。主源ip-api.com,备源ipwho.is。

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

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

Input Schema

NameRequiredDescriptionDefault
ipNo要查询的 IPv4 地址,如 "8.8.8.8";留空时尝试取调用方 IP

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed5 schema fields changed
    • addedInput schema / additionalProperties
      Added value: +false
    • addedInput schema / properties / ip / description
      Added value: +"要查询的 IPv4 地址,如 \"8.8.8.8\";留空时尝试取调用方 IP"
    • removedInput schema / properties / ip / title
      Removed value: -"Ip"
    • removedInput schema / title
      Removed value: -"query_ip_locationArguments"
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "additionalProperties": true,
      +  "type": "object"
      +}
  2. First observed

TDQS

A4.1/5.0
Behavior4/5

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

With no annotations at all, the description carries the full disclosure burden and does most of it: it reveals the data-source chain (primary ip-api.com, fallback ipwho.is) and the empty-parameter fallback behavior, both of which matter to an agent reasoning about reliability. It omits rate limits and failure behavior of third-party lookups, which would be the remaining high-value details.

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?

Three tight sentences, front-loaded with the purpose, then the special calling convention, then the data sources. The enumerated return fields arguably duplicate the existing output schema, which is the only mild redundancy; nothing else is filler.

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?

The tool is simple (one optional parameter) and an output schema already exists, so return-shape explanation is not strictly needed. The description still covers the non-obvious pieces: zero-argument behavior and upstream data providers. It would be complete at 5 with a note on rate limiting or on querying being sent to a third party.

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 coverage is 100% and the single parameter already documents the format example ("8.8.8.8") and the blank-means-caller-IP behavior. The description restates the empty-parameter rule rather than adding new meaning such as accepted formats (hostname vs literal IP) or what happens with an invalid address, so baseline 3 applies.

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+resource pair in Chinese: querying the geolocation and carrier/ISP of an IPv4 address. It goes beyond the title by naming exactly what data classes come back (country/province/city, lat-long, timezone, ISP, AS number), so an agent knows the scope without opening the schema.

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 states a concrete conditional usage rule: "ip 为空时尝试取调用方IP" (when ip is empty, fall back to the caller's IP), which tells the agent it can call with no arguments. There are no sibling tools to disambiguate against, so no exclusion language is required, but no explicit when-not-to-use guidance is given either.

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.