Improved

Nested "legs" on the order schema now accept an empty array

Broker API

The nested legs field on the order leg schema is now described as either null or an empty array, so generated clients can model it without recursion. Behavior is unchanged: order legs are never nested beyond one level and the API continues to return null.

  • legs on an order leg is constrained to zero items.
  • The field description notes that an empty array is accepted for generated-client compatibility.

Affected Endpoints

  • POST /v1/trading/accounts/{account_id}/orders
  • GET /v1/trading/accounts/{account_id}/orders
  • DELETE /v1/trading/accounts/{account_id}/orders
  • GET /v1/trading/accounts/{account_id}/orders/{order_id}
  • PATCH /v1/trading/accounts/{account_id}/orders/{order_id}
  • GET /v1/trading/accounts/{account_id}/orders:by_client_order_id
  • DELETE /v1/trading/accounts/{account_id}/positions
  • DELETE /v1/trading/accounts/{account_id}/positions/{symbol_or_asset_id}
  • GET /v2/events/trades