Paytm is India’s most popular and widely accepted Payment Gateway. Moreover, integration of it to your website or mobile app is simple enough if you possess Paytm Merchant Key. Though, paytm integration is available for various platforms, integrating it in the Golang might not be known to all.
Read about how we made this on our blog (https://www.mindinventory.com/blog/paytm-integration-using-golang/)
It is a well managed repository, using which one can integrate Patym in their GoLang Website in quick simple steps once they get Paytm Merchant Key from Paytm official website.
Set Up Merchant Key got from above process
Provide the value for PAYTM_MERCHANT_KEY in .env file
PAYTM_MID = "XXXXXXXXXXXXXXXXXXXXXXXXXX" PAYTM_MERCHANT_KEY = "XXXXXXXXXXXXXXXX" PAYTM_CHANNEL_ID = "WAP" PAYTM_CHANNEL_ID_WEB = "WEB" PAYTM_WEBSITE = "XXXXXXX" PAYTM_WEBSITE_WEB = "XXXXX" PAYTM_INDUSTRY_TYPE_ID = "XXX"
Verify Checksum Hash for successful transactions.
A checksum hash is generated by the paytm which is verified on merchant server for successful transaction. For this there is a file library.go in Paytm folder which need to be copied to your local as it works for generation and verification of checksum.
Paytm integration can be done in two stages i.e. staging and production modes have different Paytm transaction urls.
Staging mode transaction url *
PAYTM_TXN_URL = "https://securegw-stage.paytm.in/theia/processTransaction"
Production mode transaction url *
PAYTM_TXN_URL_STAGE = "https://secure.paytm.in/oltp-web/processTransaction"
For more details about Paytm refer this link https://developer.paytm.com/docs/v1/payment-gateway
PayTm integration using Golang is MIT-licensed
We’d be really happy if you sent us links to your projects where you use our component. Just send an email to [email protected] And do let us know if you have any questions or suggestion regarding our work.