Skip to main content

API Documentation

Programmatic access to Polymarket market data and analytics

REST API
JSON Response
Rate Limited

Introduction

The Polymarket Monitor API provides programmatic access to real-time market data, analytics, and insights. Perfect for building trading bots, dashboards, or integrating market data into your applications.

Base URL:

https://auth.polymarketspro.com

Authentication

All API requests require authentication using a Bearer token. You can generate an API key from your account settings.

Header Format

Authorization: Bearer YOUR_API_KEY

Example Request

curl -H "Authorization: Bearer sk_live_1234..." \
     https://auth.polymarketspro.com/api/markets

Rate Limits

API rate limits depend on your subscription plan:

Free Plan

10,000

requests per month

Pro Plan

100,000

requests per month

Rate limit headers are included in all responses:

X-RateLimit-Limit: 100000
X-RateLimit-Remaining: 99523
X-RateLimit-Reset: 1704067200

API Endpoints

GET /api/markets

Retrieve a list of markets with optional filters and pagination.

Query Parameters

Parameter Type Description
limit integer Number of results (default: 20, max: 100)
offset integer Pagination offset (default: 0)
category string Filter by category
active boolean Filter active markets only
sort string Sort by: volume, liquidity, created_at

Example Response

{
  "success": true,
  "markets": [
    {
      "id": 1,
      "question": "Will Bitcoin reach $100,000 by end of 2024?",
      "slug": "bitcoin-100k-2024",
      "yes_price": 0.67,
      "no_price": 0.33,
      "volume": 1250000,
      "liquidity": 450000,
      "end_date": 1735689600,
      "category": "Crypto"
    }
  ],
  "count": 1,
  "total": 156
}
GET /api/market/:id

Get detailed information about a specific market, including historical data.

Path Parameters

id - Market ID or slug

Example Response

{
  "success": true,
  "market": {
    "id": 1,
    "question": "Will Bitcoin reach $100,000 by end of 2024?",
    "slug": "bitcoin-100k-2024",
    "yes_price": 0.67,
    "no_price": 0.33,
    "volume": 1250000,
    "liquidity": 450000,
    "holder_count": 1523,
    "spread": 0.02,
    "end_date": 1735689600,
    "history": [
      {
        "timestamp": 1704067200,
        "yes_price": 0.65,
        "volume": 1200000
      }
    ]
  }
}
GET /api/opportunities

Get identified trading opportunities based on our analytics.

Query Parameters

type string Filter by opportunity type
min_score integer Minimum opportunity score (0-100)
limit integer Number of results (default: 20)

Example Response

{
  "success": true,
  "opportunities": [
    {
      "id": 42,
      "market_id": 1,
      "type": "volume_spike",
      "score": 85,
      "detected_at": 1704067200,
      "question": "Will Bitcoin reach $100,000?",
      "yes_price": 0.67,
      "volume": 1250000
    }
  ],
  "count": 1
}
GET /api/user/watchlist

Get the authenticated user's watchlist.

🔒 Requires Authentication

Example Response

{
  "success": true,
  "watchlist": [
    {
      "id": 1,
      "question": "Will Bitcoin reach $100,000?",
      "yes_price": 0.67,
      "volume": 1250000
    }
  ],
  "count": 1
}
GET /api/user/alerts

Get user's price alerts and recommended opportunities.

🔒 Requires Authentication

Example Response

{
  "success": true,
  "user_alerts": [],
  "opportunities": [
    {
      "id": 42,
      "type": "volume_spike",
      "score": 85,
      "question": "Will Bitcoin reach $100,000?"
    }
  ]
}

Error Codes

The API uses standard HTTP status codes:

200 OK Request successful
400 Bad Request Invalid parameters
401 Unauthorized Invalid or missing API key
429 Too Many Requests Rate limit exceeded
500 Internal Server Error Server error

Error Response Format

{
  "success": false,
  "error": "Invalid API key",
  "code": "UNAUTHORIZED"
}

Code Examples

cURL

# Get all markets
curl -H "Authorization: Bearer YOUR_API_KEY" \
     https://auth.polymarketspro.com/api/markets?limit=10

# Get specific market
curl -H "Authorization: Bearer YOUR_API_KEY" \
     https://auth.polymarketspro.com/api/market/1

# Get opportunities
curl -H "Authorization: Bearer YOUR_API_KEY" \
     https://auth.polymarketspro.com/api/opportunities?min_score=70

Python

import requests

API_KEY = "YOUR_API_KEY"
BASE_URL = "https://auth.polymarketspro.com"

headers = {
    "Authorization": f"Bearer {API_KEY}"
}

# Get markets
response = requests.get(
    f"{BASE_URL}/api/markets",
    headers=headers,
    params={"limit": 10, "sort": "volume"}
)

markets = response.json()
print(f"Found {markets['count']} markets")

# Get opportunities
response = requests.get(
    f"{BASE_URL}/api/opportunities",
    headers=headers,
    params={"min_score": 70}
)

opportunities = response.json()
for opp in opportunities['opportunities']:
    print(f"{opp['type']}: {opp['question']} (Score: {opp['score']})")

JavaScript (Node.js)

const axios = require('axios');

const API_KEY = 'YOUR_API_KEY';
const BASE_URL = 'https://auth.polymarketspro.com';

const headers = {
  'Authorization': `Bearer ${API_KEY}`
};

// Get markets
async function getMarkets() {
  const response = await axios.get(`${BASE_URL}/api/markets`, {
    headers,
    params: { limit: 10, sort: 'volume' }
  });

  console.log(`Found ${response.data.count} markets`);
  return response.data.markets;
}

// Get opportunities
async function getOpportunities() {
  const response = await axios.get(`${BASE_URL}/api/opportunities`, {
    headers,
    params: { min_score: 70 }
  });

  return response.data.opportunities;
}

getMarkets().then(markets => {
  console.log(markets);
});

Need Help?

If you have questions about the API or need assistance, we're here to help: