sveve
A (limited) Python wrapper for Sveve's API
Based on API documentation.
I am in no way affiliated with Sveve and accept no liability for damages caused as a result of using this code.
Usage
The client returns a pydantic class that matches the data structure in the API documentation unless a fatal error occurs, in which case it raises a SveveError with a descriptive error message.
Initialising client
from sveve.client import SveveClient, SveveError
client = SveveClient(user="usr", password="123", default_sender="funbit")
Sending an SMS
try:
# Sending to one recipient using client's default_sender
client.send_sms(to="12345678", msg="Hello world!")
except SveveError:
print("Something went wrong...")
# Alternatively with multiple recipients
recipients = ["12345001", "12345002", "12345003"]
client.send_sms(to=recipients, msg="Hello world!")
# Or using a custom sender name
client.send_sms(to="12345678", msg="Hello world!", sender="Your Name")
Checking remaining balance
try:
balance = client.remaining_sms()
except SveveError:
print("Something went wrong...")
Metadata
Release files for Sveve 1.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| Sveve-1.1.0.tar.gz | 5.8 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| Sveve-1.1.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 10.5 kB
Release files / Sveve-1.1.0.tar.gz
| Download URL | Sveve-1.1.0.tar.gz |
|---|---|
| Size | 5.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
0ff2ffcd19ba75166cda6961cad319971638dfe92c9afab7a8ee9a362f2072dd
|
|
BLAKE2b-256 checksum How to use checksums |
3922e0c3b3e519206e91c7df9656f58907dfdca7430d4bd6c55b55e01f160954
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.11.7
|
Release files / Sveve-1.1.0-py3-none-any.whl
| Download URL | Sveve-1.1.0-py3-none-any.whl |
|---|---|
| Size | 4.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
c127914539211dc32e4afd488c0cfb400f0f71eaf1ab0769cff263a49566d9df
|
|
BLAKE2b-256 checksum How to use checksums |
ef3e4b2d191536f511f48b3c49d89da476ed4fd65ddcd045d3670a8738133452
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.2 CPython/3.11.7
|