Skip to main content

Async Python SoloBot API Wrapper

Project description

logo-main

solobot-web-api

LICENSE Supported Versions PyPI Version

Python library for interacting with SoloBot Web API.

README also available in:

Powered by 🥕 Морковный Бот

Installing

solobot-web-api is available on PyPI:

$ python -m pip install solobot-web-api

Officially supports Python 3.9+ and requires aiohttp.

API Version and Reference

Base api url: https://pocomacho.ru/solonetbot/api/v1/modules

API reference and official docs: https://pocomacho.ru/solonetbot/api/swagger

Usage Examples

You can find a raw scheme example in the docs: https://pocomacho.ru/solonetbot/api/swagger

Grant a license to a user:

import asyncio
from solowebapi import SoloWebAPI


async def main():
    api = SoloWebAPI("username", "password")
    active = await api.grant_license("example_module", 123)
    print("License active:", active)
    await api.close()


asyncio.run(main())

Check if a license is active:

import asyncio
from solowebapi import SoloWebAPI


async def main():
    api = SoloWebAPI("username", "password")
    is_active = await api.check_license("example_module", 123)
    print("License active:", is_active)
    await api.close()


asyncio.run(main())

Revoke a license:

import asyncio
from solowebapi import SoloWebAPI


async def main():
    api = SoloWebAPI("username", "password")
    revoked = await api.revoke_license("example_module", 123)
    print("License revoked:", revoked)
    await api.close()


asyncio.run(main())

This project is licensed under the MIT License.

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

solobot_web_api-1.0.0.tar.gz (5.2 kB view details)

Uploaded Source

Built Distribution

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

solobot_web_api-1.0.0-py3-none-any.whl (5.6 kB view details)

Uploaded Python 3

File details

Details for the file solobot_web_api-1.0.0.tar.gz.

File metadata

  • Download URL: solobot_web_api-1.0.0.tar.gz
  • Upload date:
  • Size: 5.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for solobot_web_api-1.0.0.tar.gz
Algorithm Hash digest
SHA256 bcdabfc52caa614c85bac17ae0ef5e90fa9cd3ca6aab684f7722768ecade002c
MD5 7db8b9b7f092ffa5dc7932f2e9489f55
BLAKE2b-256 07dc685cb96502737b585a9e313d250799df6f049fb14da85bf9b4be657673aa

See more details on using hashes here.

Provenance

The following attestation bundles were made for solobot_web_api-1.0.0.tar.gz:

Publisher: publish.yml on hteppl/solobot-web-api

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file solobot_web_api-1.0.0-py3-none-any.whl.

File metadata

File hashes

Hashes for solobot_web_api-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 ca11ce331b2e41019b5509c826c06c3e46f14bf755460579b1ea990580509be7
MD5 08c34f91dcc42782c6b199007e11b114
BLAKE2b-256 5837721832f47c3167627c06fefdaab0b0f0144e362a3083afa0243a4b6ec8a3

See more details on using hashes here.

Provenance

The following attestation bundles were made for solobot_web_api-1.0.0-py3-none-any.whl:

Publisher: publish.yml on hteppl/solobot-web-api

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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