mirror of
https://github.com/boticord/boticordpy.git
synced 2024-11-11 19:07:29 +03:00
bump version to v2.0.3
This commit is contained in:
parent
3b2fd69e85
commit
1582434a3e
9 changed files with 36 additions and 36 deletions
44
README.md
44
README.md
|
@ -4,7 +4,7 @@
|
||||||
|
|
||||||
<p align="center">
|
<p align="center">
|
||||||
<b>
|
<b>
|
||||||
The easiest way to use Boticord API in Python.
|
The easiest way to use BotiCord API in Python.
|
||||||
<span> · </span>
|
<span> · </span>
|
||||||
<a href="https://py.boticord.top/">Docs</a>
|
<a href="https://py.boticord.top/">Docs</a>
|
||||||
</b>
|
</b>
|
||||||
|
@ -20,9 +20,9 @@
|
||||||
<h2>Features</h2>
|
<h2>Features</h2>
|
||||||
|
|
||||||
* Object-oriented
|
* Object-oriented
|
||||||
* Full Boticord API Coverage
|
* Full BotiCord API Coverage
|
||||||
* Modern Pythonic API using `async`/`await` syntax
|
* Modern Pythonic API using `async`/`await` syntax
|
||||||
* Boticord Webhooks
|
* BotiCord Webhooks
|
||||||
* It is not necessary to use any particular library to interact with the Discord API.
|
* It is not necessary to use any particular library to interact with the Discord API.
|
||||||
|
|
||||||
<h2>Installation</h2>
|
<h2>Installation</h2>
|
||||||
|
@ -32,11 +32,11 @@
|
||||||
Enter one of these commands to install the library:
|
Enter one of these commands to install the library:
|
||||||
|
|
||||||
```
|
```
|
||||||
pip install boticordpy
|
pip install boticordpy
|
||||||
```
|
```
|
||||||
|
|
||||||
```
|
```
|
||||||
python3 -m pip install boticordpy
|
python3 -m pip install boticordpy
|
||||||
```
|
```
|
||||||
|
|
||||||
Or just clone the repo: https://github.com/boticord/boticordpy
|
Or just clone the repo: https://github.com/boticord/boticordpy
|
||||||
|
@ -48,29 +48,29 @@ You can find other examples in an examples folder.
|
||||||
**Discord.py Autopost example**
|
**Discord.py Autopost example**
|
||||||
|
|
||||||
```py
|
```py
|
||||||
from discord.ext import commands
|
from discord.ext import commands
|
||||||
|
|
||||||
from boticordpy import BoticordClient
|
from boticordpy import BoticordClient
|
||||||
|
|
||||||
bot = commands.Bot(command_prefix="!")
|
bot = commands.Bot(command_prefix="!")
|
||||||
|
|
||||||
|
|
||||||
async def get_stats():
|
async def get_stats():
|
||||||
return {"servers": len(bot.guilds), "shards": 0, "users": len(bot.users)}
|
return {"servers": len(bot.guilds), "shards": 0, "users": len(bot.users)}
|
||||||
|
|
||||||
|
|
||||||
async def on_success_posting():
|
async def on_success_posting():
|
||||||
print("stats posting successfully")
|
print("stats posting successfully")
|
||||||
|
|
||||||
boticord_client = BoticordClient("your_api_token")
|
boticord_client = BoticordClient("your_api_token")
|
||||||
autopost = (
|
autopost = (
|
||||||
boticord_client.autopost()
|
boticord_client.autopost()
|
||||||
.init_stats(get_stats)
|
.init_stats(get_stats)
|
||||||
.on_success(on_success_posting)
|
.on_success(on_success_posting)
|
||||||
.start()
|
.start()
|
||||||
)
|
)
|
||||||
|
|
||||||
bot.run("bot token")
|
bot.run("bot token")
|
||||||
```
|
```
|
||||||
|
|
||||||
<h2>Links</h2>
|
<h2>Links</h2>
|
||||||
|
@ -78,9 +78,9 @@ You can find other examples in an examples folder.
|
||||||
* [PyPi](https://pypi.org/project/boticordpy)
|
* [PyPi](https://pypi.org/project/boticordpy)
|
||||||
* [Documentation](https://py.boticord.top)
|
* [Documentation](https://py.boticord.top)
|
||||||
* [Github](https://github.com/boticord/boticordpy)
|
* [Github](https://github.com/boticord/boticordpy)
|
||||||
* [Boticord](https://boticord.top/)
|
* [BotiCord](https://boticord.top/)
|
||||||
* [Support](https://boticord.top/discord)
|
* [Support](https://boticord.top/discord)
|
||||||
|
|
||||||
<h2>Help</h2>
|
<h2>Help</h2>
|
||||||
|
|
||||||
If You need any help we recommend you to check the documentation. You can find us [here](https://bcord.cc/support). Main developer is `Marakarka#0575`
|
If You need any help we recommend you to check the documentation. You can find us [here](https://bcord.cc/support). Main developer is **[Marakarka](https://boticord.top/profile/585766846268047370)**
|
||||||
|
|
|
@ -10,7 +10,7 @@ __title__ = 'boticordpy'
|
||||||
__author__ = 'Marakarka'
|
__author__ = 'Marakarka'
|
||||||
__license__ = 'MIT'
|
__license__ = 'MIT'
|
||||||
__copyright__ = 'Copyright 2022 Marakarka'
|
__copyright__ = 'Copyright 2022 Marakarka'
|
||||||
__version__ = '2.0.2'
|
__version__ = '2.0.3'
|
||||||
|
|
||||||
from .client import BoticordClient
|
from .client import BoticordClient
|
||||||
from .webhook import Webhook
|
from .webhook import Webhook
|
||||||
|
|
|
@ -6,7 +6,7 @@ from .autopost import AutoPost
|
||||||
|
|
||||||
|
|
||||||
class BoticordClient:
|
class BoticordClient:
|
||||||
"""Represents a client that can be used to interact with the Boticord API.
|
"""Represents a client that can be used to interact with the BotiCord API.
|
||||||
|
|
||||||
Note:
|
Note:
|
||||||
Remember that every http method can return http exception.
|
Remember that every http method can return http exception.
|
||||||
|
|
|
@ -7,11 +7,11 @@ from . import exceptions
|
||||||
|
|
||||||
class HttpClient:
|
class HttpClient:
|
||||||
"""
|
"""
|
||||||
Represents an HTTP client sending HTTP requests to the Top.gg API.
|
Represents an HTTP client sending HTTP requests to the BotiCord API.
|
||||||
|
|
||||||
Args:
|
Args:
|
||||||
token (:obj:`str`)
|
token (:obj:`str`)
|
||||||
Your bot's Boticord API Token.
|
Your bot's BotiCord API Token.
|
||||||
|
|
||||||
Keyword Arguments:
|
Keyword Arguments:
|
||||||
session: `aiohttp session`_
|
session: `aiohttp session`_
|
||||||
|
|
|
@ -93,7 +93,7 @@ class SingleComment(ApiData):
|
||||||
|
|
||||||
|
|
||||||
class Bot(ApiData):
|
class Bot(ApiData):
|
||||||
"""This model represents a bot, returned from the Boticord API"""
|
"""This model represents a bot, returned from the BotiCord API"""
|
||||||
id: str
|
id: str
|
||||||
"""Bot's Id"""
|
"""Bot's Id"""
|
||||||
|
|
||||||
|
@ -136,7 +136,7 @@ class Bot(ApiData):
|
||||||
long_description: typing.Optional[str]
|
long_description: typing.Optional[str]
|
||||||
"""Bot's long description"""
|
"""Bot's long description"""
|
||||||
|
|
||||||
badge: typing.Optional[int]
|
badge: typing.Optional[str]
|
||||||
"""Bot's badge"""
|
"""Bot's badge"""
|
||||||
|
|
||||||
stats: dict
|
stats: dict
|
||||||
|
|
|
@ -8,7 +8,7 @@ import aiohttp
|
||||||
|
|
||||||
|
|
||||||
class Webhook:
|
class Webhook:
|
||||||
"""Represents a client that can be used to work with Boticord Webhooks.
|
"""Represents a client that can be used to work with BotiCord Webhooks.
|
||||||
IP of the server - your machine IP. (`0.0.0.0`)
|
IP of the server - your machine IP. (`0.0.0.0`)
|
||||||
|
|
||||||
Args:
|
Args:
|
||||||
|
|
|
@ -6,7 +6,7 @@
|
||||||
API Reference
|
API Reference
|
||||||
#############
|
#############
|
||||||
|
|
||||||
API Reference for the BoticordPY Module
|
API Reference for the boticordpy Module
|
||||||
|
|
||||||
Index:
|
Index:
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
Welcome to BoticordPy's documentation!
|
Welcome to boticordpy's documentation!
|
||||||
======================================
|
======================================
|
||||||
|
|
||||||
This is a documentation for wrapper for Boticord API.
|
This is a documentation for wrapper for BotiCord API.
|
||||||
|
|
||||||
======================================
|
======================================
|
||||||
|
|
||||||
|
@ -19,5 +19,5 @@ Links
|
||||||
* :ref:`search`
|
* :ref:`search`
|
||||||
* `PyPi <https://pypi.org/project/boticordpy>`_
|
* `PyPi <https://pypi.org/project/boticordpy>`_
|
||||||
* `GitHub <https://github.com/grey-cat-1908/boticordpy>`_
|
* `GitHub <https://github.com/grey-cat-1908/boticordpy>`_
|
||||||
* `Boticord <https://boticord.top/>`_
|
* `BotiCord <https://boticord.top/>`_
|
||||||
* `Boticord Support <https://boticord.top/boticord>`_
|
* `BotiCord Support <https://boticord.top/discord>`_
|
||||||
|
|
4
setup.py
4
setup.py
|
@ -37,11 +37,11 @@ setup(
|
||||||
packages=find_packages(),
|
packages=find_packages(),
|
||||||
version=version,
|
version=version,
|
||||||
python_requires=">= 3.6",
|
python_requires=">= 3.6",
|
||||||
description="A Python wrapper for Boticord API",
|
description="A Python wrapper for BotiCord API",
|
||||||
long_description=README,
|
long_description=README,
|
||||||
long_description_content_type="text/markdown",
|
long_description_content_type="text/markdown",
|
||||||
url="https://github.com/boticord/boticordpy",
|
url="https://github.com/boticord/boticordpy",
|
||||||
author="KerdokuCat",
|
author="Marakarka",
|
||||||
author_email="support@kerdoku.top",
|
author_email="support@kerdoku.top",
|
||||||
license="MIT",
|
license="MIT",
|
||||||
classifiers=[
|
classifiers=[
|
||||||
|
|
Loading…
Reference in a new issue