Rave inline
This pages shows how to implement Rave's Inline JS
Rave Inline Sample
You can embed rave on your page using the getpaidSetup
function. The function returns a response inside the callback
, and you can pick your txRef and send to your server to perform a verification before giving value for the transaction.
<form>
<script src="https://api.ravepay.co/flwv3-pug/getpaidx/api/flwpbf-inline.js"></script>
<button type="button" onClick="payWithRave()">Pay Now</button>
</form>
<script>
const API_publicKey = "<ADD YOUR PUBLIC KEY HERE>";
function payWithRave() {
var x = getpaidSetup({
PBFPubKey: API_publicKey,
customer_email: "[email protected]",
amount: 2000,
customer_phone: "234099940409",
currency: "NGN",
txref: "rave-123456",
meta: [{
metaname: "flightID",
metavalue: "AP1234"
}],
onclose: function() {},
callback: function(response) {
var txref = response.data.txRef; // collect txRef returned and pass to a server page to complete status check.
console.log("This is the response returned after a charge", response);
if (
response.data.chargeResponseCode == "00" ||
response.data.chargeResponseCode == "0"
) {
// redirect to a success page
} else {
// redirect to a failure page.
}
x.close(); // use this to close the modal immediately after payment.
}
});
}
</script>
<form>
<script src="https://api.ravepay.co/flwv3-pug/getpaidx/api/flwpbf-inline.js"></script>
<button type="button" onClick="payWithRave()">Pay Now</button>
</form>
<script>
const API_publicKey = "<ADD YOUR PUBLIC KEY HERE>";
function payWithRave() {
var x = getpaidSetup({
PBFPubKey: API_publicKey,
customer_email: "[email protected]",
amount: 2000,
customer_phone: "234099940409",
currency: "NGN",
txref: "rave-123456",
payment_plan: 245,
meta: [{
metaname: "flightID",
metavalue: "AP1234"
}],
onclose: function() {},
callback: function(response) {
var txref = response.data.txRef; // collect txRef returned and pass to a server page to complete status check.
console.log("This is the response returned after a charge", response);
if (
response.data.chargeResponseCode == "00" ||
response.data.chargeResponseCode == "0"
) {
// redirect to a success page
} else {
// redirect to a failure page.
}
x.close(); // use this to close the modal immediately after payment.
}
});
}
</script>
<form>
<script src="https://api.ravepay.co/flwv3-pug/getpaidx/api/flwpbf-inline.js"></script>
<button type="button" onClick="payWithRave()">Pay Now</button>
</form>
<script>
const API_publicKey = "<ADD YOUR PUBLIC KEY HERE>";
function payWithRave() {
var x = getpaidSetup({
PBFPubKey: API_publicKey,
customer_email: "[email protected]",
amount: 2000,
currency: "NGN",
txref: "rave-123456",
subaccounts: [
{
id: "RS_D87A9EE339AE28BFA2AE86041C6DE70E" // This assumes you have setup your commission on the dashboard.
}
],
meta: [{
metaname: "flightID",
metavalue: "AP1234"
}],
onclose: function() {},
callback: function(response) {
var txref = response.data.txRef; // collect flwRef returned and pass to a server page to complete status check.
console.log("This is the response returned after a charge", response);
if (
response.data.chargeResponseCode == "00" ||
response.data.chargeResponseCode == "0"
) {
// redirect to a success page
} else {
// redirect to a failure page.
}
x.close(); // use this to close the modal immediately after payment.
}
});
}
</script>
When the user enters their payment details, Rave would do the following:
-
Validate the transaction
-
Collect the funds from the customer's account.
-
And pass a response object (containing a response code as
chargeResponseCode
, status and a unique payment reference asflwRef
).
The chargeResponseCode has two important common response codes 00
|| 0
and 02
the former means the transaction came back with a successful response, the latter means the transaction is pending validation. If after performing verification on your server and you get a responsecode
that isn't 00
that means the transaction was not successful.
Rave Inline Quick Setup Method [Embed Code]
Alternatively you can always use a quick setup method to embed your pay button on your site. Using the embed code you can paste it on your page and a button is immediately generated to accept payments.
Quick Setup Validation
Using a quick setup we don't return a response to you, that would mean you would need to validate via other means, you can pass a
redirect url
so we redirect to the url after payment and append the response asquery parameters
to the redirect url.
Rave Inline Quick Setup Sample
<form>
<a class="flwpug_getpaid"
data-PBFPubKey="<ADD YOUR PUBLIC KEY HERE>"
data-txref="rave-123456"
data-amount="2000"
data-customer_email="[email protected]"
data-meta-flightID="APX0093GHK"
data-currency="NGN"
data-pay_button_text="Pay Now"
data-country="NG"
data-redirect_url="https://your-website.com/urlredirect"></a>
<script type="text/javascript" src="https://api.ravepay.co/flwv3-pug/getpaidx/api/flwpbf-inline.js"></script>
</form>
Rave Inline Sample callback response
{
"status": "success",
"message": "Charge Complete",
"data": {
"data": {
"responsecode": "00",
"responsemessage": "successful"
},
"tx": {
"id": 10604,
"txRef": "12373",
"orderRef": "URF_1501152088995_7069035",
"flwRef": "FLW-MOCK-f0ef7b5fc0e9a2e00e02169aff4572de",
"redirectUrl": "http://127.0.0",
"device_fingerprint": "69e6b7f0b72037aa8428b70fbe03986c",
"settlement_token": null,
"cycle": "recurring-daily",
"amount": 290,
"charged_amount": 290,
"appfee": 0,
"merchantfee": 0,
"merchantbearsfee": 0,
"chargeResponseCode": "00",
"chargeResponseMessage": "Success-Pending-otp-validation",
"authModelUsed": "PIN",
"currency": "NGN",
"IP": "197.242.109.215",
"narration": "FLW-PBF CARD Transaction ",
"status": "successful",
"vbvrespmessage": "successful",
"authurl": "http://flw-pms-dev.eu-west-1.elasticbeanstalk.com/mockvbvpage?ref=FLW-MOCK-f0ef7b5fc0e9a2e00e02169aff4572de&code=00&message=Approved. Successful",
"vbvrespcode": "00",
"acctvalrespmsg": null,
"acctvalrespcode": null,
"paymentType": "card",
"paymentId": "2",
"fraud_status": "ok",
"charge_type": "normal",
"is_live": 0,
"createdAt": "2017-07-27T10:41:28.000Z",
"updatedAt": "2017-07-27T10:41:42.000Z",
"deletedAt": null,
"customerId": 517,
"AccountId": 134,
"customer": {
"id": 517,
"phone": null,
"fullName": "teni adebola",
"customertoken": null,
"email": "[email protected]",
"createdAt": "2017-06-02T10:33:13.000Z",
"updatedAt": "2017-06-02T10:33:13.000Z",
"deletedAt": null,
"AccountId": 134
},
"chargeToken": {
"user_token": "82bfc",
"embed_token": "flw-t0-2a2646448375873c9060eeffe48bdedb-m03k"
}
}
}
}
{
"status": "success",
"message": "Charge Complete",
"data": {
"data": {
"responsetoken": null,
"responsecode": "RR",
"responsemessage": "Sorry, that OTP is invalid. Please try again",
"transactionreference": "RAVE/FLW34130692",
"otptransactionidentifier": null,
"responsehtml": null,
"redirecturl": null,
"avsresponsecode": null,
"avsresponsemessage": null
},
"tx": {
"id": 127367,
"txRef": "rave-checkout-1501076030",
"orderRef": "URF_1501076057894_416335",
"flwRef": "RAVE/FLW34130692",
"redirectUrl": "http://127.0.0",
"device_fingerprint": "69e6b7f0b72037aa8428b70fbe03986c",
"settlement_token": null,
"cycle": "one-time",
"amount": 20,
"charged_amount": 20.25,
"appfee": 0.25,
"merchantfee": 0,
"merchantbearsfee": 0,
"chargeResponseCode": "02",
"chargeResponseMessage": "Enter the OTP code sent to your phone to complete the transaction",
"authModelUsed": "PIN",
"currency": "NGN",
"IP": "197.242.109.215",
"narration": "FLW-PBF CARD Transaction ",
"status": "failed",
"vbvrespmessage": "Sorry, that OTP is invalid. Please try again",
"authurl": "N/A",
"vbvrespcode": "RR",
"acctvalrespmsg": null,
"acctvalrespcode": null,
"paymentType": "card",
"paymentId": "2",
"fraud_status": "ok",
"charge_type": "normal",
"is_live": 0,
"createdAt": "2017-07-26T13:34:17.000Z",
"updatedAt": "2017-07-26T13:34:59.000Z",
"deletedAt": null,
"customerId": 34,
"AccountId": 48,
"customer": {
"id": 34,
"phone": null,
"fullName": "Anonymous customer",
"customertoken": null,
"email": "[email protected]",
"createdAt": "2017-02-08T17:35:44.000Z",
"updatedAt": "2017-02-08T17:35:44.000Z",
"deletedAt": null,
"AccountId": 48
}
}
}
}
{
"status": "error",
"message": "Fraudulent. Transaction",
"data": {
"code": "FLW_ERR",
"message": "Fraudulent. Transaction",
"tx": {
"id": 34347,
"txRef": "rave-checkout-1505323730",
"orderRef": "URF_1505323795398_2349835",
"flwRef": "FLW-MOCK-ed8b451ad9e54f756f26fb68cfcac352",
"redirectUrl": "http://127.0.0",
"device_fingerprint": "69e6b7f0b72037aa8428b70fbe03986c",
"settlement_token": null,
"cycle": "one-time",
"amount": 3000,
"charged_amount": 3000,
"appfee": 0,
"merchantfee": 0,
"merchantbearsfee": 0,
"chargeResponseCode": "MRA",
"chargeResponseMessage": "Fraudulent. Transaction",
"authModelUsed": "PIN",
"currency": "NGN",
"IP": "41.78.174.160",
"narration": "FLW-PBF CARD Transaction ",
"status": "failed",
"vbvrespmessage": "Fraudulent. Transaction",
"authurl": "http://flw-pms-dev.eu-west-1.elasticbeanstalk.com/mockvbvpage?ref=FLW-MOCK-ed8b451ad9e54f756f26fb68cfcac352&code=MRA&message=Fraudulent. Transaction&receiptno=RN1505323795404",
"vbvrespcode": "MRA",
"acctvalrespmsg": null,
"acctvalrespcode": null,
"paymentType": "card",
"paymentId": "4",
"fraud_status": "ok",
"charge_type": "normal",
"is_live": 0,
"createdAt": "2017-09-13T17:29:55.000Z",
"updatedAt": "2017-09-13T17:29:56.000Z",
"deletedAt": null,
"customerId": 3670,
"AccountId": 134,
"customer": {
"id": 3670,
"phone": null,
"fullName": "Anonymous customer",
"customertoken": null,
"email": "[email protected]",
"createdAt": "2017-09-13T17:29:55.000Z",
"updatedAt": "2017-09-13T17:29:55.000Z",
"deletedAt": null,
"AccountId": 134
}
}
}
}
{
"status": "success",
"message": "Charge Complete",
"data": {
"data": {
"responsecode": "00",
"responsemessage": "successful"
},
"tx": {
"id": 9795,
"txRef": "12373",
"orderRef": "URF_1501076378098_6170335",
"flwRef": "FLW-MOCK-81b4a857591eecab860833496697e81a",
"redirectUrl": "http://127.0.0",
"device_fingerprint": "69e6b7f0b72037aa8428b70fbe03986c",
"settlement_token": null,
"cycle": "recurring-daily",
"amount": 290,
"charged_amount": 290,
"appfee": 0,
"merchantfee": 0,
"merchantbearsfee": 0,
"chargeResponseCode": "00",
"chargeResponseMessage": "Success-Pending-otp-validation",
"authModelUsed": "PIN",
"currency": "NGN",
"IP": "197.242.109.215",
"narration": "FLW-PBF CARD Transaction ",
"status": "successful",
"vbvrespmessage": "successful",
"authurl": "http://flw-pms-dev.eu-west-1.elasticbeanstalk.com/mockvbvpage?ref=FLW-MOCK-81b4a857591eecab860833496697e81a&code=00&message=Approved. Successful",
"vbvrespcode": "00",
"acctvalrespmsg": null,
"acctvalrespcode": null,
"paymentType": "card",
"paymentId": "2",
"fraud_status": "ok",
"charge_type": "normal",
"is_live": 0,
"createdAt": "2017-07-26T13:39:38.000Z",
"updatedAt": "2017-07-26T13:39:45.000Z",
"deletedAt": null,
"customerId": 517,
"AccountId": 134,
"customer": {
"id": 517,
"phone": null,
"fullName": "teni adebola",
"customertoken": null,
"email": "[email protected]",
"createdAt": "2017-06-02T10:33:13.000Z",
"updatedAt": "2017-06-02T10:33:13.000Z",
"deletedAt": null,
"AccountId": 134
},
"chargeToken": {
"user_token": "82bfc",
"embed_token": "flw-t0-2a2646448375873c9060eeffe48bdedb-m03k"
}
}
}
}
{
"status": "error",
"message": "NOT_ENROLLED_NO_ERROR_DETAILS",
"data": {
"code": "FLW_ERR",
"message": "NOT_ENROLLED_NO_ERROR_DETAILS",
"tx": {
"id": 34355,
"txRef": "rave-checkout-1505327540",
"orderRef": "URF_1505327555322_5655035",
"flwRef": "URF_1505327555322_5655035",
"redirectUrl": "http://127.0.0",
"device_fingerprint": "69e6b7f0b72037aa8428b70fbe03986c",
"settlement_token": null,
"cycle": "one-time",
"amount": 9000,
"charged_amount": 9000,
"appfee": 0,
"merchantfee": 0,
"merchantbearsfee": 0,
"chargeResponseCode": "RR",
"chargeResponseMessage": "NOT_ENROLLED_NO_ERROR_DETAILS",
"authModelUsed": "VBVSECURECODE",
"currency": "NGN",
"IP": "41.78.174.160",
"narration": "FLW-PBF CARD Transaction ",
"status": "failed",
"vbvrespmessage": "NOT_ENROLLED_NO_ERROR_DETAILS",
"authurl": "N/A",
"vbvrespcode": "RR",
"acctvalrespmsg": null,
"acctvalrespcode": null,
"paymentType": "card",
"paymentId": "172",
"fraud_status": "ok",
"charge_type": "normal",
"is_live": 0,
"createdAt": "2017-09-13T18:32:35.000Z",
"updatedAt": "2017-09-13T18:32:41.000Z",
"deletedAt": null,
"customerId": 3678,
"AccountId": 134,
"customer": {
"id": 3678,
"phone": null,
"fullName": "Anonymous customer",
"customertoken": null,
"email": "[email protected]",
"createdAt": "2017-09-13T18:32:35.000Z",
"updatedAt": "2017-09-13T18:32:35.000Z",
"deletedAt": null,
"AccountId": 134
}
}
}
}
{
"status": "error",
"message": "Insufficient Funds",
"data": {
"code": "FLW_ERR",
"message": "Insufficient Funds",
"tx": {
"id": 34349,
"txRef": "rave-checkout-1505324017",
"orderRef": "URF_1505324080498_3936935",
"flwRef": "FLW-MOCK-c7d4527561388d6c9e568edc64c8a214",
"redirectUrl": "http://127.0.0",
"device_fingerprint": "69e6b7f0b72037aa8428b70fbe03986c",
"settlement_token": null,
"cycle": "one-time",
"amount": 4500,
"charged_amount": 4500,
"appfee": 0,
"merchantfee": 0,
"merchantbearsfee": 0,
"chargeResponseCode": "ISF",
"chargeResponseMessage": "Insufficient Funds",
"authModelUsed": "PIN",
"currency": "NGN",
"IP": "41.78.174.160",
"narration": "FLW-PBF CARD Transaction ",
"status": "failed",
"vbvrespmessage": "Insufficient Funds",
"authurl": "http://flw-pms-dev.eu-west-1.elasticbeanstalk.com/mockvbvpage?ref=FLW-MOCK-c7d4527561388d6c9e568edc64c8a214&code=MRL&message=Insufficient Funds&receiptno=RN1505324080503",
"vbvrespcode": "ISF",
"acctvalrespmsg": null,
"acctvalrespcode": null,
"paymentType": "card",
"paymentId": "3",
"fraud_status": "ok",
"charge_type": "normal",
"is_live": 0,
"createdAt": "2017-09-13T17:34:40.000Z",
"updatedAt": "2017-09-13T17:34:42.000Z",
"deletedAt": null,
"customerId": 3672,
"AccountId": 134,
"customer": {
"id": 3672,
"phone": null,
"fullName": "Anonymous customer",
"customertoken": null,
"email": "[email protected]",
"createdAt": "2017-09-13T17:34:40.000Z",
"updatedAt": "2017-09-13T17:34:40.000Z",
"deletedAt": null,
"AccountId": 134
}
}
}
}
{
"status": "error",
"message": "pending-otp-validation",
"data": {
"code": "FLW_ERR",
"message": "pending-otp-validation",
"tx": {
"id": 34348,
"txRef": "rave-checkout-1505323938",
"orderRef": "URF_1505323956032_3583235",
"flwRef": "FLW-MOCK-bff85eabbd68a6f5d58772e75138ca73",
"redirectUrl": "http://127.0.0",
"device_fingerprint": "69e6b7f0b72037aa8428b70fbe03986c",
"settlement_token": null,
"cycle": "one-time",
"amount": 6000,
"charged_amount": 6000,
"appfee": 0,
"merchantfee": 0,
"merchantbearsfee": 0,
"chargeResponseCode": "DBN",
"chargeResponseMessage": "pending-otp-validation",
"authModelUsed": "PIN",
"currency": "NGN",
"IP": "41.78.174.160",
"narration": "FLW-PBF CARD Transaction ",
"status": "failed",
"vbvrespmessage": "pending-otp-validation",
"authurl": "http://flw-pms-dev.eu-west-1.elasticbeanstalk.com/mockvbvpage?ref=FLW-MOCK-bff85eabbd68a6f5d58772e75138ca73&code=MRD&message=Declined: Bank-Do-not-honor&receiptno=RN1505323956072",
"vbvrespcode": "DBN",
"acctvalrespmsg": null,
"acctvalrespcode": null,
"paymentType": "card",
"paymentId": "11",
"fraud_status": "ok",
"charge_type": "normal",
"is_live": 0,
"createdAt": "2017-09-13T17:32:36.000Z",
"updatedAt": "2017-09-13T17:32:37.000Z",
"deletedAt": null,
"customerId": 3671,
"AccountId": 134,
"customer": {
"id": 3671,
"phone": null,
"fullName": "Anonymous customer",
"customertoken": null,
"email": "[email protected]",
"createdAt": "2017-09-13T17:32:36.000Z",
"updatedAt": "2017-09-13T17:32:36.000Z",
"deletedAt": null,
"AccountId": 134
}
}
}
}
https://rave-webhook.herokuapp.com/newregistration?resp=%7B%22name%22%3A%22opop%22%2C%22data%22%3A%7B%22status%22%3A%22success%22%2C%22message%22%3A%22V-COMP%22%2C%22data%22%3A%7B%22id%22%3A301782%2C%22txRef%22%3A%22rave-checkout-1541080175862%22%2C%22orderRef%22%3A%22URF_1541080202653_2603435%22%2C%22flwRef%22%3A%22FLWACHMOCK-1541080203844%22%2C%22redirectUrl%22%3A%22https%3A%2F%2Frave-webhook.herokuapp.com%2Fnewregistration%22%2C%22device_fingerprint%22%3A%22532b4e9fa7695279392f4780b9868b9b%22%2C%22settlement_token%22%3Anull%2C%22cycle%22%3A%22one-time%22%2C%22amount%22%3A60%2C%22charged_amount%22%3A60%2C%22appfee%22%3A0.9%2C%22merchantfee%22%3A0%2C%22merchantbearsfee%22%3A1%2C%22chargeResponseCode%22%3A%2200%22%2C%22raveRef%22%3A%22RV31541080202194E1A956BA48%22%2C%22chargeResponseMessage%22%3A%22Approved.+Successful.%22%2C%22authModelUsed%22%3A%22AUTH%22%2C%22currency%22%3A%22NGN%22%2C%22IP%22%3A%22197.149.95.62%22%2C%22narration%22%3A%22Synergy+Group%22%2C%22status%22%3A%22successful%22%2C%22modalauditid%22%3A%2276d43165b4e49f5ce5e71736298e109d%22%2C%22vbvrespmessage%22%3A%22N%2FA%22%2C%22authurl%22%3A%22NO-URL%22%2C%22vbvrespcode%22%3A%22N%2FA%22%2C%22acctvalrespmsg%22%3Anull%2C%22acctvalrespcode%22%3Anull%2C%22paymentType%22%3A%22account%22%2C%22paymentPlan%22%3Anull%2C%22paymentPage%22%3Anull%2C%22paymentId%22%3A%22478%22%2C%22fraud_status%22%3A%22ok%22%2C%22charge_type%22%3A%22normal%22%2C%22is_live%22%3A0%2C%22createdAt%22%3A%222018-11-01T13%3A50%3A02.000Z%22%2C%22updatedAt%22%3A%222018-11-01T13%3A50%3A03.000Z%22%2C%22deletedAt%22%3Anull%2C%22customerId%22%3A58159%2C%22AccountId%22%3A134%2C%22customer%22%3A%7B%22id%22%3A58159%2C%22phone%22%3A%22N%2FA%22%2C%22fullName%22%3A%22Anonymous+customer%22%2C%22customertoken%22%3Anull%2C%22email%22%3A%22cchizie26%40gmail.com%22%2C%22createdAt%22%3A%222018-10-24T16%3A58%3A21.000Z%22%2C%22updatedAt%22%3A%222018-10-24T16%3A58%3A21.000Z%22%2C%22deletedAt%22%3Anull%2C%22AccountId%22%3A134%7D%2C%22validateInstructions%22%3A%7B%22valparams%22%3A%5B%5D%2C%22instruction%22%3A%22%22%7D%2C%22validateInstruction%22%3A%22Please+dial+*901*4*1%23+to+get+your+OTP.+Enter+the+OTP+gotten+in+the+field+below%22%7D%7D%2C%22tx%22%3A%7B%22id%22%3A301782%2C%22txRef%22%3A%22rave-checkout-1541080175862%22%2C%22orderRef%22%3A%22URF_1541080202653_2603435%22%2C%22flwRef%22%3A%22FLWACHMOCK-1541080203844%22%2C%22redirectUrl%22%3A%22https%3A%2F%2Frave-webhook.herokuapp.com%2Fnewregistration%22%2C%22device_fingerprint%22%3A%22532b4e9fa7695279392f4780b9868b9b%22%2C%22settlement_token%22%3Anull%2C%22cycle%22%3A%22one-time%22%2C%22amount%22%3A60%2C%22charged_amount%22%3A60%2C%22appfee%22%3A0.9%2C%22merchantfee%22%3A0%2C%22merchantbearsfee%22%3A1%2C%22chargeResponseCode%22%3A%2200%22%2C%22raveRef%22%3A%22RV31541080202194E1A956BA48%22%2C%22chargeResponseMessage%22%3A%22Approved.+Successful.%22%2C%22authModelUsed%22%3A%22AUTH%22%2C%22currency%22%3A%22NGN%22%2C%22IP%22%3A%22197.149.95.62%22%2C%22narration%22%3A%22Synergy+Group%22%2C%22status%22%3A%22successful%22%2C%22modalauditid%22%3A%2276d43165b4e49f5ce5e71736298e109d%22%2C%22vbvrespmessage%22%3A%22N%2FA%22%2C%22authurl%22%3A%22NO-URL%22%2C%22vbvrespcode%22%3A%22N%2FA%22%2C%22acctvalrespmsg%22%3Anull%2C%22acctvalrespcode%22%3Anull%2C%22paymentType%22%3A%22account%22%2C%22paymentPlan%22%3Anull%2C%22paymentPage%22%3Anull%2C%22paymentId%22%3A%22478%22%2C%22fraud_status%22%3A%22ok%22%2C%22charge_type%22%3A%22normal%22%2C%22is_live%22%3A0%2C%22createdAt%22%3A%222018-11-01T13%3A50%3A02.000Z%22%2C%22updatedAt%22%3A%222018-11-01T13%3A50%3A03.000Z%22%2C%22deletedAt%22%3Anull%2C%22customerId%22%3A58159%2C%22AccountId%22%3A134%2C%22customer%22%3A%7B%22id%22%3A58159%2C%22phone%22%3A%22N%2FA%22%2C%22fullName%22%3A%22Anonymous+customer%22%2C%22customertoken%22%3Anull%2C%22email%22%3A%22cchizie26%40gmail.com%22%2C%22createdAt%22%3A%222018-10-24T16%3A58%3A21.000Z%22%2C%22updatedAt%22%3A%222018-10-24T16%3A58%3A21.000Z%22%2C%22deletedAt%22%3Anull%2C%22AccountId%22%3A134%7D%2C%22validateInstructions%22%3A%7B%22valparams%22%3A%5B%5D%2C%22instruction%22%3A%22%22%7D%2C%22validateInstruction%22%3A%22Please+dial+*901*4*1%23+to+get+your+OTP.+Enter+the+OTP+gotten+in+the+field+below%22%7D%2C%22success%22%3Atrue%7D
Parameters you can pass
Rave Inline Parameters
Parameter | Required | Description |
---|---|---|
PBFPubKey | true | Your merchant public key, see how to get your API Keys |
integrity_hash | false | This is a sha256 hash of your getpaidSetup values, it is used for passing secured values to the payment gateway. |
txref | true | Your Unique transaction reference. |
payment_options | false | This allows you to select the payment option you want for your users, see Choose Payment Methods for more info. |
payment_plan | false | This is the payment plan ID used for Recurring billing ]. |
subaccounts | false | This is an array of objects containing the subaccount IDs to split the payment into. |
amount | true | Amount to charge. |
currency | false | The is the currency to charge the customer's payment source in, it defaults to NGN if nothing is passed. |
country | false | defaults to NG route country. |
customer_email | true | Email of the customer. |
customer_phone | true | phone number of the customer. |
customer_firstname | false | first name of the customer. |
customer_lastname | false | last name of the customer. |
pay_button_text | false | Text to be displayed on the Rave Checkout Button. |
custom_title | false | Text to be displayed as the title of the payment modal. |
custom_description | false | Text to be displayed as a short modal description. |
redirect_url | false | URL to redirect to when a transaction is completed. This is useful for 3DSecure payments so we can redirect your customer back to a custom page you want to show them. |
custom_logo | false | Link to the Logo image. |
onclose: function() | false | A function to be called when the pay modal is closed. |
callback: function(b) | false | A function to be called on successful card charge. User’s can always be redirected to a successful or failed page supplied by the merchant here based on response. |
meta:[{metaname:‘flightid’,metavalue:‘93849-MK5000’}] | false | Any other custom data you wish to pass. |
Rave Quick Setup (Embed) Parameters
Parameter | Required | Description |
---|---|---|
data-PBFPubKey | true | Your merchant public key, see how to get your API Keys |
data-integrity_hash | true | This is a Sha256 hash of your getpaidSetup values, it is used for passing secure values to the payment gateway. |
data-txref | true | Your Unique transaction reference. |
data-payment_options | false | This allows you to select the payment option you want for your users, see Choose Payment Methods for more info. |
data-payment_plan | false | This is the payment plan ID used for Recurring billing ]. |
data-subaccounts | false | This is an array of objects containing the subaccount IDs to split the payment into. |
data-amount | true | Amount to charge. |
data-currency | false | The is the currency to charge the customer's payment source in, it defaults to NGN if nothing is passed. |
data-country | false | defaults to NG route country. |
data-customer_email | true | Email of the customer. |
data-customer_phonenumber | true | phone number of the customer. |
data-customer_firstname | false | first name of the customer. |
data-customer_lastname | false | last name of the customer. |
data-pay_button_text | false | Text to be displayed on the Rave Checkout Button. |
data-custom_title | false | Text to be displayed as the title of the payment modal. |
data-custom_description | false | Text to be displayed as a short modal description. |
data-redirect_url | false | URL to redirect to when a transaction is completed. This is useful for 3DSecure payments so we can redirect your customer back to a custom page you want to show them. |
data-custom_logo | false | Link to the Logo image. |
data-meta-[custom_param] | false | Any other custom data you wish to pass. |
Updated over 4 years ago
Congrats! You now have our hosted payment form on your site to accept payment securely from your customers, to see how to check the status of your payment click on the button below.