The Get Merchant Credentials API is used to perform the following:
- Used to get the merchant credentials to generate the API Key and Salt
 - Authorized using the Client ID and Client Secret to generate the access token
 
The merchant ID in the request header must be included as a query parameter in the mid field.
Environment
| Test Environment | <https://uat-partner.payu.in> | 
| Production Environment | <https://partner.payu.in> | 
Note:The access token with the scope as read_merchant_reseller from is required on the header. For more information on getting the access token, refer to Get Token API.
Sample request
curl --location --request GET '{{partner_base_url}}api/v1/merchants/{{merchant_id}}/credential' \
--header 'Content-Type: application/json' \
--header 'Authorization: Bearer w0282c38b64e072f3d66e4e6efee9789ffe1250f0cd04c20753d6e6f25df9cc7'Sample response
Success Scenario
{
  "data": {
    "credentials": {
      "prod_key": "JPM7Fg",
      "prod_salt": "a*******"
    }
  }
}Failure Scenarios
- When the token is invalid
 
{
  "status": "Unauthorized"
}- When credentials were incorrect for a referred merchant
 
{
  "status": "Unauthorized"
}