Add caching to market hour and cater for (long) weekends in the 1DTE trade automation

This commit is contained in:
2024-08-30 15:39:18 -05:00
parent 51b4d17cd7
commit e0be7c1889
3 changed files with 14 additions and 9 deletions

View File

@@ -21,6 +21,4 @@ echo $fromEnteredTime
./getNewAccessToken.sh
curl -s -X GET "https://api.schwabapi.com/trader/v1/orders?fromEnteredTime=${fromEnteredTime}&toEnteredTime=${toEnteredTime}" -H "Authorization: Bearer $(<access_token.dat)" > ${tempFile}
#jq -r 'map(.enteredTime)[]' < ${tempFile}
#jq -r '.[].orderLegCollection[].instrument.symbol' < ${tempFile}
jq -r '.[] | [.orderId | tostring][0] + "," + .status + "," + .orderLegCollection[].instrument.symbol' < ${tempFile}