-
-
Save thaaddeus/2a57a81084c40290dd045edd9b2ea3dc to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const { replay } = require('tardis-dev') | |
;(async () => { | |
const messages = replay({ | |
exchange: 'deribit', | |
from: '2021-12-01', | |
to: '2021-12-02', | |
filters: [{ channel: 'book', symbols: ['BTC-PERPETUAL'] }], | |
apiKey: '<YOUR_API_KEY>' | |
}) | |
// localTimestamp is a message arrival timestamp | |
// message is a message object as provided by Deribit real-time stream | |
for await (const { localTimestamp, message } of messages) { | |
console.log(localTimestamp, message) | |
} | |
})() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment