@liberfi.io/react-predict 0.1.63 → 0.1.64

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.
@@ -734,6 +734,10 @@ type WsServerMessage = WsPongMessage | WsSubscribedMessage | WsErrorMessage | Ws
734
734
  interface TickSizeResponse {
735
735
  minimum_tick_size: number;
736
736
  }
737
+ /** Response from the Polymarket fee-rate endpoint. */
738
+ interface FeeRateResponse {
739
+ base_fee: number;
740
+ }
737
741
  /** Aggregate statistics for all open prediction events. */
738
742
  interface EventStats {
739
743
  total_events: number;
@@ -901,6 +905,8 @@ declare class PredictClient {
901
905
  createPolymarketOrder(input: CreateOrderInput, headers: Record<string, string>): Promise<PredictOrder>;
902
906
  /** Maps to `GET /api/v1/polymarket/tick-size?token_id=xxx`. */
903
907
  getPolymarketTickSize(tokenId: string): Promise<TickSizeResponse>;
908
+ /** Maps to `GET /api/v1/polymarket/fee-rate?token_id=xxx`. */
909
+ getPolymarketFeeRate(tokenId: string): Promise<FeeRateResponse>;
904
910
  /** Maps to `POST /api/v1/orders/kalshi/quote`. */
905
911
  createDFlowQuote(body: DFlowQuoteRequest): Promise<DFlowQuoteResponse>;
906
912
  /** Maps to `POST /api/v1/orders/kalshi/submit`. */
@@ -1451,6 +1457,8 @@ interface BuildOrderMessageInput extends CreateOrderInput {
1451
1457
  signerAddress: string;
1452
1458
  /** Signature type (0 = EOA, 1 = Magic, 2 = Poly Proxy). */
1453
1459
  signatureType: 0 | 1 | 2;
1460
+ /** Fee rate in basis points from the CLOB fee-rate endpoint. Defaults to "0". */
1461
+ feeRateBps?: string;
1454
1462
  }
1455
1463
  interface OrderMessage {
1456
1464
  salt: string;
@@ -1555,4 +1563,4 @@ interface ClobOrderPayload {
1555
1563
  */
1556
1564
  declare function buildClobPayload(signedOrder: SignedOrder, owner: string): ClobOrderPayload;
1557
1565
 
1558
- export { type CreateOrderInput as $, type AvailableSharesResponse as A, type BalanceResponse as B, type Candlestick as C, type DFlowQuoteRequest as D, type EventStats as E, type DFlowSubmitRequest as F, type DFlowKYCStatus as G, type PolymarketSetupStatus as H, type WithdrawBuildRequest as I, type WithdrawSubmitResponse as J, type WithdrawSubmitRequest as K, type ListEventsParams as L, type MatchesParams as M, type WithdrawStatusResponse as N, type Orderbook as O, PredictClient as P, type PolymarketDepositAddresses as Q, type PolymarketWithdrawResponse as R, type SimilarEventsParams as S, type PolymarketWithdrawRequest as T, type TickSizeResponse as U, type WsConnectionStatus as V, type WithdrawBuildResponse as W, type WsDataMessage as X, type WsPriceEvent as Y, type WsOrderbookEvent as Z, type WsTradeEvent as _, PredictWsClient as a, buildPolymarketL2Headers as a$, createPredictClient as a0, createPredictWsClient as a1, type PredictWsClientConfig as a2, type ProviderMeta as a3, type PredictTag as a4, type SettlementSource as a5, type MarketStatus as a6, type MarketResult as a7, type MarketOutcome as a8, type OrderbookLevel as a9, type WsClientMessage as aA, type WsSubscribeMessage as aB, type WsPingMessage as aC, type WsServerMessage as aD, type WsPongMessage as aE, type WsSubscribedMessage as aF, type WsErrorCode as aG, type WsErrorMessage as aH, eventQueryKey as aI, fetchEvent as aJ, resolveTagSlug as aK, resolveEventsParams as aL, infiniteEventsQueryKey as aM, fetchEventsPage as aN, type ResolveEventsParamsInput as aO, type TagSlugSelection as aP, marketQueryKey as aQ, fetchMarket as aR, matchesQueryKey as aS, matchQueryKey as aT, fetchMatchesPage as aU, matchMarketsQueryKey as aV, fetchMatchMarketsPage as aW, CLOB_AUTH_DOMAIN as aX, CLOB_AUTH_TYPES as aY, buildClobAuthMessage as aZ, hmacSha256Base64 as a_, type TradeType as aa, type EventSummary as ab, type MarketSummary as ac, type PricePoint as ad, type PredictPosition as ae, type OrderStatus as af, type OrderSide as ag, type DFlowOrderContext as ah, type PolymarketOrderType as ai, type DepositBuildRequest as aj, type DepositBuildResponse as ak, type DepositSubmitRequest as al, type DepositSubmitResponse as am, type DepositStatusResponse as an, type UnsignedTx as ao, type PolymarketWithdrawPrepareRequest as ap, type PolymarketWithdrawPrepareResponse as aq, type MatchStatus as ar, type MatchGroupEntry as as, type MatchGroupMarket as at, type MatchSortField as au, type MatchesStats as av, type MatchConfidenceTier as aw, type MatchMarketFlat as ax, type WsChannel as ay, type WsChannelEvent as az, type PredictPage as b, derivePolymarketApiKey as b0, type HttpMethod as b1, type PolymarketL2HeadersInput as b2, type PolymarketL2Headers as b3, type BuildClobAuthMessageInput as b4, CTF_EXCHANGE_ADDRESS as b5, NEG_RISK_CTF_EXCHANGE_ADDRESS as b6, USDC_ADDRESS as b7, POLYGON_CHAIN_ID as b8, buildCtfExchangeDomain as b9, CTF_ORDER_TYPES as ba, ORDER_TYPE as bb, SIDE as bc, buildOrderMessage as bd, buildSignedOrder as be, buildClobPayload as bf, type ClobOrderPayload as bg, type BuildOrderMessageInput as bh, type OrderMessage as bi, type SignedOrder as bj, DEFAULT_PAGE_SIZE as bk, type PredictEvent as c, type ProviderSource as d, type EventStatus as e, type EventSortField as f, type PredictMarket as g, type ListMarketTradesParams as h, type PredictTrade as i, type PriceHistoryRange as j, type PriceHistoryResponse as k, type ListCandlesticksParams as l, type PositionsResponse as m, type ListOrdersParams as n, type PredictOrder as o, type ListOrdersMultiParams as p, type PredictOrdersResponse as q, type CancelOrderResult as r, type MatchGroupPage as s, type MatchGroup as t, type MatchMarketParams as u, type MatchMarketPage as v, type ListTradesParams as w, type ListTradesMultiParams as x, type DFlowQuoteResponse as y, type DFlowSubmitResponse as z };
1566
+ export { type WsTradeEvent as $, type AvailableSharesResponse as A, type BalanceResponse as B, type Candlestick as C, type DFlowQuoteRequest as D, type EventStats as E, type DFlowSubmitRequest as F, type DFlowKYCStatus as G, type PolymarketSetupStatus as H, type WithdrawBuildRequest as I, type WithdrawSubmitResponse as J, type WithdrawSubmitRequest as K, type ListEventsParams as L, type MatchesParams as M, type WithdrawStatusResponse as N, type Orderbook as O, PredictClient as P, type PolymarketDepositAddresses as Q, type PolymarketWithdrawResponse as R, type SimilarEventsParams as S, type PolymarketWithdrawRequest as T, type TickSizeResponse as U, type FeeRateResponse as V, type WithdrawBuildResponse as W, type WsConnectionStatus as X, type WsDataMessage as Y, type WsPriceEvent as Z, type WsOrderbookEvent as _, PredictWsClient as a, hmacSha256Base64 as a$, type CreateOrderInput as a0, createPredictClient as a1, createPredictWsClient as a2, type PredictWsClientConfig as a3, type ProviderMeta as a4, type PredictTag as a5, type SettlementSource as a6, type MarketStatus as a7, type MarketResult as a8, type MarketOutcome as a9, type WsChannelEvent as aA, type WsClientMessage as aB, type WsSubscribeMessage as aC, type WsPingMessage as aD, type WsServerMessage as aE, type WsPongMessage as aF, type WsSubscribedMessage as aG, type WsErrorCode as aH, type WsErrorMessage as aI, eventQueryKey as aJ, fetchEvent as aK, resolveTagSlug as aL, resolveEventsParams as aM, infiniteEventsQueryKey as aN, fetchEventsPage as aO, type ResolveEventsParamsInput as aP, type TagSlugSelection as aQ, marketQueryKey as aR, fetchMarket as aS, matchesQueryKey as aT, matchQueryKey as aU, fetchMatchesPage as aV, matchMarketsQueryKey as aW, fetchMatchMarketsPage as aX, CLOB_AUTH_DOMAIN as aY, CLOB_AUTH_TYPES as aZ, buildClobAuthMessage as a_, type OrderbookLevel as aa, type TradeType as ab, type EventSummary as ac, type MarketSummary as ad, type PricePoint as ae, type PredictPosition as af, type OrderStatus as ag, type OrderSide as ah, type DFlowOrderContext as ai, type PolymarketOrderType as aj, type DepositBuildRequest as ak, type DepositBuildResponse as al, type DepositSubmitRequest as am, type DepositSubmitResponse as an, type DepositStatusResponse as ao, type UnsignedTx as ap, type PolymarketWithdrawPrepareRequest as aq, type PolymarketWithdrawPrepareResponse as ar, type MatchStatus as as, type MatchGroupEntry as at, type MatchGroupMarket as au, type MatchSortField as av, type MatchesStats as aw, type MatchConfidenceTier as ax, type MatchMarketFlat as ay, type WsChannel as az, type PredictPage as b, buildPolymarketL2Headers as b0, derivePolymarketApiKey as b1, type HttpMethod as b2, type PolymarketL2HeadersInput as b3, type PolymarketL2Headers as b4, type BuildClobAuthMessageInput as b5, CTF_EXCHANGE_ADDRESS as b6, NEG_RISK_CTF_EXCHANGE_ADDRESS as b7, USDC_ADDRESS as b8, POLYGON_CHAIN_ID as b9, buildCtfExchangeDomain as ba, CTF_ORDER_TYPES as bb, ORDER_TYPE as bc, SIDE as bd, buildOrderMessage as be, buildSignedOrder as bf, buildClobPayload as bg, type ClobOrderPayload as bh, type BuildOrderMessageInput as bi, type OrderMessage as bj, type SignedOrder as bk, DEFAULT_PAGE_SIZE as bl, type PredictEvent as c, type ProviderSource as d, type EventStatus as e, type EventSortField as f, type PredictMarket as g, type ListMarketTradesParams as h, type PredictTrade as i, type PriceHistoryRange as j, type PriceHistoryResponse as k, type ListCandlesticksParams as l, type PositionsResponse as m, type ListOrdersParams as n, type PredictOrder as o, type ListOrdersMultiParams as p, type PredictOrdersResponse as q, type CancelOrderResult as r, type MatchGroupPage as s, type MatchGroup as t, type MatchMarketParams as u, type MatchMarketPage as v, type ListTradesParams as w, type ListTradesMultiParams as x, type DFlowQuoteResponse as y, type DFlowSubmitResponse as z };
@@ -734,6 +734,10 @@ type WsServerMessage = WsPongMessage | WsSubscribedMessage | WsErrorMessage | Ws
734
734
  interface TickSizeResponse {
735
735
  minimum_tick_size: number;
736
736
  }
737
+ /** Response from the Polymarket fee-rate endpoint. */
738
+ interface FeeRateResponse {
739
+ base_fee: number;
740
+ }
737
741
  /** Aggregate statistics for all open prediction events. */
738
742
  interface EventStats {
739
743
  total_events: number;
@@ -901,6 +905,8 @@ declare class PredictClient {
901
905
  createPolymarketOrder(input: CreateOrderInput, headers: Record<string, string>): Promise<PredictOrder>;
902
906
  /** Maps to `GET /api/v1/polymarket/tick-size?token_id=xxx`. */
903
907
  getPolymarketTickSize(tokenId: string): Promise<TickSizeResponse>;
908
+ /** Maps to `GET /api/v1/polymarket/fee-rate?token_id=xxx`. */
909
+ getPolymarketFeeRate(tokenId: string): Promise<FeeRateResponse>;
904
910
  /** Maps to `POST /api/v1/orders/kalshi/quote`. */
905
911
  createDFlowQuote(body: DFlowQuoteRequest): Promise<DFlowQuoteResponse>;
906
912
  /** Maps to `POST /api/v1/orders/kalshi/submit`. */
@@ -1451,6 +1457,8 @@ interface BuildOrderMessageInput extends CreateOrderInput {
1451
1457
  signerAddress: string;
1452
1458
  /** Signature type (0 = EOA, 1 = Magic, 2 = Poly Proxy). */
1453
1459
  signatureType: 0 | 1 | 2;
1460
+ /** Fee rate in basis points from the CLOB fee-rate endpoint. Defaults to "0". */
1461
+ feeRateBps?: string;
1454
1462
  }
1455
1463
  interface OrderMessage {
1456
1464
  salt: string;
@@ -1555,4 +1563,4 @@ interface ClobOrderPayload {
1555
1563
  */
1556
1564
  declare function buildClobPayload(signedOrder: SignedOrder, owner: string): ClobOrderPayload;
1557
1565
 
1558
- export { type CreateOrderInput as $, type AvailableSharesResponse as A, type BalanceResponse as B, type Candlestick as C, type DFlowQuoteRequest as D, type EventStats as E, type DFlowSubmitRequest as F, type DFlowKYCStatus as G, type PolymarketSetupStatus as H, type WithdrawBuildRequest as I, type WithdrawSubmitResponse as J, type WithdrawSubmitRequest as K, type ListEventsParams as L, type MatchesParams as M, type WithdrawStatusResponse as N, type Orderbook as O, PredictClient as P, type PolymarketDepositAddresses as Q, type PolymarketWithdrawResponse as R, type SimilarEventsParams as S, type PolymarketWithdrawRequest as T, type TickSizeResponse as U, type WsConnectionStatus as V, type WithdrawBuildResponse as W, type WsDataMessage as X, type WsPriceEvent as Y, type WsOrderbookEvent as Z, type WsTradeEvent as _, PredictWsClient as a, buildPolymarketL2Headers as a$, createPredictClient as a0, createPredictWsClient as a1, type PredictWsClientConfig as a2, type ProviderMeta as a3, type PredictTag as a4, type SettlementSource as a5, type MarketStatus as a6, type MarketResult as a7, type MarketOutcome as a8, type OrderbookLevel as a9, type WsClientMessage as aA, type WsSubscribeMessage as aB, type WsPingMessage as aC, type WsServerMessage as aD, type WsPongMessage as aE, type WsSubscribedMessage as aF, type WsErrorCode as aG, type WsErrorMessage as aH, eventQueryKey as aI, fetchEvent as aJ, resolveTagSlug as aK, resolveEventsParams as aL, infiniteEventsQueryKey as aM, fetchEventsPage as aN, type ResolveEventsParamsInput as aO, type TagSlugSelection as aP, marketQueryKey as aQ, fetchMarket as aR, matchesQueryKey as aS, matchQueryKey as aT, fetchMatchesPage as aU, matchMarketsQueryKey as aV, fetchMatchMarketsPage as aW, CLOB_AUTH_DOMAIN as aX, CLOB_AUTH_TYPES as aY, buildClobAuthMessage as aZ, hmacSha256Base64 as a_, type TradeType as aa, type EventSummary as ab, type MarketSummary as ac, type PricePoint as ad, type PredictPosition as ae, type OrderStatus as af, type OrderSide as ag, type DFlowOrderContext as ah, type PolymarketOrderType as ai, type DepositBuildRequest as aj, type DepositBuildResponse as ak, type DepositSubmitRequest as al, type DepositSubmitResponse as am, type DepositStatusResponse as an, type UnsignedTx as ao, type PolymarketWithdrawPrepareRequest as ap, type PolymarketWithdrawPrepareResponse as aq, type MatchStatus as ar, type MatchGroupEntry as as, type MatchGroupMarket as at, type MatchSortField as au, type MatchesStats as av, type MatchConfidenceTier as aw, type MatchMarketFlat as ax, type WsChannel as ay, type WsChannelEvent as az, type PredictPage as b, derivePolymarketApiKey as b0, type HttpMethod as b1, type PolymarketL2HeadersInput as b2, type PolymarketL2Headers as b3, type BuildClobAuthMessageInput as b4, CTF_EXCHANGE_ADDRESS as b5, NEG_RISK_CTF_EXCHANGE_ADDRESS as b6, USDC_ADDRESS as b7, POLYGON_CHAIN_ID as b8, buildCtfExchangeDomain as b9, CTF_ORDER_TYPES as ba, ORDER_TYPE as bb, SIDE as bc, buildOrderMessage as bd, buildSignedOrder as be, buildClobPayload as bf, type ClobOrderPayload as bg, type BuildOrderMessageInput as bh, type OrderMessage as bi, type SignedOrder as bj, DEFAULT_PAGE_SIZE as bk, type PredictEvent as c, type ProviderSource as d, type EventStatus as e, type EventSortField as f, type PredictMarket as g, type ListMarketTradesParams as h, type PredictTrade as i, type PriceHistoryRange as j, type PriceHistoryResponse as k, type ListCandlesticksParams as l, type PositionsResponse as m, type ListOrdersParams as n, type PredictOrder as o, type ListOrdersMultiParams as p, type PredictOrdersResponse as q, type CancelOrderResult as r, type MatchGroupPage as s, type MatchGroup as t, type MatchMarketParams as u, type MatchMarketPage as v, type ListTradesParams as w, type ListTradesMultiParams as x, type DFlowQuoteResponse as y, type DFlowSubmitResponse as z };
1566
+ export { type WsTradeEvent as $, type AvailableSharesResponse as A, type BalanceResponse as B, type Candlestick as C, type DFlowQuoteRequest as D, type EventStats as E, type DFlowSubmitRequest as F, type DFlowKYCStatus as G, type PolymarketSetupStatus as H, type WithdrawBuildRequest as I, type WithdrawSubmitResponse as J, type WithdrawSubmitRequest as K, type ListEventsParams as L, type MatchesParams as M, type WithdrawStatusResponse as N, type Orderbook as O, PredictClient as P, type PolymarketDepositAddresses as Q, type PolymarketWithdrawResponse as R, type SimilarEventsParams as S, type PolymarketWithdrawRequest as T, type TickSizeResponse as U, type FeeRateResponse as V, type WithdrawBuildResponse as W, type WsConnectionStatus as X, type WsDataMessage as Y, type WsPriceEvent as Z, type WsOrderbookEvent as _, PredictWsClient as a, hmacSha256Base64 as a$, type CreateOrderInput as a0, createPredictClient as a1, createPredictWsClient as a2, type PredictWsClientConfig as a3, type ProviderMeta as a4, type PredictTag as a5, type SettlementSource as a6, type MarketStatus as a7, type MarketResult as a8, type MarketOutcome as a9, type WsChannelEvent as aA, type WsClientMessage as aB, type WsSubscribeMessage as aC, type WsPingMessage as aD, type WsServerMessage as aE, type WsPongMessage as aF, type WsSubscribedMessage as aG, type WsErrorCode as aH, type WsErrorMessage as aI, eventQueryKey as aJ, fetchEvent as aK, resolveTagSlug as aL, resolveEventsParams as aM, infiniteEventsQueryKey as aN, fetchEventsPage as aO, type ResolveEventsParamsInput as aP, type TagSlugSelection as aQ, marketQueryKey as aR, fetchMarket as aS, matchesQueryKey as aT, matchQueryKey as aU, fetchMatchesPage as aV, matchMarketsQueryKey as aW, fetchMatchMarketsPage as aX, CLOB_AUTH_DOMAIN as aY, CLOB_AUTH_TYPES as aZ, buildClobAuthMessage as a_, type OrderbookLevel as aa, type TradeType as ab, type EventSummary as ac, type MarketSummary as ad, type PricePoint as ae, type PredictPosition as af, type OrderStatus as ag, type OrderSide as ah, type DFlowOrderContext as ai, type PolymarketOrderType as aj, type DepositBuildRequest as ak, type DepositBuildResponse as al, type DepositSubmitRequest as am, type DepositSubmitResponse as an, type DepositStatusResponse as ao, type UnsignedTx as ap, type PolymarketWithdrawPrepareRequest as aq, type PolymarketWithdrawPrepareResponse as ar, type MatchStatus as as, type MatchGroupEntry as at, type MatchGroupMarket as au, type MatchSortField as av, type MatchesStats as aw, type MatchConfidenceTier as ax, type MatchMarketFlat as ay, type WsChannel as az, type PredictPage as b, buildPolymarketL2Headers as b0, derivePolymarketApiKey as b1, type HttpMethod as b2, type PolymarketL2HeadersInput as b3, type PolymarketL2Headers as b4, type BuildClobAuthMessageInput as b5, CTF_EXCHANGE_ADDRESS as b6, NEG_RISK_CTF_EXCHANGE_ADDRESS as b7, USDC_ADDRESS as b8, POLYGON_CHAIN_ID as b9, buildCtfExchangeDomain as ba, CTF_ORDER_TYPES as bb, ORDER_TYPE as bc, SIDE as bd, buildOrderMessage as be, buildSignedOrder as bf, buildClobPayload as bg, type ClobOrderPayload as bh, type BuildOrderMessageInput as bi, type OrderMessage as bj, type SignedOrder as bk, DEFAULT_PAGE_SIZE as bl, type PredictEvent as c, type ProviderSource as d, type EventStatus as e, type EventSortField as f, type PredictMarket as g, type ListMarketTradesParams as h, type PredictTrade as i, type PriceHistoryRange as j, type PriceHistoryResponse as k, type ListCandlesticksParams as l, type PositionsResponse as m, type ListOrdersParams as n, type PredictOrder as o, type ListOrdersMultiParams as p, type PredictOrdersResponse as q, type CancelOrderResult as r, type MatchGroupPage as s, type MatchGroup as t, type MatchMarketParams as u, type MatchMarketPage as v, type ListTradesParams as w, type ListTradesMultiParams as x, type DFlowQuoteResponse as y, type DFlowSubmitResponse as z };
package/dist/server.d.mts CHANGED
@@ -1 +1 @@
1
- export { B as BalanceResponse, b4 as BuildClobAuthMessageInput, bh as BuildOrderMessageInput, aX as CLOB_AUTH_DOMAIN, aY as CLOB_AUTH_TYPES, b5 as CTF_EXCHANGE_ADDRESS, ba as CTF_ORDER_TYPES, r as CancelOrderResult, C as Candlestick, bg as ClobOrderPayload, $ as CreateOrderInput, bk as DEFAULT_PAGE_SIZE, ah as DFlowOrderContext, D as DFlowQuoteRequest, y as DFlowQuoteResponse, F as DFlowSubmitRequest, z as DFlowSubmitResponse, aj as DepositBuildRequest, ak as DepositBuildResponse, an as DepositStatusResponse, al as DepositSubmitRequest, am as DepositSubmitResponse, f as EventSortField, e as EventStatus, ab as EventSummary, b1 as HttpMethod, l as ListCandlesticksParams, L as ListEventsParams, h as ListMarketTradesParams, n as ListOrdersParams, w as ListTradesParams, a8 as MarketOutcome, a7 as MarketResult, a6 as MarketStatus, ac as MarketSummary, aw as MatchConfidenceTier, t as MatchGroup, as as MatchGroupEntry, at as MatchGroupMarket, s as MatchGroupPage, ax as MatchMarketFlat, v as MatchMarketPage, u as MatchMarketParams, au as MatchSortField, ar as MatchStatus, M as MatchesParams, av as MatchesStats, b6 as NEG_RISK_CTF_EXCHANGE_ADDRESS, bb as ORDER_TYPE, bi as OrderMessage, ag as OrderSide, af as OrderStatus, O as Orderbook, a9 as OrderbookLevel, b8 as POLYGON_CHAIN_ID, b3 as PolymarketL2Headers, b2 as PolymarketL2HeadersInput, ai as PolymarketOrderType, m as PositionsResponse, P as PredictClient, c as PredictEvent, g as PredictMarket, o as PredictOrder, b as PredictPage, ae as PredictPosition, a4 as PredictTag, i as PredictTrade, a as PredictWsClient, a2 as PredictWsClientConfig, j as PriceHistoryRange, k as PriceHistoryResponse, ad as PricePoint, a3 as ProviderMeta, d as ProviderSource, aO as ResolveEventsParamsInput, bc as SIDE, a5 as SettlementSource, bj as SignedOrder, S as SimilarEventsParams, aP as TagSlugSelection, aa as TradeType, b7 as USDC_ADDRESS, ao as UnsignedTx, ay as WsChannel, az as WsChannelEvent, aA as WsClientMessage, V as WsConnectionStatus, X as WsDataMessage, aG as WsErrorCode, aH as WsErrorMessage, Z as WsOrderbookEvent, aC as WsPingMessage, aE as WsPongMessage, Y as WsPriceEvent, aD as WsServerMessage, aB as WsSubscribeMessage, aF as WsSubscribedMessage, _ as WsTradeEvent, aZ as buildClobAuthMessage, bf as buildClobPayload, b9 as buildCtfExchangeDomain, bd as buildOrderMessage, a$ as buildPolymarketL2Headers, be as buildSignedOrder, a0 as createPredictClient, a1 as createPredictWsClient, b0 as derivePolymarketApiKey, aI as eventQueryKey, aJ as fetchEvent, aN as fetchEventsPage, aR as fetchMarket, aW as fetchMatchMarketsPage, aU as fetchMatchesPage, a_ as hmacSha256Base64, aM as infiniteEventsQueryKey, aQ as marketQueryKey, aV as matchMarketsQueryKey, aT as matchQueryKey, aS as matchesQueryKey, aL as resolveEventsParams, aK as resolveTagSlug } from './server-exUYV2o0.mjs';
1
+ export { B as BalanceResponse, b5 as BuildClobAuthMessageInput, bi as BuildOrderMessageInput, aY as CLOB_AUTH_DOMAIN, aZ as CLOB_AUTH_TYPES, b6 as CTF_EXCHANGE_ADDRESS, bb as CTF_ORDER_TYPES, r as CancelOrderResult, C as Candlestick, bh as ClobOrderPayload, a0 as CreateOrderInput, bl as DEFAULT_PAGE_SIZE, ai as DFlowOrderContext, D as DFlowQuoteRequest, y as DFlowQuoteResponse, F as DFlowSubmitRequest, z as DFlowSubmitResponse, ak as DepositBuildRequest, al as DepositBuildResponse, ao as DepositStatusResponse, am as DepositSubmitRequest, an as DepositSubmitResponse, f as EventSortField, e as EventStatus, ac as EventSummary, b2 as HttpMethod, l as ListCandlesticksParams, L as ListEventsParams, h as ListMarketTradesParams, n as ListOrdersParams, w as ListTradesParams, a9 as MarketOutcome, a8 as MarketResult, a7 as MarketStatus, ad as MarketSummary, ax as MatchConfidenceTier, t as MatchGroup, at as MatchGroupEntry, au as MatchGroupMarket, s as MatchGroupPage, ay as MatchMarketFlat, v as MatchMarketPage, u as MatchMarketParams, av as MatchSortField, as as MatchStatus, M as MatchesParams, aw as MatchesStats, b7 as NEG_RISK_CTF_EXCHANGE_ADDRESS, bc as ORDER_TYPE, bj as OrderMessage, ah as OrderSide, ag as OrderStatus, O as Orderbook, aa as OrderbookLevel, b9 as POLYGON_CHAIN_ID, b4 as PolymarketL2Headers, b3 as PolymarketL2HeadersInput, aj as PolymarketOrderType, m as PositionsResponse, P as PredictClient, c as PredictEvent, g as PredictMarket, o as PredictOrder, b as PredictPage, af as PredictPosition, a5 as PredictTag, i as PredictTrade, a as PredictWsClient, a3 as PredictWsClientConfig, j as PriceHistoryRange, k as PriceHistoryResponse, ae as PricePoint, a4 as ProviderMeta, d as ProviderSource, aP as ResolveEventsParamsInput, bd as SIDE, a6 as SettlementSource, bk as SignedOrder, S as SimilarEventsParams, aQ as TagSlugSelection, ab as TradeType, b8 as USDC_ADDRESS, ap as UnsignedTx, az as WsChannel, aA as WsChannelEvent, aB as WsClientMessage, X as WsConnectionStatus, Y as WsDataMessage, aH as WsErrorCode, aI as WsErrorMessage, _ as WsOrderbookEvent, aD as WsPingMessage, aF as WsPongMessage, Z as WsPriceEvent, aE as WsServerMessage, aC as WsSubscribeMessage, aG as WsSubscribedMessage, $ as WsTradeEvent, a_ as buildClobAuthMessage, bg as buildClobPayload, ba as buildCtfExchangeDomain, be as buildOrderMessage, b0 as buildPolymarketL2Headers, bf as buildSignedOrder, a1 as createPredictClient, a2 as createPredictWsClient, b1 as derivePolymarketApiKey, aJ as eventQueryKey, aK as fetchEvent, aO as fetchEventsPage, aS as fetchMarket, aX as fetchMatchMarketsPage, aV as fetchMatchesPage, a$ as hmacSha256Base64, aN as infiniteEventsQueryKey, aR as marketQueryKey, aW as matchMarketsQueryKey, aU as matchQueryKey, aT as matchesQueryKey, aM as resolveEventsParams, aL as resolveTagSlug } from './server-BJChohWB.mjs';
package/dist/server.d.ts CHANGED
@@ -1 +1 @@
1
- export { B as BalanceResponse, b4 as BuildClobAuthMessageInput, bh as BuildOrderMessageInput, aX as CLOB_AUTH_DOMAIN, aY as CLOB_AUTH_TYPES, b5 as CTF_EXCHANGE_ADDRESS, ba as CTF_ORDER_TYPES, r as CancelOrderResult, C as Candlestick, bg as ClobOrderPayload, $ as CreateOrderInput, bk as DEFAULT_PAGE_SIZE, ah as DFlowOrderContext, D as DFlowQuoteRequest, y as DFlowQuoteResponse, F as DFlowSubmitRequest, z as DFlowSubmitResponse, aj as DepositBuildRequest, ak as DepositBuildResponse, an as DepositStatusResponse, al as DepositSubmitRequest, am as DepositSubmitResponse, f as EventSortField, e as EventStatus, ab as EventSummary, b1 as HttpMethod, l as ListCandlesticksParams, L as ListEventsParams, h as ListMarketTradesParams, n as ListOrdersParams, w as ListTradesParams, a8 as MarketOutcome, a7 as MarketResult, a6 as MarketStatus, ac as MarketSummary, aw as MatchConfidenceTier, t as MatchGroup, as as MatchGroupEntry, at as MatchGroupMarket, s as MatchGroupPage, ax as MatchMarketFlat, v as MatchMarketPage, u as MatchMarketParams, au as MatchSortField, ar as MatchStatus, M as MatchesParams, av as MatchesStats, b6 as NEG_RISK_CTF_EXCHANGE_ADDRESS, bb as ORDER_TYPE, bi as OrderMessage, ag as OrderSide, af as OrderStatus, O as Orderbook, a9 as OrderbookLevel, b8 as POLYGON_CHAIN_ID, b3 as PolymarketL2Headers, b2 as PolymarketL2HeadersInput, ai as PolymarketOrderType, m as PositionsResponse, P as PredictClient, c as PredictEvent, g as PredictMarket, o as PredictOrder, b as PredictPage, ae as PredictPosition, a4 as PredictTag, i as PredictTrade, a as PredictWsClient, a2 as PredictWsClientConfig, j as PriceHistoryRange, k as PriceHistoryResponse, ad as PricePoint, a3 as ProviderMeta, d as ProviderSource, aO as ResolveEventsParamsInput, bc as SIDE, a5 as SettlementSource, bj as SignedOrder, S as SimilarEventsParams, aP as TagSlugSelection, aa as TradeType, b7 as USDC_ADDRESS, ao as UnsignedTx, ay as WsChannel, az as WsChannelEvent, aA as WsClientMessage, V as WsConnectionStatus, X as WsDataMessage, aG as WsErrorCode, aH as WsErrorMessage, Z as WsOrderbookEvent, aC as WsPingMessage, aE as WsPongMessage, Y as WsPriceEvent, aD as WsServerMessage, aB as WsSubscribeMessage, aF as WsSubscribedMessage, _ as WsTradeEvent, aZ as buildClobAuthMessage, bf as buildClobPayload, b9 as buildCtfExchangeDomain, bd as buildOrderMessage, a$ as buildPolymarketL2Headers, be as buildSignedOrder, a0 as createPredictClient, a1 as createPredictWsClient, b0 as derivePolymarketApiKey, aI as eventQueryKey, aJ as fetchEvent, aN as fetchEventsPage, aR as fetchMarket, aW as fetchMatchMarketsPage, aU as fetchMatchesPage, a_ as hmacSha256Base64, aM as infiniteEventsQueryKey, aQ as marketQueryKey, aV as matchMarketsQueryKey, aT as matchQueryKey, aS as matchesQueryKey, aL as resolveEventsParams, aK as resolveTagSlug } from './server-exUYV2o0.js';
1
+ export { B as BalanceResponse, b5 as BuildClobAuthMessageInput, bi as BuildOrderMessageInput, aY as CLOB_AUTH_DOMAIN, aZ as CLOB_AUTH_TYPES, b6 as CTF_EXCHANGE_ADDRESS, bb as CTF_ORDER_TYPES, r as CancelOrderResult, C as Candlestick, bh as ClobOrderPayload, a0 as CreateOrderInput, bl as DEFAULT_PAGE_SIZE, ai as DFlowOrderContext, D as DFlowQuoteRequest, y as DFlowQuoteResponse, F as DFlowSubmitRequest, z as DFlowSubmitResponse, ak as DepositBuildRequest, al as DepositBuildResponse, ao as DepositStatusResponse, am as DepositSubmitRequest, an as DepositSubmitResponse, f as EventSortField, e as EventStatus, ac as EventSummary, b2 as HttpMethod, l as ListCandlesticksParams, L as ListEventsParams, h as ListMarketTradesParams, n as ListOrdersParams, w as ListTradesParams, a9 as MarketOutcome, a8 as MarketResult, a7 as MarketStatus, ad as MarketSummary, ax as MatchConfidenceTier, t as MatchGroup, at as MatchGroupEntry, au as MatchGroupMarket, s as MatchGroupPage, ay as MatchMarketFlat, v as MatchMarketPage, u as MatchMarketParams, av as MatchSortField, as as MatchStatus, M as MatchesParams, aw as MatchesStats, b7 as NEG_RISK_CTF_EXCHANGE_ADDRESS, bc as ORDER_TYPE, bj as OrderMessage, ah as OrderSide, ag as OrderStatus, O as Orderbook, aa as OrderbookLevel, b9 as POLYGON_CHAIN_ID, b4 as PolymarketL2Headers, b3 as PolymarketL2HeadersInput, aj as PolymarketOrderType, m as PositionsResponse, P as PredictClient, c as PredictEvent, g as PredictMarket, o as PredictOrder, b as PredictPage, af as PredictPosition, a5 as PredictTag, i as PredictTrade, a as PredictWsClient, a3 as PredictWsClientConfig, j as PriceHistoryRange, k as PriceHistoryResponse, ae as PricePoint, a4 as ProviderMeta, d as ProviderSource, aP as ResolveEventsParamsInput, bd as SIDE, a6 as SettlementSource, bk as SignedOrder, S as SimilarEventsParams, aQ as TagSlugSelection, ab as TradeType, b8 as USDC_ADDRESS, ap as UnsignedTx, az as WsChannel, aA as WsChannelEvent, aB as WsClientMessage, X as WsConnectionStatus, Y as WsDataMessage, aH as WsErrorCode, aI as WsErrorMessage, _ as WsOrderbookEvent, aD as WsPingMessage, aF as WsPongMessage, Z as WsPriceEvent, aE as WsServerMessage, aC as WsSubscribeMessage, aG as WsSubscribedMessage, $ as WsTradeEvent, a_ as buildClobAuthMessage, bg as buildClobPayload, ba as buildCtfExchangeDomain, be as buildOrderMessage, b0 as buildPolymarketL2Headers, bf as buildSignedOrder, a1 as createPredictClient, a2 as createPredictWsClient, b1 as derivePolymarketApiKey, aJ as eventQueryKey, aK as fetchEvent, aO as fetchEventsPage, aS as fetchMarket, aX as fetchMatchMarketsPage, aV as fetchMatchesPage, a$ as hmacSha256Base64, aN as infiniteEventsQueryKey, aR as marketQueryKey, aW as matchMarketsQueryKey, aU as matchQueryKey, aT as matchesQueryKey, aM as resolveEventsParams, aL as resolveTagSlug } from './server-BJChohWB.js';
package/dist/server.js CHANGED
@@ -335,6 +335,11 @@ var PredictClient = class {
335
335
  const url = `${this.endpoint}/api/v1/polymarket/tick-size?token_id=${encodeURIComponent(tokenId)}`;
336
336
  return await utils.httpGet(url);
337
337
  }
338
+ /** Maps to `GET /api/v1/polymarket/fee-rate?token_id=xxx`. */
339
+ async getPolymarketFeeRate(tokenId) {
340
+ const url = `${this.endpoint}/api/v1/polymarket/fee-rate?token_id=${encodeURIComponent(tokenId)}`;
341
+ return await utils.httpGet(url);
342
+ }
338
343
  // -------------------------------------------------------------------------
339
344
  // DFlow trading
340
345
  // -------------------------------------------------------------------------
@@ -1076,7 +1081,7 @@ function buildOrderMessage(input) {
1076
1081
  takerAmount,
1077
1082
  expiration: String(input.expiration ?? 0),
1078
1083
  nonce: "0",
1079
- feeRateBps: "0",
1084
+ feeRateBps: input.feeRateBps ?? "0",
1080
1085
  side,
1081
1086
  signatureType: input.signatureType
1082
1087
  };