Getting Started

Setup & Authentication

This Prediction Markets API is powered by SportsGameOdds.com. When you sign up, your account and API key are managed through SportsGameOdds.

There are only two things you need to get started — an API key and a way to make requests.

Base URL

https://api.sportsgameodds.com/v2

API Key

  • Get an API key from the pricing page. Required on every request.
  • We offer a free plan — no credit card required to start.
  • Your key will be emailed to you after sign-up. Check spam if it hasn't arrived within a few minutes.
  • Keep your key secret. Never expose it in frontend code or commit it to version control.
  • Pass it via the x-api-key header or the apiKey query parameter.

Making Requests in Code

Replace YOUR_API_KEY with your actual key.

JavaScript

fetch("https://api.sportsgameodds.com/v2/events?bookmakerID=kalshi,polymarket&oddsAvailable=true&limit=5", {
  headers: { "x-api-key": "YOUR_API_KEY" },
})
  .then((res) => res.json())
  .then((data) => console.log(data));

Python

import requests

response = requests.get(
    "https://api.sportsgameodds.com/v2/events",
    headers={"x-api-key": "YOUR_API_KEY"},
    params={
        "bookmakerID": "kalshi,polymarket",
        "oddsAvailable": "true",
        "limit": 5
    }
)
print(response.json())

Go

package main

import (
    "fmt"
    "io"
    "net/http"
)

func main() {
    req, _ := http.NewRequest("GET",
        "https://api.sportsgameodds.com/v2/events?bookmakerID=kalshi,polymarket&oddsAvailable=true&limit=5",
        nil,
    )
    req.Header.Set("x-api-key", "YOUR_API_KEY")

    resp, _ := http.DefaultClient.Do(req)
    defer resp.Body.Close()
    body, _ := io.ReadAll(resp.Body)
    fmt.Println(string(body))
}

Java

URL url = new URL(
    "https://api.sportsgameodds.com/v2/events?bookmakerID=kalshi,polymarket&oddsAvailable=true&limit=5"
);
HttpURLConnection conn = (HttpURLConnection) url.openConnection();
conn.setRequestMethod("GET");
conn.setRequestProperty("x-api-key", "YOUR_API_KEY");

BufferedReader in = new BufferedReader(new InputStreamReader(conn.getInputStream()));
String line;
StringBuilder content = new StringBuilder();
while ((line = in.readLine()) != null) content.append(line);
in.close();
System.out.println(content.toString());

Using the apiKey Query Parameter

You can also authenticate via the apiKey query parameter — useful for quick browser tests:

https://api.sportsgameodds.com/v2/events?apiKey=YOUR_API_KEY&bookmakerID=kalshi&oddsAvailable=true&limit=5

Never use the query parameter method in production code — it risks exposing your key in logs and browser history. Use the x-api-key header instead.