# market2000.xyz Time Series Pattern Matching API

> market2000.xyz Time Series Pattern Matching API is a paid API for AI agents from market2000.xyz, paid per call via x402, $0.05/call, status unknown (last checked 2026-09-15).

Finds historical price pattern matches in time series data and returns similarity scores with forward return statistics

## Facts

- Endpoint: GET https://market2000.xyz/get_patterns
- Price: $0.05/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-15
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/market2000-xyz-time-series-pattern-matching-api-f0c2b764
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_9fX5_v8234Cx5rrM0KXov

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 market2000-xyz-time-series-pattern-matching-api-f0c2b764
```

Example prompt: I want to find historical price patterns that look similar to AAPL's recent price action over the last 30 days — show me the closest matches, how similar they were, and what the average 7-day and 30-day returns looked like after those patterns played out.

## When to prefer this

Use this endpoint when you need quantitative historical pattern matching for financial time series data with similarity scoring and forward return statistics. Prefer it over general financial data APIs when the goal is to find analogous historical market setups and estimate probable outcomes based on past pattern performance.

## Known failure modes

- Invalid or unsupported ticker symbol returns error
- Insufficient historical data for the requested pattern window
- Payment failure via x402 on Base results in 402 response with no data
- Malformed POST body or missing required fields returns 400
- No matching patterns found returns empty matches array

## How this service works

An origin the crawlers already index. We count what AI agents try to buy, what they are refused, and what the AI companies take without sending anyone back. Sold per call in USDC.

## Output

Returns a list of historical pattern matches, each with matching dates, closing prices, and a similarity score, plus a summary of average 7-day return, 30-day return, and pattern average return across all matches.

## 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",
    "queryParams"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET",
      "HEAD",
      "DELETE"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "ticker",
      "start_date",
      "end_date"
     ],
     "properties": {
      "k": {
       "type": "integer",
       "description": "Number of analog patterns to return (default 3)"
      },
      "wrap": {
       "type": "boolean",
       "description": "Allow circular search (default true)"
      },
      "metric": {
       "enum": [
        "l1",
        "l2"
       ],
       "type": "string",
       "description": "Distance metric"
      },
      "ticker": {
       "type": "string",
       "description": "Asset symbol (e.g. AAPL, BTC-USD, SPY)"
      },
      "end_date": {
       "type": "string",
       "description": "Query window end, exclusive (YYYY-MM-DD)"
      },
      "timeframe": {
       "type": "string",
       "description": "Bar size: 1d, 1h, 30m, 15m, etc."
      },
      "start_date": {
       "type": "string",
       "description": "Query window start, inclusive (YYYY-MM-DD)"
      }
     }
    }
   }
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object",
     "required": [
      "matches",
      "summary"
     ],
     "properties": {
      "matches": {
       "type": "array",
       "items": {
        "type": "object",
        "required": [
         "dates",
         "closes",
         "similarity",
         "query_return",
         "description"
        ],
        "properties": {
         "dates": {
          "type": "array",
          "items": {
           "type": "string"
          },
          "description": "Bar timestamps for the matched window"
         },
         "closes": {
          "type": "array",
          "items": {
           "type": "number"
          },
          "description": "Closing prices for the matched window"
         },
         "similarity": {
          "type": "number",
          "description": "Normalized distance score (lower = closer match)"
         },
         "description": {
          "type": "s
… (truncated)
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "matches": [
   {
    "dates": [
     "2020-01-15 00:00:00",
     "2020-01-16 00:00:00",
     "2020-01-17 00:00:00"
    ],
    "closes": [
     156.23,
     157.81,
     158.4
    ],
    "similarity": 0.082,
    "description": "AAPL pattern match 1",
    "query_return": 0.043
   }
  ],
  "summary": {
   "Average 7 day return": 1.2,
   "Average 30 day return": 3.5,
   "Pattern Average return": 2.1
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/market2000-xyz-time-series-pattern-matching-api-f0c2b764/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from market2000.xyz](https://www.zero.xyz/host/market2000.xyz/llms.txt)
