|
|
@ -1,4 +1,6 @@ |
|
|
|
using CustomerOnlineV2.Common.Models; |
|
|
|
using CustomerOnlineV2.Common.Helper; |
|
|
|
using CustomerOnlineV2.Common.Models; |
|
|
|
using Microsoft.Extensions.Configuration; |
|
|
|
using Newtonsoft.Json; |
|
|
|
using Newtonsoft.Json.Linq; |
|
|
|
using System.Net.Http.Headers; |
|
|
@ -9,9 +11,11 @@ namespace CustomerOnlineV2.Business.Business |
|
|
|
public class ThirdPartyAPI |
|
|
|
{ |
|
|
|
private static int timeOut = 100; |
|
|
|
private string tp_base_url = "http://77.68.15.91:1083/api/v1/"; |
|
|
|
private string apiAccessKey = "KPb1ttRs3CJnORpVU8SmAKUs7a42vtvjzQ47gU0b4u0vxAEI0PgZref6puzkVhLTX2PRNMGCbnb2TglupsjV5AGhYvw8a8POTcUcFSrEdHmTkhkIGNvUvxSpKjUOXGFQWaGU1bxoqqUSaFOmNE5zGojVmwPoMy38CNLwnpQKjdsIuxCKGCApa2gWHJl9gebmIpUODv9jAZgmMEaXqyR4CLg4iSksfTyYNjdqxEE88P5THYt5GuNk8Ti6K2RxIKfPWY49hBOpiYnXcApgSDiKFYqQG9WuZ7cvDGJIWg5WgWKjGle8Y3OydhONXVkN5OMPXDA4VZkK4c5nM363Zkg4w4qdzWuwhsEoAwU4rej6sMRZue3L0BowBJja1OK0iPoTX70EexX8rviMLOZPUDwhxzkL3eODS69VEEbjHb8WSjhho5h3KnCE4tcqCWihwSZ8Yuyhw1rzIMNw2C8pN1GEJyXc6goIFkf7dmK9ynJSxu52D9GjOkKqoD7dFNFulOFVfgeCuhPDYG2A2c2RSvGHv24VDXvmGVaAMLiPtsTz5oD8f0na7fX1xGg0Qveh0KgQL5THnrMK6gm5Ky7O8nbecIxY"; |
|
|
|
//private string tp_base_url = Common.Configs.ConfigurationManager.AppSettings["tp_base_url"];
|
|
|
|
//private string apiAccessKey = Common.Configs.ConfigurationManager.AppSettings["apiAccessKey"];
|
|
|
|
|
|
|
|
private string tp_base_url = Utilities.ReadFromAppSettings("tp_base_url"); |
|
|
|
private string apiAccessKey = Utilities.ReadFromAppSettings("apiAccessKey"); |
|
|
|
|
|
|
|
public ResponseModel ThirdPartyApiGetDataOnly<RequestModel, ResponseModel>(RequestModel model, string api_url, out APIJsonResponse jsonResponse, string MethodType = "post") |
|
|
|
{ |
|
|
|