Skip to content

[Release] Candidate - #352

Merged
kartojal merged 1 commit into
mainfrom
changeset-release/main
Sep 9, 2026
Merged

[Release] Candidate#352
kartojal merged 1 commit into
mainfrom
changeset-release/main

Conversation

@github-actions

@github-actions github-actions Bot commented Sep 9, 2026

Copy link
Copy Markdown
Contributor

This PR was opened by the Changesets release GitHub action. When you're ready to do a release, you can merge this and the packages will be published to npm automatically. If you're not ready to do a release yet, that's fine, whenever you add more changesets to main, this PR will be updated.

Releases

@polymarket/bindings@0.10.0

Minor Changes

  • 6e3ae8d: Breaking: migrate listBuilderLeaderboard and fetchBuilderVolume to their v2 contracts. Builder rankings now use server cursors and normalized BuilderStanding rows; builder volume returns complete date buckets as BuilderVolumePoint rows. Replace timePeriod with window or interval, and use bucketLimit to bound volume buckets.
  • 8befd1f: Add the core pieces for the data /v2 surface: /v2 envelope schemas (paginated list with server-minted branded cursors, and single-object including null answers), a withRateLimitRetry pipeline helper that honors server-requested delays, and the MIGRATION activity type with its MigrationActivity variant. All additive — no existing API shape changes.
  • 7b68c7a: Breaking: the feed surfaces are fully replaced — same names, new contracts. listActivity, listComboActivity, listPositions, and listComboPositions now serve exact cursor pagination with automatic rate-limit retry and the condition-id vocabulary. conditionId filters validate the service's shared selector cap client-side: at most 20 distinct ids per request (case-insensitive dedupe first), so an oversized list fails typed instead of as a service 400. listPositions bundles the whole lifecycle behind status (OPEN/REDEEMABLE/CLOSED) with redeemable/mergeable flags and fee-exclusive entry economics on every row — listClosedPositions and listMarketPositions are removed (use listPositions with status/a conditionId anchor). Every windowed method takes one window option ('full' | { start?, end? }, epoch seconds or Date) replacing raw start/end. Money, size, price, and PnL fields normalize to DecimalString (the wire's JSON numbers are stringified without loss at their 6-decimal grain, matching the v1 SDK surface), endDate is a typed IsoCalendarDateString, and ComboPositionStatus gains Redeemable (sole-value filter, also tolerated on rows); the Activity union, Position, ComboPosition, and ComboActivity rows are strict and normalized (epoch ms, empty-string/999-sentinel absence as undefined, assetId canonical with deprecated tokenId alias). Combo activity rows carry positionId on every row while dropping transactionAt/logIndex/moduleId. Request vocabularies are exported enums: trade direction reuses OrderSide (the standalone Side type is removed), and SortDirection, TradeFilterType, PositionFilterType, PositionSortBy, ComboPositionSortBy, and TipSide join PositionStatus/ComboPositionStatus. On the secure client, listPositions always binds the authenticated wallet (the user: null opt-out is removed); list a market's holders through a public client instead.
  • 12935c4: Breaking: migrate listMarketHolders to its cursor-paginated /v2 contract, using condition IDs, normalized holder fields, and optional position economics.
  • d64f383: Breaking: migrate open-interest and live-volume reads to their v2 contracts. Replace listOpenInterest with fetchOpenInterest, use condition and event identifiers, and expose cumulative taker volume explicitly.
  • 0df4f2b: Breaking: migrate fetchPortfolioValue to its /v2 contract, returning one PortfolioValue with a decimal-string value and accepting conditionIds instead of the legacy market filter. Add fetchUserStats with decimal-string money, size, and PnL fields, and remove fetchTradedMarketCount; use fetchUserStats().tradedMarketCount for the exact distinct-market count. The accounting snapshot download remains available unchanged.
  • 454c772: Breaking: replace fetchPriceHistory with cursor-paginated listPriceHistory, using token IDs, strict time selections, second-based bucket widths, and normalized price points.
  • cb664fb: Add fetchResolutions for non-paginated resolution lifecycle lookups by question, condition, or event. Resolution rows normalize identity, lifecycle, oracle, payout, and finality fields, while unset wire sentinels become omitted SDK fields.
  • 7992375: Breaking: migrate trader leaderboard reads to the cursor-paginated v2 contract, add a separate by-wallet standing method, and add biggest-winner pagination with explicit market and Combo variants.
  • 7ed1af9: Breaking: listTrades is fully replaced — same name, new contract. It now serves exact continuation signals (hasMore/server-minted nextCursor — no page-size probing), re-sends the original filters with every page, has no offset vocabulary (pageSize default 100, max 1000 rejected-not-clamped), retries transient rate limits after the server-requested delay, and accepts partial filterType/filterAmount (the service fills the other half in). The Trade row is strict and normalized (numbers for size/price, epoch milliseconds, empty-string and unknown-sentinel absence as undefined). Following the service's naming remap, the request filter is conditionId (the wire's condition/condition_id — the old market key no longer exists upstream) and the row field parsed is condition_id. Bindings gain the reusable data envelope parsers (dataPageSchema, dataEnvelopeSchema) that turn the service's paginated envelope straight into the SDK page shape.
  • d320dfa: Add fetchUserPnl and fetchUserVolume with normalized decimal-string amounts, cumulative PnL metadata, shared time-window inputs, and authenticated-wallet defaults.

