Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

luno

Package Overview
Dependencies
Maintainers
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

luno

Luno Crypto Currency Exchanage Python API

  • 0.3.6
  • PyPI
  • Socket score

Maintainers
1

Luno Python Library

Sync and Async Python 3 clients for the Luno API

Quickstart

This library includes 2 types of clients, a sync client built using the requests library and an async library built with treq and twisted.

Sync client

from luno.clients.sync import LunoSyncClient

api_key = ''
api_secret = ''

client = LunoSyncClient(api_key=api_key, secret=api_secret)
client.ticker('XBTZAR')

Async client

from typing import Dict
from twisted.internet import reactor
from luno.clients.asynchronous import LunoAsyncClient

api_key = ''
api_secret = ''

client = LunoAsyncClient(api_key=api_key, secret=api_secret)
d = client.ticker('XBTZAR') # returns a twisted deferred

def print_data(data: Dict) -> None:
    """prints the json response from an API call"""
    print(data)
        
d.addCallback(print_data)

reactor.run()

Installation

The library can be installed from PyPi as follows.

pip install luno

The async client is an optional extra and may be installed as follows.

pip install luno[async]

To install the version on this repository follow the steps below.

git clone https://github.com/BradleyKirton/luno
cd luno
python -m venv env # virtualenv env
source env/bin/activate
pip install . #pip install .[async] for the async client

Developement

Clone the repo and install the package with it's development requirements.

git clone https://github.com/BradleyKirton/luno
cd luno
python -m venv env # virtualenv env
source env/bin/activate
pip install -e .[dev]
pytest

TODO

Note this library is still in beta.

  • Write documentation

Keywords

FAQs


Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc