Skip to main content

Simple python library for CryptoBot (service CryptoPay) API

Project description

Overview

This is a simple sync Python library for API @CryptoBot particularly payment service CryptoPay.

Check official API documentation: https://help.crypt.bot/crypto-pay-api


Installation

pip install CryptoBotSyncApi

First Steps

  1. Create your application and get an API token: Open @CryptoBot or @CryptoTestnetBot (for testnet).
  2. Send bot a command /pay to create a new app and get API Token.
  3. Copy API token
  4. Use your API token to create CryptoPay object

All queries to the Crypto Pay API must be sent over HTTPS


Example

from CryptoBotSyncApi import CryptoPay

pay = CryptoPay("crypto_bot_api")
invoice = pay.create_invoice(amount='500', currency_type='fiat', accepted_assets='usdt,btc', fiat='RUB')

Methods

  • get_me() - Use this method to test your app's authentication token. Requires no parameters.
  • create_invoice() - Use this method to test your app's authentication token. Requires no parameters.
  • delete_invoice - Use this method to delete invoices created by your app.
  • create_check - Use this method to create a new check.
  • delete_check - Use this method to delete checks created by your app.
  • transfer - Use this method to send coins from your app's balance to a user. This method must first be enabled in the security settings of your app. Open @CryptoBot (@CryptoTestnetBot for testnet), go to Crypto Pay → My Apps, choose an app, then go to Security -> Transfers... and tap Enable.
  • get_invoices() - Use this method to get invoices created by your app.
  • get_transfers() - Use this method to get transfers created by your app.
  • get_checks() - Use this method to get checks created by your app.
  • get_balance() - Use this method to get balances of your app. Requires no parameters.
  • get_exchange_rates() - Use this method to get exchange rates of supported currencies. Requires no parameters.
  • get_currencies() - Use this method to get a list of supported currencies. Requires no parameters.
  • get_stats() - Use this method to get app statistics.

Creator

Library developed by @Artcher.

I will be 😊 very thankful if you use my ref link to register in CryptoBot

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

cryptobotsyncapi-1.0.1.tar.gz (13.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

cryptobotsyncapi-1.0.1-py3-none-any.whl (6.4 kB view details)

Uploaded Python 3

File details

Details for the file cryptobotsyncapi-1.0.1.tar.gz.

File metadata

  • Download URL: cryptobotsyncapi-1.0.1.tar.gz
  • Upload date:
  • Size: 13.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.12.3

File hashes

Hashes for cryptobotsyncapi-1.0.1.tar.gz
Algorithm Hash digest
SHA256 7ec78897fca58136ed3a0895779d08e5ca6216cfbe8ee30da3818c4a4d617995
MD5 9ad991bba2c6b27474b8c4134594614e
BLAKE2b-256 e07f7b288bde6ea405113c952c7ae742f501130ef125152f61597969168a82f4

See more details on using hashes here.

File details

Details for the file cryptobotsyncapi-1.0.1-py3-none-any.whl.

File metadata

File hashes

Hashes for cryptobotsyncapi-1.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 59c0e319b745c7b02f10fc214b5854e73701bdedb3b0d48e3ae134aa7bf13eaa
MD5 05ce2fe4f52edfc0afcb14c7faa5048a
BLAKE2b-256 b8d8e9577cfe5581e654f624c0eaea66cc52f33d6489d6a5bc7b02b00704a58c

See more details on using hashes here.

Supported by

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