8000 GitHub - gelhteag/onchainaggregator: Onchain Aggregator is a Go package that implements queries for uniswapV2, as defined in their API reference. These queries retrieve data from the Uniswap smart contract running on the Ethereum blockchain. uniswapV2 API reference
[go: up one dir, main page]

Skip to content

Onchain Aggregator is a Go package that implements queries for uniswapV2, as defined in their API reference. These queries retrieve data from the Uniswap smart contract running on the Ethereum blockchain. uniswapV2 API reference

License

Notifications You must be signed in to change notification settings

gelhteag/onchainaggregator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

17 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Onchain Aggregator

Onchain Aggregator is a Go package that implements queries for uniswapV2, as defined in their API reference. These queries retrieve data from the Uniswap smart contract running on the Ethereum blockchain. uniswapV2 API reference

About The Graph

The Graph is a decentralized protocol for indexing and querying blockchain data. The Graph makes it possible to query data that is difficult to query directly. Projects with complex smart contracts like Uniswap store data on the Ethereum blockchain, making it really difficult to read anything other than basic data directly from the blockchain. The Graph solves this with a decentralized protocol that indexes and enables the performant and efficient querying of blockchain data. These APIs (indexed "subgraphs") can then be queried with a standard GraphQL API.

To test subgraph queries, you can use the Uniswap v2 subgraph on the hosted service provided by The Graph, which can be accessed on the playground

Functions

Onchain Aggregator provides the following functions, which implement queries defined by Uniswap and can be found in their API reference:

Global Data

  • QueryGlobalStats
  • QueryGlobalHistoricalLookup

Pair Data

  • QueryRecentSwapsFromPair
  • QueryPairOverview
  • QueryAllUniswapPairs
  • QueryMostLiquidPairs
  • QueryRecentSwapsFromPair
  • QueryPairDailyAggregated

Token Data

  • QueryTokenOverview
  • QueryTokenData
  • QueryAllUniswapTokens
  • QueryTokenTransactions
  • QueryTokenDailyData

Requirements

  • Go v1.16 or higher
  • The following Go packages:
    • github.com/machinebox/graphql
    • github.com/influxdata/influxdb-client-go/v2

About

Onchain Aggregator is a Go package that retrieves onchain data from the Uniswap smart contract and stores it in a database. The raw data will subsequently undergo transformation to extract meaningful information. At present, it only gathers data from Uniswap, but this package may expand to include other blockchains and platforms in the future.

If you use this package, please provide a reference to the original source.

License

This package is released under the MIT License. See the LICENSE file for details.

About

Onchain Aggregator is a Go package that implements queries for uniswapV2, as defined in their API reference. These queries retrieve data from the Uniswap smart contract running on the Ethereum blockchain. uniswapV2 API reference

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

0