integration Paytm Payment Gateway Android

So, Finally I was able to get through. Most Importantly you need to get in touch with Paytm's Ops team. Contact the person who provided the Key & ID's and he will lead to the Tech/ops team. Share Logs with them.

mail them on: [email protected] & [email protected]

For Paytm, setup Merchant Key on server side files (verifyChecksum.php & generateChecksum.php). My Issue was, My client provided different Merchant Key (may be Sandbox one) which lead me to "Client Authentication failed". After Sharing Logs with their team they provided the Correct Key and I started getting correct response from the server. Also, check for INDUSTRY_TYPE_ID" with the support guys. Wrong INDUSTRY_TYPE_ID" will lead you to the different error.

Good Luck!!


To integrate paytm on android app please add dependency in gradle file

// paytm dependency
    implementation('com.paytm:pgplussdk:1.2.3') {
        transitive = true;
    }

Add Paytm Activity in android menifest file

<activity android:name="com.paytm.pgsdk.PaytmPGActivity"
       android:screenOrientation="portrait" android:configChanges="keyboardHidden|orientation|keyboard"/>

To generate checksum you don't need to pass email id and mobile number.You should pass only 8 param as below-

    String url ="https://www.blueappsoftware.com/payment/payment_paytm/generateChecksum.php";
    String varifyurl = "https://pguat.paytm.com/paytmchecksum/paytmCallback.jsp";

 String param=
                    "MID="+mid+
                    "&ORDER_ID=" + orderId+
                    "&CUST_ID="+custid+
                    "&CHANNEL_ID=WAP&TXN_AMOUNT=100&WEBSITE=WEBSTAGING"+
                            "&CALLBACK_URL="+ varifyurl+"&INDUSTRY_TYPE_ID=Retail";

Please check this reference link. You can find step by step process on this reference link- https://www.blueappsoftware.com/paytm-payment-gateway-integration-android-studio/