# x402stock Compare Endpoint

> x402stock Compare Endpoint is a paid API for AI agents from agents.x402stock.xyz, paid per call via x402 or MPP, $0.05/call, status unknown (last checked 2026-10-20).

Compares market and economic data across multiple US stocks, ETFs, forex pairs, crypto, or macro indicators side by side

## Facts

- Endpoint: GET https://agents.x402stock.xyz/api/v1/compare?utm_source=zero.xyz
- Price: $0.05/call
- Payment: x402, MPP
- Status: unknown
- Last checked: 2026-10-20
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/x402stock-compare-endpoint-084d7693
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_W6tGwN2K5IiZKipk1uYsF

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 x402stock-compare-endpoint-084d7693
```

Example prompt: Compare AAPL and MSFT side by side — show me their key price and market metrics so I can see which is performing better right now.

## When to prefer this

Use this endpoint when you need to compare two or more financial assets or economic indicators side by side in a single call, rather than making separate individual lookups and manually comparing results. Ideal for equity vs equity, ETF vs ETF, or cross-asset comparisons.

## Known failure modes

- Invalid or unsupported ticker symbols return an error
- Missing required properties parameter may return incomplete data
- Payment failure via x402/MPP returns 402 status
- Rate limiting or server errors return 5xx responses
- Unsupported asset class combinations may return partial results

## How this service works

Compare 2 to 3 US-listed stocks side by side (peer or watchlist comparisons). Pass a comma-separated list via `?tickers=AAPL,MSFT,NVDA` (1 to 3 symbols). Returns price and day change, market cap, P/E, EPS, revenue, gross and net margins, and dividend yield per ticker. Built for multiple stocks — for a single stock, `/api/v1/quote/{ticker}` is cheaper. From x402stock

## Output

Returns a side-by-side comparison of requested market data properties for the specified tickers or assets, potentially including price, volume, financial ratios, or macro indicators depending on the properties parameter supplied.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "properties": {
   "type": "string"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "object",
 "required": [
  "source",
  "as_of",
  "count",
  "tickers",
  "rows"
 ],
 "properties": {
  "note": {
   "type": "string"
  },
  "rows": {
   "type": "array",
   "items": {
    "type": "object",
    "required": [
     "ticker",
     "name",
     "price",
     "change_percent",
     "market_cap",
     "pe_ratio",
     "eps",
     "revenue",
     "gross_margin_percent",
     "net_margin_percent",
     "dividend_yield_percent",
     "available"
    ],
    "properties": {
     "eps": {
      "anyOf": [
       {
        "type": "number"
       },
       {
        "type": "null"
       }
      ]
     },
     "name": {
      "anyOf": [
       {
        "type": "string"
       },
       {
        "type": "null"
       }
      ]
     },
     "price": {
      "anyOf": [
       {
        "type": "number"
       },
       {
        "type": "null"
       }
      ]
     },
     "ticker": {
      "type": "string"
     },
     "revenue": {
      "anyOf": [
       {
        "type": "number"
       },
       {
        "type": "null"
       }
      ]
     },
     "pe_ratio": {
      "anyOf": [
       {
        "type": "number"
       },
       {
        "type": "null"
       }
      ]
     },
     "available": {
      "type": "string"
     },
     "market_cap": {
      "anyOf": [
       {
        "type": "number"
       },
       {
        "type": "null"
       }
      ]
     },
     "change_percent": {
      "anyOf": [
       {
        "type": "number"
       },
       {
        "type": "null"
       }
      ]
     },
     "net_margin_percent": {
      "anyOf": [
       {
        "type": "number"
       },
       {
        "type": "null"
       }
      ]
     },
     "gross_margin_percent": {
      "anyOf": [
       {
        "type": "number"
       },
       {
        "type": "null"
       }
      ]
     },
     "dividend_yield_percent": {
      "anyOf": [
       {
        "type": "number"
       },
       {
        "type": "null"
       }
      ]
     }
    },
    "additionalProperties": false
   }
  },
  "as_of": {
   "type": "string"
  },
  "count": {
   "type": "number"
  },
  "source": {
   "type": "string",
   "const": "x402stock"
  },
  "tickers": {
   "type": "array",
   "items": {
    "type": "string"
   }
  }
 },
 "additionalProperties": false
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/x402stock-compare-endpoint-084d7693/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from agents.x402stock.xyz](https://www.zero.xyz/host/agents.x402stock.xyz/llms.txt)
