Skip to content

Kalshi amendOrder spec capability not implemented in core KalshiExchange or either SDK #1133

Description

@realfishsam

Gap

The Kalshi API spec defines AmendOrder (POST /portfolio/orders/{order_id}/amend), which updates the max-fillable quantity and/or price of an existing resting order. KalshiExchange in core has no amendOrder() method, and neither SDK exposes a typed wrapper. The only current access path is the raw callApi("AmendOrder", params) escape hatch, which provides no type safety and no documentation.

Core

Spec: core/specs/kalshi/Kalshi.yaml line 498–523

/portfolio/orders/{order_id}/amend:
  post:
    operationId: AmendOrder
    description: 'Endpoint for amending the max number of fillable contracts and/or price in an existing order.'
    # Request body: AmendOrderRequest (new price, new count, client_order_id, etc.)
    # Response: AmendOrderResponse (updated Order object)

AmendOrderRequest schema (core/specs/kalshi/Kalshi.yaml line 5677): fields include price (new limit price in cents), count (new max-fillable contracts), client_order_id, updated_client_order_id, sub_account_id.

core/src/exchanges/kalshi/index.ts — No amendOrder() method exists in KalshiExchange. The only order mutation method is cancelOrder(orderId) at line 387.

TypeScript SDK

Missing — no amendOrder method in sdks/typescript/pmxt/client.ts. Searching the entire sdks/typescript/ tree returns no results for amendOrder.

Python SDK

Missing — no amend_order method in sdks/python/pmxt/client.py or sdks/python/pmxt/_exchanges.py.

Evidence

# Spec defines the endpoint
grep -n "AmendOrder" core/specs/kalshi/Kalshi.yaml
# line 500: operationId: AmendOrder

# Core exchange — no implementation
grep -rn "amendOrder\|amend_order" core/src/exchanges/kalshi/
# (no matches)

# Both SDKs — no wrapper
grep -rn "amendOrder\|amend_order" sdks/
# (no matches, excluding API_REFERENCE docs)

AmendOrder is accessible through callApi("AmendOrder", { order_id, price, count }) in both SDKs, but only as an untyped string-keyed escape hatch. There is no typed method, no parameter validation, and no IDE completion.

Impact

Kalshi users who want to adjust a live order's price or size without cancelling and re-submitting must either use callApi with raw string operation IDs or cancel-and-replace entirely. Cancel-and-replace risks losing queue priority and creating a gap in market exposure. AmendOrder is the standard mechanism to reprice without re-queuing, and its absence from the unified interface makes Kalshi less competitive as a trading venue through the SDK.


Found by automated Core-to-SDK surface coverage audit

Metadata

Metadata

Assignees

No one assigned

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions