Skip to main content

cryptocom crypto exchange api client

Project description

cryptocom-python

Python SDK (sync and async) for Cryptocom with Rest and WS capabilities.

You can check Cryptocom's docs here: Docs

You can check the SDK docs here: SDK

This package derives from CCXT and allows you to call pretty much every endpoint by either using the unified CCXT API or calling the endpoints directly

Installation

pip install crypto-com-sdk

Usage

Sync

from cryptocom import CryptocomSync

def main():
    instance = CryptocomSync({})
    ob =  instance.fetch_order_book("BTC/USDC")
    print(ob)
    #
    # balance = instance.fetch_balance()
    # order = instance.create_order("BTC/USDC", "limit", "buy", 1, 100000)

Async

import asyncio
from cryptocom import CryptocomAsync

async def main():
    instance = CryptocomAsync({})
    ob =  await instance.fetch_order_book("BTC/USDC")
    print(ob)
    #
    # balance = await instance.fetch_balance()
    # order = await instance.create_order("BTC/USDC", "limit", "buy", 1, 100000)

asyncio.run(main())

Websockets

from cryptocom import CryptocomWs

async def main():
    instance = CryptocomWs({})
    while True:
        ob = await instance.watch_order_book("BTC/USDC")
        print(ob)
        # orders = await instance.watch_orders("BTC/USDC")

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

crypto_com_sdk-0.0.9.tar.gz (528.4 kB view details)

Uploaded Source

Built Distribution

crypto_com_sdk-0.0.9-py3-none-any.whl (1.6 kB view details)

Uploaded Python 3

File details

Details for the file crypto_com_sdk-0.0.9.tar.gz.

File metadata

  • Download URL: crypto_com_sdk-0.0.9.tar.gz
  • Upload date:
  • Size: 528.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.2

File hashes

Hashes for crypto_com_sdk-0.0.9.tar.gz
Algorithm Hash digest
SHA256 965d3739708177bdd4fad16fdabc8a415c9592814faab61bdd772daec407d924
MD5 7ac870d0ba4836715cd3cb0541898b7f
BLAKE2b-256 d6fb608e8feec71edb6346601d10313e891a76989bb1b1b64b5c00fecc05ac88

See more details on using hashes here.

File details

Details for the file crypto_com_sdk-0.0.9-py3-none-any.whl.

File metadata

  • Download URL: crypto_com_sdk-0.0.9-py3-none-any.whl
  • Upload date:
  • Size: 1.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.2

File hashes

Hashes for crypto_com_sdk-0.0.9-py3-none-any.whl
Algorithm Hash digest
SHA256 3f4aa7b4aac44370470e05a6b7a4204b1fafad199940219c3dfe8667be2de689
MD5 e7af06d951d03f9c99d021da42050d72
BLAKE2b-256 3e2169f32ff51996c307bce85b4a558b2f948c7a43106ccc5f238616df6206b2

See more details on using hashes here.

Supported by

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