Open Orders Support
Great project! Example code works great. Have you looked into how to implement retrieving account open orders?
I might be willing to do a PR to add open orders if you can just point me to the Schwab spec for API URLs, e.g. such that got you to https://client.schwab.com/api/PositionV2/PositionsDataV2.
Thanks!
Hi @kimardenmiller , I haven't personally looked into retrieving open account orders but I'd love to review and merge a PR for it.
Schwab doesn't have a spec for their API URLs. After logging in, I just looked at the network requests being made by the website and did some trial and error to identify the API that was generating the response I was looking for!
Thanks @itsjafer. Looks as if we can return return data from the open orders page at https://client.schwab.com/Trade/OrderStatus/ViewOrderStatus.aspx?ViewTypeFilter=Open.
But rather than the very nice XHR data on positions, all I'm seeing back with open orders data is the html document.
Any thoughts before I look into parsing that html, which might mean creating new, additional dependencies to parse efficiently.
Hi @kimardenmiller, I've updated this package to use the latest API that Schwab is using on their UI. I've added an orders_v2() function that should help you get the information you're looking for!
Thanks for that update, Jafer. I’ll have a look in a bit. :-)
On Dec 13, 2023, at 3:01 PM, Jafer Haider @.***> wrote:
Hi @kimardenmiller https://github.com/kimardenmiller, I've updated this package to use the latest API that Schwab is using on their UI. I've added an orders_v2() function that should help you get the information you're looking for!
— Reply to this email directly, view it on GitHub https://github.com/itsjafer/schwab-api/issues/7#issuecomment-1854693800, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAQQUWAL6ILKW4PH5FPY7DTYJIJRJAVCNFSM5MZWVQ42U5DIOJSWCZC7NNSXTN2JONZXKZKDN5WW2ZLOOQ5TCOBVGQ3DSMZYGAYA. You are receiving this because you were mentioned.