Skip to main content
Glama
crisjonblvx

enrichrapi-mcp

by crisjonblvx

parse_user_agent

Parse any User-Agent string to identify browser, OS, device type, and detect bots like Googlebot and GPTBot.

Instructions

Parse a User-Agent string into browser, OS, and device details.

Detects 7 browsers, 9 OS variants, device type (desktop/mobile/tablet), and 17+ known bots including Googlebot, GPTBot, and ClaudeBot.

Args: user_agent: The full User-Agent header value

Returns: dict with keys: is_bot, bot_name, browser, browser_version, os, os_version, device_type, cost_usd

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
user_agentYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.0

TDQS

A3.7/5.0
Behavior3/5

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

No annotations are provided, so the description carries the full burden. It mentions the return structure (keys) and bot detection, which adds some transparency. However, it doesn't disclose whether the operation is read-only, whether it makes network calls, or any error/edge-case behavior. The mention of 'cost_usd' hints at potential billing but isn't explained.

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 concise, well-structured with a summary and Args/Returns sections. Every line earns its place, and the most important information (what it does) is front-loaded. No unnecessary words.

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?

For a single-parameter tool with no output schema, the description covers the return keys, which is good. However, it omits error conditions, potential null returns, or any caveats about the cost_usd field. Given the lack of annotations, it should also clarify whether this is a safe read-only operation. These gaps make it less complete than it could be.

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?

The schema has no description for the user_agent parameter (0% coverage), so the description must compensate. It explicitly says 'The full User-Agent header value', which clarifies what format is expected. This is helpful and goes beyond the schema's type-only declaration.

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 action (parse a User-Agent string), the target (browser, OS, device), and specific capabilities (detects 7 browsers, 9 OS variants, device type, and 17+ bots). This is a specific verb+resource and distinguishes it from sibling tools like parse_url or convert_units.

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

Usage Guidelines2/5

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

No guidance on when to use this tool vs alternatives. It doesn't mention when not to use it, prerequisites, or mention any other tool as an alternative. The description assumes the user knows they need to parse a UA string, but doesn't help an agent decide between this and other parsing tools.

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