get https://mercury-uat.phonepe.com/v3/vpa///validate
This API is used to check if the given VPA is valid or not.
Header Name | Header Value |
---|---|
Content-Type | application/json |
X-VERIFY | SHA256("/v3/{merchantId}/{vpa}/validate" + saltKey) + "###" + saltIndex |
Parameter Name | Type | Description | Mandatory |
---|---|---|---|
merchantId | STRING | Unique Merchant ID assigned to the merchant by PhonePe | Yes |
vpa | STRING | VPA (UPI ID) for which validation is required | Yes |
Parameter Name | Type | Description |
---|---|---|
success | BOOLEAN | A boolean to indicate the success/failure of the request. Merchant should check for this parameter if VPA exists or not |
code | ENUM (see list of codes below) | This parameter is used to decide if collect was successfully sent or not. |
message | STRING | Short message about status of VPA |
exists | BOOLEAN | Flag indicates if VPA (UPI ID) exists |
name | STRING | Name of the person registered on this VPA |
vpa | STRING | VPA ID passed in request |
Code | Description |
---|---|
EXTERNAL_VPA_ERROR | Incorrect VPA. VPA ID does not exists. |
BAD_REQUEST | Some mandatory parameter was missing |
AUTHORIZATION_FAILED | Checksum sent in header was not valid |
INTERNAL_SERVER_ERROR | Something went wrong |
To check if a VPA is valid, Merchant should consider the following values:
success:true, code:"SUCCESS", exists:trueThe value of data would be populated only if value of success is true.