Recurrent transactions

Makes it possible to charge a customer a fixed amount perpetually for the any desired cycle

For a transaction to be considered a recurrent transaction, the cycle parameter must be set and assigned a value such as daily, weekly, monthly, quarterly, or annually.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
<button type="button" onclick="getpaid();">Pay Now</button>
<script type="text/javascript" src="{{base_url}}/bp-inline.js"></script>
<script type="text/javascript">
function getpaid(){
const public_key = "XXXXX";
var reference = "BP_PB_TRANSACTIONS_"+Math.random();
boltpaySetup({
bp_public_key: public_key,
txref: reference,
customer_email: "example@domain.com",
customer_phone: "15551234567",
customer_firstname: "Example",
customer_lastname: "User",
amount: 999, //amount in cents
currency: "USD",
cycle: "monthly",
callback: function(response){}
}
});
}
</script>

As seen above, cycle and recurrent_reference are returned in the payload response.

View All Recurrent Payments

1
2
3
4
curl --request POST
--url {{base_url}}/recurrent-transactions/
--header 'content-type: application/json'
--data '{"secret":"YOUR_SECRET_KEY"}'

Example response

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
{
"status": "success",
"message": "Transaction(s) successfully fetched",
"data": [
{
"recurrent_reference": "BP_REC_60e724f7-29b9-43ce-aa8f-3722bc528c05",
"amount": "9.99",
"currency": "USD",
"customer": {
"name": "Customer Name",
"email_address": "email@domain.com",
"phone_number": "+15551234567"
},
"cycle": "monthly",
"transaction_history": [
"2018-08-23 12:00:00",
"2018-09-23 12:00:00",
"2018-10-23 12:00:00"
],
"next_transaction": "2018-11-23",
"created_at": "2018-08-23 12:21:51"
},
{
"recurrent_reference": "BP_REC_7c5d87de-ee30-49cb-b1f0-a33cf226d1d1",
"amount": "10.99",
"currency": "USD",
"customer": {
"name": "Customer Name",
"email_address": "email@domain.com",
"phone_number": "+15551234567"
},
"cycle": "monthly",
"transaction_history": [
"2018-08-23 12:00:00",
"2018-09-23 12:00:00",
"2018-10-23 12:00:00"
],
"next_transaction": "2018-11-23",
"created_at": "2018-08-23 12:21:51"
}
]
}

Stop a Recurrent Payment

1
2
3
4
curl --request POST
--url {{base_url}}/stop-recurrent/
--header 'content-type: application/json'
--data '{"secret":"YOUR_SECRET_KEY", "recurrent_reference": "BP_REC_XXXX"}'

Content

  • Recurrent transactions
  • View All Recurrent Payments
  • Example response
  • Stop a Recurrent Payment
  • Still questions?