# StockCheck

> StockCheck is a paid API for AI agents from stockcheck-mainnet-production.up.railway.app, paid per call via x402, $0.01/call, status unknown (last checked 2026-10-28).

Checks real-time product stock and availability on public ecommerce product pages, returning availability status, stock message, and purchasability with a confidence score.

## Facts

- Endpoint: POST https://stockcheck-mainnet-production.up.railway.app/stock?utm_source=zero.xyz
- Price: $0.01/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-28
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/stockcheck-c3cb0b87
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_JdxC-mMh8uBNqVGUWU1XU

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 stockcheck-c3cb0b87 -d '<json body>'
```

Example prompt: Can you check if this Nike Air Max shoe in size 10 is currently in stock and available to buy? Here's the product page: https://www.nike.com/t/air-max-270-mens-shoes/AH8050-002

## When to prefer this

Use StockCheck when you need to determine in real time whether a specific product on an ecommerce website is available to purchase, especially when you have a direct product URL. It is ideal for variant-level stock checks (e.g. a specific size, colour, or configuration) and when you need a confidence-rated availability signal rather than just a raw page scrape. Prefer this over general web scrapers when you want a structured, normalized availability output with purchasability flag rather than raw HTML.

## Known failure modes

- URL is not a public ecommerce product page — returns error or low-confidence result
- Product page requires login or is behind a paywall — may return unavailable or uncertain result
- Variant specified does not match options on the page — confidence score will be low
- Page uses heavy JavaScript rendering that cannot be parsed — may return uncertain availability
- Product URL is malformed or unreachable — returns error response
- Retailer has anti-scraping protections — may result in failure or incorrect availability

## How this service works

Paid x402 API that checks product stock and availability on public ecommerce webpages.

## Output

Returns a JSON object with: availability status (e.g. 'in_stock', 'out_of_stock'), a human-readable stock message, the product name extracted from the page, a boolean indicating whether the product is purchasable right now, and a confidence score (0–1) reflecting how reliably the availability was determined.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "url": {
   "type": "string",
   "format": "uri",
   "description": "Public ecommerce product webpage"
  },
  "variant": {
   "type": "string",
   "description": "Optional product variant, size, colour or configuration to check"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "confidence": 0.97,
  "availability": "in_stock",
  "product_name": "Example Product",
  "stock_message": "In stock",
  "purchasable_now": true
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/stockcheck-c3cb0b87/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from stockcheck-mainnet-production.up.railway.app](https://www.zero.xyz/host/stockcheck-mainnet-production.up.railway.app/llms.txt)
