Visa Developer Community

Highlighted
Helper

Error 9124

Hi,

I'm newbie here and started my integration with VISA API. I followed the two way ssl authentication process and able to call from SOAP UI , but when i try to call using the same keystore from java i get the error :

 

{"responseStatus":{"status":400,"code":"9124","severity":"ERROR","message":"Expected input credential was not present","info":""}}

 

URL : https://sandbox.api.visa.com/vdp/helloworld.

 

18 REPLIES 18
Highlighted

Re: Error 9124

Hi,

This issue could be resolved by adding 'DigiCert Global Root CA' certificate into the client keystore, i.e. now your keystore should have private key+(public key + certificate) + vdp sandbox cert. + digi cert root ca. So, we need to add the global root ca to the client keystore in order to call from Java ApiClient.

Also, you can directly add 'DigiCert Global Root CA' to the cacerts of jre. But I'd recommend going for the first approach.

If it's still confusing please follow this tutorial on how to set up ssl https://developer.visa.com/pages/working-with-visa-apis/two-way-ssl#configuring_a_twoway_ssl_keystor...

 

and post your query if you still aren't able to resolve the issue.

 

Note: Use 'jks' keystore with java and enter correct credentials in API Client's Test class. Java Code should look something like this:

apiClient.setUsername("fsfdgsdfgsdfgsfgfdg"); (Available in API sandbox under credentials)
apiClient.setPassword("afasdfasdfasdf");apiClient.setKeystorePath("/path/to/keys/dir/myProject_keyAndCertBundle.jks");

apiClient.setKeystorePassword("password"); (keystore password entered while generating 'jks' keystore)
apiClient.setPrivateKeyPassword("password");

You can test if you aren't entering wrong credentials by keeping all export passwords as same while generating keystore. But not recommended in production env.

Visa Dev Moderator

Re: Error 9124

Hey @Anees,

 

Go here for Visa Developer error codes and cause and resolution - https://developer.visa.com/pages/visa-developer-error-codes 

 

We recommend you to use the VDC Playground tool for your testing. Can you please download this tool and test from there?

 

You can also download VDC Playground from your Visa Developer project app. Just click on your project, and and download VDC Playground from the Assets section and Run it. Refer to screenshot.

20190917 Assets VDP Playground.png

 

I have also attached the VDC Playground tool as an attachment, for your convenience.


You can find the guide on Getting Started with VDC Playground from this blog post here - https://developer.visa.com/pages/visa-developer-center-playground 

 

If the issue persists, please provide the following information and I'd be happy to help:

1. Endpoint
2. Request Header
3. Request Body
4. Response Header (include the x-correlation-id)
5. Response Body

Using SoapUI, you can find the x-correlation-id in the Raw Tab of the response header.

 

Hey @swaritsharma,

That's a great suggestion too!

 

 



Was your question answered? Don't forget to click on "Accept as Solution" to help other devs find the answer to the same question.

Thanks,
Diana

Highlighted
Helper

Re: Error 9124

Hi Swaritsharma,

First of all thank you for taking out time to reply to my issue.

I have imported all the certificate but same issue, I can call from SOAP UI but when i use the same keystore in my java code same error gives.

Highlighted
Helper

Re: Error 9124

Hi Diana,

I'm grateful to you that you have answered in very detail. I have downloaded the VDC Playground tool and successfully cal the API, but i can also able to call the API from SOAP UI previously. issue is when i use that same keystore in my java code it gives me:

{"status":400,"code":"9124","severity":"ERROR","message":"Expected input credential was not present","info":""}.

 

I called the :

https://sandbox.api.visa.com/visadirect/v1/transactionquery?acquiringBIN=408999

https://sandbox.api.visa.com/visadirect/mvisa/v1/merchantpushpayments.

 

Might be issue is with the keystore. Can i somehow share my keystore and my java class with you to check ? would be your kindness to me. I'm stuck.

Tags (1)
Highlighted
Visa Dev Moderator

Re: Error 9124

Hey @Anees,

 

Yes, please share your keystore and java code with us so we can take a look and help to resolve the issue. You can send the keystore and java code to us using this community forum thread or you can send an email to developer@visa.com. If you email developer@visa.com, please reference this community forum link so that we have the details to your issue.

 

 

 



Was your question answered? Don't forget to click on "Accept as Solution" to help other devs find the answer to the same question.

Thanks,
Diana

Highlighted
Helper

Re: Error 9124

Hello Diana,

Good morning, i have sent the email with the subject line Error 9124 , given the link of this forum in the email body, attached the java class and the keystore. Please review that and guide me what wrong i'm doing.

 

Thanks.

Regards,

Anees.

Highlighted
Visa Dev Moderator

Re: Error 9124

Hey @Anees,

 

We received your email with your java class and keystore files at developer@visa.com. I've created case INC8978116 for the engineering team to investigate the issue. Someone will get back to you shortly.



Was your question answered? Don't forget to click on "Accept as Solution" to help other devs find the answer to the same question.

Thanks,
Diana

Highlighted
Helper

Re: Error 9124

Hey Diana,

Thanks, waiting for some helpful response.

Highlighted
Visa Dev Moderator

Re: Error 9124

Hey @Anees,

 

Looking at the error it looks like you didn't import both common certificates into your keystore. You should import "Visa Development Platform Certificate" and "DigiCert Certificate". You should also import the certificate you received for your app. So a total of three certificates should be imported. Can you please confirm that you have done this and let us know if the issue persists?

 



Was your question answered? Don't forget to click on "Accept as Solution" to help other devs find the answer to the same question.

Thanks,
Diana