feat: batch 1 API updates — new endpoints, WS channel, _fp fields#26
Merged
feat: batch 1 API updates — new endpoints, WS channel, _fp fields#26
Conversation
…l, and _fp fields
Add new Kalshi API endpoints:
- PUT /portfolio/order_groups/{id}/trigger (trigger_order_group)
- PUT /portfolio/order_groups/{id}/limit (update_order_group_limit)
- GET /account/limits (get_api_limits)
Add OrderGroupUpdates WebSocket channel for order group lifecycle events
(created, triggered, reset, deleted, limit_updated).
Add fixed-point _fp string fields to order group models and WebSocket
message types (OrderbookDeltaData, TickerData, TradeData, FillData,
MarketPositionData) for precise decimal representation.
Make contracts_limit optional on CreateOrderGroupRequest, supporting
contracts_limit_fp as an alternative.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Implements Kalshi API changelog items from Batch 1 (Jan 22–29, 2026):
trigger_order_group(PUT.../trigger),update_order_group_limit(PUT.../limit),get_api_limits(GET/account/limits)OrderGroupUpdatesfor order group lifecycle events (created, triggered, reset, deleted, limit_updated)_fpfields: Addedcontracts_limit_fpon order group models, anddelta_fp,volume_fp,open_interest_fp,count_fp,post_position_fp,position_fpon WebSocket message typesCreateOrderGroupRequest.contracts_limitis nowOption<i64>(wasi64); usecontracts_limit_fpas alternativeput_no_responseHTTP helper for PUT endpoints with JSON body and no response bodyAll paths and model fields verified against the Kalshi Python SDK (v3.7.0).
Test plan
cargo test— 182 tests passcargo clippy— cleancargo build --examples— all examples compilecargo run --example order_groups— exercises trigger/limit endpoints live (requires API credentials)