async client library for the Emoji Connoisseur API
Project description
aioec
=====
An aiohttp-based client for the `Emoji Connoisseur API <https://emoji-connoisseur.python-for.life>`_.
Usage
----
.. code-block:: python
import aioec
client = aioec.Client(token='your token here')
# if no token is provided, only anonymous endpoints will be available
# this step isn't necessary but makes sure that your token is correct
await client.login()
# in a coroutine...
emote = await client.emote('Think')
emote.name # Think
await emote.edit(name='Think_', description='a real happy thinker')
# remove the description:
await emote.edit(description=None)
for gamewisp_emote in await client.search('GW'):
await gamewisp_emote.delete()
all_emotes = await client.emotes()
popular_emotes = await client.popular()
await client.close()
# it's also a context manager:
async with aioec.Client(token=my_token) as client:
await client.delete('Think_')
# this will automatically close the client
License
-------
MIT/X11
Copyright © 2018 Benjamin Mintz <bmintz@protonmail.com>
=====
An aiohttp-based client for the `Emoji Connoisseur API <https://emoji-connoisseur.python-for.life>`_.
Usage
----
.. code-block:: python
import aioec
client = aioec.Client(token='your token here')
# if no token is provided, only anonymous endpoints will be available
# this step isn't necessary but makes sure that your token is correct
await client.login()
# in a coroutine...
emote = await client.emote('Think')
emote.name # Think
await emote.edit(name='Think_', description='a real happy thinker')
# remove the description:
await emote.edit(description=None)
for gamewisp_emote in await client.search('GW'):
await gamewisp_emote.delete()
all_emotes = await client.emotes()
popular_emotes = await client.popular()
await client.close()
# it's also a context manager:
async with aioec.Client(token=my_token) as client:
await client.delete('Think_')
# this will automatically close the client
License
-------
MIT/X11
Copyright © 2018 Benjamin Mintz <bmintz@protonmail.com>
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
aioec-0.0.4.tar.gz
(4.7 kB
view details)
File details
Details for the file aioec-0.0.4.tar.gz
.
File metadata
- Download URL: aioec-0.0.4.tar.gz
- Upload date:
- Size: 4.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: Python-urllib/3.6
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 886f72a2f867d066f9ee3a22f53f0a5ec9cee8ac78d13610ad092250bae52da2 |
|
MD5 | d41dc9b143592ee8fa211b495a52776f |
|
BLAKE2b-256 | df887d8c9a74db915e7dd9d121af37fbc529501e01be18234c0939257b7372ac |