POST v1/api/Payment/initiatePaystackPayment
Request Information
URI Parameters
None.
Body Parameters
paystackPaymentRequestName | Description | Type | Additional information |
---|---|---|---|
amount | decimal number |
None. |
|
emailAddress | string |
None. |
|
reference | string |
None. |
|
channels | Collection of string |
None. |
|
useCallBack | boolean |
None. |
Request Formats
application/json, text/json
Sample:
{ "amount": 1.0, "emailAddress": "sample string 2", "reference": "sample string 3", "channels": [ "sample string 1", "sample string 2" ], "useCallBack": true }
application/xml, text/xml
Sample:
<paystackPaymentRequest xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/enrrolleeApp.Models.api_Main.paystackPayment"> <amount>1</amount> <channels xmlns:d2p1="http://schemas.microsoft.com/2003/10/Serialization/Arrays"> <d2p1:string>sample string 1</d2p1:string> <d2p1:string>sample string 2</d2p1:string> </channels> <emailAddress>sample string 2</emailAddress> <reference>sample string 3</reference> <useCallBack>true</useCallBack> </paystackPaymentRequest>
application/x-www-form-urlencoded
Sample:
Sample not available.
text/html
Sample:
{"amount":1.0,"emailAddress":"sample string 2","reference":"sample string 3","channels":["sample string 1","sample string 2"],"useCallBack":true}
Response Information
Resource Description
paystackPaymentResultName | Description | Type | Additional information |
---|---|---|---|
success | boolean |
None. |
|
errorMsg | string |
None. |
|
paymentUrl | string |
None. |
|
refernce | string |
None. |
|
access_code | string |
None. |
Response Formats
application/json, text/json
Sample:
{ "success": true, "errorMsg": "sample string 2", "paymentUrl": "sample string 3", "refernce": "sample string 4", "access_code": "sample string 5" }
application/xml, text/xml
Sample:
<paystackPaymentResult xmlns:i="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://schemas.datacontract.org/2004/07/enrrolleeApp.Models.api_Main.paystackPayment"> <access_code>sample string 5</access_code> <errorMsg>sample string 2</errorMsg> <paymentUrl>sample string 3</paymentUrl> <refernce>sample string 4</refernce> <success>true</success> </paystackPaymentResult>
text/html
Sample:
{"success":true,"errorMsg":"sample string 2","paymentUrl":"sample string 3","refernce":"sample string 4","access_code":"sample string 5"}