v2.1.0
OpenAPI spec sync from v3.13.0 → v3.18.0. Adds the V2 event-market
orders family, deposits/withdrawals history, account endpoint-cost
introspection, and several optional query / body fields. Also fixes
a recurring false-alarm in the weekly spec-sync workflow.
Added
- V2 event-market orders (
/portfolio/events/orders/*). Legacy
/portfolio/orderswill be deprecated no earlier than May 6, 2026.orders.create_v2(request=CreateOrderV2Request(...))orders.cancel_v2(order_id, subaccount=..., exchange_index=...)orders.amend_v2(order_id, request=AmendOrderV2Request(...))orders.decrease_v2(order_id, request=DecreaseOrderV2Request(...))orders.batch_create_v2(request=BatchCreateOrdersV2Request(...))orders.batch_cancel_v2(request=BatchCancelOrdersV2Request(...))
portfolio.deposits()/portfolio.deposits_all()— deposit history.portfolio.withdrawals()/portfolio.withdrawals_all()— withdrawal history.account.endpoint_costs()— lists endpoints whose token cost differs from the default.- Optional
exchange_indexonCreateOrderRequest,AmendOrderRequest,
DecreaseOrderRequest,BatchCancelOrdersRequestOrder,CreateOrderGroupRequest,
and as a query kwarg onorders.cancel/order_groups.delete. - Optional
user_filteroncommunications.list_rfqs/list_all_rfqs;
user_filter+rfq_user_filteroncommunications.list_quotes/list_all_quotes. - Optional
incentive_descriptiononincentive_programs.list/list_all. - Optional
post_onlyonCreateQuoteRequest. Balance.balance_dollars(required,DollarDecimal) — the same value as
balance(cents) rendered as a fixed-point dollar string. Required in
the v3.18.0 spec forGetBalanceResponse.Balance.balance_breakdown(optional,list[IndexedBalance]) — splits
the balance across exchange shards when present.- New
IndexedBalancemodel (exchange_index,balance) exposed from
kalshiandkalshi.models.
Changed
-
Balancegained a requiredbalance_dollars: DollarDecimalfield
(added by spec v3.18.0). Callers who constructBalancefrom API
responses are unaffected — the server now guarantees the field. But
callers who buildBalance(...)instances directly in their own
tests or mocks will hitValidationErroruntil they add it. This is
a soft breaking change at the model-construction surface; the field is
required because the spec marks itrequired, not optional-in-practice.# before v2.1.0 Balance(balance=50000, portfolio_value=75000, updated_ts=ts) # v2.1.0+ Balance( balance=50000, balance_dollars=Decimal("500.00"), # new required field portfolio_value=75000, updated_ts=ts, )
Migration note
CreateOrderV2Request.client_order_idis required. V1's
CreateOrderRequestmade it optional, so callers migrating from
orders.create()toorders.create_v2()must generate a unique
client-order-id per call (UUID4 is the common choice). The server uses
this field as the V2 idempotency key, so reusing a value will cause
the server to return the original order rather than placing a new one.
Fixed
specs/asyncapi.yamlis now committed as a pinned snapshot, matching the
long-standing intent onspecs/openapi.yaml. The weekly spec-sync workflow
no longer reports a bogus "AsyncAPI 0 → 13 channels" delta every Monday
(the file was previously gitignored, so each cron diffed the fresh
download against a non-existent old file).