Skip to content

masaar/limp_gateway_twilio

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

LIMP Gateway for Twilio

This repo is a LIMP Package for the sole purpose of integrating Twilio SMS into LIMP apps using LIMP Gateways.

How-to

  1. Clone this repo into your LIMP modules folder.
  2. Add following to your app package config:
'vars':{
	'twilio':{
		'sid':'YOUR_TWILIO_SID_HERE',
		'token':'YOUR_TWILIO_TOKEN_HERE',
		'no':'YOUR_TWILIO_PHONE_HERE'
	}
}
  1. Twilio gateway requires following args:
    1. phone: Target phone number using international format with prefixed +. Type str.
    2. content: Message body. Type str.
  2. Twilio gateway accepts optional arg, namely twilio_auth, replicating twilio value in vars Config Attr for dynamic Twilio API credentials.
  3. Use Twilio gateway using LIMP Gateway Controller:
from gateway import Gateway

Gateway.send(gateway='twilio', phone=phone, content=content)

Releases

No releases published

Packages

No packages published

Languages