我在支付网关URL上发布了4个参数,作为响应服务器将名为auth_token & postBackURL的参数发回。
我不明白如何从auth_token MVC ?中获取这些参数(postBackURL和ASP.NET )。
下面是我的密码。
var client = new HttpClient();
var values = new List<KeyValuePair<string, string>>();
values.Add(new KeyValuePair<string, string>("storeId", "1234"));
values.Add(new KeyValuePair<string, string>("amount", "1000"));
values.Add(new KeyValuePair<string, string>("postBackURL","http://www.smmotors.org"));
values.Add(new KeyValuePair<string, string>("orderRefNum", "1101"));
var content = new FormUrlEncodedContent(values);
HttpResponseMessage response = client.PostAsync("https://easypaystg.easypaisa.com.pk/easypay/Index.jsf", content).Result;下面的是插件集成文档.
商家需要在以下URL上向Easypay发布以下参数:
沙箱环境:https://easypaystg.easypaisa.com.pk/easypay/Index.jsf
国际货币基金组织( storeId postBackURLorderRefNum )
成功重定向后,客户将登陆Easypay屏幕,在该屏幕中,需要填写有关事务信息的表单。
沙箱环境:https://easypaystg.easypaisa.com.pk/easypay/Confirm.jsf
auth_token postBackURL
在此重定向之后,Easypay将对商人发送的auth_token进行前一步的身份验证,在成功的身份验证后,它将使客户登陆成功的签出屏幕,将以下两个变量发送回第二个postBackURL:
orderRefNumberstatusdesc
发布于 2016-09-27 11:05:17
您可以像这样使用来获取响应键。
public ActionResult AdvPaymentResponse()
{
List<PaypalAddDataValueModel> keyvalueList = new List<PaypalAddDataValueModel>();
var postdata = System.Web.HttpContext.Current.Request.Form;
foreach (var item in postdata)
{
PaypalAddDataValueModel datavalue = new PaypalAddDataValueModel();
datavalue.Key = item.ToString();
datavalue.Value = System.Web.HttpContext.Current.Request.Form[item.ToString()];
keyvalueList.Add(datavalue);
// var data = System.Web.HttpContext.Current.Request.Form[item.ToString()];
}
AdvPaypalResponse obj = new AdvPaypalResponse();
obj.AVSZIP = keyvalueList[0].Value;
obj.BILLTOEMAIL = keyvalueList[1].Value;
obj.TYPE = keyvalueList[2].Value;
obj.ZIPTOSHIP = keyvalueList[3].Value;
obj.BILLTOLASTNAME = keyvalueList[4].Value;
obj.BILLTONAME = keyvalueList[5].Value;
}https://stackoverflow.com/questions/39722292
复制相似问题