List Polymarket Markets
curl --request GET \
--url https://api.entityml.com/api/v1/polymarket/market/list \
--header 'Authorization: <authorization>'import requests
url = "https://api.entityml.com/api/v1/polymarket/market/list"
headers = {"Authorization": "<authorization>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: '<authorization>'}};
fetch('https://api.entityml.com/api/v1/polymarket/market/list', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.entityml.com/api/v1/polymarket/market/list",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: <authorization>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.entityml.com/api/v1/polymarket/market/list"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "<authorization>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.entityml.com/api/v1/polymarket/market/list")
.header("Authorization", "<authorization>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.entityml.com/api/v1/polymarket/market/list")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = '<authorization>'
response = http.request(request)
puts response.read_body{
"total_markets": 123,
"returned_count": 123,
"filter_prefix": "<string>",
"market_condition_ids": [
{}
],
"pagination": {}
}Polymarket
List Polymarket Markets
List stored Polymarket market condition IDs from the backing S3 inventory.
GET
/
api
/
v1
/
polymarket
/
market
/
list
List Polymarket Markets
curl --request GET \
--url https://api.entityml.com/api/v1/polymarket/market/list \
--header 'Authorization: <authorization>'import requests
url = "https://api.entityml.com/api/v1/polymarket/market/list"
headers = {"Authorization": "<authorization>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: '<authorization>'}};
fetch('https://api.entityml.com/api/v1/polymarket/market/list', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.entityml.com/api/v1/polymarket/market/list",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: <authorization>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.entityml.com/api/v1/polymarket/market/list"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "<authorization>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.entityml.com/api/v1/polymarket/market/list")
.header("Authorization", "<authorization>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.entityml.com/api/v1/polymarket/market/list")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = '<authorization>'
response = http.request(request)
puts response.read_body{
"total_markets": 123,
"returned_count": 123,
"filter_prefix": "<string>",
"market_condition_ids": [
{}
],
"pagination": {}
}Request
Headers
string
required
Bearer token. Example:
Bearer YOUR_API_KEYQuery Parameters
string
Optional condition ID prefix filter. Values are accepted with or without the
0x prefix. Example: 0x8213.integer
Number of markets to skip. Default:
0.integer
Maximum number of markets to return. Default:
100. Max: 1000.Response
integer
Total number of stored Polymarket markets after applying the optional prefix filter.
integer
Number of market IDs returned in this page.
string
The normalized prefix filter that was applied, if any.
array
Array of stored Polymarket market condition IDs.
object
Standard pagination metadata with
offset, limit, total_count, and has_more.Each successful call to this endpoint counts as 1 API request.
Example
curl -H "Authorization: Bearer YOUR_API_KEY" \
"https://api.entityml.com/api/v1/polymarket/market/list?prefix=0x8213&offset=0&limit=5"
import os
import requests
response = requests.get(
"https://api.entityml.com/api/v1/polymarket/market/list",
headers={"Authorization": f"Bearer {os.environ['ENTITY_API_KEY']}"},
params={"prefix": "0x8213", "offset": 0, "limit": 5},
)
print(response.json())
Example response
{
"total_markets": 1,
"returned_count": 1,
"filter_prefix": "0x8213",
"market_condition_ids": [
"0x8213d395e079614d6c4d7f4cbb9be9337ab51648a21cc2a334ae8f1966d164b4"
],
"pagination": {
"offset": 0,
"limit": 5,
"total_count": 1,
"has_more": false
}
}