Patch Changes

  • 5bdc101: Expose the yearly builder-volume bucket as BuilderVolumeInterval.Year while preserving the wire value all.
  • b56a0a8: Normalize resolution timestamps, transaction metadata, and payout values into canonical SDK types.
  • 6e5c293: Expose question, groupItemTitle, sportsMarketType, line, and outcomes on combo leg markets returned by listComboPositions and listComboActivity.
  • e7882e8: Normalize protocol v2 market condition IDs for position and portfolio-value reads, share canonicalization in bindings, and clarify activity and trade history windows.

@polymarket/client@0.10.0

Minor Changes

  • 6e3ae8d: Breaking: migrate listBuilderLeaderboard and fetchBuilderVolume to their v2 contracts. Builder rankings now use server cursors and normalized BuilderStanding rows; builder volume returns complete date buckets as BuilderVolumePoint rows. Replace timePeriod with window or interval, and use bucketLimit to bound volume buckets.
  • 8befd1f: Add the core pieces for the data /v2 surface: /v2 envelope schemas (paginated list with server-minted branded cursors, and single-object including null answers), a withRateLimitRetry pipeline helper that honors server-requested delays, and the MIGRATION activity type with its MigrationActivity variant. All additive — no existing API shape changes.
  • 7b68c7a: Breaking: the feed surfaces are fully replaced — same names, new contracts. listActivity, listComboActivity, listPositions, and listComboPositions now serve exact cursor pagination with automatic rate-limit retry and the condition-id vocabulary. conditionId filters validate the service's shared selector cap client-side: at most 20 distinct ids per request (case-insensitive dedupe first), so an oversized list fails typed instead of as a service 400. listPositions bundles the whole lifecycle behind status (OPEN/REDEEMABLE/CLOSED) with redeemable/mergeable flags and fee-exclusive entry economics on every row — listClosedPositions and listMarketPositions are removed (use listPositions with status/a conditionId anchor). Every windowed method takes one window option ('full' | { start?, end? }, epoch seconds or Date) replacing raw start/end. Money, size, price, and PnL fields normalize to DecimalString (the wire's JSON numbers are stringified without loss at their 6-decimal grain, matching the v1 SDK surface), endDate is a typed IsoCalendarDateString, and ComboPositionStatus gains Redeemable (sole-value filter, also tolerated on rows); the Activity union, Position, ComboPosition, and ComboActivity rows are strict and normalized (epoch ms, empty-string/999-sentinel absence as undefined, assetId canonical with deprecated tokenId alias). Combo activity rows carry positionId on every row while dropping transactionAt/logIndex/moduleId. Request vocabularies are exported enums: trade direction reuses OrderSide (the standalone Side type is removed), and SortDirection, TradeFilterType, PositionFilterType, PositionSortBy, ComboPositionSortBy, and TipSide join PositionStatus/ComboPositionStatus. On the secure client, listPositions always binds the authenticated wallet (the user: null opt-out is removed); list a market's holders through a public client instead.
  • 12935c4: Breaking: migrate listMarketHolders to its cursor-paginated /v2 contract, using condition IDs, normalized holder fields, and optional position economics.
  • d64f383: Breaking: migrate open-interest and live-volume reads to their v2 contracts. Replace listOpenInterest with fetchOpenInterest, use condition and event identifiers, and expose cumulative taker volume explicitly.
  • 0df4f2b: Breaking: migrate fetchPortfolioValue to its /v2 contract, returning one PortfolioValue with a decimal-string value and accepting conditionIds instead of the legacy market filter. Add fetchUserStats with decimal-string money, size, and PnL fields, and remove fetchTradedMarketCount; use fetchUserStats().tradedMarketCount for the exact distinct-market count. The accounting snapshot download remains available unchanged.
  • 454c772: Breaking: replace fetchPriceHistory with cursor-paginated listPriceHistory, using token IDs, strict time selections, second-based bucket widths, and normalized price points.
  • cb664fb: Add fetchResolutions for non-paginated resolution lifecycle lookups by question, condition, or event. Resolution rows normalize identity, lifecycle, oracle, payout, and finality fields, while unset wire sentinels become omitted SDK fields.
  • 7992375: Breaking: migrate trader leaderboard reads to the cursor-paginated v2 contract, add a separate by-wallet standing method, and add biggest-winner pagination with explicit market and Combo variants.
  • 7ed1af9: Breaking: listTrades is fully replaced — same name, new contract. It now serves exact continuation signals (hasMore/server-minted nextCursor — no page-size probing), re-sends the original filters with every page, has no offset vocabulary (pageSize default 100, max 1000 rejected-not-clamped), retries transient rate limits after the server-requested delay, and accepts partial filterType/filterAmount (the service fills the other half in). The Trade row is strict and normalized (numbers for size/price, epoch milliseconds, empty-string and unknown-sentinel absence as undefined). Following the service's naming remap, the request filter is conditionId (the wire's condition/condition_id — the old market key no longer exists upstream) and the row field parsed is condition_id. Bindings gain the reusable data envelope parsers (dataPageSchema, dataEnvelopeSchema) that turn the service's paginated envelope straight into the SDK page shape.
  • d320dfa: Add fetchUserPnl and fetchUserVolume with normalized decimal-string amounts, cumulative PnL metadata, shared time-window inputs, and authenticated-wallet defaults.

