Last active
October 2, 2019 17:47
-
-
Save zohairshaikh/04c58f1a63de6db6a900522b138ec3ac to your computer and use it in GitHub Desktop.
Example Usage of Fusion Wrapper
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
##### SMS Example ##### | |
fw = FusionWrapper() | |
payload = {'contact': 'XXXXXXXXXX', 'message': 'Hello World!', 'countryCode': '91'} | |
job_id = fw.sms(FusionWrapper.SMS.OTP, payload=payload) | |
) | |
##### Email Example ##### | |
payload = { | |
'to': ['xxxx@xxx.com'], | |
'message': 'Hello World!', | |
'subject': 'Email subject', | |
'cc': [], | |
'bcc': [] | |
} | |
job_id = fw.email(FusionWrapper.EMAIL.WELCOME, payload=payload) | |
##### Webhook Example ##### | |
payload = { | |
'url': 'https://livehealth.in/', | |
'data': {'param': 1}, | |
'timeout': 20 # This is an optional param | |
} | |
job_id = fw.webhook(FusionWrapper.WEBHOOK.GET, payload=payload) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment