Asynchronous Python wrapper for BenBot API.
Project description
BenBot
Python wrapper for BenBot.
Installing:
Synchronous:
Windows: py -3 -m pip install BenBot
Linux/macOS: python3 -m pip install BenBot
Asynchronous:
Windows: py -3 -m pip install AsyncBenBot
Linux/macOS: python3 -m pip install AsyncBenBot
Examples:
import BenBotAsync
async def ben_search():
result = await BenBotAsync.get_cosmetic(
content,
params=BenBotAsync.Tags.NAME,
filter=[BenBotAsync.Filters.TYPE, 'Outfit']
)
print(result.id)
loop = asyncio.get_event_loop()
loop.run_until_complete(ben_search())
loop.close()
fortnitepy example:
import fortnitepy
import BenBotAsync
client = fortnitepy.Client(
email='example@email.com',
password='password123'
)
@client.event
async def event_friend_message(message):
args = message.content.split()
split = args[1:]
content = " ".join(split)
if args[0] == '!skin':
skin = result = await BenBotAsync.get_cosmetic(
content,
params=BenBotAsync.Tags.NAME,
filter=[BenBotAsync.Filters.TYPE, 'Outfit']
)
await client.user.party.me.set_outfit(asset=skin.id)
client.run()
This would output:
CID_029_Athena_Commando_F_Halloween
The list of functions is on the Wiki.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
BenBotAsync-1.1.8.tar.gz
(4.0 kB
view hashes)
Built Distribution
Close
Hashes for BenBotAsync-1.1.8-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 65bd2ea0df0aa91ff8206312a4f1ec137f5ef16ea7ba498b4a57f38c01f6dac8 |
|
MD5 | dd816b81bb332af27b525c41e8310512 |
|
BLAKE2b-256 | 76c8b376464685cb55a11f2bfab9de6162b3835c198db00ee580d222d0aa7afb |