Configuring Wire Transfer
Learn how to configure Wire Transfer for DigitalRiver.js with Elements.
If you're using DigitalRiver.js with Elements, you can create an Wire Transfer payment method for your app or website in four easy steps:
Step 1: Build a Wire Transfer source request object
Build a Wire Transfer Source Request object. A Wire Transfer Source Request object requires the following fields.
type
wireTransfer
sessionId
The payment session identifier.
owner
An Owner object.
wireTransfer
A Wire Transfer object. (This is currently empty)
Step 2: Create a Wire Transfer source using DigitalRiver.js
Use the DigitalRiver.js library to create and mount elements to the HTML container.
var data = {
"type": "wireTransfer",
"sessionId": "ea03bf6f-84ef-4993-b1e7-b7d5ecf71d1f",
"owner": {
"firstName": "John",
"lastName": "Doe",
"email": "[email protected]",
"phoneNumber": "1555000000",
"address": {
"line1": "123 Main Street",
"line2": "",
"city": "Minnetonka",
"state": "MN",
"postalCode": "55343",
"country": "US"
}
},
"wireTransfer": {
}
}
digitalriver.createSource(data).then(function(result) {
if (result.error) {
//handle errors
} else {
var source = result.source;
//send the source to the back end
sendToBackend(source);
}
});Wire Transfer Source response example
Step 3: Use the authorized source
Once authorized, you can use the source by attaching it to a cart.
Step 4: Direct your customer to go to their banking institution
Once the customer submits the order, the source remains in the pending_funds state. Direct your customer to go to their banking institution to wire the money to the account details listed in the wireTransfer block of your source.
Last updated
Was this helpful?