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):
- get_simple_token_price(network_id: str, token_addresses: list, include_market_cap: bool = False, mcap_fdv_fallback: bool = False, include_24hr_vol: bool = False, include_24hr_price_change: bool = False, include_total_reserve_in_usd: bool = False): Fetch USD prices for up to 30 token addresses in a single call. Returns a DataFrame keyed by
token_addresswith aprice_usdcolumn (plus optionalmarket_cap_usd/volume_usd_h24/price_change_percentage_h24/reserve_in_usdcolumns when requested).
Endpoints to add:
- /search/pools
- / rest of tokens list
Metadata
Release files for geckoterminal-py 0.3.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| geckoterminal_py-0.3.1.tar.gz | 17.0 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| geckoterminal_py-0.3.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 37.4 kB
Release files / geckoterminal_py-0.3.1.tar.gz
| Download URL | geckoterminal_py-0.3.1.tar.gz |
|---|---|
| Size | 17.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
f9ee378f49060a0ddc57cfe8ff0a30718fdd57831d811c72e41cdd2d4a3c13ee
|
|
BLAKE2b-256 checksum How to use checksums |
932aca50d8bd19a7d980aa6df8510d51c6426683f0c0c5d8922b358afb33b262
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|
Release files / geckoterminal_py-0.3.1-py3-none-any.whl
| Download URL | geckoterminal_py-0.3.1-py3-none-any.whl |
|---|---|
| Size | 20.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
fec3fd6a5639c7478005536f10ea7401d93e005d3b738d92f5f73a774183f2c7
|
|
BLAKE2b-256 checksum How to use checksums |
f8af00745fcec035fd68d7cf7e5191adb51d4c8a1c4443f389ae952d7910fb7d
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|