Skip to content

Vlad2030/solathon-aiohttp

Repository files navigation

Solathon logo

PyPI version MIT License

Solathon-aiohttp

Solathon is a high performance, easy to use and feature-rich Solana SDK for Python. Easy for beginners, powerful for real world applications.

Rewritten solathon that uses aiohttp instead httpx

✨ Getting started

Installation

pip install solathon_aiohttp

Client example

import asyncio

from solathon_aiohttp import AsyncClient, MAINNET_ENDPOINT

async def main() -> None:
    client = AsyncClient(MAINNET_ENDPOINT)

if __name__ == "__main__":
    asyncio.run(main())

Basic usage example

# Basic example of fetching a public key's balance
import asyncio
from solathon_aiohttp import AsyncClient, DEVNET_ENDPOINT

public_key = "6igbZNEsbRRXvutJc3VYC19MxNg9u1zMHX39zgXpjgrn"

async def main() -> None:
    client = AsyncClient(MAINNET_ENDPOINT)
    balance = await client.get_balance(public_key)
    print(balance)

if __name__ == "__main__":
    asyncio.run(main())

🗃️ Contribution

Drop a pull request for anything which seems wrong or can be improved, could be a small typo or an entirely new feature! Checkout CONTRIBUTING.md for guidelines on how to proceed.