GithubHelp home page GithubHelp logo

staciax / marblex.py Goto Github PK

View Code? Open in Web Editor NEW
2.0 1.0 0.0 32 KB

An Asynchronous and Synchronous Marblex API Wrapper for Python

License: MIT License

Python 100.00%
api-wrapper asynchronous ninokuni python marblex cryptocurrency

marblex.py's Introduction

marblex.py

An Asynchronous Marblex API Wrapper for Python

Installation

Windows:

$ pip install -U marblex.py

Linux/MacOS:

$ python3 -m pip install -U marblex.py

Asynchronous Example:

import asyncio
from marblex import Marblex

mbx = Marblex()

async def main():

    async with mbx:
        nkt = await mbx.get_territe_token()
        nka = await mbx.get_asterite_token()

        print(f"NKT : {nkt.USD}$, Percent: {nkt.percent}")
        print(f"NKA : {nka.USD}$, Percent: {nka.percent}")

asyncio.run(main())

Synchronous Example:

from marblex import MarblexSync

mbx = MarblexSync()

nkt = mbx.get_territe_token()
nka = mbx.get_asterite_token()
itu = mbx.get_inetrium_token()

print(f"NKT : {nkt.USD}$, Percent: {nkt.percent}")
print(f"NKA : {nka.USD}$, Percent: {nka.percent}")
print(f"ITU : {itu.USD}$, Percent: {itu.percent}")

>>> NKT : 1.47$, Percent: -4.22 %
>>> NKA : 3.56$, Percent: +1.61 %
>>> ITU : 0.13$, Percent: -0.59 %

License

MIT

inspired by

marblex.py's People

Contributors

staciax avatar

Stargazers

 avatar  avatar

Watchers

 avatar

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.