A simple wrapper to send SMS through available gateways.
Project description
A simple wrapper to send SMS through available gateways.
Gateways
Install
pip install smsit
Usage
Basic:
from smsit import SMS
from smsit.gateways import SMSMagicGateway
config = {
'api_key': '0000',
'sender_id': '1111'
}
sms = SMS(
text='Hi',
receiver='9893311223344'
)
SMSMagicGateway(config).send(sms)
With gateway manager:
from smsit import SMS, SMSGatewayManager
from smsit.gateways import SMSMagicGateway, NikSMSGateway
config = {
'smsmagic': {
'api_key': '0000',
'sender_id': '1111'
},
'niksms': {
'username': '0000',
'password': '0000',
'sender': '0000'
}
}
sms = SMS(
text='Hi',
receiver='9893311223344'
)
manager = SMSGatewayManager()
manager.register('smsmagic', SMSMagicGateway)
manager.register('niksms', NikSMSGateway)
manager.configure(config)
manager.send('smsmagic', sms)
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
smsit-1.2.0.tar.gz
(7.1 kB
view details)
File details
Details for the file smsit-1.2.0.tar.gz.
File metadata
- Download URL: smsit-1.2.0.tar.gz
- Upload date:
- Size: 7.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.11.2
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f05cd19b831b52912256f7d94440edf6e456eab35203f946d222633d531315cf
|
|
| MD5 |
2a3ef7eacca4e20cacabaf9b250ec081
|
|
| BLAKE2b-256 |
37c38ce4b2f5e17c8104f3f6c2b81fbf479ac9c1ad84794b3e23811f2fc36370
|