Skip to content

get_orders_by_path formats HTTP request with datetimes while TDA expects dates - #177

Open
silasb wants to merge 2 commits into
alexgolec:masterfrom
silasb:get-orders-use-dates-not-datetimes
Open

get_orders_by_path formats HTTP request with datetimes while TDA expects dates#177
silasb wants to merge 2 commits into
alexgolec:masterfrom
silasb:get-orders-use-dates-not-datetimes

Conversation

@silasb

@silasb silasb commented Feb 20, 2021

Copy link
Copy Markdown

While debugging https://tda-api.readthedocs.io/en/stable/client.html#accessing-existing-orders I noticed that when you specify no arguments it would not return any data. After digging in I saw that https://developer.tdameritrade.com/account-access/apis/get/orders-0 only accepts yyyy-MM-dd format. Per their documentation I set the "from date" to be 60 days from today. When testing, it seems like they are lenient around this date.

Changes

  • When passing in no date arguments pass in dates
  • Set the from date to be 60 days ago

@silasb silasb changed the title get_orders_by_path uses datetimes while expecting dates get_orders_by_path formats HTTP request with datetimes while TDA expects dates Feb 20, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant