ios - Integrate Paytm with swift 3.0 -
i want integrate paytm payment gateway swift 3.0.i follow github link . have probelm in ["checksumhash"]= "" . can put in key.
orderdict["mid"] = strmid orderdict["order_id"] = strorderid orderdict["cust_id"] = strcustomerid orderdict["industry_type_id"] = strindustrytype orderdict["channel_id"] = strchanalid orderdict["txn_amount"] = stramt orderdict["website"] = strwebsite orderdict["callback_url"] = "http://xxxxx.co.in/verifychecksum.php" orderdict["checksumhash"] = "" this gives me invalid checksum please tell me how can generate checksum.
first of can call server api generate checksum. if using almofire call
var parameters:[string:string]? parameters = ["mid":strmid,"order_id":strorderid ,"industry_type_id":strindustrytype,"channel_id":strchanalid,"txn_amount":stramt,"website":strwebsite, "cust_id":strcustomerid,"callback_url":"http://xxxxxxx.co.in/verifychecksum.php"] showhud(self.view) print(parameters) alamofire.request("http://xxxxxx.co.in/generatechecksum.php", method: .post, parameters: parameters,encoding: urlencoding.default, headers: nil).responsejson {} please pass all parameter in api . gives below response
{ "checksumhash": "xxxxxxxxxxxxx", "order_id": "xxxxxxxx", "payt_status": "1" } in dictionary checksumhash pass paytm order.
Comments
Post a Comment