- Url: https://mcpn.us/limeApi?ev=createPoll
- Parameters (bold are mandatory):
Parameter Name (Case Sensitive)
|
Value |
Description |
Default Value |
user |
Advertiser username |
The advertiser’s username that matches the api_id |
None |
api_id |
Advertiser Api Id |
The advertiser’s api_id that matches the username |
Generated from edit profile |
poll_question |
Poll question text |
The question that will be sent |
|
option1 |
Option Text |
Text for option no' 1 |
|
option2 |
Option Text |
Text for option no' 2 |
|
option3 |
Option Text |
Text for option no' 3 |
|
option4 |
Option Text |
Text for option no' 4 |
|
option5 |
Option Text |
Text for option no' 5 |
|
coupon_id |
Number |
Coupon id that will be sent when user response to the poll |
|
reply_message |
Text |
A message that will be sent when user response to the poll |
|
response_url |
Url |
Url that will be called when a user response to the poll. See description below |
|
Return Code
- If the API succeeds then it will return with status code 200 with the following message: “Poll ID:<New Poll ID>" i.e. Poll ID:252
- If an error occurs or there is an invalid parameter then it returns with status code 400 or 500 with an error message in the response.
Example: https://mcpn.us/limeApi?ev=createPoll&user=adv@my.com&api_id=q5HI76WrLV83822C&poll_question=Who will win the game&option1=LA Lakers&option2=Miami Heat&coupon_id=1234&reply_message=Thank you for your response&response_url=http://yourcompany.com/api
- When a mobile response to the poll and a response url is supplied, then the response will be sent to your response url with http GET method with the following parameters:
Parameter Name
|
Value |
Description |
poll_id
|
Poll Id |
The poll id that got the response |
mobile_number
|
Mobile number |
The mobile number that sent the response |
text
|
Mobile response text can be 1-5 |
The text that the mobile number response to the poll |
option
|
Option Text |
Text at the poll that match to the response |
Example:
When the user got a text with the following question:
"Who will win the game"
Reply:
"1" for New York Knicks
"2" for Miami Heat
If the user replies 1, the response url will be:
http://yourcompany.com/api?poll_id=252&mobile_number=155525555555&text=1&option=LA Lakers
Comments
0 comments
Article is closed for comments.