Patch Changes

  • 5bdc101: Expose the yearly builder-volume bucket as BuilderVolumeInterval.Year while preserving the wire value all.
  • b56a0a8: Normalize resolution timestamps, transaction metadata, and payout values into canonical SDK types.
  • 6e5c293: Expose question, groupItemTitle, sportsMarketType, line, and outcomes on combo leg markets returned by listComboPositions and listComboActivity.
  • e7882e8: Normalize protocol v2 market condition IDs for position and portfolio-value reads, share canonicalization in bindings, and clarify activity and trade history windows.
  • Updated dependencies [5bdc101]
  • Updated dependencies [b56a0a8]
  • Updated dependencies [6e3ae8d]
  • Updated dependencies [6e5c293]
  • Updated dependencies [8befd1f]
  • Updated dependencies [7b68c7a]
  • Updated dependencies [12935c4]
  • Updated dependencies [d64f383]
  • Updated dependencies [e7882e8]
  • Updated dependencies [0df4f2b]
  • Updated dependencies [454c772]
  • Updated dependencies [cb664fb]
  • Updated dependencies [7992375]
  • Updated dependencies [7ed1af9]
  • Updated dependencies [d320dfa]
    • @polymarket/bindings@0.10.0

Note

High Risk
This release encodes many breaking public API and typing changes across portfolio, positions, trades, and authenticated reads—consumers must migrate call sites before upgrading.

Overview
This Changesets release PR bumps @polymarket/bindings and @polymarket/client to 0.10.0, rolls the pending changeset notes into each package CHANGELOG, and deletes the consumed .changeset/*.md files. There is no new application code in the diff—merge triggers npm publish of the already-merged Data API work.

0.10.0 is dominated by breaking Data /v2 migrations: cursor pagination and shared envelopes/rate-limit retry on feeds (listActivity, positions, trades, etc.), conditionId vocabulary (replacing legacy market filters where upstream dropped them), unified listPositions (removing listClosedPositions / listMarketPositions), and v2 swaps for portfolio value, price history, open interest, holders, builder/trader leaderboards, and related reads. Additive pieces include fetchResolutions, fetchUserStats, fetchUserPnl/fetchUserVolume, MigrationActivity, and assorted normalization (decimal strings, condition IDs, combo leg metadata, resolution fields).

Secure listPositions no longer allows user: null; callers must use a public client for market holders.

Reviewed by Cursor Bugbot for commit 2216853. Bugbot is set up for automated code reviews on this repo. Configure here.

@kartojal
kartojal merged commit 542202c into main Sep 9, 2026
7 of 8 checks passed
@kartojal
kartojal deleted the changeset-release/main branch September 9, 2026 09:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant