Getting PAYMENT_CREATION_ERROR while testing payment on sandbox mode

himanshu1706
Contributor
Contributor

I am getting below error, while making payment from my android app. I am using paypal android sdk.

 

paypal.sdk: request failed with server response:{"name":"PAYMENT_CREATION_ERROR","debug_id":"3550e355c6299","message":"checkout-session not created","information_link":"https://developer.paypal.com/docs/api/#PAYMENT_CREATION_ERROR"}

 

I am using sandbox env. Please guide me to resolve the error.

Login to Me Too
1 ACCEPTED SOLUTION

Accepted Solutions
Solved

MTS_Ciaran
Moderator
Moderator

hmmmm, 

 

So I suspect that the sandbox account might be the issue, based on the currencies in the buyer and seller accounts USD should be fine so I suspect that there is an issue when we're pulling the accounts details at runtime. 

 

Can you try creating a new sandbox Merchant account and trying the transaction again. 

View solution in original post

Login to Me Too
6 REPLIES 6

MTS_Ciaran
Moderator
Moderator

@himanshu1706 - Im seeing an unsupported currency error for this failure. As in the merchant/receiver account doesn't support the currency set in the API call for the transactions. 

Login to Me Too

himanshu1706
Contributor
Contributor

@MTS_CiaranI am using "USD" in currency. If it's wrong what should I use?

Login to Me Too

MTS_Ciaran
Moderator
Moderator

Can you post here the API call you are sending?

Login to Me Too

himanshu1706
Contributor
Contributor
private static PayPalConfiguration config = new PayPalConfiguration()
            .environment(CONFIG_ENVIRONMENT)
            .clientId(PAYPAL_CLIENT_ID)
            .merchantName("Chubb Connect")
            .acceptCreditCards(false)
            .merchantPrivacyPolicyUri(Uri.parse("https://www.example.com/privacy"))
            .merchantUserAgreementUri(Uri.parse("https://www.example.com/legal"));


 PayPalPayment thingToBuy = new PayPalPayment(price, "USD",
                itemDescription, PayPalPayment.PAYMENT_INTENT_SALE);
        Intent intent = new Intent(mContext, PaymentActivity.class);
        intent.putExtra(PaymentActivity.EXTRA_PAYMENT, thingToBuy);
        startActivityForResult(intent, REQUEST_CODE_PAYMENT);

Above code I am using by paypal android SDK.
Login to Me Too
Solved

MTS_Ciaran
Moderator
Moderator

hmmmm, 

 

So I suspect that the sandbox account might be the issue, based on the currencies in the buyer and seller accounts USD should be fine so I suspect that there is an issue when we're pulling the accounts details at runtime. 

 

Can you try creating a new sandbox Merchant account and trying the transaction again. 

Login to Me Too

himanshu1706
Contributor
Contributor

@MTS_CiaranCreating the new merchant account worked for me. Thanks

Login to Me Too

Haven't Found your Answer?

It happens. Hit the "Login to Ask the community" button to create a question for the PayPal community.