This repository was archived by the owner on May 11, 2026. It is now read-only.
types(client): return typed order responses instead of any#329
Open
jasonandjay wants to merge 1 commit into
Open
types(client): return typed order responses instead of any#329jasonandjay wants to merge 1 commit into
jasonandjay wants to merge 1 commit into
Conversation
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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.
Addresses #307
What changed
anyreturn types in order-posting APIs with explicit types:postOrder->Promise<OrderResponse>postOrders->Promise<OrderResponse[]>createAndPostOrder->Promise<OrderResponse>createAndPostMarketOrder->Promise<OrderResponse>Why
This improves TypeScript ergonomics and safety for SDK consumers by exposing concrete response shapes instead of
any.Validation
pnpm lintpnpm buildvitest run tests/utilities.test.tsNote
Low Risk
Low risk; changes are TypeScript return-type annotations for order-posting methods and should not affect runtime behavior, but may require downstream callers to align with the
OrderResponseshape.Overview
Updates the client order submission APIs to return explicit response types instead of
any.postOrder,postOrders,createAndPostOrder, andcreateAndPostMarketOrdernow returnOrderResponse/OrderResponse[], exposing a concrete response contract (e.g.,success,errorMsg,orderID,transactionsHashes,status, amounts) for SDK consumers.Written by Cursor Bugbot for commit 436d3c6. This will update automatically on new commits. Configure here.