https://github.com/masaar/limp_gateway_twilio
LIMP Gateway for Twilio
https://github.com/masaar/limp_gateway_twilio
gateway limp twilio twilio-sms
Last synced: 3 months ago
JSON representation
LIMP Gateway for Twilio
- Host: GitHub
- URL: https://github.com/masaar/limp_gateway_twilio
- Owner: masaar
- License: lgpl-3.0
- Created: 2019-11-02T16:57:26.000Z (over 6 years ago)
- Default Branch: master
- Last Pushed: 2019-11-26T13:18:51.000Z (over 6 years ago)
- Last Synced: 2026-01-03T01:07:02.060Z (7 months ago)
- Topics: gateway, limp, twilio, twilio-sms
- Language: Python
- Size: 4.88 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# LIMP Gateway for Twilio
This repo is a [LIMP](https://github.com/masaar/limp) [Package](https://github.com/masaar/limp-docs/blob/APIv5.8/api/package.md) for the sole purpose of integrating [Twilio SMS](https://www.twilio.com/sms) into LIMP apps using [LIMP Gateways](https://github.com/masaar/limp-docs/blob/APIv5.8/api/gateways.md).
## How-to
1. Clone this repo into your LIMP `modules` folder.
2. Add following to your app package config:
```python
'vars':{
'twilio':{
'sid':'YOUR_TWILIO_SID_HERE',
'token':'YOUR_TWILIO_TOKEN_HERE',
'no':'YOUR_TWILIO_PHONE_HERE'
}
}
```
3. Twilio gateway requires following args:
1. `phone`: Target phone number using international format with prefixed `+`. Type `str`.
2. `content`: Message body. Type `str`.
4. Twilio gateway accepts optional arg, namely `twilio_auth`, replicating `twilio` value in `vars Config Attr` for dynamic Twilio API credentials.
5. Use Twilio gateway using LIMP Gateway Controller:
```python
from gateway import Gateway
Gateway.send(gateway='twilio', phone=phone, content=content)
```