Skip to main content

Library for api.botstat.io

Project description

aiobotstat

Mini library for BotStat API.

Current API version: 0.1

Install

  • Git: pip install git+https://github.com/viuipan/aiobotstat.git

  • PyPi: pip install aiobotstat

Example:

import asyncio

from aiobotstat import BotStatAPI

BOT_TOKEN = ''
FILE_PATH = ''
BOT_USERNAME = ''

api = BotStatAPI(BOT_TOKEN)


async def main():
    bot_info = await api.get_bot_info(username=BOT_USERNAME)
    print(bot_info)

    task = await api.create_task(file=FILE_PATH)
    print(task)

    status = await api.get_task_status(task_id=task.id)
    print(status)

    cancel_result = await api.cancel_task(task_id=task.id)
    print(f'Cancel result is {cancel_result}')


asyncio.run(main())

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

aiobotstat-0.1.3.tar.gz (5.9 kB view details)

Uploaded Source

Built Distribution

aiobotstat-0.1.3-py3-none-any.whl (7.3 kB view details)

Uploaded Python 3

File details

Details for the file aiobotstat-0.1.3.tar.gz.

File metadata

  • Download URL: aiobotstat-0.1.3.tar.gz
  • Upload date:
  • Size: 5.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.10.0

File hashes

Hashes for aiobotstat-0.1.3.tar.gz
Algorithm Hash digest
SHA256 330bd316b134c15988cc7d802dbda697af9ee162594832efc4ed853dbf257edb
MD5 5ce388f340ea309a6b2c980945b4ab73
BLAKE2b-256 f248aee4041a3239e1880a7b9b091f52ff09fa160daafa3c9d4e9e975faf9055

See more details on using hashes here.

File details

Details for the file aiobotstat-0.1.3-py3-none-any.whl.

File metadata

  • Download URL: aiobotstat-0.1.3-py3-none-any.whl
  • Upload date:
  • Size: 7.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.10.0

File hashes

Hashes for aiobotstat-0.1.3-py3-none-any.whl
Algorithm Hash digest
SHA256 8ae0bd582aa1fadf7af1a3a64463099503bb60ca4739de5f1f32447ffea48462
MD5 3c8c6ecd92f0cde1b832479e325bf429
BLAKE2b-256 ebd6ea2db41534f132f15ee02b03e78ece420de8a9b37608608ed24d1a5c7a86

See more details on using hashes here.

Supported by

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