@structbuild/sdk 0.5.6 → 0.5.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/generated/polymarket.d.ts +918 -865
- package/dist/generated/webhooks.d.ts +34 -0
- package/dist/generated/ws-alerts.d.ts +43 -1
- package/dist/generated/ws.d.ts +51 -1
- package/dist/index.cjs +22 -9
- package/dist/index.cjs.map +3 -3
- package/dist/index.js +4 -1
- package/dist/index.js.map +3 -3
- package/dist/namespaces/assets.d.ts +2 -1
- package/dist/types/index.d.ts +10 -0
- package/package.json +9 -1
|
@@ -103,6 +103,26 @@ export interface paths {
|
|
|
103
103
|
patch?: never;
|
|
104
104
|
trace?: never;
|
|
105
105
|
};
|
|
106
|
+
"/polymarket/asset-history/candlestick": {
|
|
107
|
+
parameters: {
|
|
108
|
+
query?: never;
|
|
109
|
+
header?: never;
|
|
110
|
+
path?: never;
|
|
111
|
+
cookie?: never;
|
|
112
|
+
};
|
|
113
|
+
/**
|
|
114
|
+
* Get OHLC candles for a crypto asset
|
|
115
|
+
* @description Retrieve OHLC candlestick data for a single crypto asset at the requested resolution.
|
|
116
|
+
*/
|
|
117
|
+
get: operations["get_asset_candlestick"];
|
|
118
|
+
put?: never;
|
|
119
|
+
post?: never;
|
|
120
|
+
delete?: never;
|
|
121
|
+
options?: never;
|
|
122
|
+
head?: never;
|
|
123
|
+
patch?: never;
|
|
124
|
+
trace?: never;
|
|
125
|
+
};
|
|
106
126
|
"/polymarket/builders": {
|
|
107
127
|
parameters: {
|
|
108
128
|
query?: never;
|
|
@@ -1363,7 +1383,7 @@ export interface paths {
|
|
|
1363
1383
|
};
|
|
1364
1384
|
/**
|
|
1365
1385
|
* Get tag by slug
|
|
1366
|
-
* @description Retrieve a single tag by its ID or slug. Pass `include_metrics=true` to attach analytics metrics (volume_usd, txn_count, unique_traders, fees_usd) — adds +1 credit. Use `timeframe` to select the window; defaults to `1d`.
|
|
1386
|
+
* @description Retrieve a single tag by its ID or slug. Pass `include_metrics=true` to attach analytics metrics (volume_usd, shares_volume, txn_count, unique_traders, unique_makers, unique_takers, fees_usd, and builder metrics) — adds +1 credit. Use `timeframe` to select the window; defaults to `1d`.
|
|
1367
1387
|
*/
|
|
1368
1388
|
get: operations["get_tag_by_id"];
|
|
1369
1389
|
put?: never;
|
|
@@ -1746,44 +1766,100 @@ export interface components {
|
|
|
1746
1766
|
* @enum {string}
|
|
1747
1767
|
*/
|
|
1748
1768
|
AnalyticsResolution: "60" | "240" | "D" | "1D" | "W" | "1W" | "M" | "1M";
|
|
1749
|
-
/** @
|
|
1750
|
-
|
|
1751
|
-
|
|
1752
|
-
* @description Sort metric for the trader → builders list.
|
|
1753
|
-
* @enum {string}
|
|
1754
|
-
*/
|
|
1755
|
-
TraderBuilderSortBy: "volume" | "txns" | "fees";
|
|
1756
|
-
/** @description Output payload for Split trades (deposit collateral → receive outcome tokens). */
|
|
1757
|
-
SplitTrade: {
|
|
1758
|
-
id: string;
|
|
1759
|
-
hash: string;
|
|
1769
|
+
/** @description One builder's stats under a single tag. */
|
|
1770
|
+
TagBuilderRow: {
|
|
1771
|
+
builder_code: string;
|
|
1760
1772
|
/** Format: int64 */
|
|
1761
|
-
block
|
|
1773
|
+
block: number;
|
|
1774
|
+
/** Format: int32 */
|
|
1775
|
+
ts: number;
|
|
1776
|
+
/** Format: double */
|
|
1777
|
+
volume_usd: number;
|
|
1778
|
+
/** Format: double */
|
|
1779
|
+
buy_volume_usd: number;
|
|
1780
|
+
/** Format: double */
|
|
1781
|
+
sell_volume_usd: number;
|
|
1762
1782
|
/** Format: int64 */
|
|
1763
|
-
|
|
1783
|
+
unique_traders: number;
|
|
1764
1784
|
/** Format: int64 */
|
|
1765
|
-
|
|
1785
|
+
unique_makers: number;
|
|
1766
1786
|
/** Format: int64 */
|
|
1767
|
-
|
|
1787
|
+
unique_takers: number;
|
|
1768
1788
|
/** Format: int64 */
|
|
1769
|
-
|
|
1770
|
-
|
|
1771
|
-
|
|
1772
|
-
|
|
1773
|
-
|
|
1774
|
-
slug?: string | null;
|
|
1775
|
-
event_slug?: string | null;
|
|
1789
|
+
txn_count: number;
|
|
1790
|
+
/** Format: int64 */
|
|
1791
|
+
buy_count: number;
|
|
1792
|
+
/** Format: int64 */
|
|
1793
|
+
sell_count: number;
|
|
1776
1794
|
/** Format: double */
|
|
1777
|
-
|
|
1778
|
-
/**
|
|
1779
|
-
|
|
1780
|
-
|
|
1795
|
+
fees_usd: number;
|
|
1796
|
+
/** Format: double */
|
|
1797
|
+
builder_fees: number;
|
|
1798
|
+
/** Format: double */
|
|
1799
|
+
shares_volume: number;
|
|
1800
|
+
/** Format: double */
|
|
1801
|
+
yes_volume_usd: number;
|
|
1802
|
+
/** Format: double */
|
|
1803
|
+
no_volume_usd: number;
|
|
1804
|
+
/** Format: int64 */
|
|
1805
|
+
yes_count: number;
|
|
1806
|
+
/** Format: int64 */
|
|
1807
|
+
no_count: number;
|
|
1808
|
+
/** Format: int64 */
|
|
1809
|
+
buy_dist_under_10: number;
|
|
1810
|
+
/** Format: int64 */
|
|
1811
|
+
buy_dist_10_100: number;
|
|
1812
|
+
/** Format: int64 */
|
|
1813
|
+
buy_dist_100_1k: number;
|
|
1814
|
+
/** Format: int64 */
|
|
1815
|
+
buy_dist_1k_10k: number;
|
|
1816
|
+
/** Format: int64 */
|
|
1817
|
+
buy_dist_10k_50k: number;
|
|
1818
|
+
/** Format: int64 */
|
|
1819
|
+
buy_dist_50k_plus: number;
|
|
1820
|
+
/** Format: int64 */
|
|
1821
|
+
new_users: number;
|
|
1822
|
+
/** Format: double */
|
|
1823
|
+
avg_rev_per_user: number;
|
|
1824
|
+
/** Format: double */
|
|
1825
|
+
avg_vol_per_user: number;
|
|
1781
1826
|
};
|
|
1782
1827
|
/**
|
|
1783
|
-
* @description
|
|
1784
|
-
*
|
|
1828
|
+
* @description One bucket of derived order-book metrics for a position at a point in time.
|
|
1829
|
+
* Only summary metrics are returned — the underlying bid/ask ladders are
|
|
1830
|
+
* available from the snapshot endpoint.
|
|
1785
1831
|
*/
|
|
1786
|
-
|
|
1832
|
+
SpreadRow: {
|
|
1833
|
+
/** Format: int64 */
|
|
1834
|
+
ts: number;
|
|
1835
|
+
position_id: string;
|
|
1836
|
+
condition_id: string;
|
|
1837
|
+
/** Format: double */
|
|
1838
|
+
best_bid?: number | null;
|
|
1839
|
+
/** Format: double */
|
|
1840
|
+
best_ask?: number | null;
|
|
1841
|
+
/** Format: double */
|
|
1842
|
+
mid_price?: number | null;
|
|
1843
|
+
/** Format: double */
|
|
1844
|
+
spread?: number | null;
|
|
1845
|
+
/** Format: double */
|
|
1846
|
+
bid_liquidity_usd?: number | null;
|
|
1847
|
+
/** Format: double */
|
|
1848
|
+
ask_liquidity_usd?: number | null;
|
|
1849
|
+
/** Format: int32 */
|
|
1850
|
+
bid_levels?: number | null;
|
|
1851
|
+
/** Format: int32 */
|
|
1852
|
+
ask_levels?: number | null;
|
|
1853
|
+
};
|
|
1854
|
+
/** @enum {string} */
|
|
1855
|
+
TagChangeTimeframe: "1h" | "24h" | "7d" | "30d" | "1mo";
|
|
1856
|
+
/**
|
|
1857
|
+
* @description `TagBuilderRow` with builder display metadata (name, icon, links) merged
|
|
1858
|
+
* onto each row. Returned by `/polymarket/builders/tags/{tag}`.
|
|
1859
|
+
*/
|
|
1860
|
+
TagBuilderRowWithMetadata: components["schemas"]["TagBuilderRow"] & {
|
|
1861
|
+
metadata?: null | components["schemas"]["BuilderMetadataInline"];
|
|
1862
|
+
};
|
|
1787
1863
|
/** @description V3 UMA OOv3: an assertion was disputed. */
|
|
1788
1864
|
AssertionDisputedEvent: {
|
|
1789
1865
|
id: string;
|
|
@@ -1868,17 +1944,29 @@ export interface components {
|
|
|
1868
1944
|
slug?: string | null;
|
|
1869
1945
|
event_slug?: string | null;
|
|
1870
1946
|
};
|
|
1871
|
-
|
|
1947
|
+
AssetCandlestickBar: {
|
|
1948
|
+
/** Format: double */
|
|
1949
|
+
l?: number | null;
|
|
1950
|
+
/** Format: double */
|
|
1951
|
+
h?: number | null;
|
|
1952
|
+
/** Format: double */
|
|
1953
|
+
o?: number | null;
|
|
1954
|
+
/** Format: double */
|
|
1955
|
+
c?: number | null;
|
|
1956
|
+
/** Format: int64 */
|
|
1957
|
+
t: number;
|
|
1958
|
+
};
|
|
1959
|
+
/** @description One bucket of an asset's price history at a fixed time-window resolution. */
|
|
1872
1960
|
AssetPriceHistoryRow: {
|
|
1873
1961
|
asset_symbol: string;
|
|
1874
1962
|
/**
|
|
1875
1963
|
* Format: double
|
|
1876
|
-
* @description Opening price at start_time
|
|
1964
|
+
* @description Opening price at `start_time`.
|
|
1877
1965
|
*/
|
|
1878
1966
|
asset_open_price: number;
|
|
1879
1967
|
/**
|
|
1880
1968
|
* Format: double
|
|
1881
|
-
* @description Closing price at end_time
|
|
1969
|
+
* @description Closing price at `end_time`.
|
|
1882
1970
|
*/
|
|
1883
1971
|
asset_close_price: number;
|
|
1884
1972
|
/** Format: double */
|
|
@@ -1902,29 +1990,14 @@ export interface components {
|
|
|
1902
1990
|
AssetSymbol: "BTC" | "ETH" | "XRP" | "SOL" | "DOGE" | "BNB" | "HYPE";
|
|
1903
1991
|
/** @enum {string} */
|
|
1904
1992
|
AssetVariant: "5m" | "15m" | "1h" | "4h" | "1d";
|
|
1905
|
-
/**
|
|
1906
|
-
|
|
1907
|
-
|
|
1908
|
-
|
|
1909
|
-
|
|
1910
|
-
|
|
1911
|
-
|
|
1912
|
-
|
|
1913
|
-
/** Format: double */
|
|
1914
|
-
best_ask?: number | null;
|
|
1915
|
-
/** Format: double */
|
|
1916
|
-
mid_price?: number | null;
|
|
1917
|
-
/** Format: double */
|
|
1918
|
-
spread?: number | null;
|
|
1919
|
-
/** Format: double */
|
|
1920
|
-
bid_liquidity_usd?: number | null;
|
|
1921
|
-
/** Format: double */
|
|
1922
|
-
ask_liquidity_usd?: number | null;
|
|
1923
|
-
/** Format: int32 */
|
|
1924
|
-
bid_levels?: number | null;
|
|
1925
|
-
/** Format: int32 */
|
|
1926
|
-
ask_levels?: number | null;
|
|
1927
|
-
};
|
|
1993
|
+
/**
|
|
1994
|
+
* @description Metric to order by when `sort=<value>` is provided.
|
|
1995
|
+
*
|
|
1996
|
+
* `unique_*` variants rank by the number of distinct wallet addresses
|
|
1997
|
+
* active in the selected timeframe.
|
|
1998
|
+
* @enum {string}
|
|
1999
|
+
*/
|
|
2000
|
+
TagSortBy: "volume" | "shares_volume" | "txns" | "unique_traders" | "unique_makers" | "unique_takers" | "fees";
|
|
1928
2001
|
BondMarket: {
|
|
1929
2002
|
condition_id: string;
|
|
1930
2003
|
title?: string | null;
|
|
@@ -1956,90 +2029,8 @@ export interface components {
|
|
|
1956
2029
|
};
|
|
1957
2030
|
/** @enum {string} */
|
|
1958
2031
|
BondsSortBy: "end_date" | "apy" | "liquidity" | "volume";
|
|
1959
|
-
/**
|
|
1960
|
-
|
|
1961
|
-
* at end of bucket) and `/analytics/deltas` (per-bucket deltas). All metrics
|
|
1962
|
-
* the snapshot `/counts` returns are included.
|
|
1963
|
-
*
|
|
1964
|
-
* Short field names for compact JSON responses:
|
|
1965
|
-
* t=bucket (unix seconds), v=volume_usd, bv=buy_volume_usd, sv=sell_volume_usd,
|
|
1966
|
-
* ut=unique_traders, um=unique_makers, uk=unique_takers,
|
|
1967
|
-
* tc=txn_count, bc=buy_count, sc=sell_count,
|
|
1968
|
-
* rc=redemption_count, rv=redemption_volume_usd, mc=merge_count, mv=merge_volume_usd,
|
|
1969
|
-
* sp=split_count, spv=split_volume_usd, f=fees_usd, sh=shares_volume,
|
|
1970
|
-
* yv=yes_volume_usd, nv=no_volume_usd, yc=yes_count, nc=no_count,
|
|
1971
|
-
* bd_*=buy distribution by USD bucket
|
|
1972
|
-
*/
|
|
1973
|
-
TimeBucketRow: {
|
|
1974
|
-
/** Format: int32 */
|
|
1975
|
-
t: number;
|
|
1976
|
-
/** Format: double */
|
|
1977
|
-
v: number;
|
|
1978
|
-
/** Format: double */
|
|
1979
|
-
bv: number;
|
|
1980
|
-
/** Format: double */
|
|
1981
|
-
sv: number;
|
|
1982
|
-
/** Format: int64 */
|
|
1983
|
-
tc: number;
|
|
1984
|
-
/** Format: int64 */
|
|
1985
|
-
bc: number;
|
|
1986
|
-
/** Format: int64 */
|
|
1987
|
-
sc: number;
|
|
1988
|
-
/** Format: int64 */
|
|
1989
|
-
rc: number;
|
|
1990
|
-
/** Format: double */
|
|
1991
|
-
rv: number;
|
|
1992
|
-
/** Format: int64 */
|
|
1993
|
-
mc: number;
|
|
1994
|
-
/** Format: double */
|
|
1995
|
-
mv: number;
|
|
1996
|
-
/** Format: int64 */
|
|
1997
|
-
sp: number;
|
|
1998
|
-
/** Format: double */
|
|
1999
|
-
spv: number;
|
|
2000
|
-
/** Format: double */
|
|
2001
|
-
f: number;
|
|
2002
|
-
/** Format: double */
|
|
2003
|
-
sh: number;
|
|
2004
|
-
/** Format: double */
|
|
2005
|
-
yv: number;
|
|
2006
|
-
/** Format: double */
|
|
2007
|
-
nv: number;
|
|
2008
|
-
/** Format: int64 */
|
|
2009
|
-
yc: number;
|
|
2010
|
-
/** Format: int64 */
|
|
2011
|
-
nc: number;
|
|
2012
|
-
/**
|
|
2013
|
-
* Format: int64
|
|
2014
|
-
* @description Buy distribution — count of buy trades falling in each USD bucket.
|
|
2015
|
-
*/
|
|
2016
|
-
bd_u10: number;
|
|
2017
|
-
/** Format: int64 */
|
|
2018
|
-
bd_100: number;
|
|
2019
|
-
/** Format: int64 */
|
|
2020
|
-
bd_1k: number;
|
|
2021
|
-
/** Format: int64 */
|
|
2022
|
-
bd_10k: number;
|
|
2023
|
-
/** Format: int64 */
|
|
2024
|
-
bd_50k: number;
|
|
2025
|
-
/** Format: int64 */
|
|
2026
|
-
bd_50p: number;
|
|
2027
|
-
/**
|
|
2028
|
-
* Format: int64
|
|
2029
|
-
* @description Distinct traders ACTIVE in this bucket (window-unique, not first-time).
|
|
2030
|
-
*/
|
|
2031
|
-
ut: number;
|
|
2032
|
-
/**
|
|
2033
|
-
* Format: int64
|
|
2034
|
-
* @description Distinct makers active in this bucket.
|
|
2035
|
-
*/
|
|
2036
|
-
um: number;
|
|
2037
|
-
/**
|
|
2038
|
-
* Format: int64
|
|
2039
|
-
* @description Distinct takers active in this bucket.
|
|
2040
|
-
*/
|
|
2041
|
-
uk: number;
|
|
2042
|
-
};
|
|
2032
|
+
/** @enum {string} */
|
|
2033
|
+
SortDirection: "asc" | "desc";
|
|
2043
2034
|
BuilderFeeRate: {
|
|
2044
2035
|
code: string;
|
|
2045
2036
|
/** Format: int32 */
|
|
@@ -2212,12 +2203,9 @@ export interface components {
|
|
|
2212
2203
|
builder_taker_fee_rate_bps: number;
|
|
2213
2204
|
};
|
|
2214
2205
|
/**
|
|
2215
|
-
* @description
|
|
2216
|
-
*
|
|
2217
|
-
*
|
|
2218
|
-
* data structure at runtime — the actual response is built by
|
|
2219
|
-
* `BuilderLatestRow` plus a JSON-level merge from the metadata cache, which
|
|
2220
|
-
* produces this exact shape.
|
|
2206
|
+
* @description Latest builder stats with builder display metadata (name, icon, links)
|
|
2207
|
+
* merged onto each row. Returned by endpoints that embed display metadata,
|
|
2208
|
+
* such as `/`, `/{builder_code}`, and `/tags/{tag}`.
|
|
2221
2209
|
*/
|
|
2222
2210
|
BuilderLatestRowWithMetadata: components["schemas"]["BuilderLatestRow"] & {
|
|
2223
2211
|
metadata?: null | components["schemas"]["BuilderMetadataInline"];
|
|
@@ -2306,25 +2294,34 @@ export interface components {
|
|
|
2306
2294
|
avg_vol_per_user: number;
|
|
2307
2295
|
};
|
|
2308
2296
|
/**
|
|
2309
|
-
* @description
|
|
2310
|
-
*
|
|
2311
|
-
*
|
|
2312
|
-
*
|
|
2313
|
-
* Used in:
|
|
2314
|
-
* - holders endpoints (market/event holders)
|
|
2315
|
-
* - trades endpoints
|
|
2316
|
-
* - leaderboard endpoints
|
|
2297
|
+
* @description Market metadata for the market a trader's best / worst trade landed in.
|
|
2298
|
+
* Accompanies the existing flat `best_trade_pnl_usd` / `worst_trade_pnl_usd`
|
|
2299
|
+
* numerics on trader / event / category PnL summaries.
|
|
2317
2300
|
*/
|
|
2318
|
-
|
|
2319
|
-
|
|
2301
|
+
TradeMarketRef: {
|
|
2302
|
+
condition_id?: string | null;
|
|
2303
|
+
market_slug?: string | null;
|
|
2304
|
+
title?: string | null;
|
|
2305
|
+
question?: string | null;
|
|
2306
|
+
image_url?: string | null;
|
|
2307
|
+
event_slug?: string | null;
|
|
2308
|
+
};
|
|
2309
|
+
/**
|
|
2310
|
+
* @description Trader profile info embedded in API responses.
|
|
2311
|
+
*
|
|
2312
|
+
* Used in:
|
|
2313
|
+
* - holders endpoints (market/event holders)
|
|
2314
|
+
* - trades endpoints
|
|
2315
|
+
* - leaderboard endpoints
|
|
2316
|
+
*/
|
|
2317
|
+
Trader: {
|
|
2318
|
+
address: string;
|
|
2320
2319
|
name?: string | null;
|
|
2321
2320
|
pseudonym?: string | null;
|
|
2322
2321
|
profile_image?: string | null;
|
|
2323
2322
|
x_username?: string | null;
|
|
2324
2323
|
verified_badge?: boolean;
|
|
2325
2324
|
};
|
|
2326
|
-
/** @enum {string} */
|
|
2327
|
-
TradeType: "0" | "1" | "2" | "3" | "4" | "5" | "6" | "22" | "23" | "24";
|
|
2328
2325
|
/**
|
|
2329
2326
|
* @description Sort metric for the builders list endpoint.
|
|
2330
2327
|
* @enum {string}
|
|
@@ -2478,85 +2475,49 @@ export interface components {
|
|
|
2478
2475
|
* @enum {string}
|
|
2479
2476
|
*/
|
|
2480
2477
|
BuilderTimeframe: "lifetime" | "1d" | "7d" | "30d";
|
|
2481
|
-
/**
|
|
2482
|
-
|
|
2483
|
-
|
|
2484
|
-
|
|
2485
|
-
|
|
2486
|
-
|
|
2487
|
-
|
|
2488
|
-
|
|
2489
|
-
|
|
2490
|
-
|
|
2491
|
-
|
|
2492
|
-
|
|
2493
|
-
|
|
2494
|
-
|
|
2495
|
-
/**
|
|
2496
|
-
|
|
2497
|
-
|
|
2498
|
-
|
|
2499
|
-
|
|
2500
|
-
|
|
2501
|
-
/**
|
|
2502
|
-
|
|
2503
|
-
|
|
2504
|
-
|
|
2505
|
-
|
|
2506
|
-
|
|
2507
|
-
/**
|
|
2508
|
-
|
|
2509
|
-
|
|
2510
|
-
|
|
2511
|
-
|
|
2512
|
-
|
|
2513
|
-
/**
|
|
2514
|
-
|
|
2515
|
-
|
|
2516
|
-
|
|
2517
|
-
|
|
2518
|
-
|
|
2519
|
-
/**
|
|
2520
|
-
|
|
2521
|
-
|
|
2522
|
-
|
|
2523
|
-
|
|
2524
|
-
}) | (components["schemas"]["AssertionSettledEvent"] & {
|
|
2525
|
-
/** @enum {string} */
|
|
2526
|
-
trade_type: "Settled";
|
|
2527
|
-
}) | (components["schemas"]["QuestionResolvedEvent"] & {
|
|
2528
|
-
/** @enum {string} */
|
|
2529
|
-
trade_type: "Resolution";
|
|
2530
|
-
}) | (components["schemas"]["ConditionResolutionEvent"] & {
|
|
2531
|
-
/** @enum {string} */
|
|
2532
|
-
trade_type: "ConditionResolution";
|
|
2533
|
-
}) | (components["schemas"]["QuestionResetEvent"] & {
|
|
2534
|
-
/** @enum {string} */
|
|
2535
|
-
trade_type: "Reset";
|
|
2536
|
-
}) | (components["schemas"]["QuestionFlaggedEvent"] & {
|
|
2537
|
-
/** @enum {string} */
|
|
2538
|
-
trade_type: "Flag";
|
|
2539
|
-
}) | (components["schemas"]["QuestionUnflaggedEvent"] & {
|
|
2540
|
-
/** @enum {string} */
|
|
2541
|
-
trade_type: "Unflag";
|
|
2542
|
-
}) | (components["schemas"]["QuestionPausedEvent"] & {
|
|
2543
|
-
/** @enum {string} */
|
|
2544
|
-
trade_type: "Pause";
|
|
2545
|
-
}) | (components["schemas"]["QuestionUnpausedEvent"] & {
|
|
2546
|
-
/** @enum {string} */
|
|
2547
|
-
trade_type: "Unpause";
|
|
2548
|
-
}) | (components["schemas"]["QuestionEmergencyResolvedEvent"] & {
|
|
2549
|
-
/** @enum {string} */
|
|
2550
|
-
trade_type: "ManualResolution";
|
|
2551
|
-
}) | (components["schemas"]["NegRiskOutcomeReportedEvent"] & {
|
|
2552
|
-
/** @enum {string} */
|
|
2553
|
-
trade_type: "NegRiskOutcomeReported";
|
|
2554
|
-
}) | (components["schemas"]["RegisterTokenTrade"] & {
|
|
2555
|
-
/** @enum {string} */
|
|
2556
|
-
trade_type: "RegisterToken";
|
|
2557
|
-
});
|
|
2558
|
-
/** @enum {string} */
|
|
2559
|
-
TradeSide: "0" | "1";
|
|
2478
|
+
/** @description Token outcome (position) */
|
|
2479
|
+
TokenOutcome: {
|
|
2480
|
+
token_id: string;
|
|
2481
|
+
outcome: string;
|
|
2482
|
+
};
|
|
2483
|
+
/** @description Market-level PnL entry */
|
|
2484
|
+
TraderMarketPnlEntry: {
|
|
2485
|
+
condition_id?: string | null;
|
|
2486
|
+
market_slug?: string | null;
|
|
2487
|
+
event_slug?: string | null;
|
|
2488
|
+
question?: string | null;
|
|
2489
|
+
image_url?: string | null;
|
|
2490
|
+
/** Format: int64 */
|
|
2491
|
+
outcomes_traded?: number | null;
|
|
2492
|
+
/** Format: int64 */
|
|
2493
|
+
total_buys?: number | null;
|
|
2494
|
+
/** Format: int64 */
|
|
2495
|
+
total_sells?: number | null;
|
|
2496
|
+
/** Format: int64 */
|
|
2497
|
+
total_redemptions?: number | null;
|
|
2498
|
+
/** Format: int64 */
|
|
2499
|
+
total_merges?: number | null;
|
|
2500
|
+
/** Format: double */
|
|
2501
|
+
buy_usd?: number | null;
|
|
2502
|
+
/** Format: double */
|
|
2503
|
+
sell_usd?: number | null;
|
|
2504
|
+
/** Format: double */
|
|
2505
|
+
redemption_usd?: number | null;
|
|
2506
|
+
/** Format: double */
|
|
2507
|
+
merge_usd?: number | null;
|
|
2508
|
+
/** Format: double */
|
|
2509
|
+
realized_pnl_usd?: number | null;
|
|
2510
|
+
/** Format: int64 */
|
|
2511
|
+
winning_outcomes?: number | null;
|
|
2512
|
+
/** Format: double */
|
|
2513
|
+
total_fees?: number | null;
|
|
2514
|
+
/** Format: int64 */
|
|
2515
|
+
first_trade_at?: number | null;
|
|
2516
|
+
/** Format: int64 */
|
|
2517
|
+
last_trade_at?: number | null;
|
|
2518
|
+
/** Format: double */
|
|
2519
|
+
realized_pnl_pct?: number | null;
|
|
2520
|
+
};
|
|
2560
2521
|
/** @description Output payload for Cancelled orders. */
|
|
2561
2522
|
CancelledTrade: {
|
|
2562
2523
|
id: string;
|
|
@@ -2587,77 +2548,96 @@ export interface components {
|
|
|
2587
2548
|
ChangeTimeframe: "1h" | "24h" | "7d" | "30d" | "1mo" | "1y";
|
|
2588
2549
|
/** @enum {string} */
|
|
2589
2550
|
ChartResolution: "1H" | "6H" | "1D" | "1W" | "1M" | "ALL";
|
|
2590
|
-
|
|
2591
|
-
trader:
|
|
2592
|
-
/** Format: double */
|
|
2593
|
-
realized_pnl_usd?: number | null;
|
|
2594
|
-
/** Format: double */
|
|
2595
|
-
realized_pnl_pct?: number | null;
|
|
2596
|
-
/** Format: double */
|
|
2597
|
-
buy_usd?: number | null;
|
|
2598
|
-
/** Format: double */
|
|
2599
|
-
sell_usd?: number | null;
|
|
2551
|
+
TopTraderRow: {
|
|
2552
|
+
trader: string;
|
|
2600
2553
|
/** Format: double */
|
|
2601
|
-
|
|
2554
|
+
volume_usd: number;
|
|
2555
|
+
/** Format: int64 */
|
|
2556
|
+
txn_count: number;
|
|
2602
2557
|
/** Format: double */
|
|
2603
|
-
|
|
2558
|
+
fees_usd: number;
|
|
2604
2559
|
/** Format: double */
|
|
2605
|
-
|
|
2560
|
+
builder_fees: number;
|
|
2561
|
+
};
|
|
2562
|
+
/** @description Trader profile info - backwards compatibility */
|
|
2563
|
+
TraderInfo: {
|
|
2564
|
+
address: string;
|
|
2565
|
+
name?: string | null;
|
|
2566
|
+
pseudonym?: string | null;
|
|
2567
|
+
profile_image?: string | null;
|
|
2568
|
+
x_username?: string | null;
|
|
2569
|
+
verified_badge?: boolean;
|
|
2570
|
+
};
|
|
2571
|
+
/** @description Outcome-level PnL entry (per outcome token / position_id) */
|
|
2572
|
+
TraderOutcomePnlEntry: {
|
|
2573
|
+
position_id?: string | null;
|
|
2574
|
+
condition_id?: string | null;
|
|
2575
|
+
market_slug?: string | null;
|
|
2576
|
+
event_slug?: string | null;
|
|
2577
|
+
title?: string | null;
|
|
2578
|
+
image_url?: string | null;
|
|
2579
|
+
outcome?: string | null;
|
|
2580
|
+
/** Format: int32 */
|
|
2581
|
+
outcome_index?: number | null;
|
|
2582
|
+
/** @description TRUE = won, FALSE = lost, NULL = open or sold before resolution */
|
|
2583
|
+
won?: boolean | null;
|
|
2606
2584
|
/** Format: int64 */
|
|
2607
2585
|
total_buys?: number | null;
|
|
2608
2586
|
/** Format: int64 */
|
|
2609
2587
|
total_sells?: number | null;
|
|
2610
|
-
/** Format: int64 */
|
|
2611
|
-
total_redemptions?: number | null;
|
|
2612
|
-
/** Format: int64 */
|
|
2613
|
-
total_merges?: number | null;
|
|
2614
|
-
/** Format: int64 */
|
|
2615
|
-
outcomes_traded?: number | null;
|
|
2616
|
-
/** Format: int64 */
|
|
2617
|
-
winning_outcomes?: number | null;
|
|
2618
|
-
/** Format: int64 */
|
|
2619
|
-
first_trade_at?: number | null;
|
|
2620
|
-
/** Format: int64 */
|
|
2621
|
-
last_trade_at?: number | null;
|
|
2622
|
-
};
|
|
2623
|
-
TopTraderPositionEntry: {
|
|
2624
|
-
trader: components["schemas"]["TraderInfo"];
|
|
2625
2588
|
/** Format: double */
|
|
2626
|
-
|
|
2627
|
-
/** Format: double */
|
|
2628
|
-
realized_pnl_pct?: number | null;
|
|
2629
|
-
/** Format: double */
|
|
2630
|
-
shares?: number | null;
|
|
2589
|
+
total_shares_bought?: number | null;
|
|
2631
2590
|
/** Format: double */
|
|
2632
|
-
|
|
2591
|
+
total_shares_sold?: number | null;
|
|
2633
2592
|
/** Format: double */
|
|
2634
|
-
|
|
2593
|
+
total_buy_usd?: number | null;
|
|
2635
2594
|
/** Format: double */
|
|
2595
|
+
total_sell_usd?: number | null;
|
|
2596
|
+
/**
|
|
2597
|
+
* Format: double
|
|
2598
|
+
* @description Payout on redemption (non-zero only if won)
|
|
2599
|
+
*/
|
|
2636
2600
|
redemption_usd?: number | null;
|
|
2637
|
-
/**
|
|
2638
|
-
|
|
2639
|
-
|
|
2601
|
+
/**
|
|
2602
|
+
* Format: double
|
|
2603
|
+
* @description VWAP price paid per share across all buys (0–1)
|
|
2604
|
+
*/
|
|
2640
2605
|
avg_entry_price?: number | null;
|
|
2641
|
-
/**
|
|
2606
|
+
/**
|
|
2607
|
+
* Format: double
|
|
2608
|
+
* @description VWAP price received per share across all sells (0–1)
|
|
2609
|
+
*/
|
|
2642
2610
|
avg_exit_price?: number | null;
|
|
2643
|
-
/** Format:
|
|
2644
|
-
|
|
2645
|
-
/** Format:
|
|
2646
|
-
|
|
2647
|
-
won?: boolean | null;
|
|
2611
|
+
/** Format: double */
|
|
2612
|
+
realized_pnl_usd?: number | null;
|
|
2613
|
+
/** Format: double */
|
|
2614
|
+
total_fees?: number | null;
|
|
2648
2615
|
/** Format: int64 */
|
|
2649
2616
|
first_trade_at?: number | null;
|
|
2650
2617
|
/** Format: int64 */
|
|
2651
2618
|
last_trade_at?: number | null;
|
|
2652
|
-
|
|
2653
|
-
|
|
2654
|
-
|
|
2655
|
-
|
|
2656
|
-
|
|
2657
|
-
|
|
2658
|
-
|
|
2659
|
-
|
|
2660
|
-
|
|
2619
|
+
/**
|
|
2620
|
+
* Format: double
|
|
2621
|
+
* @description Last traded price for this outcome (0–1). NULL if market_outcomes has no price yet.
|
|
2622
|
+
*/
|
|
2623
|
+
current_price?: number | null;
|
|
2624
|
+
/**
|
|
2625
|
+
* Format: double
|
|
2626
|
+
* @description Current shares held: balance / 1e6.
|
|
2627
|
+
*/
|
|
2628
|
+
current_shares_balance?: number | null;
|
|
2629
|
+
/**
|
|
2630
|
+
* Format: double
|
|
2631
|
+
* @description Estimated current USD value of held shares: (balance / 1e6) * current_price.
|
|
2632
|
+
* Only meaningful for open positions (balance above dust threshold).
|
|
2633
|
+
*/
|
|
2634
|
+
current_value?: number | null;
|
|
2635
|
+
/**
|
|
2636
|
+
* Format: double
|
|
2637
|
+
* @description Realized PnL as a percentage of total spend: (realized_pnl_usd / total_buy_usd) * 100.
|
|
2638
|
+
* NULL when total_buy_usd = 0.
|
|
2639
|
+
*/
|
|
2640
|
+
realized_pnl_pct?: number | null;
|
|
2661
2641
|
};
|
|
2662
2642
|
/** @description CLOB reward (public API format) */
|
|
2663
2643
|
ClobReward: {
|
|
@@ -2881,6 +2861,10 @@ export interface components {
|
|
|
2881
2861
|
/** Format: int32 */
|
|
2882
2862
|
unique_traders: number;
|
|
2883
2863
|
/** Format: int32 */
|
|
2864
|
+
unique_makers: number;
|
|
2865
|
+
/** Format: int32 */
|
|
2866
|
+
unique_takers: number;
|
|
2867
|
+
/** Format: int32 */
|
|
2884
2868
|
unique_builder_traders: number;
|
|
2885
2869
|
/** Format: double */
|
|
2886
2870
|
avg_trade_usd: number;
|
|
@@ -3016,10 +3000,8 @@ export interface components {
|
|
|
3016
3000
|
accepting_orders: boolean | null;
|
|
3017
3001
|
/** @default null */
|
|
3018
3002
|
uma_resolution_status: string | null;
|
|
3019
|
-
|
|
3020
|
-
|
|
3021
|
-
/** @default [] */
|
|
3022
|
-
outcomes: components["schemas"]["EventMarketOutcome"][];
|
|
3003
|
+
clob_rewards?: components["schemas"]["ClobReward"][];
|
|
3004
|
+
outcomes?: components["schemas"]["EventMarketOutcome"][];
|
|
3023
3005
|
/** @default null */
|
|
3024
3006
|
winning_outcome: null | components["schemas"]["EventMarketOutcome"];
|
|
3025
3007
|
};
|
|
@@ -3068,6 +3050,10 @@ export interface components {
|
|
|
3068
3050
|
/** Format: int32 */
|
|
3069
3051
|
unique_traders: number;
|
|
3070
3052
|
/** Format: int32 */
|
|
3053
|
+
unique_makers: number;
|
|
3054
|
+
/** Format: int32 */
|
|
3055
|
+
unique_takers: number;
|
|
3056
|
+
/** Format: int32 */
|
|
3071
3057
|
unique_builder_traders: number;
|
|
3072
3058
|
/** Format: double */
|
|
3073
3059
|
avg_trade_usd: number;
|
|
@@ -3079,13 +3065,82 @@ export interface components {
|
|
|
3079
3065
|
/** @enum {string} */
|
|
3080
3066
|
EventSortBy: "volume" | "txns" | "unique_traders" | "title" | "creation_date" | "start_date" | "end_date" | "relevance";
|
|
3081
3067
|
/**
|
|
3082
|
-
* @description
|
|
3083
|
-
*
|
|
3084
|
-
* `unique_*` ranks by window-distinct addresses — exact `uniqExact` count
|
|
3085
|
-
* of addresses active in the timeframe.
|
|
3086
|
-
* @enum {string}
|
|
3068
|
+
* @description Tagged enum for all trade types — serializes with `"trade_type": "..."` discriminator
|
|
3069
|
+
* and only includes fields relevant to each type.
|
|
3087
3070
|
*/
|
|
3088
|
-
|
|
3071
|
+
TradeEvent: (components["schemas"]["OrderFilledTrade"] & {
|
|
3072
|
+
/** @enum {string} */
|
|
3073
|
+
trade_type: "OrderFilled";
|
|
3074
|
+
}) | (components["schemas"]["OrderFilledTrade"] & {
|
|
3075
|
+
/** @enum {string} */
|
|
3076
|
+
trade_type: "OrdersMatched";
|
|
3077
|
+
}) | (components["schemas"]["OrderFilledTrade"] & {
|
|
3078
|
+
/** @enum {string} */
|
|
3079
|
+
trade_type: "MakerRebate";
|
|
3080
|
+
}) | (components["schemas"]["OrderFilledTrade"] & {
|
|
3081
|
+
/** @enum {string} */
|
|
3082
|
+
trade_type: "Reward";
|
|
3083
|
+
}) | (components["schemas"]["OrderFilledTrade"] & {
|
|
3084
|
+
/** @enum {string} */
|
|
3085
|
+
trade_type: "Yield";
|
|
3086
|
+
}) | (components["schemas"]["RedemptionTrade"] & {
|
|
3087
|
+
/** @enum {string} */
|
|
3088
|
+
trade_type: "Redemption";
|
|
3089
|
+
}) | (components["schemas"]["MergeTrade"] & {
|
|
3090
|
+
/** @enum {string} */
|
|
3091
|
+
trade_type: "Merge";
|
|
3092
|
+
}) | (components["schemas"]["SplitTrade"] & {
|
|
3093
|
+
/** @enum {string} */
|
|
3094
|
+
trade_type: "Split";
|
|
3095
|
+
}) | (components["schemas"]["PositionsConvertedTrade"] & {
|
|
3096
|
+
/** @enum {string} */
|
|
3097
|
+
trade_type: "PositionsConverted";
|
|
3098
|
+
}) | (components["schemas"]["CancelledTrade"] & {
|
|
3099
|
+
/** @enum {string} */
|
|
3100
|
+
trade_type: "Cancelled";
|
|
3101
|
+
}) | (components["schemas"]["QuestionInitializedEvent"] & {
|
|
3102
|
+
/** @enum {string} */
|
|
3103
|
+
trade_type: "Initialization";
|
|
3104
|
+
}) | (components["schemas"]["AssertionMadeEvent"] & {
|
|
3105
|
+
/** @enum {string} */
|
|
3106
|
+
trade_type: "Proposal";
|
|
3107
|
+
}) | (components["schemas"]["AssertionDisputedEvent"] & {
|
|
3108
|
+
/** @enum {string} */
|
|
3109
|
+
trade_type: "Dispute";
|
|
3110
|
+
}) | (components["schemas"]["AssertionSettledEvent"] & {
|
|
3111
|
+
/** @enum {string} */
|
|
3112
|
+
trade_type: "Settled";
|
|
3113
|
+
}) | (components["schemas"]["QuestionResolvedEvent"] & {
|
|
3114
|
+
/** @enum {string} */
|
|
3115
|
+
trade_type: "Resolution";
|
|
3116
|
+
}) | (components["schemas"]["ConditionResolutionEvent"] & {
|
|
3117
|
+
/** @enum {string} */
|
|
3118
|
+
trade_type: "ConditionResolution";
|
|
3119
|
+
}) | (components["schemas"]["QuestionResetEvent"] & {
|
|
3120
|
+
/** @enum {string} */
|
|
3121
|
+
trade_type: "Reset";
|
|
3122
|
+
}) | (components["schemas"]["QuestionFlaggedEvent"] & {
|
|
3123
|
+
/** @enum {string} */
|
|
3124
|
+
trade_type: "Flag";
|
|
3125
|
+
}) | (components["schemas"]["QuestionUnflaggedEvent"] & {
|
|
3126
|
+
/** @enum {string} */
|
|
3127
|
+
trade_type: "Unflag";
|
|
3128
|
+
}) | (components["schemas"]["QuestionPausedEvent"] & {
|
|
3129
|
+
/** @enum {string} */
|
|
3130
|
+
trade_type: "Pause";
|
|
3131
|
+
}) | (components["schemas"]["QuestionUnpausedEvent"] & {
|
|
3132
|
+
/** @enum {string} */
|
|
3133
|
+
trade_type: "Unpause";
|
|
3134
|
+
}) | (components["schemas"]["QuestionEmergencyResolvedEvent"] & {
|
|
3135
|
+
/** @enum {string} */
|
|
3136
|
+
trade_type: "ManualResolution";
|
|
3137
|
+
}) | (components["schemas"]["NegRiskOutcomeReportedEvent"] & {
|
|
3138
|
+
/** @enum {string} */
|
|
3139
|
+
trade_type: "NegRiskOutcomeReported";
|
|
3140
|
+
}) | (components["schemas"]["RegisterTokenTrade"] & {
|
|
3141
|
+
/** @enum {string} */
|
|
3142
|
+
trade_type: "RegisterToken";
|
|
3143
|
+
});
|
|
3089
3144
|
/**
|
|
3090
3145
|
* @description One tag's stats aggregated across every builder routing activity into it.
|
|
3091
3146
|
*
|
|
@@ -3514,7 +3569,7 @@ export interface components {
|
|
|
3514
3569
|
slug?: string | null;
|
|
3515
3570
|
/**
|
|
3516
3571
|
* Format: int64
|
|
3517
|
-
* @description Total unique holders across all outcomes
|
|
3572
|
+
* @description Total unique holders across all outcomes of this market.
|
|
3518
3573
|
*/
|
|
3519
3574
|
total_holders: number;
|
|
3520
3575
|
/** @description Holders grouped by outcome */
|
|
@@ -3528,8 +3583,17 @@ export interface components {
|
|
|
3528
3583
|
last_price?: number | null;
|
|
3529
3584
|
/** Format: double */
|
|
3530
3585
|
last_probability?: number | null;
|
|
3586
|
+
/** @description Per-timeframe metrics keyed by lookback window. Each timeframe key is optional — present only when data exists for that window. */
|
|
3531
3587
|
metrics?: {
|
|
3532
|
-
|
|
3588
|
+
"1m"?: components["schemas"]["OutcomeTimeframeMetrics"];
|
|
3589
|
+
"5m"?: components["schemas"]["OutcomeTimeframeMetrics"];
|
|
3590
|
+
"30m"?: components["schemas"]["OutcomeTimeframeMetrics"];
|
|
3591
|
+
"1h"?: components["schemas"]["OutcomeTimeframeMetrics"];
|
|
3592
|
+
"6h"?: components["schemas"]["OutcomeTimeframeMetrics"];
|
|
3593
|
+
"24h"?: components["schemas"]["OutcomeTimeframeMetrics"];
|
|
3594
|
+
"7d"?: components["schemas"]["OutcomeTimeframeMetrics"];
|
|
3595
|
+
"30d"?: components["schemas"]["OutcomeTimeframeMetrics"];
|
|
3596
|
+
lifetime?: components["schemas"]["OutcomeTimeframeMetrics"];
|
|
3533
3597
|
};
|
|
3534
3598
|
};
|
|
3535
3599
|
/** @description Outcome for market API responses */
|
|
@@ -3606,8 +3670,17 @@ export interface components {
|
|
|
3606
3670
|
tags?: string[];
|
|
3607
3671
|
event_slug?: string | null;
|
|
3608
3672
|
resolution_source?: string | null;
|
|
3673
|
+
/** @description Per-timeframe metrics keyed by lookback window. Each timeframe key is optional — present only when data exists for that window. */
|
|
3609
3674
|
metrics?: {
|
|
3610
|
-
|
|
3675
|
+
"1m"?: components["schemas"]["SimpleTimeframeMetrics"];
|
|
3676
|
+
"5m"?: components["schemas"]["SimpleTimeframeMetrics"];
|
|
3677
|
+
"30m"?: components["schemas"]["SimpleTimeframeMetrics"];
|
|
3678
|
+
"1h"?: components["schemas"]["SimpleTimeframeMetrics"];
|
|
3679
|
+
"6h"?: components["schemas"]["SimpleTimeframeMetrics"];
|
|
3680
|
+
"24h"?: components["schemas"]["SimpleTimeframeMetrics"];
|
|
3681
|
+
"7d"?: components["schemas"]["SimpleTimeframeMetrics"];
|
|
3682
|
+
"30d"?: components["schemas"]["SimpleTimeframeMetrics"];
|
|
3683
|
+
lifetime?: components["schemas"]["SimpleTimeframeMetrics"];
|
|
3611
3684
|
};
|
|
3612
3685
|
/** Format: double */
|
|
3613
3686
|
relevance_score?: number | null;
|
|
@@ -3718,44 +3791,31 @@ export interface components {
|
|
|
3718
3791
|
slug?: string | null;
|
|
3719
3792
|
event_slug?: string | null;
|
|
3720
3793
|
};
|
|
3721
|
-
|
|
3722
|
-
|
|
3723
|
-
|
|
3724
|
-
|
|
3725
|
-
/** Format: double */
|
|
3726
|
-
realized_pnl_pct?: number | null;
|
|
3727
|
-
/** Format: double */
|
|
3728
|
-
total_volume_usd?: number | null;
|
|
3729
|
-
/** Format: double */
|
|
3730
|
-
buy_usd?: number | null;
|
|
3731
|
-
/** Format: double */
|
|
3732
|
-
sell_usd?: number | null;
|
|
3733
|
-
/** Format: double */
|
|
3734
|
-
redemption_usd?: number | null;
|
|
3735
|
-
/** Format: double */
|
|
3736
|
-
merge_usd?: number | null;
|
|
3737
|
-
/** Format: double */
|
|
3738
|
-
total_fees?: number | null;
|
|
3739
|
-
/** Format: int64 */
|
|
3740
|
-
total_buys?: number | null;
|
|
3741
|
-
/** Format: int64 */
|
|
3742
|
-
total_sells?: number | null;
|
|
3743
|
-
/** Format: int64 */
|
|
3744
|
-
total_redemptions?: number | null;
|
|
3745
|
-
/** Format: int64 */
|
|
3746
|
-
total_merges?: number | null;
|
|
3747
|
-
/** Format: int64 */
|
|
3748
|
-
markets_traded?: number | null;
|
|
3794
|
+
/** @description Output payload for Split trades (deposit collateral → receive outcome tokens). */
|
|
3795
|
+
SplitTrade: {
|
|
3796
|
+
id: string;
|
|
3797
|
+
hash: string;
|
|
3749
3798
|
/** Format: int64 */
|
|
3750
|
-
|
|
3799
|
+
block?: number | null;
|
|
3751
3800
|
/** Format: int64 */
|
|
3752
|
-
|
|
3801
|
+
confirmed_at?: number | null;
|
|
3753
3802
|
/** Format: int64 */
|
|
3754
|
-
|
|
3803
|
+
received_at?: number | null;
|
|
3755
3804
|
/** Format: int64 */
|
|
3756
|
-
|
|
3805
|
+
log_index?: number | null;
|
|
3757
3806
|
/** Format: int64 */
|
|
3758
|
-
|
|
3807
|
+
block_index?: number | null;
|
|
3808
|
+
trader: components["schemas"]["TraderInfo"];
|
|
3809
|
+
condition_id?: string | null;
|
|
3810
|
+
question?: string | null;
|
|
3811
|
+
image_url?: string | null;
|
|
3812
|
+
slug?: string | null;
|
|
3813
|
+
event_slug?: string | null;
|
|
3814
|
+
/** Format: double */
|
|
3815
|
+
usd_amount: number;
|
|
3816
|
+
/** @description Per-position mint amounts */
|
|
3817
|
+
position_details?: components["schemas"]["PositionDetail"][];
|
|
3818
|
+
exchange: components["schemas"]["PolymarketExchange"];
|
|
3759
3819
|
};
|
|
3760
3820
|
/**
|
|
3761
3821
|
* @description Tagged enum for all oracle event types — serializes with `"event_type": "..."` discriminator
|
|
@@ -3866,25 +3926,12 @@ export interface components {
|
|
|
3866
3926
|
*/
|
|
3867
3927
|
builder_fee?: number | null;
|
|
3868
3928
|
};
|
|
3869
|
-
|
|
3870
|
-
|
|
3871
|
-
event_slug?: string | null;
|
|
3872
|
-
question?: string | null;
|
|
3873
|
-
image_url?: string | null;
|
|
3874
|
-
/** Format: int64 */
|
|
3875
|
-
markets_traded?: number | null;
|
|
3876
|
-
/** Format: int64 */
|
|
3877
|
-
outcomes_traded?: number | null;
|
|
3878
|
-
/** Format: int64 */
|
|
3879
|
-
total_buys?: number | null;
|
|
3880
|
-
/** Format: int64 */
|
|
3881
|
-
total_sells?: number | null;
|
|
3882
|
-
/** Format: int64 */
|
|
3883
|
-
total_redemptions?: number | null;
|
|
3884
|
-
/** Format: int64 */
|
|
3885
|
-
total_merges?: number | null;
|
|
3929
|
+
TopTraderMarketEntry: {
|
|
3930
|
+
trader: components["schemas"]["TraderInfo"];
|
|
3886
3931
|
/** Format: double */
|
|
3887
|
-
|
|
3932
|
+
realized_pnl_usd?: number | null;
|
|
3933
|
+
/** Format: double */
|
|
3934
|
+
realized_pnl_pct?: number | null;
|
|
3888
3935
|
/** Format: double */
|
|
3889
3936
|
buy_usd?: number | null;
|
|
3890
3937
|
/** Format: double */
|
|
@@ -3894,19 +3941,23 @@ export interface components {
|
|
|
3894
3941
|
/** Format: double */
|
|
3895
3942
|
merge_usd?: number | null;
|
|
3896
3943
|
/** Format: double */
|
|
3897
|
-
|
|
3944
|
+
total_fees?: number | null;
|
|
3898
3945
|
/** Format: int64 */
|
|
3899
|
-
|
|
3946
|
+
total_buys?: number | null;
|
|
3900
3947
|
/** Format: int64 */
|
|
3901
|
-
|
|
3902
|
-
/** Format:
|
|
3903
|
-
|
|
3948
|
+
total_sells?: number | null;
|
|
3949
|
+
/** Format: int64 */
|
|
3950
|
+
total_redemptions?: number | null;
|
|
3951
|
+
/** Format: int64 */
|
|
3952
|
+
total_merges?: number | null;
|
|
3953
|
+
/** Format: int64 */
|
|
3954
|
+
outcomes_traded?: number | null;
|
|
3955
|
+
/** Format: int64 */
|
|
3956
|
+
winning_outcomes?: number | null;
|
|
3904
3957
|
/** Format: int64 */
|
|
3905
3958
|
first_trade_at?: number | null;
|
|
3906
3959
|
/** Format: int64 */
|
|
3907
3960
|
last_trade_at?: number | null;
|
|
3908
|
-
/** Format: double */
|
|
3909
|
-
realized_pnl_pct?: number | null;
|
|
3910
3961
|
};
|
|
3911
3962
|
OrderbookHistoryRow: {
|
|
3912
3963
|
/** Format: int64 */
|
|
@@ -3983,7 +4034,7 @@ export interface components {
|
|
|
3983
4034
|
price?: number | null;
|
|
3984
4035
|
/**
|
|
3985
4036
|
* Format: int64
|
|
3986
|
-
* @description Total holders count
|
|
4037
|
+
* @description Total holders count for this outcome.
|
|
3987
4038
|
*/
|
|
3988
4039
|
total_holders: number;
|
|
3989
4040
|
/** @description Top holders for this outcome */
|
|
@@ -4095,239 +4146,99 @@ export interface components {
|
|
|
4095
4146
|
/**
|
|
4096
4147
|
* Format: int32
|
|
4097
4148
|
* @default 0
|
|
4098
|
-
*/
|
|
4099
|
-
unique_traders: number;
|
|
4100
|
-
/**
|
|
4101
|
-
* Format: int32
|
|
4102
|
-
* @default 0
|
|
4103
|
-
*/
|
|
4104
|
-
unique_builder_traders: number;
|
|
4105
|
-
/**
|
|
4106
|
-
* Format: double
|
|
4107
|
-
* @default null
|
|
4108
|
-
*/
|
|
4109
|
-
price_open: number | null;
|
|
4110
|
-
/**
|
|
4111
|
-
* Format: double
|
|
4112
|
-
* @default null
|
|
4113
|
-
*/
|
|
4114
|
-
price_close: number | null;
|
|
4115
|
-
/**
|
|
4116
|
-
* Format: double
|
|
4117
|
-
* @default null
|
|
4118
|
-
*/
|
|
4119
|
-
price_high: number | null;
|
|
4120
|
-
/**
|
|
4121
|
-
* Format: double
|
|
4122
|
-
* @default null
|
|
4123
|
-
*/
|
|
4124
|
-
price_low: number | null;
|
|
4125
|
-
/**
|
|
4126
|
-
* Format: double
|
|
4127
|
-
* @default null
|
|
4128
|
-
*/
|
|
4129
|
-
price_change_percent: number | null;
|
|
4130
|
-
};
|
|
4131
|
-
/** @description Pagination metadata to include in API responses */
|
|
4132
|
-
PaginationMeta: {
|
|
4133
|
-
/** @description Whether there are more results available */
|
|
4134
|
-
has_more: boolean;
|
|
4135
|
-
/** @description Pagination key for the next page (if has_more is true) */
|
|
4136
|
-
pagination_key?: string | null;
|
|
4137
|
-
};
|
|
4138
|
-
/** @description A single PnL candle entry */
|
|
4139
|
-
PnlCandleEntry: {
|
|
4140
|
-
/**
|
|
4141
|
-
* Format: int64
|
|
4142
|
-
* @description Timestamp in epoch seconds (start of bucket window)
|
|
4143
|
-
*/
|
|
4144
|
-
t: number;
|
|
4145
|
-
/**
|
|
4146
|
-
* Format: double
|
|
4147
|
-
* @description Realized PnL in this bucket (USD)
|
|
4148
|
-
*/
|
|
4149
|
-
pnl: number;
|
|
4150
|
-
};
|
|
4151
|
-
/** @enum {string} */
|
|
4152
|
-
PnlCandleResolution: "1m" | "1h" | "1d";
|
|
4153
|
-
/** @enum {string} */
|
|
4154
|
-
PnlCandleTimeframe: "1d" | "7d" | "30d" | "lifetime";
|
|
4155
|
-
/** @enum {string} */
|
|
4156
|
-
PnlTimeframe: "1d" | "7d" | "30d" | "lifetime";
|
|
4157
|
-
/**
|
|
4158
|
-
* @description Crypto asset symbols accepted by `asset_price_tick` and `asset_price_window_update` filters.
|
|
4159
|
-
* @enum {string}
|
|
4160
|
-
*/
|
|
4161
|
-
WebhookAssetSymbol: "BTC" | "ETH" | "SOL" | "XRP" | "DOGE" | "BNB" | "HYPE";
|
|
4162
|
-
/**
|
|
4163
|
-
* @description Timeframe values accepted by webhook metric, milestone, spike, and asset-price filters.
|
|
4164
|
-
* @enum {string}
|
|
4165
|
-
*/
|
|
4166
|
-
WebhookTimeframe: "1m" | "5m" | "15m" | "30m" | "1h" | "4h" | "6h" | "1d" | "24h" | "7d" | "30d";
|
|
4167
|
-
/** @description V2 UMA OOv2: a price request was settled (final resolution). */
|
|
4168
|
-
SettleEvent: {
|
|
4169
|
-
id: string;
|
|
4170
|
-
hash: string;
|
|
4171
|
-
/** Format: int64 */
|
|
4172
|
-
block?: number | null;
|
|
4173
|
-
/** Format: int64 */
|
|
4174
|
-
confirmed_at?: number | null;
|
|
4175
|
-
/** Format: int64 */
|
|
4176
|
-
received_at?: number | null;
|
|
4177
|
-
/** Format: int64 */
|
|
4178
|
-
log_index?: number | null;
|
|
4179
|
-
/** Format: int64 */
|
|
4180
|
-
block_index?: number | null;
|
|
4181
|
-
oracle_contract: string;
|
|
4182
|
-
requester: string;
|
|
4183
|
-
proposer: string;
|
|
4184
|
-
disputer: string;
|
|
4185
|
-
identifier: string;
|
|
4186
|
-
timestamp: string;
|
|
4187
|
-
ancillary_data: string;
|
|
4188
|
-
/** Format: int64 */
|
|
4189
|
-
proposed_price: number;
|
|
4190
|
-
payout: string;
|
|
4191
|
-
disputed: boolean;
|
|
4192
|
-
condition_id?: string | null;
|
|
4193
|
-
proposed_outcome?: string | null;
|
|
4194
|
-
question?: string | null;
|
|
4195
|
-
image_url?: string | null;
|
|
4196
|
-
slug?: string | null;
|
|
4197
|
-
event_slug?: string | null;
|
|
4198
|
-
};
|
|
4199
|
-
TraderWithPnl: components["schemas"]["Trader"] & {
|
|
4200
|
-
pnl?: null | components["schemas"]["TraderPnlSummary"];
|
|
4201
|
-
};
|
|
4202
|
-
/** @description One builder's stats under a single tag. */
|
|
4203
|
-
TagBuilderRow: {
|
|
4204
|
-
builder_code: string;
|
|
4205
|
-
/** Format: int64 */
|
|
4206
|
-
block: number;
|
|
4207
|
-
/** Format: int32 */
|
|
4208
|
-
ts: number;
|
|
4209
|
-
/** Format: double */
|
|
4210
|
-
volume_usd: number;
|
|
4211
|
-
/** Format: double */
|
|
4212
|
-
buy_volume_usd: number;
|
|
4213
|
-
/** Format: double */
|
|
4214
|
-
sell_volume_usd: number;
|
|
4215
|
-
/** Format: int64 */
|
|
4149
|
+
*/
|
|
4216
4150
|
unique_traders: number;
|
|
4217
|
-
/**
|
|
4151
|
+
/**
|
|
4152
|
+
* Format: int32
|
|
4153
|
+
* @default 0
|
|
4154
|
+
*/
|
|
4218
4155
|
unique_makers: number;
|
|
4219
|
-
/**
|
|
4156
|
+
/**
|
|
4157
|
+
* Format: int32
|
|
4158
|
+
* @default 0
|
|
4159
|
+
*/
|
|
4220
4160
|
unique_takers: number;
|
|
4221
|
-
/** Format: int64 */
|
|
4222
|
-
txn_count: number;
|
|
4223
|
-
/** Format: int64 */
|
|
4224
|
-
buy_count: number;
|
|
4225
|
-
/** Format: int64 */
|
|
4226
|
-
sell_count: number;
|
|
4227
|
-
/** Format: double */
|
|
4228
|
-
fees_usd: number;
|
|
4229
|
-
/** Format: double */
|
|
4230
|
-
builder_fees: number;
|
|
4231
|
-
/** Format: double */
|
|
4232
|
-
shares_volume: number;
|
|
4233
|
-
/** Format: double */
|
|
4234
|
-
yes_volume_usd: number;
|
|
4235
|
-
/** Format: double */
|
|
4236
|
-
no_volume_usd: number;
|
|
4237
|
-
/** Format: int64 */
|
|
4238
|
-
yes_count: number;
|
|
4239
|
-
/** Format: int64 */
|
|
4240
|
-
no_count: number;
|
|
4241
|
-
/** Format: int64 */
|
|
4242
|
-
buy_dist_under_10: number;
|
|
4243
|
-
/** Format: int64 */
|
|
4244
|
-
buy_dist_10_100: number;
|
|
4245
|
-
/** Format: int64 */
|
|
4246
|
-
buy_dist_100_1k: number;
|
|
4247
|
-
/** Format: int64 */
|
|
4248
|
-
buy_dist_1k_10k: number;
|
|
4249
|
-
/** Format: int64 */
|
|
4250
|
-
buy_dist_10k_50k: number;
|
|
4251
|
-
/** Format: int64 */
|
|
4252
|
-
buy_dist_50k_plus: number;
|
|
4253
|
-
/** Format: int64 */
|
|
4254
|
-
new_users: number;
|
|
4255
|
-
/** Format: double */
|
|
4256
|
-
avg_rev_per_user: number;
|
|
4257
|
-
/** Format: double */
|
|
4258
|
-
avg_vol_per_user: number;
|
|
4259
|
-
};
|
|
4260
|
-
/** @description Outcome-level PnL entry (per outcome token / position_id) */
|
|
4261
|
-
TraderOutcomePnlEntry: {
|
|
4262
|
-
position_id?: string | null;
|
|
4263
|
-
condition_id?: string | null;
|
|
4264
|
-
market_slug?: string | null;
|
|
4265
|
-
event_slug?: string | null;
|
|
4266
|
-
title?: string | null;
|
|
4267
|
-
image_url?: string | null;
|
|
4268
|
-
outcome?: string | null;
|
|
4269
|
-
/** Format: int32 */
|
|
4270
|
-
outcome_index?: number | null;
|
|
4271
|
-
/** @description TRUE = won, FALSE = lost, NULL = open or sold before resolution */
|
|
4272
|
-
won?: boolean | null;
|
|
4273
|
-
/** Format: int64 */
|
|
4274
|
-
total_buys?: number | null;
|
|
4275
|
-
/** Format: int64 */
|
|
4276
|
-
total_sells?: number | null;
|
|
4277
|
-
/** Format: double */
|
|
4278
|
-
total_shares_bought?: number | null;
|
|
4279
|
-
/** Format: double */
|
|
4280
|
-
total_shares_sold?: number | null;
|
|
4281
|
-
/** Format: double */
|
|
4282
|
-
total_buy_usd?: number | null;
|
|
4283
|
-
/** Format: double */
|
|
4284
|
-
total_sell_usd?: number | null;
|
|
4285
4161
|
/**
|
|
4286
|
-
* Format:
|
|
4287
|
-
* @
|
|
4162
|
+
* Format: int32
|
|
4163
|
+
* @default 0
|
|
4288
4164
|
*/
|
|
4289
|
-
|
|
4165
|
+
unique_builder_traders: number;
|
|
4290
4166
|
/**
|
|
4291
4167
|
* Format: double
|
|
4292
|
-
* @
|
|
4168
|
+
* @default null
|
|
4293
4169
|
*/
|
|
4294
|
-
|
|
4170
|
+
price_open: number | null;
|
|
4295
4171
|
/**
|
|
4296
4172
|
* Format: double
|
|
4297
|
-
* @
|
|
4173
|
+
* @default null
|
|
4298
4174
|
*/
|
|
4299
|
-
|
|
4300
|
-
/** Format: double */
|
|
4301
|
-
realized_pnl_usd?: number | null;
|
|
4302
|
-
/** Format: double */
|
|
4303
|
-
total_fees?: number | null;
|
|
4304
|
-
/** Format: int64 */
|
|
4305
|
-
first_trade_at?: number | null;
|
|
4306
|
-
/** Format: int64 */
|
|
4307
|
-
last_trade_at?: number | null;
|
|
4175
|
+
price_close: number | null;
|
|
4308
4176
|
/**
|
|
4309
4177
|
* Format: double
|
|
4310
|
-
* @
|
|
4178
|
+
* @default null
|
|
4311
4179
|
*/
|
|
4312
|
-
|
|
4180
|
+
price_high: number | null;
|
|
4313
4181
|
/**
|
|
4314
4182
|
* Format: double
|
|
4315
|
-
* @
|
|
4183
|
+
* @default null
|
|
4316
4184
|
*/
|
|
4317
|
-
|
|
4185
|
+
price_low: number | null;
|
|
4318
4186
|
/**
|
|
4319
4187
|
* Format: double
|
|
4320
|
-
* @
|
|
4321
|
-
* Only meaningful for open positions (balance above dust threshold).
|
|
4188
|
+
* @default null
|
|
4322
4189
|
*/
|
|
4323
|
-
|
|
4190
|
+
price_change_percent: number | null;
|
|
4191
|
+
};
|
|
4192
|
+
/** @description Pagination metadata to include in API responses */
|
|
4193
|
+
PaginationMeta: {
|
|
4194
|
+
/** @description Whether there are more results available */
|
|
4195
|
+
has_more: boolean;
|
|
4196
|
+
/** @description Pagination key for the next page (if has_more is true) */
|
|
4197
|
+
pagination_key?: string | null;
|
|
4198
|
+
};
|
|
4199
|
+
/** @description A single PnL candle entry */
|
|
4200
|
+
PnlCandleEntry: {
|
|
4201
|
+
/**
|
|
4202
|
+
* Format: int64
|
|
4203
|
+
* @description Timestamp in epoch seconds (start of bucket window)
|
|
4204
|
+
*/
|
|
4205
|
+
t: number;
|
|
4324
4206
|
/**
|
|
4325
4207
|
* Format: double
|
|
4326
|
-
* @description Realized PnL
|
|
4327
|
-
* NULL when total_buy_usd = 0.
|
|
4208
|
+
* @description Realized PnL in this bucket (USD)
|
|
4328
4209
|
*/
|
|
4329
|
-
|
|
4210
|
+
pnl: number;
|
|
4211
|
+
};
|
|
4212
|
+
/** @enum {string} */
|
|
4213
|
+
PnlCandleResolution: "1m" | "1h" | "4h" | "1d" | "auto";
|
|
4214
|
+
/** @enum {string} */
|
|
4215
|
+
PnlCandleTimeframe: "1d" | "7d" | "30d" | "lifetime";
|
|
4216
|
+
/** @enum {string} */
|
|
4217
|
+
PnlTimeframe: "1d" | "7d" | "30d" | "lifetime";
|
|
4218
|
+
/**
|
|
4219
|
+
* @description Crypto asset symbols accepted by `asset_price_tick` and `asset_price_window_update` filters.
|
|
4220
|
+
* @enum {string}
|
|
4221
|
+
*/
|
|
4222
|
+
WebhookAssetSymbol: "BTC" | "ETH" | "SOL" | "XRP" | "DOGE" | "BNB" | "HYPE";
|
|
4223
|
+
/**
|
|
4224
|
+
* @description Timeframe values accepted by webhook metric, milestone, spike, and asset-price filters.
|
|
4225
|
+
* @enum {string}
|
|
4226
|
+
*/
|
|
4227
|
+
WebhookTimeframe: "1m" | "5m" | "15m" | "30m" | "1h" | "4h" | "6h" | "1d" | "24h" | "7d" | "30d";
|
|
4228
|
+
/**
|
|
4229
|
+
* @description Sort metric for the trader → builders list.
|
|
4230
|
+
* @enum {string}
|
|
4231
|
+
*/
|
|
4232
|
+
TraderBuilderSortBy: "volume" | "txns" | "fees";
|
|
4233
|
+
TraderWithPnl: components["schemas"]["Trader"] & {
|
|
4234
|
+
pnl?: null | components["schemas"]["TraderPnlSummary"];
|
|
4330
4235
|
};
|
|
4236
|
+
/**
|
|
4237
|
+
* @description Timeframe for `?sort=...` — defines the window the metric is summed over
|
|
4238
|
+
* (or `lifetime` for all-time cumulative).
|
|
4239
|
+
* @enum {string}
|
|
4240
|
+
*/
|
|
4241
|
+
TagSortTimeframe: "lifetime" | "1h" | "24h" | "7d" | "30d" | "1mo";
|
|
4331
4242
|
/** @description Trader's global PnL summary (single trader) */
|
|
4332
4243
|
TraderPnlSummary: {
|
|
4333
4244
|
trader?: string | null;
|
|
@@ -4377,33 +4288,6 @@ export interface components {
|
|
|
4377
4288
|
/** Format: int64 */
|
|
4378
4289
|
last_trade_at?: number | null;
|
|
4379
4290
|
};
|
|
4380
|
-
/**
|
|
4381
|
-
* @description Per-metric percentage change over a lookback window for one trader
|
|
4382
|
-
* address. A `null` field means the window predates the trader's first
|
|
4383
|
-
* activity or the prior value was zero (percentage undefined).
|
|
4384
|
-
*/
|
|
4385
|
-
TraderMetricPctChange: {
|
|
4386
|
-
/** Format: double */
|
|
4387
|
-
volume_usd?: number | null;
|
|
4388
|
-
/** Format: double */
|
|
4389
|
-
buy_volume_usd?: number | null;
|
|
4390
|
-
/** Format: double */
|
|
4391
|
-
sell_volume_usd?: number | null;
|
|
4392
|
-
/** Format: double */
|
|
4393
|
-
merge_volume_usd?: number | null;
|
|
4394
|
-
/** Format: double */
|
|
4395
|
-
split_volume_usd?: number | null;
|
|
4396
|
-
/** Format: double */
|
|
4397
|
-
txn_count?: number | null;
|
|
4398
|
-
/** Format: double */
|
|
4399
|
-
fees_usd?: number | null;
|
|
4400
|
-
/** Format: double */
|
|
4401
|
-
shares_volume?: number | null;
|
|
4402
|
-
/** Format: double */
|
|
4403
|
-
yes_volume_usd?: number | null;
|
|
4404
|
-
/** Format: double */
|
|
4405
|
-
no_volume_usd?: number | null;
|
|
4406
|
-
};
|
|
4407
4291
|
TraderVolumeDataPoint: {
|
|
4408
4292
|
/** Format: int64 */
|
|
4409
4293
|
t: number;
|
|
@@ -4483,6 +4367,11 @@ export interface components {
|
|
|
4483
4367
|
/** Format: int64 */
|
|
4484
4368
|
bd_50p: number;
|
|
4485
4369
|
};
|
|
4370
|
+
/**
|
|
4371
|
+
* @description Polymarket UI category.
|
|
4372
|
+
* @enum {string}
|
|
4373
|
+
*/
|
|
4374
|
+
PolymarketCategory: "Politics" | "Sports" | "Crypto" | "Finance" | "Culture" | "Mentions" | "Weather" | "Economics" | "Tech";
|
|
4486
4375
|
/** @description A Polymarket event from the Gamma API */
|
|
4487
4376
|
PolymarketEvent: {
|
|
4488
4377
|
/** @default */
|
|
@@ -4539,14 +4428,20 @@ export interface components {
|
|
|
4539
4428
|
* @default null
|
|
4540
4429
|
*/
|
|
4541
4430
|
status: string | null;
|
|
4542
|
-
/** @
|
|
4543
|
-
metrics
|
|
4544
|
-
|
|
4545
|
-
|
|
4546
|
-
|
|
4547
|
-
|
|
4548
|
-
|
|
4549
|
-
|
|
4431
|
+
/** @description Per-timeframe metrics keyed by lookback window. Each timeframe key is optional — present only when data exists for that window. */
|
|
4432
|
+
metrics?: {
|
|
4433
|
+
"1m"?: components["schemas"]["SimpleTimeframeMetrics"];
|
|
4434
|
+
"5m"?: components["schemas"]["SimpleTimeframeMetrics"];
|
|
4435
|
+
"30m"?: components["schemas"]["SimpleTimeframeMetrics"];
|
|
4436
|
+
"1h"?: components["schemas"]["SimpleTimeframeMetrics"];
|
|
4437
|
+
"6h"?: components["schemas"]["SimpleTimeframeMetrics"];
|
|
4438
|
+
"24h"?: components["schemas"]["SimpleTimeframeMetrics"];
|
|
4439
|
+
"7d"?: components["schemas"]["SimpleTimeframeMetrics"];
|
|
4440
|
+
"30d"?: components["schemas"]["SimpleTimeframeMetrics"];
|
|
4441
|
+
lifetime?: components["schemas"]["SimpleTimeframeMetrics"];
|
|
4442
|
+
};
|
|
4443
|
+
tags?: components["schemas"]["PolymarketTag"][];
|
|
4444
|
+
markets?: components["schemas"]["EventMarket"][];
|
|
4550
4445
|
/** @default null */
|
|
4551
4446
|
series: null | components["schemas"]["PolymarketSeries"];
|
|
4552
4447
|
};
|
|
@@ -4615,39 +4510,33 @@ export interface components {
|
|
|
4615
4510
|
label: string;
|
|
4616
4511
|
/** @default null */
|
|
4617
4512
|
slug: string | null;
|
|
4618
|
-
/**
|
|
4619
|
-
|
|
4620
|
-
|
|
4621
|
-
|
|
4622
|
-
|
|
4623
|
-
|
|
4624
|
-
|
|
4625
|
-
|
|
4626
|
-
|
|
4627
|
-
txn_count
|
|
4513
|
+
/** Format: double */
|
|
4514
|
+
volume_usd?: number;
|
|
4515
|
+
/** Format: double */
|
|
4516
|
+
shares_volume?: number;
|
|
4517
|
+
/** Format: double */
|
|
4518
|
+
builder_usd_volume?: number;
|
|
4519
|
+
/** Format: double */
|
|
4520
|
+
builder_shares_volume?: number;
|
|
4521
|
+
/** Format: int64 */
|
|
4522
|
+
txn_count?: number;
|
|
4523
|
+
/** Format: int64 */
|
|
4524
|
+
builder_txn_count?: number;
|
|
4628
4525
|
/**
|
|
4629
4526
|
* Format: int64
|
|
4630
4527
|
* @description Distinct active traders in the window.
|
|
4631
|
-
* @default null
|
|
4632
|
-
*/
|
|
4633
|
-
unique_traders: number;
|
|
4634
|
-
/**
|
|
4635
|
-
* Format: int64
|
|
4636
|
-
* @description Distinct active makers in the window.
|
|
4637
|
-
* @default null
|
|
4638
|
-
*/
|
|
4639
|
-
unique_makers: number;
|
|
4640
|
-
/**
|
|
4641
|
-
* Format: int64
|
|
4642
|
-
* @description Distinct active takers in the window.
|
|
4643
|
-
* @default null
|
|
4644
|
-
*/
|
|
4645
|
-
unique_takers: number;
|
|
4646
|
-
/**
|
|
4647
|
-
* Format: double
|
|
4648
|
-
* @default null
|
|
4649
4528
|
*/
|
|
4650
|
-
|
|
4529
|
+
unique_traders?: number;
|
|
4530
|
+
/** Format: int64 */
|
|
4531
|
+
unique_makers?: number;
|
|
4532
|
+
/** Format: int64 */
|
|
4533
|
+
unique_takers?: number;
|
|
4534
|
+
/** Format: int64 */
|
|
4535
|
+
unique_builder_traders?: number;
|
|
4536
|
+
/** Format: double */
|
|
4537
|
+
fees_usd?: number;
|
|
4538
|
+
/** Format: double */
|
|
4539
|
+
builder_fees_usd?: number;
|
|
4651
4540
|
};
|
|
4652
4541
|
/** @description Polymarket user profile (public API format) */
|
|
4653
4542
|
PolymarketUserProfile: {
|
|
@@ -4679,6 +4568,8 @@ export interface components {
|
|
|
4679
4568
|
};
|
|
4680
4569
|
/** @description Per-position detail for Split/Merge/Redemption trades. */
|
|
4681
4570
|
PositionDetail: {
|
|
4571
|
+
/** @description Market condition ID for this ERC1155 position. */
|
|
4572
|
+
condition_id?: string | null;
|
|
4682
4573
|
/** @description ERC1155 position ID */
|
|
4683
4574
|
position_id: string;
|
|
4684
4575
|
/**
|
|
@@ -4690,6 +4581,13 @@ export interface components {
|
|
|
4690
4581
|
outcome?: string | null;
|
|
4691
4582
|
/** @description Amount of shares created/burned/redeemed for this position */
|
|
4692
4583
|
amount: string;
|
|
4584
|
+
/**
|
|
4585
|
+
* @description Collateral paid out for this specific position, when applicable.
|
|
4586
|
+
*
|
|
4587
|
+
* For NegRisk PositionsConverted this is allocated only to burned NO
|
|
4588
|
+
* inputs. YES output details intentionally carry zero collateral.
|
|
4589
|
+
*/
|
|
4590
|
+
collateral_amount?: string;
|
|
4693
4591
|
};
|
|
4694
4592
|
/** @description Response for position (position_id) holders endpoint */
|
|
4695
4593
|
PositionHoldersResponse: {
|
|
@@ -4711,7 +4609,7 @@ export interface components {
|
|
|
4711
4609
|
price?: number | null;
|
|
4712
4610
|
/**
|
|
4713
4611
|
* Format: int64
|
|
4714
|
-
* @description Total holders
|
|
4612
|
+
* @description Total holders of this position.
|
|
4715
4613
|
*/
|
|
4716
4614
|
total_holders: number;
|
|
4717
4615
|
/** @description Top holders */
|
|
@@ -4765,6 +4663,10 @@ export interface components {
|
|
|
4765
4663
|
/** Format: int32 */
|
|
4766
4664
|
unique_traders: number;
|
|
4767
4665
|
/** Format: int32 */
|
|
4666
|
+
unique_makers: number;
|
|
4667
|
+
/** Format: int32 */
|
|
4668
|
+
unique_takers: number;
|
|
4669
|
+
/** Format: int32 */
|
|
4768
4670
|
unique_builder_traders: number;
|
|
4769
4671
|
/** Format: double */
|
|
4770
4672
|
price_open: number;
|
|
@@ -4842,6 +4744,7 @@ export interface components {
|
|
|
4842
4744
|
fee?: number | null;
|
|
4843
4745
|
/** Format: double */
|
|
4844
4746
|
fee_pct?: number | null;
|
|
4747
|
+
position_details?: components["schemas"]["PositionDetail"][];
|
|
4845
4748
|
exchange: components["schemas"]["PolymarketExchange"];
|
|
4846
4749
|
};
|
|
4847
4750
|
/**
|
|
@@ -4849,16 +4752,32 @@ export interface components {
|
|
|
4849
4752
|
* @enum {string}
|
|
4850
4753
|
*/
|
|
4851
4754
|
TopTradersSortBy: "volume" | "txns" | "fees" | "builder_fees";
|
|
4852
|
-
|
|
4853
|
-
|
|
4755
|
+
/**
|
|
4756
|
+
* @description Per-metric percentage change over a lookback window for one trader
|
|
4757
|
+
* address. A `null` field means the window predates the trader's first
|
|
4758
|
+
* activity or the prior value was zero (percentage undefined).
|
|
4759
|
+
*/
|
|
4760
|
+
TraderMetricPctChange: {
|
|
4761
|
+
/** Format: double */
|
|
4762
|
+
volume_usd?: number | null;
|
|
4763
|
+
/** Format: double */
|
|
4764
|
+
buy_volume_usd?: number | null;
|
|
4765
|
+
/** Format: double */
|
|
4766
|
+
sell_volume_usd?: number | null;
|
|
4767
|
+
/** Format: double */
|
|
4768
|
+
merge_volume_usd?: number | null;
|
|
4769
|
+
/** Format: double */
|
|
4770
|
+
split_volume_usd?: number | null;
|
|
4771
|
+
/** Format: double */
|
|
4772
|
+
txn_count?: number | null;
|
|
4854
4773
|
/** Format: double */
|
|
4855
|
-
|
|
4856
|
-
/** Format: int64 */
|
|
4857
|
-
txn_count: number;
|
|
4774
|
+
fees_usd?: number | null;
|
|
4858
4775
|
/** Format: double */
|
|
4859
|
-
|
|
4776
|
+
shares_volume?: number | null;
|
|
4860
4777
|
/** Format: double */
|
|
4861
|
-
|
|
4778
|
+
yes_volume_usd?: number | null;
|
|
4779
|
+
/** Format: double */
|
|
4780
|
+
no_volume_usd?: number | null;
|
|
4862
4781
|
};
|
|
4863
4782
|
PredictionCandlestickBar: {
|
|
4864
4783
|
/** Format: double */
|
|
@@ -5112,43 +5031,292 @@ export interface components {
|
|
|
5112
5031
|
/** Format: int64 */
|
|
5113
5032
|
block?: number | null;
|
|
5114
5033
|
/** Format: int64 */
|
|
5115
|
-
confirmed_at?: number | null;
|
|
5034
|
+
confirmed_at?: number | null;
|
|
5035
|
+
/** Format: int64 */
|
|
5036
|
+
received_at?: number | null;
|
|
5037
|
+
/** Format: int64 */
|
|
5038
|
+
log_index?: number | null;
|
|
5039
|
+
/** Format: int64 */
|
|
5040
|
+
block_index?: number | null;
|
|
5041
|
+
trader: components["schemas"]["TraderInfo"];
|
|
5042
|
+
condition_id?: string | null;
|
|
5043
|
+
outcome?: string | null;
|
|
5044
|
+
/** Format: int32 */
|
|
5045
|
+
outcome_index?: number | null;
|
|
5046
|
+
question?: string | null;
|
|
5047
|
+
image_url?: string | null;
|
|
5048
|
+
slug?: string | null;
|
|
5049
|
+
event_slug?: string | null;
|
|
5050
|
+
/** Format: double */
|
|
5051
|
+
usd_amount: number;
|
|
5052
|
+
/** Format: int32 */
|
|
5053
|
+
winning_outcome_index?: number | null;
|
|
5054
|
+
/** @description Per-position burn amounts */
|
|
5055
|
+
position_details?: components["schemas"]["PositionDetail"][];
|
|
5056
|
+
exchange: components["schemas"]["PolymarketExchange"];
|
|
5057
|
+
};
|
|
5058
|
+
/** @enum {string} */
|
|
5059
|
+
TradeSide: "0" | "1";
|
|
5060
|
+
/** @enum {string} */
|
|
5061
|
+
TradeType: "0" | "1" | "2" | "3" | "4" | "5" | "6" | "22" | "23" | "24";
|
|
5062
|
+
/** @description Output payload for RegisterToken events (YES/NO token pair registered for a condition). */
|
|
5063
|
+
RegisterTokenTrade: {
|
|
5064
|
+
id: string;
|
|
5065
|
+
hash: string;
|
|
5066
|
+
/** Format: int64 */
|
|
5067
|
+
block?: number | null;
|
|
5068
|
+
/** Format: int64 */
|
|
5069
|
+
confirmed_at?: number | null;
|
|
5070
|
+
/** Format: int64 */
|
|
5071
|
+
received_at?: number | null;
|
|
5072
|
+
/** Format: int64 */
|
|
5073
|
+
log_index?: number | null;
|
|
5074
|
+
/** Format: int64 */
|
|
5075
|
+
block_index?: number | null;
|
|
5076
|
+
condition_id: string;
|
|
5077
|
+
token0: string;
|
|
5078
|
+
token1: string;
|
|
5079
|
+
question?: string | null;
|
|
5080
|
+
image_url?: string | null;
|
|
5081
|
+
slug?: string | null;
|
|
5082
|
+
event_slug?: string | null;
|
|
5083
|
+
exchange: components["schemas"]["PolymarketExchange"];
|
|
5084
|
+
};
|
|
5085
|
+
TopTraderEventEntry: {
|
|
5086
|
+
trader: components["schemas"]["TraderInfo"];
|
|
5087
|
+
/** Format: double */
|
|
5088
|
+
realized_pnl_usd?: number | null;
|
|
5089
|
+
/** Format: double */
|
|
5090
|
+
realized_pnl_pct?: number | null;
|
|
5091
|
+
/** Format: double */
|
|
5092
|
+
total_volume_usd?: number | null;
|
|
5093
|
+
/** Format: double */
|
|
5094
|
+
buy_usd?: number | null;
|
|
5095
|
+
/** Format: double */
|
|
5096
|
+
sell_usd?: number | null;
|
|
5097
|
+
/** Format: double */
|
|
5098
|
+
redemption_usd?: number | null;
|
|
5099
|
+
/** Format: double */
|
|
5100
|
+
merge_usd?: number | null;
|
|
5101
|
+
/** Format: double */
|
|
5102
|
+
total_fees?: number | null;
|
|
5103
|
+
/** Format: int64 */
|
|
5104
|
+
total_buys?: number | null;
|
|
5105
|
+
/** Format: int64 */
|
|
5106
|
+
total_sells?: number | null;
|
|
5107
|
+
/** Format: int64 */
|
|
5108
|
+
total_redemptions?: number | null;
|
|
5109
|
+
/** Format: int64 */
|
|
5110
|
+
total_merges?: number | null;
|
|
5111
|
+
/** Format: int64 */
|
|
5112
|
+
markets_traded?: number | null;
|
|
5113
|
+
/** Format: int64 */
|
|
5114
|
+
outcomes_traded?: number | null;
|
|
5115
|
+
/** Format: int64 */
|
|
5116
|
+
winning_markets?: number | null;
|
|
5117
|
+
/** Format: int64 */
|
|
5118
|
+
losing_markets?: number | null;
|
|
5119
|
+
/** Format: int64 */
|
|
5120
|
+
first_trade_at?: number | null;
|
|
5121
|
+
/** Format: int64 */
|
|
5122
|
+
last_trade_at?: number | null;
|
|
5123
|
+
};
|
|
5124
|
+
/** @description V2 UMA OOv2: a price request was made (market initialization). */
|
|
5125
|
+
RequestPriceEvent: {
|
|
5126
|
+
id: string;
|
|
5127
|
+
hash: string;
|
|
5128
|
+
/** Format: int64 */
|
|
5129
|
+
block?: number | null;
|
|
5130
|
+
/** Format: int64 */
|
|
5131
|
+
confirmed_at?: number | null;
|
|
5132
|
+
/** Format: int64 */
|
|
5133
|
+
received_at?: number | null;
|
|
5134
|
+
/** Format: int64 */
|
|
5135
|
+
log_index?: number | null;
|
|
5136
|
+
/** Format: int64 */
|
|
5137
|
+
block_index?: number | null;
|
|
5138
|
+
oracle_contract: string;
|
|
5139
|
+
requester: string;
|
|
5140
|
+
identifier: string;
|
|
5141
|
+
/**
|
|
5142
|
+
* @description UMA request timestamp (seconds, decimal string).
|
|
5143
|
+
* The point in time the requester is asking the oracle to resolve the
|
|
5144
|
+
* price for — part of the request identity tuple
|
|
5145
|
+
* `(requester, identifier, timestamp, ancillaryData)`. Not the block
|
|
5146
|
+
* timestamp of this event; see `confirmed_at` for that.
|
|
5147
|
+
*/
|
|
5148
|
+
timestamp: string;
|
|
5149
|
+
ancillary_data: string;
|
|
5150
|
+
currency: string;
|
|
5151
|
+
reward: string;
|
|
5152
|
+
final_fee: string;
|
|
5153
|
+
condition_id?: string | null;
|
|
5154
|
+
question?: string | null;
|
|
5155
|
+
image_url?: string | null;
|
|
5156
|
+
slug?: string | null;
|
|
5157
|
+
event_slug?: string | null;
|
|
5158
|
+
};
|
|
5159
|
+
/** @description Counts of cohort traders active on day +1 / +7 / +30. */
|
|
5160
|
+
RetainedCounts: {
|
|
5161
|
+
/** Format: int64 */
|
|
5162
|
+
d1: number;
|
|
5163
|
+
/** Format: int64 */
|
|
5164
|
+
d7: number;
|
|
5165
|
+
/** Format: int64 */
|
|
5166
|
+
d30: number;
|
|
5167
|
+
};
|
|
5168
|
+
/** @description Retained counts as fractions of `cohort_size` (0 when cohort is empty). */
|
|
5169
|
+
RetentionFractions: {
|
|
5170
|
+
/** Format: double */
|
|
5171
|
+
d1: number;
|
|
5172
|
+
/** Format: double */
|
|
5173
|
+
d7: number;
|
|
5174
|
+
/** Format: double */
|
|
5175
|
+
d30: number;
|
|
5176
|
+
};
|
|
5177
|
+
/** @description Event-level PnL entry */
|
|
5178
|
+
TraderEventPnlEntry: {
|
|
5179
|
+
event_slug?: string | null;
|
|
5180
|
+
question?: string | null;
|
|
5181
|
+
image_url?: string | null;
|
|
5182
|
+
/** Format: int64 */
|
|
5183
|
+
markets_traded?: number | null;
|
|
5184
|
+
/** Format: int64 */
|
|
5185
|
+
outcomes_traded?: number | null;
|
|
5186
|
+
/** Format: int64 */
|
|
5187
|
+
total_buys?: number | null;
|
|
5188
|
+
/** Format: int64 */
|
|
5189
|
+
total_sells?: number | null;
|
|
5190
|
+
/** Format: int64 */
|
|
5191
|
+
total_redemptions?: number | null;
|
|
5192
|
+
/** Format: int64 */
|
|
5193
|
+
total_merges?: number | null;
|
|
5194
|
+
/** Format: double */
|
|
5195
|
+
total_volume_usd?: number | null;
|
|
5196
|
+
/** Format: double */
|
|
5197
|
+
buy_usd?: number | null;
|
|
5198
|
+
/** Format: double */
|
|
5199
|
+
sell_usd?: number | null;
|
|
5200
|
+
/** Format: double */
|
|
5201
|
+
redemption_usd?: number | null;
|
|
5202
|
+
/** Format: double */
|
|
5203
|
+
merge_usd?: number | null;
|
|
5204
|
+
/** Format: double */
|
|
5205
|
+
realized_pnl_usd?: number | null;
|
|
5206
|
+
/** Format: int64 */
|
|
5207
|
+
winning_markets?: number | null;
|
|
5208
|
+
/** Format: int64 */
|
|
5209
|
+
losing_markets?: number | null;
|
|
5210
|
+
/** Format: double */
|
|
5211
|
+
total_fees?: number | null;
|
|
5212
|
+
/** Format: int64 */
|
|
5213
|
+
first_trade_at?: number | null;
|
|
5214
|
+
/** Format: int64 */
|
|
5215
|
+
last_trade_at?: number | null;
|
|
5216
|
+
/** Format: double */
|
|
5217
|
+
realized_pnl_pct?: number | null;
|
|
5218
|
+
};
|
|
5219
|
+
/**
|
|
5220
|
+
* @description Bucket row returned by both `/analytics/timeseries` (cumulative values
|
|
5221
|
+
* at end of bucket) and `/analytics/deltas` (per-bucket deltas). All metrics
|
|
5222
|
+
* the snapshot `/counts` returns are included.
|
|
5223
|
+
*
|
|
5224
|
+
* Short field names for compact JSON responses:
|
|
5225
|
+
* t=bucket (unix seconds), v=volume_usd, bv=buy_volume_usd, sv=sell_volume_usd,
|
|
5226
|
+
* ut=unique_traders, um=unique_makers, uk=unique_takers,
|
|
5227
|
+
* tc=txn_count, bc=buy_count, sc=sell_count,
|
|
5228
|
+
* rc=redemption_count, rv=redemption_volume_usd, mc=merge_count, mv=merge_volume_usd,
|
|
5229
|
+
* sp=split_count, spv=split_volume_usd, f=fees_usd, sh=shares_volume,
|
|
5230
|
+
* yv=yes_volume_usd, nv=no_volume_usd, yc=yes_count, nc=no_count,
|
|
5231
|
+
* bd_*=buy distribution by USD bucket
|
|
5232
|
+
*/
|
|
5233
|
+
TimeBucketRow: {
|
|
5234
|
+
/** Format: int32 */
|
|
5235
|
+
t: number;
|
|
5236
|
+
/** Format: double */
|
|
5237
|
+
v: number;
|
|
5238
|
+
/** Format: double */
|
|
5239
|
+
bv: number;
|
|
5240
|
+
/** Format: double */
|
|
5241
|
+
sv: number;
|
|
5242
|
+
/** Format: int64 */
|
|
5243
|
+
tc: number;
|
|
5244
|
+
/** Format: int64 */
|
|
5245
|
+
bc: number;
|
|
5246
|
+
/** Format: int64 */
|
|
5247
|
+
sc: number;
|
|
5248
|
+
/** Format: int64 */
|
|
5249
|
+
rc: number;
|
|
5250
|
+
/** Format: double */
|
|
5251
|
+
rv: number;
|
|
5252
|
+
/** Format: int64 */
|
|
5253
|
+
mc: number;
|
|
5254
|
+
/** Format: double */
|
|
5255
|
+
mv: number;
|
|
5256
|
+
/** Format: int64 */
|
|
5257
|
+
sp: number;
|
|
5258
|
+
/** Format: double */
|
|
5259
|
+
spv: number;
|
|
5260
|
+
/** Format: double */
|
|
5261
|
+
f: number;
|
|
5262
|
+
/** Format: double */
|
|
5263
|
+
sh: number;
|
|
5264
|
+
/** Format: double */
|
|
5265
|
+
yv: number;
|
|
5266
|
+
/** Format: double */
|
|
5267
|
+
nv: number;
|
|
5268
|
+
/** Format: int64 */
|
|
5269
|
+
yc: number;
|
|
5270
|
+
/** Format: int64 */
|
|
5271
|
+
nc: number;
|
|
5272
|
+
/**
|
|
5273
|
+
* Format: int64
|
|
5274
|
+
* @description Buy distribution — count of buy trades falling in each USD bucket.
|
|
5275
|
+
*/
|
|
5276
|
+
bd_u10: number;
|
|
5277
|
+
/** Format: int64 */
|
|
5278
|
+
bd_100: number;
|
|
5279
|
+
/** Format: int64 */
|
|
5280
|
+
bd_1k: number;
|
|
5116
5281
|
/** Format: int64 */
|
|
5117
|
-
|
|
5282
|
+
bd_10k: number;
|
|
5118
5283
|
/** Format: int64 */
|
|
5119
|
-
|
|
5284
|
+
bd_50k: number;
|
|
5120
5285
|
/** Format: int64 */
|
|
5121
|
-
|
|
5122
|
-
|
|
5123
|
-
|
|
5124
|
-
|
|
5125
|
-
|
|
5126
|
-
|
|
5127
|
-
|
|
5128
|
-
|
|
5129
|
-
|
|
5130
|
-
|
|
5131
|
-
|
|
5132
|
-
|
|
5133
|
-
|
|
5134
|
-
|
|
5135
|
-
|
|
5136
|
-
|
|
5137
|
-
|
|
5286
|
+
bd_50p: number;
|
|
5287
|
+
/**
|
|
5288
|
+
* Format: int64
|
|
5289
|
+
* @description Distinct traders ACTIVE in this bucket (window-unique, not first-time).
|
|
5290
|
+
*/
|
|
5291
|
+
ut: number;
|
|
5292
|
+
/**
|
|
5293
|
+
* Format: int64
|
|
5294
|
+
* @description Distinct makers active in this bucket.
|
|
5295
|
+
*/
|
|
5296
|
+
um: number;
|
|
5297
|
+
/**
|
|
5298
|
+
* Format: int64
|
|
5299
|
+
* @description Distinct takers active in this bucket.
|
|
5300
|
+
*/
|
|
5301
|
+
uk: number;
|
|
5302
|
+
};
|
|
5303
|
+
SearchResponse: {
|
|
5304
|
+
events?: components["schemas"]["PolymarketEvent"][] | null;
|
|
5305
|
+
events_pagination?: null | components["schemas"]["PaginationMeta"];
|
|
5306
|
+
markets?: components["schemas"]["MarketResponse"][] | null;
|
|
5307
|
+
markets_pagination?: null | components["schemas"]["PaginationMeta"];
|
|
5308
|
+
traders?: components["schemas"]["TraderWithPnl"][] | null;
|
|
5309
|
+
traders_pagination?: null | components["schemas"]["PaginationMeta"];
|
|
5310
|
+
builders?: components["schemas"]["BuilderMetadata"][] | null;
|
|
5311
|
+
builders_pagination?: null | components["schemas"]["PaginationMeta"];
|
|
5138
5312
|
};
|
|
5139
5313
|
/**
|
|
5140
|
-
* @description
|
|
5141
|
-
* (or `lifetime` for all-time cumulative).
|
|
5314
|
+
* @description Combined sort options valid for both events and markets in search
|
|
5142
5315
|
* @enum {string}
|
|
5143
5316
|
*/
|
|
5144
|
-
|
|
5145
|
-
/** @description
|
|
5146
|
-
|
|
5147
|
-
token_id: string;
|
|
5148
|
-
outcome: string;
|
|
5149
|
-
};
|
|
5150
|
-
/** @description Output payload for RegisterToken events (YES/NO token pair registered for a condition). */
|
|
5151
|
-
RegisterTokenTrade: {
|
|
5317
|
+
SearchSortBy: "volume" | "txns" | "unique_traders" | "relevance" | "title" | "creation_date" | "start_date" | "end_date" | "liquidity" | "holders" | "end_time" | "start_time" | "created_time";
|
|
5318
|
+
/** @description V2 UMA OOv2: a price request was settled (final resolution). */
|
|
5319
|
+
SettleEvent: {
|
|
5152
5320
|
id: string;
|
|
5153
5321
|
hash: string;
|
|
5154
5322
|
/** Format: int64 */
|
|
@@ -5161,15 +5329,29 @@ export interface components {
|
|
|
5161
5329
|
log_index?: number | null;
|
|
5162
5330
|
/** Format: int64 */
|
|
5163
5331
|
block_index?: number | null;
|
|
5164
|
-
|
|
5165
|
-
|
|
5166
|
-
|
|
5332
|
+
oracle_contract: string;
|
|
5333
|
+
requester: string;
|
|
5334
|
+
proposer: string;
|
|
5335
|
+
disputer: string;
|
|
5336
|
+
identifier: string;
|
|
5337
|
+
timestamp: string;
|
|
5338
|
+
ancillary_data: string;
|
|
5339
|
+
/** Format: int64 */
|
|
5340
|
+
proposed_price: number;
|
|
5341
|
+
payout: string;
|
|
5342
|
+
disputed: boolean;
|
|
5343
|
+
condition_id?: string | null;
|
|
5344
|
+
proposed_outcome?: string | null;
|
|
5167
5345
|
question?: string | null;
|
|
5168
5346
|
image_url?: string | null;
|
|
5169
5347
|
slug?: string | null;
|
|
5170
5348
|
event_slug?: string | null;
|
|
5171
|
-
exchange: components["schemas"]["PolymarketExchange"];
|
|
5172
5349
|
};
|
|
5350
|
+
/**
|
|
5351
|
+
* @description Direction filter for spike webhooks.
|
|
5352
|
+
* @enum {string}
|
|
5353
|
+
*/
|
|
5354
|
+
SpikeDirection: "up" | "down" | "both";
|
|
5173
5355
|
SimpleTimeframeMetrics: {
|
|
5174
5356
|
/**
|
|
5175
5357
|
* Format: double
|
|
@@ -5220,78 +5402,26 @@ export interface components {
|
|
|
5220
5402
|
* Format: int32
|
|
5221
5403
|
* @default 0
|
|
5222
5404
|
*/
|
|
5223
|
-
|
|
5224
|
-
};
|
|
5225
|
-
/** @description V2 UMA OOv2: a price request was made (market initialization). */
|
|
5226
|
-
RequestPriceEvent: {
|
|
5227
|
-
id: string;
|
|
5228
|
-
hash: string;
|
|
5229
|
-
/** Format: int64 */
|
|
5230
|
-
block?: number | null;
|
|
5231
|
-
/** Format: int64 */
|
|
5232
|
-
confirmed_at?: number | null;
|
|
5233
|
-
/** Format: int64 */
|
|
5234
|
-
received_at?: number | null;
|
|
5235
|
-
/** Format: int64 */
|
|
5236
|
-
log_index?: number | null;
|
|
5237
|
-
/** Format: int64 */
|
|
5238
|
-
block_index?: number | null;
|
|
5239
|
-
oracle_contract: string;
|
|
5240
|
-
requester: string;
|
|
5241
|
-
identifier: string;
|
|
5405
|
+
unique_makers: number;
|
|
5242
5406
|
/**
|
|
5243
|
-
*
|
|
5244
|
-
*
|
|
5245
|
-
* price for — part of the request identity tuple
|
|
5246
|
-
* `(requester, identifier, timestamp, ancillaryData)`. Not the block
|
|
5247
|
-
* timestamp of this event; see `confirmed_at` for that.
|
|
5407
|
+
* Format: int32
|
|
5408
|
+
* @default 0
|
|
5248
5409
|
*/
|
|
5249
|
-
|
|
5250
|
-
|
|
5251
|
-
|
|
5252
|
-
|
|
5253
|
-
|
|
5254
|
-
|
|
5255
|
-
question?: string | null;
|
|
5256
|
-
image_url?: string | null;
|
|
5257
|
-
slug?: string | null;
|
|
5258
|
-
event_slug?: string | null;
|
|
5259
|
-
};
|
|
5260
|
-
/** @description Counts of cohort traders active on day +1 / +7 / +30. */
|
|
5261
|
-
RetainedCounts: {
|
|
5262
|
-
/** Format: int64 */
|
|
5263
|
-
d1: number;
|
|
5264
|
-
/** Format: int64 */
|
|
5265
|
-
d7: number;
|
|
5266
|
-
/** Format: int64 */
|
|
5267
|
-
d30: number;
|
|
5410
|
+
unique_takers: number;
|
|
5411
|
+
/**
|
|
5412
|
+
* Format: int32
|
|
5413
|
+
* @default 0
|
|
5414
|
+
*/
|
|
5415
|
+
unique_builder_traders: number;
|
|
5268
5416
|
};
|
|
5269
|
-
|
|
5270
|
-
|
|
5417
|
+
TopTraderPositionEntry: {
|
|
5418
|
+
trader: components["schemas"]["TraderInfo"];
|
|
5271
5419
|
/** Format: double */
|
|
5272
|
-
|
|
5420
|
+
realized_pnl_usd?: number | null;
|
|
5273
5421
|
/** Format: double */
|
|
5274
|
-
|
|
5422
|
+
realized_pnl_pct?: number | null;
|
|
5275
5423
|
/** Format: double */
|
|
5276
|
-
|
|
5277
|
-
};
|
|
5278
|
-
/** @description Market-level PnL entry */
|
|
5279
|
-
TraderMarketPnlEntry: {
|
|
5280
|
-
condition_id?: string | null;
|
|
5281
|
-
market_slug?: string | null;
|
|
5282
|
-
event_slug?: string | null;
|
|
5283
|
-
question?: string | null;
|
|
5284
|
-
image_url?: string | null;
|
|
5285
|
-
/** Format: int64 */
|
|
5286
|
-
outcomes_traded?: number | null;
|
|
5287
|
-
/** Format: int64 */
|
|
5288
|
-
total_buys?: number | null;
|
|
5289
|
-
/** Format: int64 */
|
|
5290
|
-
total_sells?: number | null;
|
|
5291
|
-
/** Format: int64 */
|
|
5292
|
-
total_redemptions?: number | null;
|
|
5293
|
-
/** Format: int64 */
|
|
5294
|
-
total_merges?: number | null;
|
|
5424
|
+
shares?: number | null;
|
|
5295
5425
|
/** Format: double */
|
|
5296
5426
|
buy_usd?: number | null;
|
|
5297
5427
|
/** Format: double */
|
|
@@ -5299,37 +5429,21 @@ export interface components {
|
|
|
5299
5429
|
/** Format: double */
|
|
5300
5430
|
redemption_usd?: number | null;
|
|
5301
5431
|
/** Format: double */
|
|
5302
|
-
|
|
5432
|
+
total_fees?: number | null;
|
|
5303
5433
|
/** Format: double */
|
|
5304
|
-
|
|
5305
|
-
/** Format: int64 */
|
|
5306
|
-
winning_outcomes?: number | null;
|
|
5434
|
+
avg_entry_price?: number | null;
|
|
5307
5435
|
/** Format: double */
|
|
5308
|
-
|
|
5436
|
+
avg_exit_price?: number | null;
|
|
5437
|
+
/** Format: int64 */
|
|
5438
|
+
total_buys?: number | null;
|
|
5439
|
+
/** Format: int64 */
|
|
5440
|
+
total_sells?: number | null;
|
|
5441
|
+
won?: boolean | null;
|
|
5309
5442
|
/** Format: int64 */
|
|
5310
5443
|
first_trade_at?: number | null;
|
|
5311
5444
|
/** Format: int64 */
|
|
5312
5445
|
last_trade_at?: number | null;
|
|
5313
|
-
/** Format: double */
|
|
5314
|
-
realized_pnl_pct?: number | null;
|
|
5315
|
-
};
|
|
5316
|
-
/** @enum {string} */
|
|
5317
|
-
TagChangeTimeframe: "1h" | "24h" | "7d" | "30d" | "1mo";
|
|
5318
|
-
SearchResponse: {
|
|
5319
|
-
events?: components["schemas"]["PolymarketEvent"][] | null;
|
|
5320
|
-
events_pagination?: null | components["schemas"]["PaginationMeta"];
|
|
5321
|
-
markets?: components["schemas"]["MarketResponse"][] | null;
|
|
5322
|
-
markets_pagination?: null | components["schemas"]["PaginationMeta"];
|
|
5323
|
-
traders?: components["schemas"]["TraderWithPnl"][] | null;
|
|
5324
|
-
traders_pagination?: null | components["schemas"]["PaginationMeta"];
|
|
5325
|
-
builders?: components["schemas"]["BuilderMetadata"][] | null;
|
|
5326
|
-
builders_pagination?: null | components["schemas"]["PaginationMeta"];
|
|
5327
5446
|
};
|
|
5328
|
-
/**
|
|
5329
|
-
* @description Combined sort options valid for both events and markets in search
|
|
5330
|
-
* @enum {string}
|
|
5331
|
-
*/
|
|
5332
|
-
SearchSortBy: "volume" | "txns" | "unique_traders" | "relevance" | "title" | "creation_date" | "start_date" | "end_date" | "liquidity" | "holders" | "end_time" | "start_time" | "created_time";
|
|
5333
5447
|
};
|
|
5334
5448
|
responses: never;
|
|
5335
5449
|
parameters: never;
|
|
@@ -5500,6 +5614,39 @@ export interface operations {
|
|
|
5500
5614
|
};
|
|
5501
5615
|
};
|
|
5502
5616
|
};
|
|
5617
|
+
get_asset_candlestick: {
|
|
5618
|
+
parameters: {
|
|
5619
|
+
query: {
|
|
5620
|
+
/** @description Asset ticker: BTC, ETH, XRP, SOL, DOGE, BNB, HYPE */
|
|
5621
|
+
asset_symbol: components["schemas"]["AssetSymbol"];
|
|
5622
|
+
/** @description Candle interval: 1, 5, 15, 30, 60, 240, D, 1D */
|
|
5623
|
+
resolution: components["schemas"]["CandlestickResolution"];
|
|
5624
|
+
/** @description Number of candles (max: 2500) */
|
|
5625
|
+
count_back?: number;
|
|
5626
|
+
/** @description Start timestamp (Unix seconds) */
|
|
5627
|
+
from?: number;
|
|
5628
|
+
/** @description End timestamp (Unix seconds) */
|
|
5629
|
+
to?: number;
|
|
5630
|
+
/** @description Cursor-based pagination key from previous response */
|
|
5631
|
+
pagination_key?: string;
|
|
5632
|
+
};
|
|
5633
|
+
header?: never;
|
|
5634
|
+
path?: never;
|
|
5635
|
+
cookie?: never;
|
|
5636
|
+
};
|
|
5637
|
+
requestBody?: never;
|
|
5638
|
+
responses: {
|
|
5639
|
+
/** @description OHLC candlestick data */
|
|
5640
|
+
200: {
|
|
5641
|
+
headers: {
|
|
5642
|
+
[name: string]: unknown;
|
|
5643
|
+
};
|
|
5644
|
+
content: {
|
|
5645
|
+
"application/json": components["schemas"]["AssetCandlestickBar"][];
|
|
5646
|
+
};
|
|
5647
|
+
};
|
|
5648
|
+
};
|
|
5649
|
+
};
|
|
5503
5650
|
list_builders: {
|
|
5504
5651
|
parameters: {
|
|
5505
5652
|
query?: {
|
|
@@ -5797,13 +5944,13 @@ export interface operations {
|
|
|
5797
5944
|
};
|
|
5798
5945
|
requestBody?: never;
|
|
5799
5946
|
responses: {
|
|
5800
|
-
/** @description Per-builder breakdown */
|
|
5947
|
+
/** @description Per-builder breakdown, each with embedded display metadata. */
|
|
5801
5948
|
200: {
|
|
5802
5949
|
headers: {
|
|
5803
5950
|
[name: string]: unknown;
|
|
5804
5951
|
};
|
|
5805
5952
|
content: {
|
|
5806
|
-
"application/json": components["schemas"]["
|
|
5953
|
+
"application/json": components["schemas"]["TagBuilderRowWithMetadata"][];
|
|
5807
5954
|
};
|
|
5808
5955
|
};
|
|
5809
5956
|
};
|
|
@@ -7138,54 +7285,7 @@ export interface operations {
|
|
|
7138
7285
|
[name: string]: unknown;
|
|
7139
7286
|
};
|
|
7140
7287
|
content: {
|
|
7141
|
-
"application/json":
|
|
7142
|
-
condition_id: string;
|
|
7143
|
-
id?: string | null;
|
|
7144
|
-
market_slug?: string | null;
|
|
7145
|
-
question?: string | null;
|
|
7146
|
-
title?: string | null;
|
|
7147
|
-
description?: string | null;
|
|
7148
|
-
image_url?: string | null;
|
|
7149
|
-
oracle?: string | null;
|
|
7150
|
-
status: string;
|
|
7151
|
-
/** Format: int64 */
|
|
7152
|
-
created_time?: number | null;
|
|
7153
|
-
/** Format: int64 */
|
|
7154
|
-
start_time?: number | null;
|
|
7155
|
-
/** Format: int64 */
|
|
7156
|
-
game_start_time?: number | null;
|
|
7157
|
-
/** Format: int64 */
|
|
7158
|
-
closed_time?: number | null;
|
|
7159
|
-
/** Format: int64 */
|
|
7160
|
-
end_time?: number | null;
|
|
7161
|
-
accepting_orders?: boolean | null;
|
|
7162
|
-
uma_resolution_status?: string | null;
|
|
7163
|
-
is_neg_risk?: boolean | null;
|
|
7164
|
-
market_maker_address?: string | null;
|
|
7165
|
-
creator?: string | null;
|
|
7166
|
-
category?: string | null;
|
|
7167
|
-
/** Format: double */
|
|
7168
|
-
volume_usd?: number | null;
|
|
7169
|
-
/** Format: double */
|
|
7170
|
-
liquidity_usd?: number | null;
|
|
7171
|
-
/** Format: double */
|
|
7172
|
-
highest_probability?: number | null;
|
|
7173
|
-
/** Format: int64 */
|
|
7174
|
-
total_holders?: number | null;
|
|
7175
|
-
/** Format: double */
|
|
7176
|
-
total_daily_rate?: number | null;
|
|
7177
|
-
winning_outcome?: null | components["schemas"]["MarketOutcome"];
|
|
7178
|
-
outcomes?: components["schemas"]["MarketOutcome"][];
|
|
7179
|
-
clob_rewards?: components["schemas"]["ClobReward"][];
|
|
7180
|
-
tags?: string[];
|
|
7181
|
-
event_slug?: string | null;
|
|
7182
|
-
resolution_source?: string | null;
|
|
7183
|
-
metrics?: {
|
|
7184
|
-
[key: string]: components["schemas"]["SimpleTimeframeMetrics"];
|
|
7185
|
-
};
|
|
7186
|
-
/** Format: double */
|
|
7187
|
-
relevance_score?: number | null;
|
|
7188
|
-
}[];
|
|
7288
|
+
"application/json": components["schemas"]["MarketResponse"][];
|
|
7189
7289
|
};
|
|
7190
7290
|
};
|
|
7191
7291
|
/** @description Market not found */
|
|
@@ -7373,54 +7473,7 @@ export interface operations {
|
|
|
7373
7473
|
[name: string]: unknown;
|
|
7374
7474
|
};
|
|
7375
7475
|
content: {
|
|
7376
|
-
"application/json":
|
|
7377
|
-
condition_id: string;
|
|
7378
|
-
id?: string | null;
|
|
7379
|
-
market_slug?: string | null;
|
|
7380
|
-
question?: string | null;
|
|
7381
|
-
title?: string | null;
|
|
7382
|
-
description?: string | null;
|
|
7383
|
-
image_url?: string | null;
|
|
7384
|
-
oracle?: string | null;
|
|
7385
|
-
status: string;
|
|
7386
|
-
/** Format: int64 */
|
|
7387
|
-
created_time?: number | null;
|
|
7388
|
-
/** Format: int64 */
|
|
7389
|
-
start_time?: number | null;
|
|
7390
|
-
/** Format: int64 */
|
|
7391
|
-
game_start_time?: number | null;
|
|
7392
|
-
/** Format: int64 */
|
|
7393
|
-
closed_time?: number | null;
|
|
7394
|
-
/** Format: int64 */
|
|
7395
|
-
end_time?: number | null;
|
|
7396
|
-
accepting_orders?: boolean | null;
|
|
7397
|
-
uma_resolution_status?: string | null;
|
|
7398
|
-
is_neg_risk?: boolean | null;
|
|
7399
|
-
market_maker_address?: string | null;
|
|
7400
|
-
creator?: string | null;
|
|
7401
|
-
category?: string | null;
|
|
7402
|
-
/** Format: double */
|
|
7403
|
-
volume_usd?: number | null;
|
|
7404
|
-
/** Format: double */
|
|
7405
|
-
liquidity_usd?: number | null;
|
|
7406
|
-
/** Format: double */
|
|
7407
|
-
highest_probability?: number | null;
|
|
7408
|
-
/** Format: int64 */
|
|
7409
|
-
total_holders?: number | null;
|
|
7410
|
-
/** Format: double */
|
|
7411
|
-
total_daily_rate?: number | null;
|
|
7412
|
-
winning_outcome?: null | components["schemas"]["MarketOutcome"];
|
|
7413
|
-
outcomes?: components["schemas"]["MarketOutcome"][];
|
|
7414
|
-
clob_rewards?: components["schemas"]["ClobReward"][];
|
|
7415
|
-
tags?: string[];
|
|
7416
|
-
event_slug?: string | null;
|
|
7417
|
-
resolution_source?: string | null;
|
|
7418
|
-
metrics?: {
|
|
7419
|
-
[key: string]: components["schemas"]["SimpleTimeframeMetrics"];
|
|
7420
|
-
};
|
|
7421
|
-
/** Format: double */
|
|
7422
|
-
relevance_score?: number | null;
|
|
7423
|
-
}[];
|
|
7476
|
+
"application/json": components["schemas"]["MarketResponse"][];
|
|
7424
7477
|
};
|
|
7425
7478
|
};
|
|
7426
7479
|
/** @description Market not found */
|