Hi, I am testing VMSS in the sandbox environment with a sample request provided in the Visa developer site. Since MLE is required, I encrypt he request, then send it. The 200 response is returned with encrypted result. But when I decrypt it, turns out the response is an error message:
{"type":"about:blank","title":"Bad Request","status":400,"detail":"Failed to read request","instance":"/api/v1/searchTerminatedRequest"}
I don't think there is a problem with my encryption and decryption, because the request is successfully sent, and response is received. I also checked the plain request body which has the exact values as provided by Visa. What could be the reason for this behavior. Is there a way to get more detailed error message to pinpoint the issue? Thanks.
Hi @agurbanova, Thank you for reaching out. An agent will get back to you as soon as possible. Until then, if any community member has information that may be helpful, feel free to reply in this thread.
Hey @agurbanova,
Please refer to the Visa Developer Error Codes page here.
The "Bad Request" (400) error indicates that there is an issue with the request being sent. Possible reasons for this behavior could include:
1. Incorrect API endpoint: Ensure you are using the correct endpoint for the Visa Merchant Screening Service (VMSS).
2. Incorrect request format: Verify that the request format matches the specifications provided by Visa.
3. Missing or incorrect headers: Ensure that all required headers are included and correctly formatted.
4. Invalid or expired credentials: Check that your credentials are valid and not expired.
5. Incorrect encryption/decryption process: Even though you mentioned that the encryption and decryption processes are working, it's worth double-checking to ensure there are no subtle issues.
To get more detailed error messages, you can enable logging on your side to capture the full request and response, including headers. Additionally, you can contact Visa Developer Support for assistance in pinpointing the issue.
Here are some key points to double-check in your request:
- Endpoint URL and version: Ensure you are using the correct URL and API version.
- Headers: Include all required headers such as `Content-Type`, `Authorization`, and any other required headers specified in the API documentation.
- Request Body: Ensure the request body matches the sample provided by Visa, including correct field names and data types.
- Encryption and Decryption: Verify that the encryption and decryption algorithms match what is required by Visa.