Skip to main content

Changelog

All notable changes to @ostium/builder-sdk will be documented in this file. The format is based on Keep a Changelog, and this project adheres to Semantic Versioning.

[0.4.1] - 2026-06-14

Added

  • streamAccountUpdates() now accepts user as an address array, allowing one or more trader addresses on a single stream (one WebSocket, one poll loop, one price feed). Emitted snapshots are keyed by normalized trader address with { positions, orders, limits } per trader.
  • OstiumAccountUpdatesStream.users getter returning the subscribed trader addresses.
  • Optional user argument to OstiumAccountUpdatesStream.addOptimisticOpen(params, submission?, user?) to attribute an optimistic open to a specific subscribed address. Required when streaming multiple addresses; defaults to the sole subscribed address otherwise.

[0.4.0] - 2026-06-11

Added

  • Added this changelog.
  • Added sets pagination support to getCandles().
  • Added getOrders() filters for global orders, builder address, status, pair ids, and execution time (start / end as Unix seconds UTC, inclusive bounds on executedAt).
  • Added getBuilderOrders(builder, params?) — fetches builder-tagged open orders plus sibling close/TP/SL orders on the same positions. limit caps phase-1 results only; phase-2 siblings are appended without a cap.
  • Added builder to returned Fill and Order objects.
  • Added ntl (USD notional) to returned Fill and Order objects.
  • Added trader to returned Fill, Order, Position, and OpenOrder objects.
  • Added timestamp (execution time, Unix seconds UTC — subgraph executedAt) to returned Fill and Order objects.
  • Added MIN_OPEN_SIZE_USD for the fixed $5 minimum open size.
  • Added per-trade optional builder.address / builder.feeBps overrides on openTrade(); omitted fields fall back to client config.
  • Added openFee and closeFee (bps) to PairopenFee is takerFeeP / 10_000 plus the configured builder fee; closeFee is always 0 as there’s no closing fees on Ostium currently.
  • Added streamAccountUpdates() for low-latency account confirmations using subgraph polling, Alchemy contract-log overlays, and live price repricing for open-trade PnL.
  • Added optimistic market-open overlays to streamAccountUpdates(), receipt orderId extraction via extractOrderIdFromReceipt(), and attachOrderId() reconciliation for lower-latency confirmations.
  • Added alchemyApiKey as a client option for account confirmation streams.
  • Added account update snapshots with SDK-formatted Order, OpenOrder, and PairPosition values.
  • Added schedule (market hours — timezone, openingHours, alwaysOpen) to Pair returned by getPairs(), and to PriceData / PriceTick from the live price feed.
  • Added background SDK usage attribution: submissions that target the Trading contract report their transaction hash to the builder API (POST /v1/trade) as a fire-and-forget request that never blocks or affects trading calls.

Changed

  • Updated the default mainnet subgraph URL to https://builder.ostium.io/v1/subgraph/gn.

Fixed

  • Removed the SDK-side openTrade() maximum leverage cap so contract-side validation is authoritative.
  • Removed the internal minimum-open-size config override path.

[0.3.1]

  • Current published package version when this changelog was introduced.