public static RiskV1UpdatePost201Response Run() { string id = "5825489395116729903003"; string riskInformationMarkingDetailsNotes = "Adding this transaction as suspect"; string riskInformationMarkingDetailsReason = "suspected"; List <string> riskInformationMarkingDetailsFieldsIncluded = new List <string>(); riskInformationMarkingDetailsFieldsIncluded.Add("customer_email"); riskInformationMarkingDetailsFieldsIncluded.Add("customer_phone"); string riskInformationMarkingDetailsAction = "add"; Riskv1decisionsidmarkingRiskInformationMarkingDetails riskInformationMarkingDetails = new Riskv1decisionsidmarkingRiskInformationMarkingDetails( Notes: riskInformationMarkingDetailsNotes, Reason: riskInformationMarkingDetailsReason, FieldsIncluded: riskInformationMarkingDetailsFieldsIncluded, Action: riskInformationMarkingDetailsAction ); Riskv1decisionsidmarkingRiskInformation riskInformation = new Riskv1decisionsidmarkingRiskInformation( MarkingDetails: riskInformationMarkingDetails ); string clientReferenceInformationCode = "12345"; string clientReferenceInformationPartnerDeveloperId = "1234"; string clientReferenceInformationPartnerSolutionId = "3321"; Riskv1decisionsClientReferenceInformationPartner clientReferenceInformationPartner = new Riskv1decisionsClientReferenceInformationPartner( DeveloperId: clientReferenceInformationPartnerDeveloperId, SolutionId: clientReferenceInformationPartnerSolutionId ); Riskv1liststypeentriesClientReferenceInformation clientReferenceInformation = new Riskv1liststypeentriesClientReferenceInformation( Code: clientReferenceInformationCode, Partner: clientReferenceInformationPartner ); var requestObj = new FraudMarkingActionRequest( RiskInformation: riskInformation, ClientReferenceInformation: clientReferenceInformation ); try { var configDictionary = new Configuration().GetConfiguration(); var clientConfig = new CyberSource.Client.Configuration(merchConfigDictObj: configDictionary); var apiInstance = new DecisionManagerApi(clientConfig); RiskV1UpdatePost201Response result = apiInstance.FraudUpdate(id, requestObj); Console.WriteLine(result); return(result); } catch (Exception e) { Console.WriteLine("Exception on calling the API : " + e.Message); return(null); } }
public static RiskV1AddressVerificationsPost201Response Run() { string clientReferenceInformationCode = "addressEg"; string clientReferenceInformationComments = "dav-error response check"; Riskv1liststypeentriesClientReferenceInformation clientReferenceInformation = new Riskv1liststypeentriesClientReferenceInformation( Code: clientReferenceInformationCode, Comments: clientReferenceInformationComments ); string orderInformationBillToAddress1 = "Apt C "; string orderInformationBillToAddress2 = ""; string orderInformationBillToAdministrativeArea = "CA"; string orderInformationBillToCountry = "US"; string orderInformationBillToLocality = "Glendale"; string orderInformationBillToPostalCode = "91204"; Riskv1addressverificationsOrderInformationBillTo orderInformationBillTo = new Riskv1addressverificationsOrderInformationBillTo( Address1: orderInformationBillToAddress1, Address2: orderInformationBillToAddress2, AdministrativeArea: orderInformationBillToAdministrativeArea, Country: orderInformationBillToCountry, Locality: orderInformationBillToLocality, PostalCode: orderInformationBillToPostalCode ); Riskv1addressverificationsOrderInformation orderInformation = new Riskv1addressverificationsOrderInformation( BillTo: orderInformationBillTo ); var requestObj = new VerifyCustomerAddressRequest( ClientReferenceInformation: clientReferenceInformation, OrderInformation: orderInformation ); try { var configDictionary = new Configuration().GetConfiguration(); var clientConfig = new CyberSource.Client.Configuration(merchConfigDictObj: configDictionary); var apiInstance = new VerificationApi(clientConfig); RiskV1AddressVerificationsPost201Response result = apiInstance.VerifyCustomerAddress(requestObj); Console.WriteLine(result); return(result); } catch (Exception e) { Console.WriteLine("Exception on calling the API : " + e.Message); return(null); } }
public static RiskV1UpdatePost201Response Run() { string type = "negative"; string orderInformationAddressAddress1 = "1234 Sample St."; string orderInformationAddressAddress2 = "Mountain View"; string orderInformationAddressLocality = "California"; string orderInformationAddressCountry = "US"; string orderInformationAddressAdministrativeArea = "CA"; string orderInformationAddressPostalCode = "94043"; Riskv1liststypeentriesOrderInformationAddress orderInformationAddress = new Riskv1liststypeentriesOrderInformationAddress( Address1: orderInformationAddressAddress1, Address2: orderInformationAddressAddress2, Locality: orderInformationAddressLocality, Country: orderInformationAddressCountry, AdministrativeArea: orderInformationAddressAdministrativeArea, PostalCode: orderInformationAddressPostalCode ); string orderInformationBillToFirstName = "John"; string orderInformationBillToLastName = "Doe"; string orderInformationBillToEmail = "*****@*****.**"; Riskv1liststypeentriesOrderInformationBillTo orderInformationBillTo = new Riskv1liststypeentriesOrderInformationBillTo( FirstName: orderInformationBillToFirstName, LastName: orderInformationBillToLastName, Email: orderInformationBillToEmail ); Riskv1liststypeentriesOrderInformation orderInformation = new Riskv1liststypeentriesOrderInformation( Address: orderInformationAddress, BillTo: orderInformationBillTo ); Riskv1liststypeentriesPaymentInformation paymentInformation = new Riskv1liststypeentriesPaymentInformation( ); string clientReferenceInformationCode = "54323007"; string clientReferenceInformationPartnerDeveloperId = "7891234"; string clientReferenceInformationPartnerSolutionId = "89012345"; Riskv1decisionsClientReferenceInformationPartner clientReferenceInformationPartner = new Riskv1decisionsClientReferenceInformationPartner( DeveloperId: clientReferenceInformationPartnerDeveloperId, SolutionId: clientReferenceInformationPartnerSolutionId ); Riskv1liststypeentriesClientReferenceInformation clientReferenceInformation = new Riskv1liststypeentriesClientReferenceInformation( Code: clientReferenceInformationCode, Partner: clientReferenceInformationPartner ); string riskInformationMarkingDetailsAction = "add"; Riskv1liststypeentriesRiskInformationMarkingDetails riskInformationMarkingDetails = new Riskv1liststypeentriesRiskInformationMarkingDetails( Action: riskInformationMarkingDetailsAction ); Riskv1liststypeentriesRiskInformation riskInformation = new Riskv1liststypeentriesRiskInformation( MarkingDetails: riskInformationMarkingDetails ); var requestObj = new AddNegativeListRequest( OrderInformation: orderInformation, PaymentInformation: paymentInformation, ClientReferenceInformation: clientReferenceInformation, RiskInformation: riskInformation ); try { var configDictionary = new Configuration().GetConfiguration(); var clientConfig = new CyberSource.Client.Configuration(merchConfigDictObj: configDictionary); var apiInstance = new DecisionManagerApi(clientConfig); RiskV1UpdatePost201Response result = apiInstance.AddNegative(type, requestObj); Console.WriteLine(result); return(result); } catch (Exception e) { Console.WriteLine("Exception on calling the API : " + e.Message); return(null); } }
public static RiskV1AddressVerificationsPost201Response Run() { string clientReferenceInformationCode = "addressEg"; string clientReferenceInformationComments = "dav-All fields"; string clientReferenceInformationPartnerDeveloperId = "7891234"; string clientReferenceInformationPartnerSolutionId = "89012345"; Riskv1decisionsClientReferenceInformationPartner clientReferenceInformationPartner = new Riskv1decisionsClientReferenceInformationPartner( DeveloperId: clientReferenceInformationPartnerDeveloperId, SolutionId: clientReferenceInformationPartnerSolutionId ); Riskv1liststypeentriesClientReferenceInformation clientReferenceInformation = new Riskv1liststypeentriesClientReferenceInformation( Code: clientReferenceInformationCode, Comments: clientReferenceInformationComments, Partner: clientReferenceInformationPartner ); string orderInformationBillToAddress1 = "12301 research st"; string orderInformationBillToAddress2 = "1"; string orderInformationBillToAddress3 = "2"; string orderInformationBillToAddress4 = "3"; string orderInformationBillToAdministrativeArea = "TX"; string orderInformationBillToCountry = "US"; string orderInformationBillToLocality = "Austin"; string orderInformationBillToPostalCode = "78759"; Riskv1addressverificationsOrderInformationBillTo orderInformationBillTo = new Riskv1addressverificationsOrderInformationBillTo( Address1: orderInformationBillToAddress1, Address2: orderInformationBillToAddress2, Address3: orderInformationBillToAddress3, Address4: orderInformationBillToAddress4, AdministrativeArea: orderInformationBillToAdministrativeArea, Country: orderInformationBillToCountry, Locality: orderInformationBillToLocality, PostalCode: orderInformationBillToPostalCode ); string orderInformationShipToAddress1 = "1715 oaks apt # 7"; string orderInformationShipToAddress2 = " "; string orderInformationShipToAddress3 = ""; string orderInformationShipToAddress4 = ""; string orderInformationShipToAdministrativeArea = "WI"; string orderInformationShipToCountry = "US"; string orderInformationShipToLocality = "SUPERIOR"; string orderInformationShipToPostalCode = "29681"; Riskv1addressverificationsOrderInformationShipTo orderInformationShipTo = new Riskv1addressverificationsOrderInformationShipTo( Address1: orderInformationShipToAddress1, Address2: orderInformationShipToAddress2, Address3: orderInformationShipToAddress3, Address4: orderInformationShipToAddress4, AdministrativeArea: orderInformationShipToAdministrativeArea, Country: orderInformationShipToCountry, Locality: orderInformationShipToLocality, PostalCode: orderInformationShipToPostalCode ); List <Riskv1addressverificationsOrderInformationLineItems> orderInformationLineItems = new List <Riskv1addressverificationsOrderInformationLineItems>(); string orderInformationLineItemsUnitPrice1 = "120.50"; int orderInformationLineItemsQuantity1 = 3; string orderInformationLineItemsProductSKU1 = "9966223"; string orderInformationLineItemsProductName1 = "headset"; string orderInformationLineItemsProductCode1 = "electronic"; orderInformationLineItems.Add(new Riskv1addressverificationsOrderInformationLineItems( UnitPrice: orderInformationLineItemsUnitPrice1, Quantity: orderInformationLineItemsQuantity1, ProductSKU: orderInformationLineItemsProductSKU1, ProductName: orderInformationLineItemsProductName1, ProductCode: orderInformationLineItemsProductCode1 )); Riskv1addressverificationsOrderInformation orderInformation = new Riskv1addressverificationsOrderInformation( BillTo: orderInformationBillTo, ShipTo: orderInformationShipTo, LineItems: orderInformationLineItems ); string buyerInformationMerchantCustomerId = "ABCD"; Riskv1addressverificationsBuyerInformation buyerInformation = new Riskv1addressverificationsBuyerInformation( MerchantCustomerId: buyerInformationMerchantCustomerId ); var requestObj = new VerifyCustomerAddressRequest( ClientReferenceInformation: clientReferenceInformation, OrderInformation: orderInformation, BuyerInformation: buyerInformation ); try { var configDictionary = new Configuration().GetConfiguration(); var clientConfig = new CyberSource.Client.Configuration(merchConfigDictObj: configDictionary); var apiInstance = new VerificationApi(clientConfig); RiskV1AddressVerificationsPost201Response result = apiInstance.VerifyCustomerAddress(requestObj); Console.WriteLine(result); return(result); } catch (Exception e) { Console.WriteLine("Exception on calling the API : " + e.Message); return(null); } }
public static RiskV1AddressVerificationsPost201Response Run() { string clientReferenceInformationCode = "addressEg"; string clientReferenceInformationComments = "dav-All fields"; Riskv1liststypeentriesClientReferenceInformation clientReferenceInformation = new Riskv1liststypeentriesClientReferenceInformation( Code: clientReferenceInformationCode, Comments: clientReferenceInformationComments ); string orderInformationBillToAddress1 = "1650 Burton Ave"; string orderInformationBillToAddress2 = ""; string orderInformationBillToAddress3 = ""; string orderInformationBillToAddress4 = ""; string orderInformationBillToAdministrativeArea = "BC"; string orderInformationBillToCountry = "CA"; string orderInformationBillToLocality = "VICTORIA"; string orderInformationBillToPostalCode = "V8T 2N6"; Riskv1addressverificationsOrderInformationBillTo orderInformationBillTo = new Riskv1addressverificationsOrderInformationBillTo( Address1: orderInformationBillToAddress1, Address2: orderInformationBillToAddress2, Address3: orderInformationBillToAddress3, Address4: orderInformationBillToAddress4, AdministrativeArea: orderInformationBillToAdministrativeArea, Country: orderInformationBillToCountry, Locality: orderInformationBillToLocality, PostalCode: orderInformationBillToPostalCode ); List <Riskv1addressverificationsOrderInformationLineItems> orderInformationLineItems = new List <Riskv1addressverificationsOrderInformationLineItems>(); string orderInformationLineItemsUnitPrice1 = "120.50"; int orderInformationLineItemsQuantity1 = 3; string orderInformationLineItemsProductSKU1 = "9966223"; string orderInformationLineItemsProductName1 = "headset"; string orderInformationLineItemsProductCode1 = "electronic"; orderInformationLineItems.Add(new Riskv1addressverificationsOrderInformationLineItems( UnitPrice: orderInformationLineItemsUnitPrice1, Quantity: orderInformationLineItemsQuantity1, ProductSKU: orderInformationLineItemsProductSKU1, ProductName: orderInformationLineItemsProductName1, ProductCode: orderInformationLineItemsProductCode1 )); Riskv1addressverificationsOrderInformation orderInformation = new Riskv1addressverificationsOrderInformation( BillTo: orderInformationBillTo, LineItems: orderInformationLineItems ); string buyerInformationMerchantCustomerId = "ABCD"; Riskv1addressverificationsBuyerInformation buyerInformation = new Riskv1addressverificationsBuyerInformation( MerchantCustomerId: buyerInformationMerchantCustomerId ); var requestObj = new VerifyCustomerAddressRequest( ClientReferenceInformation: clientReferenceInformation, OrderInformation: orderInformation, BuyerInformation: buyerInformation ); try { var configDictionary = new Configuration().GetConfiguration(); var clientConfig = new CyberSource.Client.Configuration(merchConfigDictObj: configDictionary); var apiInstance = new VerificationApi(clientConfig); RiskV1AddressVerificationsPost201Response result = apiInstance.VerifyCustomerAddress(requestObj); Console.WriteLine(result); return(result); } catch (Exception e) { Console.WriteLine("Exception on calling the API : " + e.Message); return(null); } }
public static RiskV1ExportComplianceInquiriesPost201Response Run() { string clientReferenceInformationCode = "verification example"; string clientReferenceInformationComments = "All fields"; Riskv1liststypeentriesClientReferenceInformation clientReferenceInformation = new Riskv1liststypeentriesClientReferenceInformation( Code: clientReferenceInformationCode, Comments: clientReferenceInformationComments ); string orderInformationBillToAddress1 = "901 Metro Centre Blvd"; string orderInformationBillToAddress2 = " "; string orderInformationBillToAddress3 = ""; string orderInformationBillToAddress4 = "Foster City"; string orderInformationBillToAdministrativeArea = "NH"; string orderInformationBillToCountry = "US"; string orderInformationBillToLocality = "CA"; string orderInformationBillToPostalCode = "03055"; string orderInformationBillToCompanyName = "A & C International Trade, Inc."; Riskv1exportcomplianceinquiriesOrderInformationBillToCompany orderInformationBillToCompany = new Riskv1exportcomplianceinquiriesOrderInformationBillToCompany( Name: orderInformationBillToCompanyName ); string orderInformationBillToFirstName = "Suman"; string orderInformationBillToLastName = "Kumar"; string orderInformationBillToEmail = "*****@*****.**"; Riskv1exportcomplianceinquiriesOrderInformationBillTo orderInformationBillTo = new Riskv1exportcomplianceinquiriesOrderInformationBillTo( Address1: orderInformationBillToAddress1, Address2: orderInformationBillToAddress2, Address3: orderInformationBillToAddress3, Address4: orderInformationBillToAddress4, AdministrativeArea: orderInformationBillToAdministrativeArea, Country: orderInformationBillToCountry, Locality: orderInformationBillToLocality, PostalCode: orderInformationBillToPostalCode, Company: orderInformationBillToCompany, FirstName: orderInformationBillToFirstName, LastName: orderInformationBillToLastName, Email: orderInformationBillToEmail ); string orderInformationShipToCountry = "IN"; string orderInformationShipToFirstName = "DumbelDore"; string orderInformationShipToLastName = "Albus"; Riskv1exportcomplianceinquiriesOrderInformationShipTo orderInformationShipTo = new Riskv1exportcomplianceinquiriesOrderInformationShipTo( Country: orderInformationShipToCountry, FirstName: orderInformationShipToFirstName, LastName: orderInformationShipToLastName ); List <Riskv1exportcomplianceinquiriesOrderInformationLineItems> orderInformationLineItems = new List <Riskv1exportcomplianceinquiriesOrderInformationLineItems>(); string orderInformationLineItemsUnitPrice1 = "120.50"; int orderInformationLineItemsQuantity1 = 3; string orderInformationLineItemsProductSKU1 = "610009"; string orderInformationLineItemsProductName1 = "Xer"; string orderInformationLineItemsProductCode1 = "physical_software"; orderInformationLineItems.Add(new Riskv1exportcomplianceinquiriesOrderInformationLineItems( UnitPrice: orderInformationLineItemsUnitPrice1, Quantity: orderInformationLineItemsQuantity1, ProductSKU: orderInformationLineItemsProductSKU1, ProductName: orderInformationLineItemsProductName1, ProductCode: orderInformationLineItemsProductCode1 )); Riskv1exportcomplianceinquiriesOrderInformation orderInformation = new Riskv1exportcomplianceinquiriesOrderInformation( BillTo: orderInformationBillTo, ShipTo: orderInformationShipTo, LineItems: orderInformationLineItems ); string buyerInformationMerchantCustomerId = "Export1"; Riskv1addressverificationsBuyerInformation buyerInformation = new Riskv1addressverificationsBuyerInformation( MerchantCustomerId: buyerInformationMerchantCustomerId ); string deviceInformationIpAddress = "127.0.0.1"; string deviceInformationHostName = "www.cybersource.ir"; Riskv1exportcomplianceinquiriesDeviceInformation deviceInformation = new Riskv1exportcomplianceinquiriesDeviceInformation( IpAddress: deviceInformationIpAddress, HostName: deviceInformationHostName ); string exportComplianceInformationAddressOperator = "and"; string exportComplianceInformationWeightsAddress = "low"; string exportComplianceInformationWeightsCompany = "exact"; string exportComplianceInformationWeightsName = "exact"; Riskv1exportcomplianceinquiriesExportComplianceInformationWeights exportComplianceInformationWeights = new Riskv1exportcomplianceinquiriesExportComplianceInformationWeights( Address: exportComplianceInformationWeightsAddress, Company: exportComplianceInformationWeightsCompany, Name: exportComplianceInformationWeightsName ); List <string> exportComplianceInformationSanctionLists = new List <string>(); exportComplianceInformationSanctionLists.Add("Bureau Of Industry and Security"); exportComplianceInformationSanctionLists.Add("DOS_DTC"); exportComplianceInformationSanctionLists.Add("AUSTRALIA"); Riskv1exportcomplianceinquiriesExportComplianceInformation exportComplianceInformation = new Riskv1exportcomplianceinquiriesExportComplianceInformation( AddressOperator: exportComplianceInformationAddressOperator, Weights: exportComplianceInformationWeights, SanctionLists: exportComplianceInformationSanctionLists ); var requestObj = new ValidateExportComplianceRequest( ClientReferenceInformation: clientReferenceInformation, OrderInformation: orderInformation, BuyerInformation: buyerInformation, DeviceInformation: deviceInformation, ExportComplianceInformation: exportComplianceInformation ); try { var configDictionary = new Configuration().GetConfiguration(); var clientConfig = new CyberSource.Client.Configuration(merchConfigDictObj: configDictionary); var apiInstance = new VerificationApi(clientConfig); RiskV1ExportComplianceInquiriesPost201Response result = apiInstance.ValidateExportCompliance(requestObj); Console.WriteLine(result); return(result); } catch (Exception e) { Console.WriteLine("Exception on calling the API : " + e.Message); return(null); } }
public static RiskV1ExportComplianceInquiriesPost201Response Run() { string clientReferenceInformationCode = "verification example"; Riskv1liststypeentriesClientReferenceInformation clientReferenceInformation = new Riskv1liststypeentriesClientReferenceInformation( Code: clientReferenceInformationCode ); string orderInformationBillToAddress1 = "901 Metro Centre Blvd"; string orderInformationBillToAddress2 = "2"; string orderInformationBillToAdministrativeArea = "CA"; string orderInformationBillToCountry = "US"; string orderInformationBillToLocality = "Foster City"; string orderInformationBillToPostalCode = "94404"; string orderInformationBillToFirstName = "Suman"; string orderInformationBillToLastName = "Kumar"; string orderInformationBillToEmail = "*****@*****.**"; Riskv1exportcomplianceinquiriesOrderInformationBillTo orderInformationBillTo = new Riskv1exportcomplianceinquiriesOrderInformationBillTo( Address1: orderInformationBillToAddress1, Address2: orderInformationBillToAddress2, AdministrativeArea: orderInformationBillToAdministrativeArea, Country: orderInformationBillToCountry, Locality: orderInformationBillToLocality, PostalCode: orderInformationBillToPostalCode, FirstName: orderInformationBillToFirstName, LastName: orderInformationBillToLastName, Email: orderInformationBillToEmail ); string orderInformationShipToCountry = "be"; string orderInformationShipToFirstName = "DumbelDore"; string orderInformationShipToLastName = "Albus"; Riskv1exportcomplianceinquiriesOrderInformationShipTo orderInformationShipTo = new Riskv1exportcomplianceinquiriesOrderInformationShipTo( Country: orderInformationShipToCountry, FirstName: orderInformationShipToFirstName, LastName: orderInformationShipToLastName ); List <Riskv1exportcomplianceinquiriesOrderInformationLineItems> orderInformationLineItems = new List <Riskv1exportcomplianceinquiriesOrderInformationLineItems>(); string orderInformationLineItemsUnitPrice1 = "19.00"; orderInformationLineItems.Add(new Riskv1exportcomplianceinquiriesOrderInformationLineItems( UnitPrice: orderInformationLineItemsUnitPrice1 )); Riskv1exportcomplianceinquiriesOrderInformation orderInformation = new Riskv1exportcomplianceinquiriesOrderInformation( BillTo: orderInformationBillTo, ShipTo: orderInformationShipTo, LineItems: orderInformationLineItems ); string buyerInformationMerchantCustomerId = "87789"; Riskv1addressverificationsBuyerInformation buyerInformation = new Riskv1addressverificationsBuyerInformation( MerchantCustomerId: buyerInformationMerchantCustomerId ); var requestObj = new ValidateExportComplianceRequest( ClientReferenceInformation: clientReferenceInformation, OrderInformation: orderInformation, BuyerInformation: buyerInformation ); try { var configDictionary = new Configuration().GetConfiguration(); var clientConfig = new CyberSource.Client.Configuration(merchConfigDictObj: configDictionary); var apiInstance = new VerificationApi(clientConfig); RiskV1ExportComplianceInquiriesPost201Response result = apiInstance.ValidateExportCompliance(requestObj); Console.WriteLine(result); return(result); } catch (Exception e) { Console.WriteLine("Exception on calling the API : " + e.Message); return(null); } }
public static RiskV1ExportComplianceInquiriesPost201Response Run() { string clientReferenceInformationCode = "verification example"; string clientReferenceInformationComments = "Export-basic"; string clientReferenceInformationPartnerDeveloperId = "7891234"; string clientReferenceInformationPartnerSolutionId = "89012345"; Riskv1decisionsClientReferenceInformationPartner clientReferenceInformationPartner = new Riskv1decisionsClientReferenceInformationPartner( DeveloperId: clientReferenceInformationPartnerDeveloperId, SolutionId: clientReferenceInformationPartnerSolutionId ); Riskv1liststypeentriesClientReferenceInformation clientReferenceInformation = new Riskv1liststypeentriesClientReferenceInformation( Code: clientReferenceInformationCode, Comments: clientReferenceInformationComments, Partner: clientReferenceInformationPartner ); string orderInformationBillToAddress1 = "901 Metro Centre Blvd"; string orderInformationBillToAdministrativeArea = "CA"; string orderInformationBillToCountry = "US"; string orderInformationBillToLocality = "Foster City"; string orderInformationBillToPostalCode = "94404"; string orderInformationBillToCompanyName = "A & C International Trade, Inc"; Riskv1exportcomplianceinquiriesOrderInformationBillToCompany orderInformationBillToCompany = new Riskv1exportcomplianceinquiriesOrderInformationBillToCompany( Name: orderInformationBillToCompanyName ); string orderInformationBillToFirstName = "ANDREE"; string orderInformationBillToLastName = "AGNESE"; string orderInformationBillToEmail = "*****@*****.**"; Riskv1exportcomplianceinquiriesOrderInformationBillTo orderInformationBillTo = new Riskv1exportcomplianceinquiriesOrderInformationBillTo( Address1: orderInformationBillToAddress1, AdministrativeArea: orderInformationBillToAdministrativeArea, Country: orderInformationBillToCountry, Locality: orderInformationBillToLocality, PostalCode: orderInformationBillToPostalCode, Company: orderInformationBillToCompany, FirstName: orderInformationBillToFirstName, LastName: orderInformationBillToLastName, Email: orderInformationBillToEmail ); string orderInformationShipToCountry = "IN"; string orderInformationShipToFirstName = "DumbelDore"; string orderInformationShipToLastName = "Albus"; Riskv1exportcomplianceinquiriesOrderInformationShipTo orderInformationShipTo = new Riskv1exportcomplianceinquiriesOrderInformationShipTo( Country: orderInformationShipToCountry, FirstName: orderInformationShipToFirstName, LastName: orderInformationShipToLastName ); List <Riskv1exportcomplianceinquiriesOrderInformationLineItems> orderInformationLineItems = new List <Riskv1exportcomplianceinquiriesOrderInformationLineItems>(); string orderInformationLineItemsUnitPrice1 = "120.50"; int orderInformationLineItemsQuantity1 = 3; string orderInformationLineItemsProductSKU1 = "123456"; string orderInformationLineItemsProductName1 = "Qwe"; string orderInformationLineItemsProductCode1 = "physical_software"; orderInformationLineItems.Add(new Riskv1exportcomplianceinquiriesOrderInformationLineItems( UnitPrice: orderInformationLineItemsUnitPrice1, Quantity: orderInformationLineItemsQuantity1, ProductSKU: orderInformationLineItemsProductSKU1, ProductName: orderInformationLineItemsProductName1, ProductCode: orderInformationLineItemsProductCode1 )); Riskv1exportcomplianceinquiriesOrderInformation orderInformation = new Riskv1exportcomplianceinquiriesOrderInformation( BillTo: orderInformationBillTo, ShipTo: orderInformationShipTo, LineItems: orderInformationLineItems ); var requestObj = new ValidateExportComplianceRequest( ClientReferenceInformation: clientReferenceInformation, OrderInformation: orderInformation ); try { var configDictionary = new Configuration().GetConfiguration(); var clientConfig = new CyberSource.Client.Configuration(merchConfigDictObj: configDictionary); var apiInstance = new VerificationApi(clientConfig); RiskV1ExportComplianceInquiriesPost201Response result = apiInstance.ValidateExportCompliance(requestObj); Console.WriteLine(result); return(result); } catch (Exception e) { Console.WriteLine("Exception on calling the API : " + e.Message); return(null); } }
public static RiskV1AddressVerificationsPost201Response Run() { string clientReferenceInformationCode = "addressEg"; string clientReferenceInformationComments = "dav-error response check"; Riskv1liststypeentriesClientReferenceInformation clientReferenceInformation = new Riskv1liststypeentriesClientReferenceInformation( Code: clientReferenceInformationCode, Comments: clientReferenceInformationComments ); string orderInformationBillToAddress1 = "6th 4th ave"; string orderInformationBillToAddress2 = ""; string orderInformationBillToAdministrativeArea = "NY"; string orderInformationBillToCountry = "US"; string orderInformationBillToLocality = "rensslaer"; string orderInformationBillToPostalCode = "12144"; Riskv1addressverificationsOrderInformationBillTo orderInformationBillTo = new Riskv1addressverificationsOrderInformationBillTo( Address1: orderInformationBillToAddress1, Address2: orderInformationBillToAddress2, AdministrativeArea: orderInformationBillToAdministrativeArea, Country: orderInformationBillToCountry, Locality: orderInformationBillToLocality, PostalCode: orderInformationBillToPostalCode ); List <Riskv1addressverificationsOrderInformationLineItems> orderInformationLineItems = new List <Riskv1addressverificationsOrderInformationLineItems>(); string orderInformationLineItemsUnitPrice1 = "120.50"; int orderInformationLineItemsQuantity1 = 3; string orderInformationLineItemsProductSKU1 = "996633"; string orderInformationLineItemsProductName1 = "qwerty"; string orderInformationLineItemsProductCode1 = "handling"; orderInformationLineItems.Add(new Riskv1addressverificationsOrderInformationLineItems( UnitPrice: orderInformationLineItemsUnitPrice1, Quantity: orderInformationLineItemsQuantity1, ProductSKU: orderInformationLineItemsProductSKU1, ProductName: orderInformationLineItemsProductName1, ProductCode: orderInformationLineItemsProductCode1 )); Riskv1addressverificationsOrderInformation orderInformation = new Riskv1addressverificationsOrderInformation( BillTo: orderInformationBillTo, LineItems: orderInformationLineItems ); var requestObj = new VerifyCustomerAddressRequest( ClientReferenceInformation: clientReferenceInformation, OrderInformation: orderInformation ); try { var configDictionary = new Configuration().GetConfiguration(); var clientConfig = new CyberSource.Client.Configuration(merchConfigDictObj: configDictionary); var apiInstance = new VerificationApi(clientConfig); RiskV1AddressVerificationsPost201Response result = apiInstance.VerifyCustomerAddress(requestObj); Console.WriteLine(result); return(result); } catch (Exception e) { Console.WriteLine("Exception on calling the API : " + e.Message); return(null); } }