Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Getting order completed event #902

Answered by kernc
yoavweber asked this question in Q&A
Discussion options

Hey People,
Is there any callback/way to get notified when an order gets filled?

My goal is to create a new order based on the filled order's data.

Thanks!

You must be logged in to vote

There is nothing else besides the API, which should be simple enough to wrap one's head around.

You can track trades like so:

def init(self):
 self.seen_trades = set()
def next(self):
 for trade in self.trades:
 if trade not in self.seen_trades:
 self.seen_trades.add(trade)
 ... # Create new order based on filled order's data
 ...

Replies: 1 comment

Comment options

There is nothing else besides the API, which should be simple enough to wrap one's head around.

You can track trades like so:

def init(self):
 self.seen_trades = set()
def next(self):
 for trade in self.trades:
 if trade not in self.seen_trades:
 self.seen_trades.add(trade)
 ... # Create new order based on filled order's data
 ...
You must be logged in to vote
0 replies
Answer selected by yoavweber
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants

AltStyle によって変換されたページ (->オリジナル) /