Configuring Alipay+ (cross-border)
Learn how to configure Alipay+ (cross-border) for DigitalRiver.js with Elements
Step 1: Build an Alipay+ (cross-border) source request object
Field
Value
let alipayCnSourceData = {
"type": "alipayCn",
"sessionId": "3c9473b0-630d-4f20-af61-63d3aa8acb35",
"owner": {
"firstName": "Donglei",
"lastName": "Ye",
"email": "[email protected]",
"phoneNumber": "13063725095",
"address": {
"line1": "Wei Bai Chang",
"city": "ShunDe District)",
"state": "Guangdong",
"country": "CN",
"postalCode": "528322"
}
},
"alipayCn": {
"returnUrl": redirectUrl
}
}
digitalriver.createSource(alipayCn+SourceData ).then(function(result) {
if (result.error) {
//handle errors as something went wrong
} else {
var source = result.source;
//do something with the created source
}
});Alipay+ (cross-border) source example
Step 3: Authorize an Alipay+ (cross-border) source
Redirecting the customer for authorization
Step 4: Use the authorized source
Testing Alipay+ (cross-border)
Last updated