Git Product home page Git Product logo

geckoterminal-py's Introduction

GeckoTerminal Py

GeckoTerminal Py is a Python client for the GeckoTerminal. It provides a user-friendly way to fetch network and pool data asynchronously or synchronously.

Installation

To install GeckoTerminal Py, use pip:

pip install geckoterminal-py

Usage

You can fetch data about networks using GeckoTerminal Py in two ways:

Asynchronous usage

from geckoterminal_py import GeckoTerminalAsyncClient
import asyncio


async def main():
    client = GeckoTerminalAsyncClient()
    networks_df = await client.get_networks()
    print(networks_df)
    await client.close()


# In an asyncio environment, you'd use:
asyncio.run(main())

Synchronous usage

from geckoterminal_py import GeckoTerminalSyncClient


def main():
    client = GeckoTerminalSyncClient()
    networks_df = client.get_networks()
    print(networks_df)
    client.close()


main()

Methods Available

Here is a brief description of the methods available in the GeckoTerminalClient: Please check the examples notebook where you can find the usage of all of them.

Methods:

  • get_networks():
  • get_dexes_by_network(network_id: str):
  • get_top_pools_by_network(network_id: str):
  • get_top_pools_by_network_dex(network_id: str, dex_id: str):
  • get_top_pools_by_network_token(network_id: str, token_id: str):
  • get_new_pools_by_network(network_id: str):
  • get_new_pools_all_networks():
  • get_ohlcv(network_id: str, pool_address: str, timeframe: str, before_timestamp: int = None, currency: str = "usd", token: str = "base", limit: int = 1000):

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.