public GetCardsRequestFactory() { request = new getCardsRequest() { requestHeader = CreateRequestHeader() }; }
public getCardsResponse GetCards() { GetCardsClientService client = new GetCardsClientService(); getCardsRequest request = TestData(); getCardsResponse response = new getCardsResponse(); // for SOAP //response = client.SoapClient(request); //Assert.IsNotNull(response); // for REST response = client.RestClient(Constants.GET_CARDS_URL, TestData()); return(response); }
public getCardsRequest TestData() { getCardsRequest getCardsRequest = new getCardsRequest() { requestHeader = new requestHeader() { applicationName = "PORTALTEST", applicationPwd = "ZDyXmMLWE2z7OzJU", clientIPAddress = "10.252.187.81", transactionDateTime = "20160309084056197", transactionId = "12345678901234567893" }, msisdn = "905304018286" }; return(getCardsRequest); }
private getCardsResponse GetCards(string msisdn) { GetCardsClientService client = new GetCardsClientService(); getCardsResponse response = null; getCardsRequest request = null; GetCardsRequestFactory factory = new GetCardsRequestFactory(); factory.request.msisdn = msisdn; try { request = factory.Build(); response = client.OptionalRequest(MySession.Current.requestFilter, request); return(response); } catch (Exception ex) { ShowMessage(ex.Message); return(null); } }