# market-resolution

> market-resolution is a paid API for AI agents from x402.fenixfoundry.com, paid per call via x402, $0.005/call, status unknown (last checked 2026-09-15).

Checks whether a prediction market event has settled on Polymarket or Kalshi and returns the resolved outcome, resolution time, source, and market URL.

## Facts

- Endpoint: GET https://x402.fenixfoundry.com/resolution
- Price: $0.005/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-15
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/market-resolution-118cd79e
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_oHGNN8mHw63HumRjczJCw

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 market-resolution-118cd79e
```

Example prompt: Did the US avoid a government shutdown in 2025? Check Polymarket or Kalshi to see if that market has resolved and what the outcome was.

## When to prefer this

Use this endpoint when an agent needs to verify whether a real-world binary event has officially settled according to prediction market venues (Polymarket or Kalshi), especially as a cheap on-demand oracle before triggering conditional logic, payouts, or downstream actions. Prefer over generic web search when you need a structured, machine-readable resolution with a confidence score and canonical source URL rather than free-text news results.

## Known failure modes

- No matching market found for the natural-language query — returns low or zero confidence score with null outcome
- Market exists but has not yet settled — resolved: false with closeTime instead of resolvedAt
- Ambiguous query matches multiple markets — returns best-guess with lower confidence score
- Invalid venue/id combination — 400-level error or null result
- Venue API unavailability — upstream timeout or service error

## How this service works

Did it happen? Check whether a prediction market event has settled on Polymarket or Kalshi and get the resolved outcome, resolution time, source and market URL. A cheap oracle for agents that must verify a real-world outcome before acting.

## Output

Returns a JSON object indicating whether the market is resolved (boolean), the settled outcome string (e.g. 'Yes' or 'No'), the ISO timestamp of resolution, the resolution source venue, the market URL, and a confidence score (0–1) that the returned market matches the queried event. Unresolved markets return resolved: false with a scheduled close time if available.

## 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",
     "anyOf": [
      {
       "required": [
        "q"
       ]
      },
      {
       "required": [
        "venue",
        "id"
       ]
      }
     ],
     "properties": {
      "q": {
       "type": "string",
       "maxLength": 500,
       "description": "Natural-language event query, e.g. \"Did the US government shut down in 2026?\". Use this or venue+id."
      },
      "id": {
       "type": "string",
       "description": "Direct lookup: Polymarket event slug or Kalshi ticker. Requires venue."
      },
      "venue": {
       "enum": [
        "polymarket",
        "kalshi"
       ],
       "type": "string",
       "description": "Direct lookup: which venue the market lives on. Requires id."
      }
     },
     "additionalProperties": false
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object",
     "required": [
      "resolved",
      "outcome",
      "resolvedAt",
      "resolutionSource",
      "venue",
      "url",
      "confidence",
      "attribution"
     ],
     "properties": {
      "id": {
       "type": [
        "string",
        "null"
       ]
      },
      "url": {
       "type": [
        "string",
        "null"
       ]
      },
      "query": {
       "type": [
        "string",
        "null"
       ]
      },
      "venue": {
       "enum": [
        "polymarket",
        "kalshi",
        null
       ],
       "type": [
        "string",
        "null"
       ]
      },
      "outcome": {
       "type": [
        "string",
        "null"
       ],
       "description": "Settled outcome as published, e.g. \"Yes\"."
      },
      "resolved": {
       "type": "boolean",
       "description": "True once the venue has settled the market."
      },
      "closeTime": {
       "type": [
        "string",
        "null"
       ],
       "description": "Scheduled close time for markets that have not settled."
      },
      "confidence": {
       "type"
… (truncated)
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/market-resolution-118cd79e/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from x402.fenixfoundry.com](https://www.zero.xyz/host/x402.fenixfoundry.com/llms.txt)
