# User-Agent String Parser

> User-Agent String Parser is a paid API for AI agents from dev-utils.x402tookit.com, paid per call via x402, $0.02/call, status unknown (last checked 2026-11-02).

Parses a User-Agent string to extract browser, OS, device class (desktop/mobile/tablet/tv/bot), and bot detection flag.

## Facts

- Endpoint: GET https://dev-utils.x402tookit.com/user-agent-parse?utm_source=zero.xyz
- Price: $0.02/call
- Payment: x402
- Status: unknown
- Last checked: 2026-11-02
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/user-agent-string-parser-413d46d6
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_oLIljs08uOCAQatRafzeC

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability user-agent-string-parser-413d46d6
```

Example prompt: Can you parse this user-agent string for me and tell me what browser, OS, and device type it is — also flag if it looks like a bot: 'Mozilla/5.0 (iPhone; CPU iPhone OS 16_0 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/16.0 Mobile/15E148 Safari/604.1'?

## When to prefer this

Use this endpoint when you need a quick, structured breakdown of a raw User-Agent string — especially when you need bot detection, device class classification, or browser/OS fingerprinting in a single call. Prefer it over regex-based parsing when you want a maintained, up-to-date parser that handles edge cases and flags degraded results. At $0.02 per call it's cost-effective for on-demand lookups in support workflows, access log analysis, or API middleware.

## Known failure modes

- Missing 'ua' query parameter returns an error
- User-agent string exceeding 600 characters may be truncated or rejected
- Uncommon or novel user-agent strings may return degraded results with the 'degraded' flag set to true
- Unknown or ambiguous user-agents may return null fields for browser/OS/deviceClass
- Payment failure returns HTTP 402 before parsing occurs

## How this service works

Parse a User-Agent string: browser, OS, device class (desktop, mobile, tablet, tv, bot) and a bot flag.

## Output

Returns a structured object containing: browser name/engine/version, OS name/version, device class (desktop/mobile/tablet/tv/bot), a boolean bot flag, bot name and kind if applicable, a human-readable summary and verdict, degraded-parse flag, a list of unchecked signals, disclaimer, source, and timestamp of the parse result.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "ua"
     ],
     "properties": {
      "ua": {
       "type": "string",
       "description": "The User-Agent header value, up to 600 characters"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object",
     "properties": {
      "os": {
       "type": [
        "null",
        "object"
       ],
       "properties": {
        "name": {
         "type": [
          "null",
          "string"
         ]
        },
        "version": {
         "type": [
          "null",
          "string"
         ]
        }
       }
      },
      "bot": {
       "type": [
        "boolean",
        "null"
       ]
      },
      "asOf": {
       "type": [
        "null",
        "string"
       ]
      },
      "length": {
       "type": [
        "null",
        "number"
       ]
      },
      "source": {
       "type": [
        "null",
        "string"
       ]
      },
      "botKind": {},
      "botName": {},
      "browser": {
       "type": [
        "null",
        "object"
       ],
       "properties": {
        "name": {
         "type": [
          "null",
          "string"
         ]
        },
        "engine": {
         "type": [
          "null",
          "string"
         ]
        },
        "version": {
         "type": [
          "null",
          "string"
         ]
        }
       }
      },
      "reasons": {
       "type": [
        "array",
        "null"
       ]
      },
      "summary": {
       "type": [
        "null",
        "string"
       ]
      },
      "verdict": {
       "type": [
        "null",
        "string"
       ]
      },
      "degraded": {
       "type": [
        "boolean",
        "null"
       ]
      },
      "disclaimer": {
       "type": [
        "null",
        "string"
       ]
      },
      "notChecked": {
       "type": [
        "array",
        "null"
       ],
       "items": {
        "type
… (truncated)
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/user-agent-string-parser-413d46d6/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from dev-utils.x402tookit.com](https://www.zero.xyz/host/dev-utils.x402tookit.com/llms.txt)
