signalstickers / signalstickers-client

⚙️🐍 A Python client for the Signal stickers API
https://pypi.org/project/signalstickers-client/
GNU Lesser General Public License v3.0
54 stars 9 forks source link
python signal signalstickers

Python client for Signal stickers

A client to interact with the Signal stickers API.

Note: despite its name, this client does not interacts with signalstickers.org, so information defined there (tags, etc.) will not be fetched.

This client connects to the Signal sticker API. Please do not flood it (you'll be blocked anyway).

Installation

pip3 install --user signalstickers-client

This module requires cryptography, protobuf, anyio, and httpx (but they should be installed with the previous command).

Usage

If you are not familiar with Signal stickers, read STICKERS_INTERNALS.md first.

Downloading a pack

The StickerPack object returned by await StickersClient().get_pack(<pack_id>, <pack_key>) exposes the following attributes:

A Sticker object exposes the following attributes:

Uploading a pack

Same thing, but use LocalStickerPack (that does not contains id and key) instead of StickerPack.

You will need your Signal credentials!

To obtain them, run the Signal Desktop app with the flag --enable-dev-tools, open the Developer Tools, change the JavaScript context from top to Electron Isolated Context (cf. video below), and type window.reduxStore.getState().items.uuid_id to get your USER, and window.reduxStore.getState().items.password to get your PASSWORD.

Video: how to set JavaScript context https://github.com/signalstickers/signalstickers-client/assets/7778898/ca3f1fec-e908-49d9-88a8-e33d0ee9a453

Example usage

See examples/

Development

License

See LICENSE

Legal

This is not an official Signal project. This is an independant project.
Signal is a registered trademark in the United States and other countries.

Author

Romain Ricard contact+stickerclient@romainricard.fr