Inheritance: IAPICallPreHandler
        public void GetEndpointForDefaultModeWithoutEndpoint()
        {
            Dictionary<string, string> config = new Dictionary<string, string>(accountConfig);

            PlatformAPICallPreHandler platformHandler = new PlatformAPICallPreHandler(config, "payload", "servicename", "method", Constants.APIUserName, "accessToken", "tokenSecret");
            platformHandler.GetEndpoint();
        }
        public void GetEndpointForSandboxMode()
        {
            Dictionary<string, string> config = new Dictionary<string, string>(accountConfig);
            config.Add(BaseConstants.ApplicationModeConfig, BaseConstants.LiveMode);

            PlatformAPICallPreHandler platformHandler = new PlatformAPICallPreHandler(config, "payload", "servicename", "method", Constants.APIUserName, "accessToken", "tokenSecret");
            Assert.AreEqual(BaseConstants.PlatformLiveEndpoint + "servicename/method", platformHandler.GetEndpoint());
        }
        public void GetEndpointForSandboxMode()
        {
            Dictionary<string, string> config = new Dictionary<string, string>(accountConfig);
            config.Add(BaseConstants.APPLICATION_MODE_CONFIG, BaseConstants.LIVE_MODE);

            PlatformAPICallPreHandler platformHandler = new PlatformAPICallPreHandler(config, "payload", "servicename", "method", UnitTestConstants.APIUserName, "accessToken", "tokenSecret");
            Assert.AreEqual(BaseConstants.PLATFORM_LIVE_ENDPOINT + "servicename/method", platformHandler.GetEndPoint());
        }
 public void GetHeaderMapWithSignatureWithTokenTest()
 {
     platformAPIHandler = new PlatformAPICallPreHandler("payload", "servicename", "method", UnitTestConstants.APIUserName, "accessToken", "tokenSecret");
     Dictionary<string, string> header = platformAPIHandler.GetHeaderMap();
     string authHeader = header["X-PAYPAL-AUTHORIZATION"];
     string[] headers = authHeader.Split(',');
     Assert.AreEqual("token=accessToken", headers[0]);
 }
        /// <summary>
        /// 
        /// </summary>
        ///<param name="cancelPermissionsRequest"></param>
        ///<param name="apiUserName">API Username that you want to authenticate this call against. This username and the corresponding 3-token/certificate credentials must be available in Web.Config/App.Config</param>
        public CancelPermissionsResponse CancelPermissions(CancelPermissionsRequest cancelPermissionsRequest, string apiUserName)
        {
            IAPICallPreHandler apiCallPreHandler = new PlatformAPICallPreHandler(this.config, cancelPermissionsRequest.ToNVPString(string.Empty), ServiceName, "CancelPermissions", apiUserName, getAccessToken(), getAccessTokenSecret());
               	 	((PlatformAPICallPreHandler) apiCallPreHandler).SDKName = SDKName;
            ((PlatformAPICallPreHandler) apiCallPreHandler).SDKVersion = SDKVersion;
            ((PlatformAPICallPreHandler) apiCallPreHandler).PortName = "Permissions";

            NVPUtil util = new NVPUtil();
            return CancelPermissionsResponse.CreateInstance(util.ParseNVPString(Call(apiCallPreHandler)), string.Empty, -1);
        }
 public void GetPayloadEndpointWithoutTokenTest()
 {
     platformAPIHandler = new PlatformAPICallPreHandler("payload", "servicename", "method", UnitTestConstants.APIUserName, "accessToken", "tokenSecret");
     Assert.AreEqual("https://svcs.sandbox.paypal.com/servicename/method", platformAPIHandler.GetEndPoint());
     Assert.AreEqual("payload", platformAPIHandler.GetPayLoad());
     SignatureCredential signatureCredential = (SignatureCredential)platformAPIHandler.GetCredential();
     TokenAuthorization thirdAuth = (TokenAuthorization)signatureCredential.ThirdPartyAuthorization;
     Assert.AreEqual("accessToken", thirdAuth.AccessToken);
     Assert.AreEqual("tokenSecret", thirdAuth.TokenSecret);
 }
        /// <summary>
        /// 
        /// </summary>
        ///<param name="cancelInvoiceRequest"></param>
        ///<param name="credential">An explicit ICredential object that you want to authenticate this call against</param> 
        public CancelInvoiceResponse CancelInvoice(CancelInvoiceRequest cancelInvoiceRequest, ICredential credential)
        {
            IAPICallPreHandler apiCallPreHandler = new PlatformAPICallPreHandler(this.config, cancelInvoiceRequest.ToNVPString(string.Empty), ServiceName, "CancelInvoice", credential);
               	 	((PlatformAPICallPreHandler) apiCallPreHandler).SDKName = SDKName;
            ((PlatformAPICallPreHandler) apiCallPreHandler).SDKVersion = SDKVersion;
            ((PlatformAPICallPreHandler) apiCallPreHandler).PortName = "Invoice";

            NVPUtil util = new NVPUtil();
            return CancelInvoiceResponse.CreateInstance(util.ParseNVPString(Call(apiCallPreHandler)), string.Empty, -1);
        }
 /**
   *AUTO_GENERATED
  	  */
 public CancelPermissionsResponse CancelPermissions(CancelPermissionsRequest cancelPermissionsRequest, ICredential credential)
 {
     IAPICallPreHandler apiCallPreHandler = null;
     apiCallPreHandler = new PlatformAPICallPreHandler(cancelPermissionsRequest.ToNVPString(string.Empty), ServiceName, "CancelPermissions", credential);
        	 	((PlatformAPICallPreHandler) apiCallPreHandler).SDKName = SDKName;
     ((PlatformAPICallPreHandler) apiCallPreHandler).SDKVersion = SDKVersion;
     string response = Call(apiCallPreHandler);
     NVPUtil util = new NVPUtil();
     return CancelPermissionsResponse.CreateInstance(util.ParseNVPString(response), string.Empty, -1);
 }
 /**
   *AUTO_GENERATED
  	  */
 public GetAccessTokenResponse GetAccessToken(GetAccessTokenRequest getAccessTokenRequest, string apiUserName)
 {
     IAPICallPreHandler apiCallPreHandler = null;
     apiCallPreHandler = new PlatformAPICallPreHandler(getAccessTokenRequest.ToNVPString(string.Empty), ServiceName, "GetAccessToken", apiUserName, getAccessToken(), getAccessTokenSecret());
        	 	((PlatformAPICallPreHandler) apiCallPreHandler).SDKName = SDKName;
     ((PlatformAPICallPreHandler) apiCallPreHandler).SDKVersion = SDKVersion;
     string response = Call(apiCallPreHandler);
     NVPUtil util = new NVPUtil();
     return GetAccessTokenResponse.CreateInstance(util.ParseNVPString(response), string.Empty, -1);
 }
        /// <summary>
        /// Countries Supported:
        /// AU - Australia
        /// CA - Canada
        /// FR -
        /// France
        /// DE - Germany
        /// IL - Israel
        /// IT - Italy
        /// NL - Netherlands
        /// UK - United
        /// Kingdom
        /// US - United States
        /// 
        /// 
        /// 
        /// 
        /// 
        /// </summary>
        ///<param name="addBankAccountRequest"></param>
        ///<param name="apiUserName">API Username that you want to authenticate this call against. This username and the corresponding 3-token/certificate credentials must be available in Web.Config/App.Config</param>
        public AddBankAccountResponse AddBankAccount(AddBankAccountRequest addBankAccountRequest, string apiUserName)
        {
            IAPICallPreHandler apiCallPreHandler = new PlatformAPICallPreHandler(this.config, addBankAccountRequest.ToNVPString(string.Empty), ServiceName, "AddBankAccount", apiUserName, getAccessToken(), getAccessTokenSecret());
               	 	((PlatformAPICallPreHandler) apiCallPreHandler).SDKName = SDKName;
            ((PlatformAPICallPreHandler) apiCallPreHandler).SDKVersion = SDKVersion;
            ((PlatformAPICallPreHandler) apiCallPreHandler).PortName = "AdaptiveAccounts";

            NVPUtil util = new NVPUtil();
            return AddBankAccountResponse.CreateInstance(util.ParseNVPString(Call(apiCallPreHandler)), string.Empty, -1);
        }
 public void GetHeaderMapCertificateWithoutTokenTest()
 {
     credentialMngr = CredentialManager.Instance;
     credential = credentialMngr.GetCredentials(UnitTestConstants.CertificateAPIUserName);
     platformAPIHandler = new PlatformAPICallPreHandler("payload", "servicename", "method", credential);
     Dictionary<string, string> header = platformAPIHandler.GetHeaderMap();
     Assert.AreEqual(UnitTestConstants.CertificateAPIUserName, header[BaseConstants.PAYPAL_SECURITY_USERID_HEADER]);
     Assert.AreEqual(UnitTestConstants.CertificateAPIPassword, header[BaseConstants.PAYPAL_SECURITY_PASSWORD_HEADER]);
     Assert.AreEqual(UnitTestConstants.ApplicationID, header[BaseConstants.PAYPAL_APPLICATION_ID]);
     Assert.AreEqual(BaseConstants.NVP, header[BaseConstants.PAYPAL_REQUEST_DATA_FORMAT_HEADER]);
     Assert.AreEqual(BaseConstants.NVP, header[BaseConstants.PAYPAL_RESPONSE_DATA_FORMAT_HEADER]);
 }
        public void GetEndpointForDefaultModeWithExplicitEndpoint()
        {
            Dictionary<string, string> config = new Dictionary<string, string>(accountConfig);
            config.Add(BaseConstants.EndpointConfig, Constants.APIEndpointNVP);

            PlatformAPICallPreHandler platformHandler = new PlatformAPICallPreHandler(config, "payload", "servicename", "method", Constants.APIUserName, "accessToken", "tokenSecret");
            Assert.AreEqual(Constants.APIEndpointNVP + "servicename/method", platformHandler.GetEndpoint());

            config.Add("PayPalAPI", Constants.APIEndpointSOAP);
            platformHandler = new PlatformAPICallPreHandler(config, "payload", "servicename", "method", Constants.APIUserName, "accessToken", "tokenSecret");
            platformHandler.PortName = "PayPalAPI";
            Assert.AreEqual(Constants.APIEndpointSOAP + "/servicename/method", platformHandler.GetEndpoint());
        }
        /// <summary>
        /// Countries Supported:
        /// AU - Australia
        /// AT - Austria
        /// BE
        /// - Belgium
        /// BR - Brazil
        /// CA - Canada
        /// CZ - Czech Republic
        /// FR - France
        /// DE -
        /// Germany
        /// GR - Greece
        /// HK - Hong Kong
        /// IE - Ireland
        /// IT - Italy
        /// JP - Japan
        /// LU -
        /// Luxembourg
        /// MX - Mexico
        /// NL - Netherlands
        /// NZ - New Zealand (Aotearoa)
        /// PL -
        /// Poland
        /// PT - Portugal
        /// RU - Russian Federation
        /// SG - Singapore
        /// ZA - South
        /// Africa
        /// ES - Spain
        /// CH - Switzerland
        /// UK - United Kingdom
        /// US - United
        /// States
        /// 
        /// 
        /// 
        /// 
        /// 
        /// </summary>
        ///<param name="addPaymentCardRequest"></param>
        ///<param name="credential">An explicit ICredential object that you want to authenticate this call against</param> 
        public AddPaymentCardResponse AddPaymentCard(AddPaymentCardRequest addPaymentCardRequest, ICredential credential)
        {
            IAPICallPreHandler apiCallPreHandler = new PlatformAPICallPreHandler(this.config, addPaymentCardRequest.ToNVPString(string.Empty), ServiceName, "AddPaymentCard", credential);
               	 	((PlatformAPICallPreHandler) apiCallPreHandler).SDKName = SDKName;
            ((PlatformAPICallPreHandler) apiCallPreHandler).SDKVersion = SDKVersion;
            ((PlatformAPICallPreHandler) apiCallPreHandler).PortName = "AdaptiveAccounts";

            NVPUtil util = new NVPUtil();
            return AddPaymentCardResponse.CreateInstance(util.ParseNVPString(Call(apiCallPreHandler)), string.Empty, -1);
        }
 public void GetHeaderMapWithCertificateWithTokenTest()
 {
     platformAPIHandler = new PlatformAPICallPreHandler(ConfigManager.Instance.GetProperties(), "payload", "servicename", "method", Constants.CertificateAPIUserName, "accessToken", "tokenSecret");
     Dictionary<string, string> header = platformAPIHandler.GetHeaderMap();
     string authHeader = header[BaseConstants.PayPalAuthorizationPlatformHeader];
     string[] headers = authHeader.Split(',');
     Assert.AreEqual("token=accessToken", headers[0]);
 }
 /**
   *AUTO_GENERATED
  	  */
 public GetBasicPersonalDataResponse GetBasicPersonalData(GetBasicPersonalDataRequest getBasicPersonalDataRequest, ICredential credential)
 {
     IAPICallPreHandler apiCallPreHandler = null;
     apiCallPreHandler = new PlatformAPICallPreHandler(getBasicPersonalDataRequest.ToNVPString(string.Empty), ServiceName, "GetBasicPersonalData", credential);
        	 	((PlatformAPICallPreHandler) apiCallPreHandler).SDKName = SDKName;
     ((PlatformAPICallPreHandler) apiCallPreHandler).SDKVersion = SDKVersion;
     string response = Call(apiCallPreHandler);
     NVPUtil util = new NVPUtil();
     return GetBasicPersonalDataResponse.CreateInstance(util.ParseNVPString(response), string.Empty, -1);
 }
	 	/// <summary>
		/// 
	 	/// </summary>
		///<param name="getPrePaymentDisclosureRequest"></param>
		///<param name="credential">An explicit ICredential object that you want to authenticate this call against</param> 
	 	public GetPrePaymentDisclosureResponse GetPrePaymentDisclosure(GetPrePaymentDisclosureRequest getPrePaymentDisclosureRequest, ICredential credential)
	 	{	 			 		
			IAPICallPreHandler apiCallPreHandler = new PlatformAPICallPreHandler(this.config, getPrePaymentDisclosureRequest.ToNVPString(string.Empty), ServiceName, "GetPrePaymentDisclosure", credential);
	   	 	((PlatformAPICallPreHandler) apiCallPreHandler).SDKName = SDKName;
			((PlatformAPICallPreHandler) apiCallPreHandler).SDKVersion = SDKVersion;
			((PlatformAPICallPreHandler) apiCallPreHandler).PortName = "AdaptivePayments";

			NVPUtil util = new NVPUtil();
			return GetPrePaymentDisclosureResponse.CreateInstance(util.ParseNVPString(Call(apiCallPreHandler)), string.Empty, -1);
			
	 	}
		/// <summary>
		/// 
	 	/// </summary>
		///<param name="getAvailableShippingAddressesRequest"></param>
		///<param name="apiUserName">API Username that you want to authenticate this call against. This username and the corresponding 3-token/certificate credentials must be available in Web.Config/App.Config</param>
	 	public GetAvailableShippingAddressesResponse GetAvailableShippingAddresses(GetAvailableShippingAddressesRequest getAvailableShippingAddressesRequest, string apiUserName)
	 	{	 		
			IAPICallPreHandler apiCallPreHandler = new PlatformAPICallPreHandler(this.config, getAvailableShippingAddressesRequest.ToNVPString(string.Empty), ServiceName, "GetAvailableShippingAddresses", apiUserName, getAccessToken(), getAccessTokenSecret());
	   	 	((PlatformAPICallPreHandler) apiCallPreHandler).SDKName = SDKName;
			((PlatformAPICallPreHandler) apiCallPreHandler).SDKVersion = SDKVersion;
			((PlatformAPICallPreHandler) apiCallPreHandler).PortName = "AdaptivePayments";
			
			NVPUtil util = new NVPUtil();
			return GetAvailableShippingAddressesResponse.CreateInstance(util.ParseNVPString(Call(apiCallPreHandler)), string.Empty, -1);
			
	 	}
 /**
   *AUTO_GENERATED
  	  */
 public UpdateInvoiceResponse UpdateInvoice(UpdateInvoiceRequest updateInvoiceRequest, ICredential credential)
 {
     IAPICallPreHandler apiCallPreHandler = null;
     apiCallPreHandler = new PlatformAPICallPreHandler(updateInvoiceRequest.ToNVPString(string.Empty), ServiceName, "UpdateInvoice", credential);
        	 	((PlatformAPICallPreHandler) apiCallPreHandler).SDKName = SDKName;
     ((PlatformAPICallPreHandler) apiCallPreHandler).SDKVersion = SDKVersion;
     string response = Call(apiCallPreHandler);
     NVPUtil util = new NVPUtil();
     return UpdateInvoiceResponse.CreateInstance(util.ParseNVPString(response), string.Empty, -1);
 }
        /// <summary>
        /// 
        /// </summary>
        ///<param name="updateInvoiceRequest"></param>
        ///<param name="apiUserName">API Username that you want to authenticate this call against. This username and the corresponding 3-token/certificate credentials must be available in Web.Config/App.Config</param>
        public UpdateInvoiceResponse UpdateInvoice(UpdateInvoiceRequest updateInvoiceRequest, string apiUserName)
        {
            IAPICallPreHandler apiCallPreHandler = new PlatformAPICallPreHandler(this.config, updateInvoiceRequest.ToNVPString(string.Empty), ServiceName, "UpdateInvoice", apiUserName, getAccessToken(), getAccessTokenSecret());
               	 	((PlatformAPICallPreHandler) apiCallPreHandler).SDKName = SDKName;
            ((PlatformAPICallPreHandler) apiCallPreHandler).SDKVersion = SDKVersion;
            ((PlatformAPICallPreHandler) apiCallPreHandler).PortName = "Invoice";

            NVPUtil util = new NVPUtil();
            return UpdateInvoiceResponse.CreateInstance(util.ParseNVPString(Call(apiCallPreHandler)), string.Empty, -1);
        }
        /// <summary>
        /// To be updated.
        /// Countries Supported:
        /// US - United
        /// States
        /// JP - Japan
        /// 
        /// 
        /// 
        /// 
        /// 
        /// </summary>
        ///<param name="checkComplianceCapabilityStatusRequest"></param>
        ///<param name="apiUserName">API Username that you want to authenticate this call against. This username and the corresponding 3-token/certificate credentials must be available in Web.Config/App.Config</param>
        public CheckComplianceCapabilityStatusResponse CheckComplianceCapabilityStatus(CheckComplianceCapabilityStatusRequest checkComplianceCapabilityStatusRequest, string apiUserName)
        {
            IAPICallPreHandler apiCallPreHandler = new PlatformAPICallPreHandler(this.config, checkComplianceCapabilityStatusRequest.ToNVPString(string.Empty), ServiceName, "CheckComplianceCapabilityStatus", apiUserName, getAccessToken(), getAccessTokenSecret());
               	 	((PlatformAPICallPreHandler) apiCallPreHandler).SDKName = SDKName;
            ((PlatformAPICallPreHandler) apiCallPreHandler).SDKVersion = SDKVersion;
            ((PlatformAPICallPreHandler) apiCallPreHandler).PortName = "AdaptiveAccounts";

            NVPUtil util = new NVPUtil();
            return CheckComplianceCapabilityStatusResponse.CreateInstance(util.ParseNVPString(Call(apiCallPreHandler)), string.Empty, -1);
        }
        /// <summary>
        /// To be updated.
        /// Countries Supported:
        /// AU - Australia
        /// AT - Austria
        /// BE - Belgium
        /// BR - Brazil
        /// CA - Canada
        /// CZ - Czech Republic
        /// FR
        /// - France
        /// DE - Germany
        /// GR - Greece
        /// HK - Hong Kong
        /// IE - Ireland
        /// IT - Italy
        /// JP - Japan
        /// LU - Luxembourg
        /// MX - Mexico
        /// NL - Netherlands
        /// NZ - New Zealand
        /// (Aotearoa)
        /// PL - Poland
        /// PT - Portugal
        /// RU - Russian Federation
        /// SG -
        /// Singapore
        /// ZA - South Africa
        /// ES - Spain
        /// CH - Switzerland
        /// UK - United
        /// Kingdom
        /// US - United States
        /// 
        /// 
        /// 
        /// 
        /// 
        /// </summary>
        ///<param name="setFundingSourceConfirmedRequest"></param>
        ///<param name="credential">An explicit ICredential object that you want to authenticate this call against</param> 
        public SetFundingSourceConfirmedResponse SetFundingSourceConfirmed(SetFundingSourceConfirmedRequest setFundingSourceConfirmedRequest, ICredential credential)
        {
            IAPICallPreHandler apiCallPreHandler = new PlatformAPICallPreHandler(this.config, setFundingSourceConfirmedRequest.ToNVPString(string.Empty), ServiceName, "SetFundingSourceConfirmed", credential);
               	 	((PlatformAPICallPreHandler) apiCallPreHandler).SDKName = SDKName;
            ((PlatformAPICallPreHandler) apiCallPreHandler).SDKVersion = SDKVersion;
            ((PlatformAPICallPreHandler) apiCallPreHandler).PortName = "AdaptiveAccounts";

            NVPUtil util = new NVPUtil();
            return SetFundingSourceConfirmedResponse.CreateInstance(util.ParseNVPString(Call(apiCallPreHandler)), string.Empty, -1);
        }
        /// <summary>
        /// 
        /// </summary>
        ///<param name="requestPermissionsRequest"></param>
        ///<param name="credential">An explicit ICredential object that you want to authenticate this call against</param> 
        public RequestPermissionsResponse RequestPermissions(RequestPermissionsRequest requestPermissionsRequest, ICredential credential)
        {
            IAPICallPreHandler apiCallPreHandler = new PlatformAPICallPreHandler(this.config, requestPermissionsRequest.ToNVPString(string.Empty), ServiceName, "RequestPermissions", credential);
               	 	((PlatformAPICallPreHandler) apiCallPreHandler).SDKName = SDKName;
            ((PlatformAPICallPreHandler) apiCallPreHandler).SDKVersion = SDKVersion;
            ((PlatformAPICallPreHandler) apiCallPreHandler).PortName = "Permissions";

            NVPUtil util = new NVPUtil();
            return RequestPermissionsResponse.CreateInstance(util.ParseNVPString(Call(apiCallPreHandler)), string.Empty, -1);
        }
		/// <summary>
		/// 
	 	/// </summary>
		///<param name="confirmPreapprovalRequest"></param>
		///<param name="apiUserName">API Username that you want to authenticate this call against. This username and the corresponding 3-token/certificate credentials must be available in Web.Config/App.Config</param>
	 	public ConfirmPreapprovalResponse ConfirmPreapproval(ConfirmPreapprovalRequest confirmPreapprovalRequest, string apiUserName)
	 	{	 		
			IAPICallPreHandler apiCallPreHandler = new PlatformAPICallPreHandler(this.config, confirmPreapprovalRequest.ToNVPString(string.Empty), ServiceName, "ConfirmPreapproval", apiUserName, getAccessToken(), getAccessTokenSecret());
	   	 	((PlatformAPICallPreHandler) apiCallPreHandler).SDKName = SDKName;
			((PlatformAPICallPreHandler) apiCallPreHandler).SDKVersion = SDKVersion;
			((PlatformAPICallPreHandler) apiCallPreHandler).PortName = "AdaptivePayments";
			
			NVPUtil util = new NVPUtil();
			return ConfirmPreapprovalResponse.CreateInstance(util.ParseNVPString(Call(apiCallPreHandler)), string.Empty, -1);
			
	 	}
 public void GetHeaderMapCertificateWithoutTokenTest()
 {
     credentialMngr = CredentialManager.Instance;
     credential = credentialMngr.GetCredentials(ConfigManager.Instance.GetProperties(), Constants.CertificateAPIUserName);
     platformAPIHandler = new PlatformAPICallPreHandler(ConfigManager.Instance.GetProperties(), "payload", "servicename", "method", credential);
     Dictionary<string, string> header = platformAPIHandler.GetHeaderMap();
     Assert.AreEqual(Constants.CertificateAPIUserName, header[BaseConstants.PayPalSecurityUserIdHeader]);
     Assert.AreEqual(Constants.CertificateAPIPassword, header[BaseConstants.PayPalSecurityPasswordHeader]);
     Assert.AreEqual(Constants.ApplicationId, header[BaseConstants.PayPalApplicationIdHeader]);
     Assert.AreEqual(BaseConstants.NVP, header[BaseConstants.PayPalRequestDataFormatHeader]);
     Assert.AreEqual(BaseConstants.NVP, header[BaseConstants.PayPalResponseDataFormatHeader]);
 }
        /// <summary>
        /// To be updated.
        /// Countries Supported:
        /// US - United
        /// States
        /// 
        /// 
        /// 
        /// 
        /// 
        /// </summary>
        ///<param name="checkComplianceStatusRequest"></param>
        ///<param name="credential">An explicit ICredential object that you want to authenticate this call against</param> 
        public CheckComplianceStatusResponse CheckComplianceStatus(CheckComplianceStatusRequest checkComplianceStatusRequest, ICredential credential)
        {
            IAPICallPreHandler apiCallPreHandler = new PlatformAPICallPreHandler(this.config, checkComplianceStatusRequest.ToNVPString(string.Empty), ServiceName, "CheckComplianceStatus", credential);
               	 	((PlatformAPICallPreHandler) apiCallPreHandler).SDKName = SDKName;
            ((PlatformAPICallPreHandler) apiCallPreHandler).SDKVersion = SDKVersion;
            ((PlatformAPICallPreHandler) apiCallPreHandler).PortName = "AdaptiveAccounts";

            NVPUtil util = new NVPUtil();
            return CheckComplianceStatusResponse.CreateInstance(util.ParseNVPString(Call(apiCallPreHandler)), string.Empty, -1);
        }
	 	/// <summary>
		/// 
	 	/// </summary>
		///<param name="preapprovalRequest"></param>
		///<param name="credential">An explicit ICredential object that you want to authenticate this call against</param> 
	 	public PreapprovalResponse Preapproval(PreapprovalRequest preapprovalRequest, ICredential credential)
	 	{	 			 		
			IAPICallPreHandler apiCallPreHandler = new PlatformAPICallPreHandler(this.config, preapprovalRequest.ToNVPString(string.Empty), ServiceName, "Preapproval", credential);
	   	 	((PlatformAPICallPreHandler) apiCallPreHandler).SDKName = SDKName;
			((PlatformAPICallPreHandler) apiCallPreHandler).SDKVersion = SDKVersion;
			((PlatformAPICallPreHandler) apiCallPreHandler).PortName = "AdaptivePayments";

			NVPUtil util = new NVPUtil();
			return PreapprovalResponse.CreateInstance(util.ParseNVPString(Call(apiCallPreHandler)), string.Empty, -1);
			
	 	}
 /**
   *AUTO_GENERATED
  	  */
 public MarkInvoiceAsRefundedResponse MarkInvoiceAsRefunded(MarkInvoiceAsRefundedRequest markInvoiceAsRefundedRequest, ICredential credential)
 {
     IAPICallPreHandler apiCallPreHandler = null;
     apiCallPreHandler = new PlatformAPICallPreHandler(markInvoiceAsRefundedRequest.ToNVPString(string.Empty), ServiceName, "MarkInvoiceAsRefunded", credential);
        	 	((PlatformAPICallPreHandler) apiCallPreHandler).SDKName = SDKName;
     ((PlatformAPICallPreHandler) apiCallPreHandler).SDKVersion = SDKVersion;
     string response = Call(apiCallPreHandler);
     NVPUtil util = new NVPUtil();
     return MarkInvoiceAsRefundedResponse.CreateInstance(util.ParseNVPString(response), string.Empty, -1);
 }