Authentication with PayU APIs

The PayU India API requires authentication using a merchant key and a salt. When you post requests using any of the PayU APIs, you will be posting the merchant key as the first parameter, so separate authentication is not required because these are REST APIs All requests are accompanied by a hash that is appended at the end of the request. While posting parameters for an API, the hash parameter in each API must contain the hash value to be calculated at your end. The following hash logic used in PayU India APIs:

  • Payment APIs or _payment API: The string used for calculating the hash:
  • General APIs (listed under General): The string used for calculating the hash:
  • TPV Integration: The string used calculating the hash:
  • Split Settlements Integration: The string used calculating the hash:

Here, sha512 is the encryption method used. For more information on SHA, refer to Wikipedia 1.

To perform reverse hashing, you can use the Hash API of the PayU node SDK on Github. Refer to the PayU node SDK Readme, download and install the PayU node SDK from the PayU node SDK Github location 1.



For hashing or reverse hashing, refer to Generate Hash