Overview
With this service, the calling apps can instruct a provider via OnePipe to send an SMS to a specified phone number or customer_ref. This is a standard send SMS (or bulk SMS) service. The slight difference here is that in the event that a provider needs authorization details of the account to debit for the value of the SMS (bank account, wallet, etc) this can be supplied to the provider.
Info |
---|
Before you proceed: Please read this. |
...
Code Block |
---|
|
{
"request_ref":"{{request_ref}}",
"request_type":"send_sms",
"auth": {
"type": "bank.account | card | wallet | msisdn",
"secure": "{{encrypted(bank account number | card details | wallet | msisdn)}}", //if payment should be collected realtime, it would be charged here
"auth_provider": "Beeceptor",
"route_mode": null
},
"transaction": {
"mock_mode": "live",
"transaction_ref": "{{transaction_ref}}",
"transaction_desc": "A random transaction",
"transaction_ref_parent": null,
"amount": 0,
"customer":{
"customer_ref": "{{customer_id}}",//the recipient of the message, in 234 format
"firstname": "Uju",
"surname": "Usmanu",
"email": "ujuusmanu@gmail.com",
"mobile_no": "234802343132"
},
"meta":{
"a_key":"a_meta_value_1",
"another_key":"a_meta_value_2"
},
"details": {
"message_body": "Welcome to Lagos",
"message_title": "A title",
"sender_id": "AnID" //the sender ID on the SMS if supported by the provider
}
}
} |
Response
Code Block |
---|
|
{
"status": "Successful",
"message": "Transaction processed successfully",
"data": {
"provider_response_code": "00",
"provider": "Beeceptor",
"errors": null,
"error": null,
"provider_response": {
"delivery_status": "delivered | failed | pending",
"referencecost": "506176447170071200",//in kobo
"delivery_statusreference": "delivered000022200225154318222333334432",
"costmeta":{
"1200",//in kobo"field_key":"field_value",
"field_key":"field_value"
}
}
}
} |
Breakdown of the details object
...