tedchou12 / webull

Unofficial APIs for Webull.
MIT License
601 stars 184 forks source link

Get order fill price #325

Closed Shomari closed 2 years ago

Shomari commented 2 years ago

The response from wb.place order is just a JSON that has success and an orderId, but it does not show the price that filled for. Is there another endpoint I can call with the order id to see if the order was filled and at what price?

Alanavai commented 2 years ago

Yes, the get_positions() function returns a dictionary of your current positions. One of the keys in that dictionary, "costPrice", corresponds to the price at which an order was filled.