Skip to main content

DeDust - DeDust v2 API for Python.

Project description

DeDust API for Python

Library for connecting DeDust API to Python apps.

Description

You can get token prices, volumes and liquidity.

Getting Started

Dependencies

  • aiohttp

Installing

pip install dedust

Using

Example of getting data about token.

import asyncio
from dedust.api import API
from dedust.tokens import Token

TOKEN = 'EQBlqsm144Dq6SjbPI4jjZvA1hqTIP3CvHovbIfW_t-SCALE'

async def main():
    api = API()
    token = Token(api, TOKEN)
    
    print(f'$SCALE price: {await token.get_price()} TON')
    print(f'Volume: {(await token.get_volume())[0]} TON')
    print(f'Liquidity: {(await token.get_liquidity())[0]} TON')
    print(f'$LP token: {await token.get_lp_token_address()}')


if __name__ == '__main__':
    loop = asyncio.get_event_loop()
    loop.run_until_complete(main())

Authors

@Vlad10081

Version History

  • 0.0.1
    • Initial Beta
  • 0.0.2
    • LP token address getting

License

This project is licensed under the Apache License 2.0 - see the LICENSE.md file for details

Donate

If you like the bot, I will be glad to accept donations.

  • TON: EQCgphx8rTI0PukwmgpVqiPgqguTujhQscg2h7jgc4U0t347

Acknowledgments

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

dedust-0.0.2.tar.gz (6.3 kB view hashes)

Uploaded Source

Built Distribution

dedust-0.0.2-py2.py3-none-any.whl (7.2 kB view hashes)

Uploaded Python 2 Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page