Get builder trades
curl --request GET \
--url https://clob.polymarket.com/builder/tradesimport requests
url = "https://clob.polymarket.com/builder/trades"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://clob.polymarket.com/builder/trades', 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://clob.polymarket.com/builder/trades",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$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://clob.polymarket.com/builder/trades"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://clob.polymarket.com/builder/trades")
.asString();require 'uri'
require 'net/http'
url = URI("https://clob.polymarket.com/builder/trades")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"limit": 300,
"next_cursor": "MzAw",
"count": 2,
"data": [
{
"id": "trade-123",
"tradeType": "TAKER",
"takerOrderHash": "0xabcdef1234567890abcdef1234567890abcdef12",
"builder": "0x0000000000000000000000000000000000000000000000000000000000000001",
"market": "0x0000000000000000000000000000000000000000000000000000000000000001",
"assetId": "15871154585880608648532107628464183779895785213830018178010423617714102767076",
"side": "BUY",
"size": "100000000",
"sizeUsdc": "50000000",
"price": "0.5",
"status": "TRADE_STATUS_CONFIRMED",
"outcome": "YES",
"outcomeIndex": 0,
"owner": "f4f247b7-4ac7-ff29-a152-04fda0a8755a",
"maker": "0x1234567890123456789012345678901234567890",
"transactionHash": "0x1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef",
"matchTime": "1700000000",
"bucketIndex": 0,
"fee": "300000",
"feeUsdc": "150000",
"createdAt": "2024-01-01T00:00:00Z",
"updatedAt": "2024-01-01T00:00:00Z"
}
]
}{
"error": "invalid builder trade params"
}{
"error": "could not fetch builder trades"
}获取 Builder 交易
Retrieves trades attributed to a builder code.
GET
/
builder
/
trades
Get builder trades
curl --request GET \
--url https://clob.polymarket.com/builder/tradesimport requests
url = "https://clob.polymarket.com/builder/trades"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://clob.polymarket.com/builder/trades', 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://clob.polymarket.com/builder/trades",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$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://clob.polymarket.com/builder/trades"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://clob.polymarket.com/builder/trades")
.asString();require 'uri'
require 'net/http'
url = URI("https://clob.polymarket.com/builder/trades")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"limit": 300,
"next_cursor": "MzAw",
"count": 2,
"data": [
{
"id": "trade-123",
"tradeType": "TAKER",
"takerOrderHash": "0xabcdef1234567890abcdef1234567890abcdef12",
"builder": "0x0000000000000000000000000000000000000000000000000000000000000001",
"market": "0x0000000000000000000000000000000000000000000000000000000000000001",
"assetId": "15871154585880608648532107628464183779895785213830018178010423617714102767076",
"side": "BUY",
"size": "100000000",
"sizeUsdc": "50000000",
"price": "0.5",
"status": "TRADE_STATUS_CONFIRMED",
"outcome": "YES",
"outcomeIndex": 0,
"owner": "f4f247b7-4ac7-ff29-a152-04fda0a8755a",
"maker": "0x1234567890123456789012345678901234567890",
"transactionHash": "0x1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef",
"matchTime": "1700000000",
"bucketIndex": 0,
"fee": "300000",
"feeUsdc": "150000",
"createdAt": "2024-01-01T00:00:00Z",
"updatedAt": "2024-01-01T00:00:00Z"
}
]
}{
"error": "invalid builder trade params"
}{
"error": "could not fetch builder trades"
}查询参数
Builder code to fetch attributed trades for
Pattern:
^0x[a-fA-F0-9]{64}$Trade ID to filter by specific trade
Market (condition ID) to filter trades
Pattern:
^0x[a-fA-F0-9]{64}$Asset ID (token ID) to filter trades
Filter trades before this Unix timestamp
Pattern:
^\d+$Filter trades after this Unix timestamp
Pattern:
^\d+$Cursor for pagination (base64 encoded offset)
响应
Successfully retrieved builder trades
Paginated builder trades response
此页面对您有帮助吗?
⌘I