# Polymarket — Get Klines

Get Polymarket Perps Candles data via REST or OpenAny MCP—with pay-per-use pricing and no subscription. Powered by Polymarket, pass parameters such as end_timestamp, instrument_id, interval, and retrieve structured data including structured JSON records, identifiers, and response metadata for historical charts, and windowed collection, ready for production pipelines and AI agent automation.

Documentation: https://openany.si/market/apis/polymarket/polymarket-get-klines/?offering=86a5d9e2-94a9-4593-afdc-cfb8c8360a28
API ID: 86a5d9e2-94a9-4593-afdc-cfb8c8360a28
Provider: Polymarket
Contract revision: 4
Method: GET
Endpoint: https://api.openany.si/v1/agent-apis/polymarket/v1/info/klines
Page update time: 2026-12-03T02:49:31.149Z
Access: OpenAny REST
OpenAny MCP: availability is not supplied by this REST contract. Check get_api on the configured OpenAny MCP server before execution.
Request content type: none
Execution mode: sync
Authentication: Authorization: Bearer $OPENANY_API_KEY

## Billing
Price: $0 / call
API-key calls use your shared balance. Review the published billing rules before making a paid request.
Price source: OpenAny public API contract. Price update time: not supplied.
Contract update time: 2026-12-03T02:49:30.712Z. This is not a price-change timestamp.
```json
{
  "currency": "USD",
  "mode": "fixed",
  "priceMicroUsd": "0",
  "rounding": null,
  "unit": "call",
  "unitQuantity": null
}
```

## Request parameters
```json
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "title": "Polymarket — Get Klines request inputs",
  "$comment": "Declared input types grouped by HTTP location. Path, query and header values describe decoded inputs and are serialized as text on the wire; body is the payload. This is not an exhaustive provider contract or a schema for the raw HTTP request.",
  "type": "object",
  "properties": {
    "path": {
      "type": "object",
      "properties": {}
    },
    "query": {
      "type": "object",
      "properties": {
        "instrument_id": {
          "type": "integer",
          "description": "Instrument ID",
          "minimum": 0,
          "maximum": 4294967295
        },
        "interval": {
          "type": "string",
          "description": "Kline interval",
          "enum": [
            "1s",
            "1m",
            "5m",
            "15m",
            "30m",
            "1h",
            "4h",
            "6h",
            "12h",
            "1d",
            "1w"
          ]
        },
        "start_timestamp": {
          "type": "integer",
          "description": "Start timestamp in milliseconds"
        },
        "end_timestamp": {
          "type": "integer",
          "description": "End timestamp in milliseconds"
        }
      },
      "required": [
        "instrument_id",
        "interval",
        "start_timestamp"
      ]
    },
    "headers": {
      "type": "object",
      "properties": {}
    }
  },
  "required": [
    "path",
    "query",
    "headers"
  ]
}
```

## Response fields
Source: Inferred from examples; not an exhaustive provider schema.
```json
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {}
    },
    "more": {
      "type": "boolean"
    }
  }
}
```

## Request example
Scenario: Documentation example
```bash
curl \
  'https://api.openany.si/v1/agent-apis/polymarket/v1/info/klines?end_timestamp=1793282423000&instrument_id=0&interval=1h&start_timestamp=1793278823000' \
  -X GET \
  -H "Authorization: Bearer $OPENANY_API_KEY" \
  -H 'Content-Type: application/json'
```

## Response example
Published documentation example. Verify the actual response after an approved call.
Sample response · Documented HTTP 200
```json
{
  "data": [],
  "more": false
}
```

## Error handling
400: Check the request fields.
401 / 403: Verify credentials and access permissions.
402: Inspect payment requirements and balance.
429: Respect returned retry guidance.
5xx: Inspect the error and usage record before retrying a paid operation.

## Available implementations
- Polymarket: https://openany.si/market/apis/polymarket/polymarket-get-klines/?offering=86a5d9e2-94a9-4593-afdc-cfb8c8360a28

Integration guide: https://openany.si/docs/
Agent setup: https://openany.si/SKILL.md
