Skip to content

Norbaeocystin/openbook-v2-trades

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

31 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Fetching trades data for openbook v2 using websocket. This is just proof of concept. Use on your own risk!. Websocket can be and will be instable

if you want to use yellowstone grpc geyser plugin check branch grpc
If you want to publish filled trades to zeromq and process afterwards use branch zeromq

to run

cargo run --bin openbookv2-printer -- --rpc-url <YourRPC> --market <Pubkey of market which you want to listen, default SOL-USDC>

or you can build with cargo build --release

if you want to print all openbook markets:

cargo run --example market -- --rpc-url <YourRPCWhereYouCanMakeGPACalls>

to run more market via multiple subscriptions over one websocket use branch multiple (unstable ...)

git switch multiple
cargo run -- --market CFSMrBssNG8Ud1edW59jNLnq2cwrQ9uY5cM3wXmqRJj3 DBSZ24hqXS5o8djunrTzBsJUb1P8ZvBs1nng5rmZKsJt 5h4DTiBqZctQWq7xc3H2t8qRdGcFNQNk1DstVNnbJvXs

TODO

  • option to use polling via getBlock rpc call ...
  • store data in db (redis,mongodb)
  • geyser plugin instead of websocket
  • handling of websocket
  • print trades for all markets.

cargo run -- --market CFSMrBssNG8Ud1edW59jNLnq2cwrQ9uY5cM3wXmqRJj3

About

listening to openbook v2 filled trades ...

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •