- METHOD TYPEE-wallet
- PAYMENTS
- PAYOUTS
- REFUNDS
- RECURRING
Introduction
Rakuten Pay is a payment method available in Japan that allows users to easily and securely make payments using Rakuten credentials.
Supported Countries
- Japan
Supported Currencies
- JPY
Payment (Deposit) Flow
Follow these steps to perform a payment using Nuvei REST API integration:
1. Generate a sessionToken
Press here for details.
2. Send a /payment Request
Perform the payment by sending a /payment request with its mandatory parameters including:
userTokenIdamountcurrencypaymentOption.alternativePaymentMethodclass containing:paymentMethod: “apmgw_Rakuten_Pay“
deviceDetailsclass containing:ipAddressbillingAddressclass containing:firstName,lastName,email,countryuserDetailsclass containing:firstName,lastName,email,countryurlDetailsclass containing:successUrl,failureUrl,pendingUrl
Example /payment Request
{
"sessionToken":"<sessionToken from /getSessionToken>",
"merchantId":"<your merchantId>",
"merchantSiteId":"<your merchantSiteId>",
"clientRequestId":"<unique request ID in merchant system>",
"amount":"1000",
"currency":"JPY",
"userTokenId":"<unique customer identifier in merchant system>",
"clientUniqueId":"<unique transaction ID in merchant system>",
"paymentOption":{
"alternativePaymentMethod":{
"paymentMethod":"apmgw_Rakuten_Pay"
}
},
"deviceDetails":{
"ipAddress":"<customer's IP address>"
},
"billingAddress":{
"firstName":"John",
"lastName":"Smith",
"email":"[email protected]",
"country":"JP"
},
"userDetails":{
"firstName":"John",
"lastName":"Smith",
"email":"[email protected]",
"country":"JP"
},
"urlDetails": {
"successUrl": "<http://merchantsuccessURL.html?deep_link=parameter>",
"failureUrl": "<http://merchantfailureURL.html?deep_link=parameter>",
"pendingUrl": "<<http://merchantpendingURL.html?deep_link=parameter>"
},
"timeStamp":"<YYYYMMDDHHmmss>",
"checksum":"<calculated checksum>"
}
Example /payment Response
{
"internalRequestId": 1712060044663,
"status": "SUCCESS",
"errCode": 0,
"reason": "",
"merchantId": "5416795427517477813",
"merchantSiteId": "186111",
"version": "1.0",
"clientRequestId": "20240402151405",
"sessionToken": "14b1daaf-3a43-4d41-8a3a-41ab6286c446",
"orderId": "42308541",
"paymentOption": {
"redirectUrl": "https://webapp-apm-globalpay-api-qa.nuvei.com/Home?PaymentToken=3FEEA3F2349E178B95F4E649BC8DCA6D.6889273",
"userPaymentOptionId": "",
"card": {}
},
"transactionStatus": "REDIRECT"
}
After the transaction is processed, Nuvei sends a Direct Merchant Notification (DMN) that includes the result of the transaction to the URL provided in urlDetails.notificationUrl, which Nuvei recommends including in the /payment request.
Example /payment DMN with status=APPROVED
...'ppp_status=OK&Status=APPROVED&ExErrCode=0&ErrCode=0&errApmCode=0&errApmDescription=&errScCode=0&errScDescription=&Reason=&ReasonCode=0&PPP_TransactionID=42309251&userid=&merchant_unique_id=&customData=&productId=&first_name=&last_name=Lname&email=test%40mymail.com¤cy=JPY&customField1=&customField2=&customField3=&customField4=&customField5=&customField6=&customField7=&customField8=&customField9=&customField10=&customField11=&customField12=&customField13=&customField14=&customField15=&invoice_id=&address1=Sancho+el+fuerte+15&address2=&country=Japan&state=&city=Madrid&zip=%24%7BzipU%7D&phone1=0987654321&phone2=&phone3=&client_ip=93.146.254.172&nameOnCard=&cardNumber=&bin=&noCVV=&acquirerId=&acquirerBank=Smart2Pay+Direct&expMonth=&expYear=&Token=&tokenId=&AuthCode=&AvsCode=&Cvv2Reply=&shippingCountry=&shippingState=&shippingCity=&shippingAddress=&shippingZip=&shippingFirstName=&shippingLastName=&shippingPhone=&shippingCell=&shippingMail=&total_discount=0.00&total_handling=0.00&total_shipping=0.00&total_tax=0.00&buyButtonProductBundleId=&merchant_site_id=186111&merchant_status=&action=&requestVersion=&message=APPROVED&merchantLocale=&unknownParameters=&payment_method=apmgw_Rakuten_Pay&ID=&merchant_id=5416795427517477813&responseTimeStamp=2024-04-02.12%3A55%3A28&buyButtonProductId=&webMasterId=&appliedPromotions=&uniqueCC=&transactionType=Sale&externalEmail=&cardCompany=&eci=&userPaymentOptionId=&TransactionID=2610000000000016915&externalTransactionId=6889284&APMReferenceID=48228354BDD59B6E2266613749EE201E&orderTransactionId=23742441&totalAmount=1000.00&dynamicDescriptor=hristo+descriptor&item_name_1=NA&item_number_1=&item_amount_1=1000.00&item_quantity_1=1&item_discount_1=0.00&item_handling_1=0.00&item_shipping_1=0.00&feeAmount=&amountWithoutFee=&houseNumber=&customCurrency=&type=DEPOSIT&clientRequestId=20240402155448&relatedTransactionId=&apmPayerInfo=%7B%22StatusInfo%22%3A%22%7B+StatusCode%3A+%2C+info%3A+%2C+originalAmount%3A+1000.0000%2C+ProcessedAmount%3A+100000%2C+originalCurrency%3A+YEN%2C+ProcessedCurrency%3A+JPY+%7D%22%7D&sessionId=ee05e7911a45b2a060bce1631dbb&responsechecksum=827f43044fc39e184e0a8340115c00fa819748f3b519bdf26d35851f69432203&advanceResponseChecksum=e4fc6ca69b30b45e56cc3fe528222bb8ca785131f5f5cbe41c9cbc1e12586326'
User Experience
- The user is redirected to the Rakuten website, enters an email address or member ID, and then presses Next.

- The user enters a password and logs in.

- The user selects a payment funding source, enters other required information, and then presses Confirm Input Contents.

- The user reviews the payment information and completes the payment by pressing Pay with Rakuten Pay.

Testing
In the sandbox environment, you can simulate an approval or a decline request. To simulate an approval, press the blue button (Pay). To simulate a decline and be redirected to the merchant page, press the red button (Cancel).
