Skip to content

Commit

Permalink
merge stashed files
Browse files Browse the repository at this point in the history
  • Loading branch information
alexgolec committed May 4, 2024
1 parent ba8adce commit 5ac64e7
Show file tree
Hide file tree
Showing 2 changed files with 1,168 additions and 1,051 deletions.
10 changes: 5 additions & 5 deletions schwab/client/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -171,16 +171,16 @@ def get_accounts(self, *, fields=None):
##########################################################################
# Orders

def cancel_order(self, order_id, account_hash):
'''Cancel a specific order for a specific account'''
path = '/trader/v1/accounts/{}/orders/{}'.format(account_hash, order_id)
return self._delete_request(path)

def get_order(self, order_id, account_hash):
'''Get a specific order for a specific account by its order ID'''
path = '/trader/v1/accounts/{}/orders/{}'.format(account_hash, order_id)
return self._get_request(path, {})

def cancel_order(self, order_id, account_hash):
'''Cancel a specific order for a specific account'''
path = '/trader/v1/accounts/{}/orders/{}'.format(account_hash, order_id)
return self._delete_request(path)

class Order:
class Status(Enum):
'''Order statuses passed to :meth:`get_orders_for_account` and
Expand Down
Loading

0 comments on commit 5ac64e7

Please sign in to comment.