Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

"seq" missing in trades payload? #4

Open
yoavram opened this issue Dec 28, 2016 · 3 comments
Open

"seq" missing in trades payload? #4

yoavram opened this issue Dec 28, 2016 · 3 comments

Comments

@yoavram
Copy link

yoavram commented Dec 28, 2016

The Poloniex API docs say that:

The dictionary portion of each market message ("kwargs" in the Node.js example) will contain a sequence number with the key "seq".

However, the async API only provides type, currency_pair, and data, which includes rate, type and amount (for modify events).

Where is the "seq"? What am I missing here?

@andrewshvv
Copy link
Member

@yoavram Hi! Looks like Poloniex API changed since I had implemented it.

@yoavram
Copy link
Author

yoavram commented Dec 29, 2016

thanks. I'd be happy to modify the code and make a PR, could you point me towards the place in the code where you parse the payload from the push API?

@andrewshvv
Copy link
Member

@yoavram It would be great! I think this should be somewhere here.

clayrichardson added a commit to clayrichardson/poloniex-api that referenced this issue May 7, 2017
clayrichardson added a commit to clayrichardson/poloniex-api that referenced this issue May 7, 2017
From: https://poloniex.com/support/api/
"""
The dictionary portion of each market message ("kwargs" in the Node.js example) will contain a sequence number with the key "seq". In order to keep your order book consistent, you will need to ensure that messages are applied in the order of their sequence numbers, even if they arrive out of order. In some markets, if there is no update for more than 1 second, a heartbeat message consisting of an empty argument list and the latest sequence number will be sent. These will go out once per second, but if there is no update for more than 60 seconds, the heartbeat interval will be reduced to 8 seconds until the next update.

Several order book and trade history updates will often arrive in a single message. Be sure to loop through the entire array, otherwise you will miss some updates.
"""
clayrichardson added a commit to clayrichardson/poloniex-api that referenced this issue May 7, 2017
From: https://poloniex.com/support/api/
"""
The dictionary portion of each market message ("kwargs" in the Node.js example) will contain a sequence number with the key "seq". In order to keep your order book consistent, you will need to ensure that messages are applied in the order of their sequence numbers, even if they arrive out of order. In some markets, if there is no update for more than 1 second, a heartbeat message consisting of an empty argument list and the latest sequence number will be sent. These will go out once per second, but if there is no update for more than 60 seconds, the heartbeat interval will be reduced to 8 seconds until the next update.

Several order book and trade history updates will often arrive in a single message. Be sure to loop through the entire array, otherwise you will miss some updates.
"""
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

No branches or pull requests

2 participants