A simple wrapper to send SMS through available gateways.
Project description
A simple wrapper to send SMS through available 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
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Filename, size | File type | Python version | Upload date | Hashes |
---|---|---|---|---|
Filename, size smsit-0.2.0.tar.gz (3.8 kB) | File type Source | Python version None | Upload date | Hashes View |