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.10.tar.gz (2.9 kB view details)

Uploaded Source

Built Distribution

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

Uploaded Python 3

File details

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

File metadata

  • Download URL: crypto_com_sdk-0.0.10.tar.gz
  • Upload date:
  • Size: 2.9 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.10.tar.gz
Algorithm Hash digest
SHA256 948d2df3583fda13260b390a099974ea3dfa439ce014576d2abad2112aa89b4a
MD5 c5684498cf57f96a556362f6cdb1a29a
BLAKE2b-256 d3ece418f72b74b4afa6cd65332c34220416c19ca5dd7a3c43869f3687533a58

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for crypto_com_sdk-0.0.10-py3-none-any.whl
Algorithm Hash digest
SHA256 2e65f8b719116f4708b26e067ed40d003a24bd2660d5219d085a59ae13e7818e
MD5 876e22a1940c2d40563afa0abf9badf8
BLAKE2b-256 344887bae06abb009f5f0e5a7937a4bdbabf3a0cec752dc4ba4818a0e32448f3

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