Japan COD

Japan COD allows consumers in Japan to buy items online and pay later upon delivery.

This is a popular payment method in Japan that increases customer satisfaction and reduces fraud. Delivery and payment logistics are in partnership with Asus Japan.

Configuring Japan COD for DigitalRiver.js

Create a Japan COD payment method for your app or website in three easy steps:

Step 1: Build a Japan COD Source Request object

Build a Japan COD Source Request object. The Japan COD Source Request object requires the following fields.

Field

Value

type

codJapan

amount

The total value of the transaction.

currency

The currency of the transaction. For Japan COD, you must specify JPY as the currency.

owner

An Owner object.

codJapan

A codJapan object. Currently, this value is empty.

Step 2: Create a Japan COD source using DigitalRiver.js

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

JavaScript
var data = {
"type": "codJapan",
"sessionId": "ea03bf6f-84ef-4993-b1e7-b7d5ecf71d1f",
"owner": {
firstName: "John",
lastName: "Doe",
phoneNumber: "000-000-0000",
address: {
line1: "123 Main Street",
line2: "",
city: "Paris",
postalCode: "14390",
country: "FR"
}
},
"codJapan": {
}
}
digitalriver.createSource(data).then(function(result) {
if (result.error) {
//handle errors
} else {
var source = result.source;
//send source to back end
sendToBackend(source);
}
});

Japan COD source example

JavaScript
{
"clientId": "gc",
"channelId": "drdod15",
"liveMode": false,
"id": "f28ed8fe-49ce-44e0-bd08-592d6744ee0a",
"type": "codJapan",
"reusable": false,
"owner": {
"firstName": "John",
"lastName": "Die",
"email": "[email protected]",
"address": {
"line1": "1234 Fake Street",
"line2": "Ichikawa-shi",
"city": "Chiba",
"state": "Kyongsangnamdo",
"country": "JP",
"postalCode": "272-0138"
}
},
"amount": "100.00",
"currency": "JPY",
"state": "chargeable",
"creationIp": "209.87.178.4",
"createdTime": "2019-05-22T02:44:31.787Z",
"updatedTime": "2019-05-22T02:44:31.787Z",
"flow": "standard",
"codJapan": {}
}

Step 3: Use the Authorized source

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

Attach the source to a checkout

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

Supported markets

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