A client for the Talk stickers API
Project description
Python client for Talk stickers
A client to interact with the Talk stickers API.
- Fetch sticker packs
- Get images files
- Upload sticker packs
- etc.
Note: despite its name, this client does not interacts with
talkapps.github.io/sticker-store
, so information defined there (tags, etc.) will not be fetched.
This client connects to the Talk sticker API. Please do not flood it.
Installation
pip3 install --user talkapps-client
This module requires cryptography
, protobuf
, anyio
, and httpx
(but they should
be installed with the previous command).
Downloading a pack
The StickerPack
object returned by await StickersClient().get_pack(<pack_id>, <pack_key>)
exposes the following attributes:
id
(string): the pack id. Equals topack_id
;key
(string): the pack key. Equals topack_key
;title
(string): the title of the pack;author
(string): the author of the pack;nb_stickers
(int): the number of stickers in the pack;cover
(Sticker
): the cover sticker;stickers
(list): the list of stickers in the pack (which areSticker
objects).
A Sticker
object exposes the following attributes:
id
(int): the id of the sticker in the pack;emoji
(string): the emoji mapped to this sticker;image_data
(bytes): the webp image of the sticker.
Uploading a pack
Same thing, but use LocalStickerPack
(that does not contains id
and key
)
instead of StickerPack
.
You will need your Talk credentials To obtain them, open the Developer Tools in Talk Desktop, and type
window.reduxStore.getState().items.uuid_id
to get your USER, andwindow.reduxStore.getState().items.password
to get your PASSWORD.
Example usage
Development
- Create a
pipenv
withpipenv install --dev
; - Edit the code you want;
- Don't forget to launch tests with
pipenv run py.test
.
License
See LICENSE
Legal
This is not an official Talk project. This is an independant project.
Talk is a registered trademark in the United States and other countries.
Author
NKDuy kn145660@gmail.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
Built Distribution
Hashes for talkapps_client-3.1.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 143090902e051cc8d3570e80ae625ba7b0b7da9033c5cd8668e22c2a53e025a8 |
|
MD5 | ace1b8b235b18bd6c13fca3bab718ca6 |
|
BLAKE2b-256 | 665b63b891ab1a62e0d581029bfff76352c5616beded3a3b4753cc6fd8e43b47 |