# BestOffer

> BestOffer is a paid API for AI agents from bestoffer-mainnet-production.up.railway.app, paid per call via x402, $0.03/call, status unknown (last checked 2026-10-23).

Compares 2–5 product page URLs and returns a ranked recommendation for the best currently available offer, with price, confidence score, and reasoning.

## Facts

- Endpoint: POST https://bestoffer-mainnet-production.up.railway.app/best-offer?utm_source=zero.xyz
- Price: $0.03/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-23
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/bestoffer-9c7bace1
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_dxstT08tPoKf9p2penCp-

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 bestoffer-9c7bace1 -d '<json body>'
```

Example prompt: I found the same Sony WH-1000XM5 headphones on three different sites — can you compare these pages and tell me which one has the best deal right now? Here are the URLs: https://www.amazon.co.uk/..., https://www.johnlewis.com/..., https://www.currys.co.uk/...

## When to prefer this

Use BestOffer when you have 2–5 concrete product page URLs that likely represent the same item and want a fast, automated determination of which is the best deal right now, including stock availability and delivered price. It is especially useful when prices vary by retailer or region and a human-readable explanation of the recommendation is needed. Prefer this over manual scraping pipelines or generic search when you already have the candidate URLs and want a single ranked answer with a confidence score.

## Known failure modes

- URLs are not publicly accessible or require login — scraping fails and comparison cannot be made
- Product pages represent different products or variants — comparable flag set to false
- Fewer than 2 or more than 5 URLs provided — request rejected by schema validation
- Price information not visible on the page (e.g. 'add to cart to see price') — confidence score will be low or result may be unavailable
- Payment of $0.03 USDC fails or is not submitted — 402 response returned before processing begins
- All pages are out of stock — recommendation may still be returned but with low confidence

## How this service works

Paid x402 API that compares multiple product pages and ranks the best currently available offer.

## Output

Returns a JSON object containing: the index of the best offer (best_offer_index), the best visible delivered price (best_price) and its currency, the product name inferred from the pages (product), a human-readable explanation of why that offer is best (reason), a flag indicating whether the pages are genuinely comparable (comparable), and a confidence score (0–1) reflecting certainty in the recommendation.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "urls": {
   "type": "array",
   "items": {
    "type": "string",
    "format": "uri"
   },
   "maxItems": 5,
   "minItems": 2,
   "description": "Two to five public product pages believed to represent the same product"
  },
  "product_hint": {
   "type": "string",
   "description": "Optional description, model or variant the buyer actually wants"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "reason": "Seller 2 is in stock and has the lowest visible delivered price.",
  "product": "Example Product",
  "currency": "GBP",
  "best_price": 79.99,
  "comparable": true,
  "confidence": 0.94,
  "best_offer_index": 1
 }
}
```

## More

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