A collection of tools to work with SMS messages.
Project description
A collection of tools used to send SMS messages.
Tools
Message Profiling
Accepts a raw SMS message string and determines its most efficient encoding, then determines how many segments would be used to send it.
Largely based on this tool (code found here).
Example:
from sms_toolkit.messages.profiling import profile_message import json profile = profile_message("Sup chonus") print(json.dumps(profile, indent=4)) { "num_segments": 1, "segments": [ { "message": "Sup chonus", "total_segment_length": 10, "unicode_character_list": [ "S", "u", "p", " ", "c", "h", "o", "n", "u", "s" ], "byte_groups": [ [83], [117], [112], [32], [99], [104], [111], [110], [117], [115] ] } ], "message_length": 10 }
Testing
This library needs is tested against python 2 and 3. Both interpreters need to be available to tox
pyenv versions # shows all versions available pyenv local 2.7.* 3.7.*
Run tests:
tox .
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
sms-toolkit-1.0.6.tar.gz
(7.7 kB
view hashes)
Built Distribution
Close
Hashes for sms_toolkit-1.0.6-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2e66a7d7eca43db60503240e50eef2494d49eea25a46e52df3f70f3c4d77e363 |
|
MD5 | 666f3d434b5e6617c69e501da95b70cb |
|
BLAKE2b-256 | 12a59d608370bed71baaf338dee736298efbe29e6d3cd47c8751e27f04ac7c67 |