Skip to main content
Glama

Crypto Bot Audit + Market Data (x402 paid)

ERC-20 allowance

chain_allowance
Read-onlyIdempotent

allowance(owner, spender) in raw and decimal form — how much a approval still lets a third party move, which is the number behind most drain headlines. Costs $0.001 USDC per call. Chains: base, ethereum, arbitrum, bsc, polygon, optimism, avalanche. Byte-identical to GET /chain/allowance?chain=base&token=0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913&owner=0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913&spender=0x0000000000000000000000000000000000000000.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
chainYeschain key: base, ethereum, arbitrum, bsc, polygon, optimism, avalanche [required]
ownerYesholder address [required]
tokenYestoken / NFT contract address [required]
spenderYesallowance spender address [required]

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
tsNo
rawNo
noteNo
chainNo
ownerNo
staleNo
tokenNo
caveatNo
reasonNo
sourceNo
chainIdNo
spenderNo
decimalsNo
formattedNo
chainLabelNo
unlimitedApprovalNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "$schema": "http://json-schema.org/draft-07/schema#",
      +  "additionalProperties": false,
      +  "properties": {
      +    "caveat": {
      +      "type": [
      +        "string",
      +        "null"
      +      ]
      +    },
      +    "chain": {
      +      "type": [
      +        "string",
      +        "null"
      +      ]
      +    },
      +    "chainId": {
      +      "anyOf": [
      +        {
      +          "type": "integer"
      +        },
      +        {
      +          "type": "null"
      +        }
      +      ]
      +    },
      +    "chainLabel": {
      +      "type": [
      +        "string",
      +        "null"
      +      ]
      +    },
      +    "decimals": {
      +      "type": "integer"
      +    },
      +    "formatted": {
      +      "type": "string"
      +    },
      +    "note": {
      +      "type": [
      +        "string",
      +        "null"
      +      ]
      +    },
      +    "owner": {
      +      "type": "string"
      +    },
      +    "raw": {
      +      "type": "string"
      +    },
      +    "reason": {
      +      "type": [
      +        "string",
      +        "null"
      +      ]
      +    },
      +    "source": {
      +      "type": "string"
      +    },
      +    "spender": {
      +      "type": "string"
      +    },
      +    "stale": {
      +      "type": [
      +        "boolean",
      +        "null"
      +      ]
      +    },
      +    "token": {
      +      "type": "string"
      +    },
      +    "ts": {
      +      "type": "string"
      +    },
      +    "unlimitedApproval": {
      +      "type": "boolean"
      +    }
      +  },
      +  "type": "object"
      +}
  2. Added

TDQS

A3.5/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=true, idempotentHint=true, and destructiveHint=false. The description adds valuable context beyond these: the cost per call ($0.001 USDC), the supported chains, the output format (raw and decimal), and a concrete example request. It also provides a byte-identical REST endpoint reference. This exceeds the minimum and enriches the agent's understanding of side effects and constraints.

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 concise and front-loaded with the core purpose, followed by cost, chains, and a practical example. Each sentence adds value; the example is long but informative. It avoids unnecessary filler and is well-structured for quick scanning.

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?

For a read-only, idempotent single-allowance lookup, the description covers the key context: cost, supported chains, output format, and a usage example. The output schema exists, so return values are defined elsewhere. It lacks error-case details or notes on edge cases, but these are not critical for a simple query tool.

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 description coverage is 100%, so all four parameters are already documented. The description does not add significant semantic detail beyond the schema, but the included example request clarifies address format and the 'chain key' usage. Since the schema carries the heavy lifting, this is an adequate baseline score.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the function's purpose: returning the allowance between owner and spender in raw and decimal form, with a contextual explanation ('how much a approval still lets a third party move'). It is specific about the resource and operation. However, it does not explicitly differentiate from sibling tools like chain_approvals_scan or chain_wallet_approvals, so it doesn't fully separate itself from alternatives.

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?

The description provides no guidance on when to use this tool versus other allowance-related tools. It mentions the chains and cost but does not indicate scenarios where this specific call is preferred, nor does it mention alternatives or conditions for choosing another tool. The reader must infer usage from the name and description.

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