bPay

bPay is a wire transfer payment method used in Australia, where users can make payments online and over the phone for online purchases or utility bills.

bPay is Australia's most widely used bill pay service, which allows shoppers to make easy and secure online purchases by transferring funds from their bank account.

Fulfillment occurs after authorization and settlement. The customer provides either the transfer information to their bank or completes a payment using bPay.

Configuring bPay for DigitalRiver.js

Create a bPay payment method for your app or website in three easy steps:‌

Step 1: Build a bPay source request object

A bPay Source Request object requires the following fields.

Field

Value

type

bPay

amount

The total value of the transaction.

currency

The currency of the transaction.

owner

An Owner object.

bPay

A bPay Object. (This is currently empty)

Step 2: Create a bPay source using DigitalRiver.js

To create a bPay payment source, you must use the createSource method exposed via DigitalRiver.js.

JavaScript
JavaScript
var data = {
"type": "bPay",
"sessionId": "ea03bf6f-84ef-4993-b1e7-b7d5ecf71d1f",
"owner": {
"firstName": "John",
"lastName": "Doe",
"email": "[email protected]",
"phoneNumber": "000-000-0000",
"address": {
"line1": "3 Bridge Lane",
"line2": "",
"city": "Sydney",
"state": "NSW",
"postalCode": "2000",
"country": "AU"
}
},
"bPay": {}
}
digitalriver.createSource(data).then(function(result) {
if (result.error) {
//handle errors
} else {
var source = result.source;
//send source to back end
sendToBackend(source);
}
});

bPay source example

The source event will surface a Source plus other details provided by bPay, like the billing address and the information required to send money to bPay.

Plain Text
Plain Text
{
"clientId": "gc",
"channelId": "drdod15",
"liveMode": false,
"id": "710e07b5-4ac5-4ce7-8257-aa9b4095573d",
"clientSecret": "710e07b5-4ac5-4ce7-8257-aa9b4095573d_23f5c33d-1a54-412d-9e4f-cd37dc424c8a",
"type": "bPay",
"reusable": false,
"owner": {
"firstName": "John",
"lastName": "Doe",
"email": "[email protected]",
"phoneNumber": "192-976-1833",
"address": {
"line1": "3 Bridge Lane",
"line2": "",
"city": "Sydney",
"state": "NSW",
"country": "AU",
"postalCode": "2000"
}
},
"amount": "0.15",
"currency": "AUD",
"state": "pending_funds",
"creationIp": "209.87.180.5",
"createdTime": "2019-11-06T22:11:40.698Z",
"updatedTime": "2019-11-06T22:11:40.753Z",
"flow": "receiver",
"bPay": {
"accountHolder": "Global Collect BV",
"bankName": "Commonwealth Bank",
"city": "Sydney",
"country": "Australia",
"referenceId": "890701397589",
"accountNumber": "062000-11002112",
"billerId": "141606",
"customerPaymentReference": "008907013975899",
"swiftCode": "CTBAAU2S"
}
}

Step 3: Use the authorized source

Once authorized, you can use the source by attaching it to a checkout.

POST /checkouts/{id}
POST /checkouts/{id}
{
"customerId": "5774321008",
"sourceId": "src_a78cfeae-f7ae-4719-8e1c-d05ec04e4d37"
}

Pushing funds

At this point, you should complete your order, and provide the instructions inside the bPay object to the shopper to wire payment.

When you push the funds, the source transitions to the chargeable state. The order will then be ready for fulfillment.

Supported markets

For information on supported markets and currencies for Drop-in and DigitalRiver.js, go to: