Ariadne is a library for fetching blocks from cosmos based blockchain node. The library is helpful at off-chain services building.
go get -u github.com/Decentr-net/ariadne
Short example:
f, err := ariadne.New(nodeAddr, cdc, time.Minute)
if err != nil { panic(err) }
_ = f.FetchBlocks(context.Background(), 1, func (b Block) error {
fmt.Sprintf("%+v\n", b)
return nil
})
You have to look at detailed example here
Feel free to create issues and send pull requests!
This project is under Apache-2.0 License