diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 0000000..ba6841a --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,7 @@ ++ Thanks for contributing to the Authorize.Net Node SDK. + ++ Before you submit a pull request, we ask that you consider the following: + + - Submit an issue to state the problem your pull request solves or the funtionality that it adds. We can then advise on the feasability of the pull request, and let you know if there are other possible solutions. + - Part of the SDK is auto-generated based on the XML schema. Due to this auto-generation, we cannot merge contributions for request or response classes. You are welcome to open an issue to report problems or suggest improvements. Auto-generated classes are inside [sdk-node/lib/apicontracts.js](https://github.com/AuthorizeNet/sdk-node/tree/master/lib) and [sdk-node/lib/apicontrollers.js](https://github.com/AuthorizeNet/sdk-node/tree/master/lib) folders, except [sdk-node/lib/apicontrollersbase.js](https://github.com/AuthorizeNet/sdk-node/tree/master/lib). + \ No newline at end of file diff --git a/README.md b/README.md index c79b16e..cc1bd29 100644 --- a/README.md +++ b/README.md @@ -8,6 +8,10 @@ * Node.js version 4.8.4 or higher * An Authorize.Net account (see _Registration & Configuration_ section below) +### Contribution + - If you need information or clarification about any Authorize.Net features, please create an issue for it. Also you can search in the [Authorize.Net developer community](https://community.developer.authorize.net/). + - Before creating pull requests, please read [the contributors guide](CONTRIBUTING.md). + ### TLS 1.2 The Authorize.Net APIs only support connections using the TLS 1.2 security protocol. It's important to make sure you have new enough versions of all required components to support TLS 1.2. Additionally, it's very important to keep these components up to date going forward to mitigate the risk of any security flaws that may be discovered in your system or any libraries it uses. diff --git a/lib/apicontracts.js b/lib/apicontracts.js index 3ebb29b..453d6f3 100644 --- a/lib/apicontracts.js +++ b/lib/apicontracts.js @@ -9,8 +9,11 @@ class ANetApiRequest { logger.debug('Enter ANetApiRequest constructor'); if(arguments.length == 1) { if(('merchantAuthentication' in obj) && (obj.merchantAuthentication != null)) { this.setMerchantAuthentication(new MerchantAuthenticationType(obj.merchantAuthentication)); } + else { this.setMerchantAuthentication(null); } if(('clientId' in obj) && (obj.clientId != null)) { this.setClientId(obj.clientId); } + else { this.setClientId(null); } if(('refId' in obj) && (obj.refId != null)) { this.setRefId(obj.refId); } + else { this.setRefId(null); } } else { this.setMerchantAuthentication(null); @@ -330,6 +333,28 @@ class ArrayOfCardType { module.exports.ArrayOfCardType = ArrayOfCardType; +class ArrayOfContactDetail { + constructor(obj) { + logger.debug('Enter ArrayOfContactDetail constructor'); + if(arguments.length == 1) { + if((obj != undefined) && (obj != null)) { + var contactDetailList = []; + obj.forEach(function(item) {contactDetailList.push(new ContactDetailType(item));}); + this.setContactDetail(contactDetailList); + } + } + else { + this.setContactDetail(null); + } + logger.debug('Exit ArrayOfContactDetail constructor'); + } + + setContactDetail(p_contactDetail) { this.contactDetail = p_contactDetail; } + getContactDetail() { if('contactDetail' in this) {return this.contactDetail;} } +} + +module.exports.ArrayOfContactDetail = ArrayOfContactDetail; + class ArrayOfCurrencyCode { constructor(obj) { logger.debug('Enter ArrayOfCurrencyCode constructor'); @@ -1052,6 +1077,32 @@ class CcAuthenticationType { module.exports.CcAuthenticationType = CcAuthenticationType; +class ContactDetailType { + constructor(obj) { + logger.debug('Enter ContactDetailType constructor'); + if(arguments.length == 1) { + if(('email' in obj) && (obj.email != null)) { this.setEmail(obj.email); } + if(('firstName' in obj) && (obj.firstName != null)) { this.setFirstName(obj.firstName); } + if(('lastName' in obj) && (obj.lastName != null)) { this.setLastName(obj.lastName); } + } + else { + this.setEmail(null); + this.setFirstName(null); + this.setLastName(null); + } + logger.debug('Exit ContactDetailType constructor'); + } + + setEmail(p_email) { this.email = p_email; } + getEmail() { if('email' in this) {return this.email;} } + setFirstName(p_firstName) { this.firstName = p_firstName; } + getFirstName() { if('firstName' in this) {return this.firstName;} } + setLastName(p_lastName) { this.lastName = p_lastName; } + getLastName() { if('lastName' in this) {return this.lastName;} } +} + +module.exports.ContactDetailType = ContactDetailType; + class CreateProfileResponse { constructor(obj) { logger.debug('Enter CreateProfileResponse constructor'); @@ -1830,6 +1881,26 @@ class LineItemType { if(('quantity' in obj) && (obj.quantity != null)) { this.setQuantity(obj.quantity); } if(('unitPrice' in obj) && (obj.unitPrice != null)) { this.setUnitPrice(obj.unitPrice); } if(('taxable' in obj) && (obj.taxable != null)) { this.setTaxable(obj.taxable); } + if(('unitOfMeasure' in obj) && (obj.unitOfMeasure != null)) { this.setUnitOfMeasure(obj.unitOfMeasure); } + if(('typeOfSupply' in obj) && (obj.typeOfSupply != null)) { this.setTypeOfSupply(obj.typeOfSupply); } + if(('taxRate' in obj) && (obj.taxRate != null)) { this.setTaxRate(obj.taxRate); } + if(('taxAmount' in obj) && (obj.taxAmount != null)) { this.setTaxAmount(obj.taxAmount); } + if(('nationalTax' in obj) && (obj.nationalTax != null)) { this.setNationalTax(obj.nationalTax); } + if(('localTax' in obj) && (obj.localTax != null)) { this.setLocalTax(obj.localTax); } + if(('vatRate' in obj) && (obj.vatRate != null)) { this.setVatRate(obj.vatRate); } + if(('alternateTaxId' in obj) && (obj.alternateTaxId != null)) { this.setAlternateTaxId(obj.alternateTaxId); } + if(('alternateTaxType' in obj) && (obj.alternateTaxType != null)) { this.setAlternateTaxType(obj.alternateTaxType); } + if(('alternateTaxTypeApplied' in obj) && (obj.alternateTaxTypeApplied != null)) { this.setAlternateTaxTypeApplied(obj.alternateTaxTypeApplied); } + if(('alternateTaxRate' in obj) && (obj.alternateTaxRate != null)) { this.setAlternateTaxRate(obj.alternateTaxRate); } + if(('alternateTaxAmount' in obj) && (obj.alternateTaxAmount != null)) { this.setAlternateTaxAmount(obj.alternateTaxAmount); } + if(('totalAmount' in obj) && (obj.totalAmount != null)) { this.setTotalAmount(obj.totalAmount); } + if(('commodityCode' in obj) && (obj.commodityCode != null)) { this.setCommodityCode(obj.commodityCode); } + if(('productCode' in obj) && (obj.productCode != null)) { this.setProductCode(obj.productCode); } + if(('productSKU' in obj) && (obj.productSKU != null)) { this.setProductSKU(obj.productSKU); } + if(('discountRate' in obj) && (obj.discountRate != null)) { this.setDiscountRate(obj.discountRate); } + if(('discountAmount' in obj) && (obj.discountAmount != null)) { this.setDiscountAmount(obj.discountAmount); } + if(('taxIncludedInTotal' in obj) && (obj.taxIncludedInTotal != null)) { this.setTaxIncludedInTotal(obj.taxIncludedInTotal); } + if(('taxIsAfterDiscount' in obj) && (obj.taxIsAfterDiscount != null)) { this.setTaxIsAfterDiscount(obj.taxIsAfterDiscount); } } else { this.setItemId(null); @@ -1838,6 +1909,26 @@ class LineItemType { this.setQuantity(null); this.setUnitPrice(null); this.setTaxable(null); + this.setUnitOfMeasure(null); + this.setTypeOfSupply(null); + this.setTaxRate(null); + this.setTaxAmount(null); + this.setNationalTax(null); + this.setLocalTax(null); + this.setVatRate(null); + this.setAlternateTaxId(null); + this.setAlternateTaxType(null); + this.setAlternateTaxTypeApplied(null); + this.setAlternateTaxRate(null); + this.setAlternateTaxAmount(null); + this.setTotalAmount(null); + this.setCommodityCode(null); + this.setProductCode(null); + this.setProductSKU(null); + this.setDiscountRate(null); + this.setDiscountAmount(null); + this.setTaxIncludedInTotal(null); + this.setTaxIsAfterDiscount(null); } logger.debug('Exit LineItemType constructor'); } @@ -1854,6 +1945,46 @@ class LineItemType { getUnitPrice() { if('unitPrice' in this) {return this.unitPrice;} } setTaxable(p_taxable) { this.taxable = p_taxable; } getTaxable() { if('taxable' in this) {return this.taxable;} } + setUnitOfMeasure(p_unitOfMeasure) { this.unitOfMeasure = p_unitOfMeasure; } + getUnitOfMeasure() { if('unitOfMeasure' in this) {return this.unitOfMeasure;} } + setTypeOfSupply(p_typeOfSupply) { this.typeOfSupply = p_typeOfSupply; } + getTypeOfSupply() { if('typeOfSupply' in this) {return this.typeOfSupply;} } + setTaxRate(p_taxRate) { this.taxRate = p_taxRate; } + getTaxRate() { if('taxRate' in this) {return this.taxRate;} } + setTaxAmount(p_taxAmount) { this.taxAmount = p_taxAmount; } + getTaxAmount() { if('taxAmount' in this) {return this.taxAmount;} } + setNationalTax(p_nationalTax) { this.nationalTax = p_nationalTax; } + getNationalTax() { if('nationalTax' in this) {return this.nationalTax;} } + setLocalTax(p_localTax) { this.localTax = p_localTax; } + getLocalTax() { if('localTax' in this) {return this.localTax;} } + setVatRate(p_vatRate) { this.vatRate = p_vatRate; } + getVatRate() { if('vatRate' in this) {return this.vatRate;} } + setAlternateTaxId(p_alternateTaxId) { this.alternateTaxId = p_alternateTaxId; } + getAlternateTaxId() { if('alternateTaxId' in this) {return this.alternateTaxId;} } + setAlternateTaxType(p_alternateTaxType) { this.alternateTaxType = p_alternateTaxType; } + getAlternateTaxType() { if('alternateTaxType' in this) {return this.alternateTaxType;} } + setAlternateTaxTypeApplied(p_alternateTaxTypeApplied) { this.alternateTaxTypeApplied = p_alternateTaxTypeApplied; } + getAlternateTaxTypeApplied() { if('alternateTaxTypeApplied' in this) {return this.alternateTaxTypeApplied;} } + setAlternateTaxRate(p_alternateTaxRate) { this.alternateTaxRate = p_alternateTaxRate; } + getAlternateTaxRate() { if('alternateTaxRate' in this) {return this.alternateTaxRate;} } + setAlternateTaxAmount(p_alternateTaxAmount) { this.alternateTaxAmount = p_alternateTaxAmount; } + getAlternateTaxAmount() { if('alternateTaxAmount' in this) {return this.alternateTaxAmount;} } + setTotalAmount(p_totalAmount) { this.totalAmount = p_totalAmount; } + getTotalAmount() { if('totalAmount' in this) {return this.totalAmount;} } + setCommodityCode(p_commodityCode) { this.commodityCode = p_commodityCode; } + getCommodityCode() { if('commodityCode' in this) {return this.commodityCode;} } + setProductCode(p_productCode) { this.productCode = p_productCode; } + getProductCode() { if('productCode' in this) {return this.productCode;} } + setProductSKU(p_productSKU) { this.productSKU = p_productSKU; } + getProductSKU() { if('productSKU' in this) {return this.productSKU;} } + setDiscountRate(p_discountRate) { this.discountRate = p_discountRate; } + getDiscountRate() { if('discountRate' in this) {return this.discountRate;} } + setDiscountAmount(p_discountAmount) { this.discountAmount = p_discountAmount; } + getDiscountAmount() { if('discountAmount' in this) {return this.discountAmount;} } + setTaxIncludedInTotal(p_taxIncludedInTotal) { this.taxIncludedInTotal = p_taxIncludedInTotal; } + getTaxIncludedInTotal() { if('taxIncludedInTotal' in this) {return this.taxIncludedInTotal;} } + setTaxIsAfterDiscount(p_taxIsAfterDiscount) { this.taxIsAfterDiscount = p_taxIsAfterDiscount; } + getTaxIsAfterDiscount() { if('taxIsAfterDiscount' in this) {return this.taxIsAfterDiscount;} } } module.exports.LineItemType = LineItemType; @@ -2081,11 +2212,13 @@ class OpaqueDataType { if(('dataDescriptor' in obj) && (obj.dataDescriptor != null)) { this.setDataDescriptor(obj.dataDescriptor); } if(('dataValue' in obj) && (obj.dataValue != null)) { this.setDataValue(obj.dataValue); } if(('dataKey' in obj) && (obj.dataKey != null)) { this.setDataKey(obj.dataKey); } + if(('expirationTimeStamp' in obj) && (obj.expirationTimeStamp != null)) { this.setExpirationTimeStamp(obj.expirationTimeStamp); } } else { this.setDataDescriptor(null); this.setDataValue(null); this.setDataKey(null); + this.setExpirationTimeStamp(null); } logger.debug('Exit OpaqueDataType constructor'); } @@ -2096,6 +2229,8 @@ class OpaqueDataType { getDataValue() { if('dataValue' in this) {return this.dataValue;} } setDataKey(p_dataKey) { this.dataKey = p_dataKey; } getDataKey() { if('dataKey' in this) {return this.dataKey;} } + setExpirationTimeStamp(p_expirationTimeStamp) { this.expirationTimeStamp = p_expirationTimeStamp; } + getExpirationTimeStamp() { if('expirationTimeStamp' in this) {return this.expirationTimeStamp;} } } module.exports.OpaqueDataType = OpaqueDataType; @@ -2106,10 +2241,42 @@ class OrderType { if(arguments.length == 1) { if(('invoiceNumber' in obj) && (obj.invoiceNumber != null)) { this.setInvoiceNumber(obj.invoiceNumber); } if(('description' in obj) && (obj.description != null)) { this.setDescription(obj.description); } + if(('discountAmount' in obj) && (obj.discountAmount != null)) { this.setDiscountAmount(obj.discountAmount); } + if(('taxIsAfterDiscount' in obj) && (obj.taxIsAfterDiscount != null)) { this.setTaxIsAfterDiscount(obj.taxIsAfterDiscount); } + if(('totalTaxTypeCode' in obj) && (obj.totalTaxTypeCode != null)) { this.setTotalTaxTypeCode(obj.totalTaxTypeCode); } + if(('purchaserVATRegistrationNumber' in obj) && (obj.purchaserVATRegistrationNumber != null)) { this.setPurchaserVATRegistrationNumber(obj.purchaserVATRegistrationNumber); } + if(('merchantVATRegistrationNumber' in obj) && (obj.merchantVATRegistrationNumber != null)) { this.setMerchantVATRegistrationNumber(obj.merchantVATRegistrationNumber); } + if(('vatInvoiceReferenceNumber' in obj) && (obj.vatInvoiceReferenceNumber != null)) { this.setVatInvoiceReferenceNumber(obj.vatInvoiceReferenceNumber); } + if(('purchaserCode' in obj) && (obj.purchaserCode != null)) { this.setPurchaserCode(obj.purchaserCode); } + if(('summaryCommodityCode' in obj) && (obj.summaryCommodityCode != null)) { this.setSummaryCommodityCode(obj.summaryCommodityCode); } + if(('purchaseOrderDateUTC' in obj) && (obj.purchaseOrderDateUTC != null)) { this.setPurchaseOrderDateUTC(obj.purchaseOrderDateUTC); } + if(('supplierOrderReference' in obj) && (obj.supplierOrderReference != null)) { this.setSupplierOrderReference(obj.supplierOrderReference); } + if(('authorizedContactName' in obj) && (obj.authorizedContactName != null)) { this.setAuthorizedContactName(obj.authorizedContactName); } + if(('cardAcceptorRefNumber' in obj) && (obj.cardAcceptorRefNumber != null)) { this.setCardAcceptorRefNumber(obj.cardAcceptorRefNumber); } + if(('amexDataTAA1' in obj) && (obj.amexDataTAA1 != null)) { this.setAmexDataTAA1(obj.amexDataTAA1); } + if(('amexDataTAA2' in obj) && (obj.amexDataTAA2 != null)) { this.setAmexDataTAA2(obj.amexDataTAA2); } + if(('amexDataTAA3' in obj) && (obj.amexDataTAA3 != null)) { this.setAmexDataTAA3(obj.amexDataTAA3); } + if(('amexDataTAA4' in obj) && (obj.amexDataTAA4 != null)) { this.setAmexDataTAA4(obj.amexDataTAA4); } } else { this.setInvoiceNumber(null); this.setDescription(null); + this.setDiscountAmount(null); + this.setTaxIsAfterDiscount(null); + this.setTotalTaxTypeCode(null); + this.setPurchaserVATRegistrationNumber(null); + this.setMerchantVATRegistrationNumber(null); + this.setVatInvoiceReferenceNumber(null); + this.setPurchaserCode(null); + this.setSummaryCommodityCode(null); + this.setPurchaseOrderDateUTC(null); + this.setSupplierOrderReference(null); + this.setAuthorizedContactName(null); + this.setCardAcceptorRefNumber(null); + this.setAmexDataTAA1(null); + this.setAmexDataTAA2(null); + this.setAmexDataTAA3(null); + this.setAmexDataTAA4(null); } logger.debug('Exit OrderType constructor'); } @@ -2118,10 +2285,80 @@ class OrderType { getInvoiceNumber() { if('invoiceNumber' in this) {return this.invoiceNumber;} } setDescription(p_description) { this.description = p_description; } getDescription() { if('description' in this) {return this.description;} } + setDiscountAmount(p_discountAmount) { this.discountAmount = p_discountAmount; } + getDiscountAmount() { if('discountAmount' in this) {return this.discountAmount;} } + setTaxIsAfterDiscount(p_taxIsAfterDiscount) { this.taxIsAfterDiscount = p_taxIsAfterDiscount; } + getTaxIsAfterDiscount() { if('taxIsAfterDiscount' in this) {return this.taxIsAfterDiscount;} } + setTotalTaxTypeCode(p_totalTaxTypeCode) { this.totalTaxTypeCode = p_totalTaxTypeCode; } + getTotalTaxTypeCode() { if('totalTaxTypeCode' in this) {return this.totalTaxTypeCode;} } + setPurchaserVATRegistrationNumber(p_purchaserVATRegistrationNumber) { this.purchaserVATRegistrationNumber = p_purchaserVATRegistrationNumber; } + getPurchaserVATRegistrationNumber() { if('purchaserVATRegistrationNumber' in this) {return this.purchaserVATRegistrationNumber;} } + setMerchantVATRegistrationNumber(p_merchantVATRegistrationNumber) { this.merchantVATRegistrationNumber = p_merchantVATRegistrationNumber; } + getMerchantVATRegistrationNumber() { if('merchantVATRegistrationNumber' in this) {return this.merchantVATRegistrationNumber;} } + setVatInvoiceReferenceNumber(p_vatInvoiceReferenceNumber) { this.vatInvoiceReferenceNumber = p_vatInvoiceReferenceNumber; } + getVatInvoiceReferenceNumber() { if('vatInvoiceReferenceNumber' in this) {return this.vatInvoiceReferenceNumber;} } + setPurchaserCode(p_purchaserCode) { this.purchaserCode = p_purchaserCode; } + getPurchaserCode() { if('purchaserCode' in this) {return this.purchaserCode;} } + setSummaryCommodityCode(p_summaryCommodityCode) { this.summaryCommodityCode = p_summaryCommodityCode; } + getSummaryCommodityCode() { if('summaryCommodityCode' in this) {return this.summaryCommodityCode;} } + setPurchaseOrderDateUTC(p_purchaseOrderDateUTC) { this.purchaseOrderDateUTC = p_purchaseOrderDateUTC; } + getPurchaseOrderDateUTC() { if('purchaseOrderDateUTC' in this) {return this.purchaseOrderDateUTC;} } + setSupplierOrderReference(p_supplierOrderReference) { this.supplierOrderReference = p_supplierOrderReference; } + getSupplierOrderReference() { if('supplierOrderReference' in this) {return this.supplierOrderReference;} } + setAuthorizedContactName(p_authorizedContactName) { this.authorizedContactName = p_authorizedContactName; } + getAuthorizedContactName() { if('authorizedContactName' in this) {return this.authorizedContactName;} } + setCardAcceptorRefNumber(p_cardAcceptorRefNumber) { this.cardAcceptorRefNumber = p_cardAcceptorRefNumber; } + getCardAcceptorRefNumber() { if('cardAcceptorRefNumber' in this) {return this.cardAcceptorRefNumber;} } + setAmexDataTAA1(p_amexDataTAA1) { this.amexDataTAA1 = p_amexDataTAA1; } + getAmexDataTAA1() { if('amexDataTAA1' in this) {return this.amexDataTAA1;} } + setAmexDataTAA2(p_amexDataTAA2) { this.amexDataTAA2 = p_amexDataTAA2; } + getAmexDataTAA2() { if('amexDataTAA2' in this) {return this.amexDataTAA2;} } + setAmexDataTAA3(p_amexDataTAA3) { this.amexDataTAA3 = p_amexDataTAA3; } + getAmexDataTAA3() { if('amexDataTAA3' in this) {return this.amexDataTAA3;} } + setAmexDataTAA4(p_amexDataTAA4) { this.amexDataTAA4 = p_amexDataTAA4; } + getAmexDataTAA4() { if('amexDataTAA4' in this) {return this.amexDataTAA4;} } } module.exports.OrderType = OrderType; +class OtherTaxType { + constructor(obj) { + logger.debug('Enter OtherTaxType constructor'); + if(arguments.length == 1) { + if(('nationalTaxAmount' in obj) && (obj.nationalTaxAmount != null)) { this.setNationalTaxAmount(obj.nationalTaxAmount); } + if(('localTaxAmount' in obj) && (obj.localTaxAmount != null)) { this.setLocalTaxAmount(obj.localTaxAmount); } + if(('alternateTaxAmount' in obj) && (obj.alternateTaxAmount != null)) { this.setAlternateTaxAmount(obj.alternateTaxAmount); } + if(('alternateTaxId' in obj) && (obj.alternateTaxId != null)) { this.setAlternateTaxId(obj.alternateTaxId); } + if(('vatTaxRate' in obj) && (obj.vatTaxRate != null)) { this.setVatTaxRate(obj.vatTaxRate); } + if(('vatTaxAmount' in obj) && (obj.vatTaxAmount != null)) { this.setVatTaxAmount(obj.vatTaxAmount); } + } + else { + this.setNationalTaxAmount(null); + this.setLocalTaxAmount(null); + this.setAlternateTaxAmount(null); + this.setAlternateTaxId(null); + this.setVatTaxRate(null); + this.setVatTaxAmount(null); + } + logger.debug('Exit OtherTaxType constructor'); + } + + setNationalTaxAmount(p_nationalTaxAmount) { this.nationalTaxAmount = p_nationalTaxAmount; } + getNationalTaxAmount() { if('nationalTaxAmount' in this) {return this.nationalTaxAmount;} } + setLocalTaxAmount(p_localTaxAmount) { this.localTaxAmount = p_localTaxAmount; } + getLocalTaxAmount() { if('localTaxAmount' in this) {return this.localTaxAmount;} } + setAlternateTaxAmount(p_alternateTaxAmount) { this.alternateTaxAmount = p_alternateTaxAmount; } + getAlternateTaxAmount() { if('alternateTaxAmount' in this) {return this.alternateTaxAmount;} } + setAlternateTaxId(p_alternateTaxId) { this.alternateTaxId = p_alternateTaxId; } + getAlternateTaxId() { if('alternateTaxId' in this) {return this.alternateTaxId;} } + setVatTaxRate(p_vatTaxRate) { this.vatTaxRate = p_vatTaxRate; } + getVatTaxRate() { if('vatTaxRate' in this) {return this.vatTaxRate;} } + setVatTaxAmount(p_vatTaxAmount) { this.vatTaxAmount = p_vatTaxAmount; } + getVatTaxAmount() { if('vatTaxAmount' in this) {return this.vatTaxAmount;} } +} + +module.exports.OtherTaxType = OtherTaxType; + class Paging { constructor(obj) { logger.debug('Enter Paging constructor'); @@ -2426,6 +2663,36 @@ class PermissionType { module.exports.PermissionType = PermissionType; +class ProcessingOptions { + constructor(obj) { + logger.debug('Enter ProcessingOptions constructor'); + if(arguments.length == 1) { + if(('isFirstRecurringPayment' in obj) && (obj.isFirstRecurringPayment != null)) { this.setIsFirstRecurringPayment(obj.isFirstRecurringPayment); } + if(('isFirstSubsequentAuth' in obj) && (obj.isFirstSubsequentAuth != null)) { this.setIsFirstSubsequentAuth(obj.isFirstSubsequentAuth); } + if(('isSubsequentAuth' in obj) && (obj.isSubsequentAuth != null)) { this.setIsSubsequentAuth(obj.isSubsequentAuth); } + if(('isStoredCredentials' in obj) && (obj.isStoredCredentials != null)) { this.setIsStoredCredentials(obj.isStoredCredentials); } + } + else { + this.setIsFirstRecurringPayment(null); + this.setIsFirstSubsequentAuth(null); + this.setIsSubsequentAuth(null); + this.setIsStoredCredentials(null); + } + logger.debug('Exit ProcessingOptions constructor'); + } + + setIsFirstRecurringPayment(p_isFirstRecurringPayment) { this.isFirstRecurringPayment = p_isFirstRecurringPayment; } + getIsFirstRecurringPayment() { if('isFirstRecurringPayment' in this) {return this.isFirstRecurringPayment;} } + setIsFirstSubsequentAuth(p_isFirstSubsequentAuth) { this.isFirstSubsequentAuth = p_isFirstSubsequentAuth; } + getIsFirstSubsequentAuth() { if('isFirstSubsequentAuth' in this) {return this.isFirstSubsequentAuth;} } + setIsSubsequentAuth(p_isSubsequentAuth) { this.isSubsequentAuth = p_isSubsequentAuth; } + getIsSubsequentAuth() { if('isSubsequentAuth' in this) {return this.isSubsequentAuth;} } + setIsStoredCredentials(p_isStoredCredentials) { this.isStoredCredentials = p_isStoredCredentials; } + getIsStoredCredentials() { if('isStoredCredentials' in this) {return this.isStoredCredentials;} } +} + +module.exports.ProcessingOptions = ProcessingOptions; + class ProcessorType { constructor(obj) { logger.debug('Enter ProcessorType constructor'); @@ -2842,6 +3109,28 @@ class SubscriptionPaymentType { module.exports.SubscriptionPaymentType = SubscriptionPaymentType; +class SubsequentAuthInformation { + constructor(obj) { + logger.debug('Enter SubsequentAuthInformation constructor'); + if(arguments.length == 1) { + if(('originalNetworkTransId' in obj) && (obj.originalNetworkTransId != null)) { this.setOriginalNetworkTransId(obj.originalNetworkTransId); } + if(('reason' in obj) && (obj.reason != null)) { this.setReason(obj.reason); } + } + else { + this.setOriginalNetworkTransId(null); + this.setReason(null); + } + logger.debug('Exit SubsequentAuthInformation constructor'); + } + + setOriginalNetworkTransId(p_originalNetworkTransId) { this.originalNetworkTransId = p_originalNetworkTransId; } + getOriginalNetworkTransId() { if('originalNetworkTransId' in this) {return this.originalNetworkTransId;} } + setReason(p_reason) { this.reason = p_reason; } + getReason() { if('reason' in this) {return this.reason;} } +} + +module.exports.SubsequentAuthInformation = SubsequentAuthInformation; + class TokenMaskedType { constructor(obj) { logger.debug('Enter TokenMaskedType constructor'); @@ -2952,6 +3241,8 @@ class TransactionDetailsType { if(('surcharge' in obj) && (obj.surcharge != null)) { this.setSurcharge(new ExtendedAmountType(obj.surcharge)); } if(('employeeId' in obj) && (obj.employeeId != null)) { this.setEmployeeId(obj.employeeId); } if(('tip' in obj) && (obj.tip != null)) { this.setTip(new ExtendedAmountType(obj.tip)); } + if(('otherTax' in obj) && (obj.otherTax != null)) { this.setOtherTax(new OtherTaxType(obj.otherTax)); } + if(('shipFrom' in obj) && (obj.shipFrom != null)) { this.setShipFrom(new NameAndAddressType(obj.shipFrom)); } } else { this.setTransId(null); @@ -3000,6 +3291,8 @@ class TransactionDetailsType { this.setSurcharge(null); this.setEmployeeId(null); this.setTip(null); + this.setOtherTax(null); + this.setShipFrom(null); } logger.debug('Exit TransactionDetailsType constructor'); } @@ -3096,6 +3389,10 @@ class TransactionDetailsType { getEmployeeId() { if('employeeId' in this) {return this.employeeId;} } setTip(p_tip) { this.tip = p_tip; } getTip() { if('tip' in this) {return this.tip;} } + setOtherTax(p_otherTax) { this.otherTax = p_otherTax; } + getOtherTax() { if('otherTax' in this) {return this.otherTax;} } + setShipFrom(p_shipFrom) { this.shipFrom = p_shipFrom; } + getShipFrom() { if('shipFrom' in this) {return this.shipFrom;} } } module.exports.TransactionDetailsType = TransactionDetailsType; @@ -3157,6 +3454,10 @@ class TransactionRequestType { if(('merchantDescriptor' in obj) && (obj.merchantDescriptor != null)) { this.setMerchantDescriptor(obj.merchantDescriptor); } if(('subMerchant' in obj) && (obj.subMerchant != null)) { this.setSubMerchant(new SubMerchantType(obj.subMerchant)); } if(('tip' in obj) && (obj.tip != null)) { this.setTip(new ExtendedAmountType(obj.tip)); } + if(('processingOptions' in obj) && (obj.processingOptions != null)) { this.setProcessingOptions(new ProcessingOptions(obj.processingOptions)); } + if(('subsequentAuthInformation' in obj) && (obj.subsequentAuthInformation != null)) { this.setSubsequentAuthInformation(new SubsequentAuthInformation(obj.subsequentAuthInformation)); } + if(('otherTax' in obj) && (obj.otherTax != null)) { this.setOtherTax(new OtherTaxType(obj.otherTax)); } + if(('shipFrom' in obj) && (obj.shipFrom != null)) { this.setShipFrom(new NameAndAddressType(obj.shipFrom)); } } else { this.setTransactionType(null); @@ -3190,6 +3491,10 @@ class TransactionRequestType { this.setMerchantDescriptor(null); this.setSubMerchant(null); this.setTip(null); + this.setProcessingOptions(null); + this.setSubsequentAuthInformation(null); + this.setOtherTax(null); + this.setShipFrom(null); } logger.debug('Exit TransactionRequestType constructor'); } @@ -3256,6 +3561,14 @@ class TransactionRequestType { getSubMerchant() { if('subMerchant' in this) {return this.subMerchant;} } setTip(p_tip) { this.tip = p_tip; } getTip() { if('tip' in this) {return this.tip;} } + setProcessingOptions(p_processingOptions) { this.processingOptions = p_processingOptions; } + getProcessingOptions() { if('processingOptions' in this) {return this.processingOptions;} } + setSubsequentAuthInformation(p_subsequentAuthInformation) { this.subsequentAuthInformation = p_subsequentAuthInformation; } + getSubsequentAuthInformation() { if('subsequentAuthInformation' in this) {return this.subsequentAuthInformation;} } + setOtherTax(p_otherTax) { this.otherTax = p_otherTax; } + getOtherTax() { if('otherTax' in this) {return this.otherTax;} } + setShipFrom(p_shipFrom) { this.shipFrom = p_shipFrom; } + getShipFrom() { if('shipFrom' in this) {return this.shipFrom;} } } module.exports.TransactionRequestType = TransactionRequestType; @@ -3288,6 +3601,7 @@ class TransactionResponse { if(('emvResponse' in obj) && (obj.emvResponse != null)) { this.setEmvResponse(new TransactionResponse.EmvResponse(obj.emvResponse)); } if(('transHashSha2' in obj) && (obj.transHashSha2 != null)) { this.setTransHashSha2(obj.transHashSha2); } if(('profile' in obj) && (obj.profile != null)) { this.setProfile(new CustomerProfileIdType(obj.profile)); } + if(('networkTransId' in obj) && (obj.networkTransId != null)) { this.setNetworkTransId(obj.networkTransId); } } else { this.setResponseCode(null); @@ -3314,6 +3628,7 @@ class TransactionResponse { this.setEmvResponse(null); this.setTransHashSha2(null); this.setProfile(null); + this.setNetworkTransId(null); } logger.debug('Exit TransactionResponse constructor'); } @@ -3366,6 +3681,8 @@ class TransactionResponse { getTransHashSha2() { if('transHashSha2' in this) {return this.transHashSha2;} } setProfile(p_profile) { this.profile = p_profile; } getProfile() { if('profile' in this) {return this.profile;} } + setNetworkTransId(p_networkTransId) { this.networkTransId = p_networkTransId; } + getNetworkTransId() { if('networkTransId' in this) {return this.networkTransId;} } } module.exports.TransactionResponse = TransactionResponse; @@ -5500,6 +5817,70 @@ class GetCustomerPaymentProfileListResponse extends ANetApiResponse { module.exports.GetCustomerPaymentProfileListResponse = GetCustomerPaymentProfileListResponse; +class GetCustomerPaymentProfileNonceRequest extends ANetApiRequest { + getJSON() { + logger.debug('Enter GetCustomerPaymentProfileNonceRequest getJSON'); + utils.delete_null_properties(this, true); + var obj = { 'getCustomerPaymentProfileNonceRequest' : this }; + logger.debug('Exit GetCustomerPaymentProfileNonceRequest getJSON'); + return obj; + } + + constructor(obj) { + logger.debug('Enter GetCustomerPaymentProfileNonceRequest constructor'); + if(arguments.length == 1) { + super(obj); + if(('connectedAccessToken' in obj) && (obj.connectedAccessToken != null)) { this.setConnectedAccessToken(obj.connectedAccessToken); } + if(('customerProfileId' in obj) && (obj.customerProfileId != null)) { this.setCustomerProfileId(obj.customerProfileId); } + if(('customerPaymentProfileId' in obj) && (obj.customerPaymentProfileId != null)) { this.setCustomerPaymentProfileId(obj.customerPaymentProfileId); } + } + else { + super(); + this.setConnectedAccessToken(null); + this.setCustomerProfileId(null); + this.setCustomerPaymentProfileId(null); + } + logger.debug('Exit GetCustomerPaymentProfileNonceRequest constructor'); + } + + setConnectedAccessToken(p_connectedAccessToken) { this.connectedAccessToken = p_connectedAccessToken; } + getConnectedAccessToken() { if('connectedAccessToken' in this) {return this.connectedAccessToken;} } + setCustomerProfileId(p_customerProfileId) { this.customerProfileId = p_customerProfileId; } + getCustomerProfileId() { if('customerProfileId' in this) {return this.customerProfileId;} } + setCustomerPaymentProfileId(p_customerPaymentProfileId) { this.customerPaymentProfileId = p_customerPaymentProfileId; } + getCustomerPaymentProfileId() { if('customerPaymentProfileId' in this) {return this.customerPaymentProfileId;} } +} + +module.exports.GetCustomerPaymentProfileNonceRequest = GetCustomerPaymentProfileNonceRequest; + +class GetCustomerPaymentProfileNonceResponse extends ANetApiResponse { + getJSON() { + logger.debug('Enter GetCustomerPaymentProfileNonceResponse getJSON'); + utils.delete_null_properties(this, true); + var obj = { 'getCustomerPaymentProfileNonceResponse' : this }; + logger.debug('Exit GetCustomerPaymentProfileNonceResponse getJSON'); + return obj; + } + + constructor(obj) { + logger.debug('Enter GetCustomerPaymentProfileNonceResponse constructor'); + if(arguments.length == 1) { + super(obj); + if(('opaqueData' in obj) && (obj.opaqueData != null)) { this.setOpaqueData(new OpaqueDataType(obj.opaqueData)); } + } + else { + super(); + this.setOpaqueData(null); + } + logger.debug('Exit GetCustomerPaymentProfileNonceResponse constructor'); + } + + setOpaqueData(p_opaqueData) { this.opaqueData = p_opaqueData; } + getOpaqueData() { if('opaqueData' in this) {return this.opaqueData;} } +} + +module.exports.GetCustomerPaymentProfileNonceResponse = GetCustomerPaymentProfileNonceResponse; + class GetCustomerPaymentProfileRequest extends ANetApiRequest { getJSON() { logger.debug('Enter GetCustomerPaymentProfileRequest getJSON'); @@ -5912,6 +6293,9 @@ class GetMerchantDetailsResponse extends ANetApiResponse { if(('paymentMethods' in obj) && (obj.paymentMethods != null)) { this.setPaymentMethods(new ArrayOfPaymentMethod(obj.paymentMethods)); } if(('currencies' in obj) && (obj.currencies != null)) { this.setCurrencies(new ArrayOfCurrencyCode(obj.currencies)); } if(('publicClientKey' in obj) && (obj.publicClientKey != null)) { this.setPublicClientKey(obj.publicClientKey); } + if(('businessInformation' in obj) && (obj.businessInformation != null)) { this.setBusinessInformation(new CustomerAddressType(obj.businessInformation)); } + if(('merchantTimeZone' in obj) && (obj.merchantTimeZone != null)) { this.setMerchantTimeZone(obj.merchantTimeZone); } + if(('contactDetails' in obj) && (obj.contactDetails != null)) { this.setContactDetails(new ArrayOfContactDetail(obj.contactDetails)); } } else { super(); @@ -5924,6 +6308,9 @@ class GetMerchantDetailsResponse extends ANetApiResponse { this.setPaymentMethods(null); this.setCurrencies(null); this.setPublicClientKey(null); + this.setBusinessInformation(null); + this.setMerchantTimeZone(null); + this.setContactDetails(null); } logger.debug('Exit GetMerchantDetailsResponse constructor'); } @@ -5946,6 +6333,12 @@ class GetMerchantDetailsResponse extends ANetApiResponse { getCurrencies() { if('currencies' in this) {return this.currencies;} } setPublicClientKey(p_publicClientKey) { this.publicClientKey = p_publicClientKey; } getPublicClientKey() { if('publicClientKey' in this) {return this.publicClientKey;} } + setBusinessInformation(p_businessInformation) { this.businessInformation = p_businessInformation; } + getBusinessInformation() { if('businessInformation' in this) {return this.businessInformation;} } + setMerchantTimeZone(p_merchantTimeZone) { this.merchantTimeZone = p_merchantTimeZone; } + getMerchantTimeZone() { if('merchantTimeZone' in this) {return this.merchantTimeZone;} } + setContactDetails(p_contactDetails) { this.contactDetails = p_contactDetails; } + getContactDetails() { if('contactDetails' in this) {return this.contactDetails;} } } module.exports.GetMerchantDetailsResponse = GetMerchantDetailsResponse; @@ -6426,6 +6819,8 @@ class ProfileTransOrderType extends ProfileTransAmountType { if(('recurringBilling' in obj) && (obj.recurringBilling != null)) { this.setRecurringBilling(obj.recurringBilling); } if(('cardCode' in obj) && (obj.cardCode != null)) { this.setCardCode(obj.cardCode); } if(('splitTenderId' in obj) && (obj.splitTenderId != null)) { this.setSplitTenderId(obj.splitTenderId); } + if(('processingOptions' in obj) && (obj.processingOptions != null)) { this.setProcessingOptions(new ProcessingOptions(obj.processingOptions)); } + if(('subsequentAuthInformation' in obj) && (obj.subsequentAuthInformation != null)) { this.setSubsequentAuthInformation(new SubsequentAuthInformation(obj.subsequentAuthInformation)); } } else { super(); @@ -6437,6 +6832,8 @@ class ProfileTransOrderType extends ProfileTransAmountType { this.setRecurringBilling(null); this.setCardCode(null); this.setSplitTenderId(null); + this.setProcessingOptions(null); + this.setSubsequentAuthInformation(null); } logger.debug('Exit ProfileTransOrderType constructor'); } @@ -6457,6 +6854,10 @@ class ProfileTransOrderType extends ProfileTransAmountType { getCardCode() { if('cardCode' in this) {return this.cardCode;} } setSplitTenderId(p_splitTenderId) { this.splitTenderId = p_splitTenderId; } getSplitTenderId() { if('splitTenderId' in this) {return this.splitTenderId;} } + setProcessingOptions(p_processingOptions) { this.processingOptions = p_processingOptions; } + getProcessingOptions() { if('processingOptions' in this) {return this.processingOptions;} } + setSubsequentAuthInformation(p_subsequentAuthInformation) { this.subsequentAuthInformation = p_subsequentAuthInformation; } + getSubsequentAuthInformation() { if('subsequentAuthInformation' in this) {return this.subsequentAuthInformation;} } } module.exports.ProfileTransOrderType = ProfileTransOrderType; @@ -7315,6 +7716,14 @@ const FDSFilterActionEnum = { }; module.exports.FDSFilterActionEnum = FDSFilterActionEnum; +const MerchantInitTransReasonEnum = { + RESUBMISSION : 'resubmission', + DELAYEDCHARGE : 'delayedCharge', + REAUTHORIZATION : 'reauthorization', + NOSHOW : 'noShow' +}; +module.exports.MerchantInitTransReasonEnum = MerchantInitTransReasonEnum; + const MessageTypeEnum = { OK : 'Ok', ERROR : 'Error' diff --git a/lib/apicontrollers.js b/lib/apicontrollers.js index ba8d295..9b5afb4 100644 --- a/lib/apicontrollers.js +++ b/lib/apicontrollers.js @@ -486,6 +486,26 @@ class GetCustomerPaymentProfileListController extends APIOperationBase { module.exports.GetCustomerPaymentProfileListController = GetCustomerPaymentProfileListController; +class GetCustomerPaymentProfileNonceController extends APIOperationBase { + constructor(apiRequest) { + logger.debug('Enter GetCustomerPaymentProfileNonceController constructor'); + super(apiRequest); + logger.debug('Exit GetCustomerPaymentProfileNonceController constructor'); + } + + validateRequest(){ + logger.debug('Enter validateRequest'); + + logger.debug('Exit validateRequest'); + return; + } + + getRequestType(){ + return 'GetCustomerPaymentProfileNonceRequest'; + } +} + +module.exports.GetCustomerPaymentProfileNonceController = GetCustomerPaymentProfileNonceController; class GetCustomerProfileController extends APIOperationBase { constructor(apiRequest) { logger.debug('Enter GetCustomerProfileController constructor'); diff --git a/lib/apicontrollersbase.js b/lib/apicontrollersbase.js index 46f170d..877c91b 100644 --- a/lib/apicontrollersbase.js +++ b/lib/apicontrollersbase.js @@ -83,10 +83,6 @@ class APIOperationBase { var reqOpts = { url: this._endpoint, method: 'POST', - headers: { - 'Content-Type': 'application/json', - 'Content-Length': this._request.length - }, json: true, timeout: config.timeout, body: this._request @@ -102,9 +98,10 @@ class APIOperationBase { } else { //TODO: slice added due to BOM character. remove once BOM character is removed. - var responseObj = JSON.parse(body.slice(1)); - logger.debug(JSON.stringify(responseObj, 2, null)); - obj._response = responseObj; + if(typeof body!=='undefined'){ + var responseObj = JSON.parse(body.slice(1)); + logger.debug(JSON.stringify(responseObj, 2, null)); + obj._response = responseObj; /* var jsonResponse = JSON.stringify(body); console.log("escaped body : '" + escape(jsonResponse) + "'"); @@ -114,6 +111,11 @@ class APIOperationBase { */ callback(); } + else + { + logger.error("Undefined Response"); + } + } }); logger.debug('Exit APIOperationBase execute'); diff --git a/mappings/Schema.js b/mappings/Schema.js index b8d2717..e626c5e 100644 --- a/mappings/Schema.js +++ b/mappings/Schema.js @@ -382,6 +382,14 @@ var Schema_Module_Factory = function () { name: 'emailSettings', typeInfo: '.EmailSettingsType' }] + }, { + localName: 'ArrayOfContactDetail', + propertyInfos: [{ + name: 'contactDetail', + minOccurs: 0, + collection: true, + typeInfo: '.ContactDetailType' + }] }, { localName: 'TransactionDetailsType.EmvDetails', typeName: null, @@ -544,6 +552,12 @@ var Schema_Module_Factory = function () { }, { name: 'tip', typeInfo: '.ExtendedAmountType' + }, { + name: 'otherTax', + typeInfo: '.OtherTaxType' + }, { + name: 'shipFrom', + typeInfo: '.NameAndAddressType' }] }, { localName: 'ARBTransactionList', @@ -656,6 +670,14 @@ var Schema_Module_Factory = function () { typeInfo: '.TokenMaskedType' }] }, { + localName: 'GetCustomerPaymentProfileNonceResponse', + typeName: null, + baseTypeInfo: '.ANetApiResponse', + propertyInfos: [{ + name: 'opaqueData', + typeInfo: '.OpaqueDataType' + }] + },{ localName: 'CustomerProfilePaymentType', typeName: 'customerProfilePaymentType', propertyInfos: [{ @@ -755,6 +777,9 @@ var Schema_Module_Factory = function () { required: true }, { name: 'dataKey' + }, { + name: 'expirationTimeStamp', + typeInfo: 'DateTime' }] }, { localName: 'ProfileTransAuthOnlyType', @@ -821,6 +846,14 @@ var Schema_Module_Factory = function () { typeInfo: '.ArrayOfCurrencyCode' }, { name: 'publicClientKey' + }, { + name: 'businessInformation', + typeInfo: '.CustomerAddressType' + }, { + name: 'merchantTimeZone' + }, { + name: 'contactDetails', + typeInfo: '.ArrayOfContactDetail' }] }, { localName: 'ARBGetSubscriptionStatusResponse', @@ -1230,6 +1263,20 @@ var Schema_Module_Factory = function () { typeInfo: '.SubscriptionDetail' }] }, { + localName: 'GetCustomerPaymentProfileNonceRequest', + typeName: null, + baseTypeInfo: '.ANetApiRequest', + propertyInfos: [{ + name: 'connectedAccessToken', + required: true + }, { + name: 'customerProfileId', + required: true + }, { + name: 'customerPaymentProfileId', + required: true + }] + },{ localName: 'ValidateCustomerPaymentProfileResponse', typeName: null, baseTypeInfo: '.ANetApiResponse', @@ -1303,6 +1350,22 @@ var Schema_Module_Factory = function () { maxOccurs: 1000, collection: true }] + },{ + localName: 'ProcessingOptions', + typeName: 'processingOptions', + propertyInfos: [{ + name: 'isFirstRecurringPayment', + typeInfo: 'Boolean' + }, { + name: 'isFirstSubsequentAuth', + typeInfo: 'Boolean' + }, { + name: 'isSubsequentAuth', + typeInfo: 'Boolean' + }, { + name: 'isStoredCredentials', + typeInfo: 'Boolean' + }] }, { localName: 'LogoutRequest', typeName: null, @@ -1412,6 +1475,58 @@ var Schema_Module_Factory = function () { }, { name: 'taxable', typeInfo: 'Boolean' + },{ + name: 'unitOfMeasure' + }, { + name: 'typeOfSupply' + }, { + name: 'taxRate', + typeInfo: 'Decimal' + }, { + name: 'taxAmount', + typeInfo: 'Decimal' + }, { + name: 'nationalTax', + typeInfo: 'Decimal' + }, { + name: 'localTax', + typeInfo: 'Decimal' + }, { + name: 'vatRate', + typeInfo: 'Decimal' + }, { + name: 'alternateTaxId' + }, { + name: 'alternateTaxType' + }, { + name: 'alternateTaxTypeApplied' + }, { + name: 'alternateTaxRate', + typeInfo: 'Decimal' + }, { + name: 'alternateTaxAmount', + typeInfo: 'Decimal' + }, { + name: 'totalAmount', + typeInfo: 'Decimal' + }, { + name: 'commodityCode' + }, { + name: 'productCode' + }, { + name: 'productSKU' + }, { + name: 'discountRate', + typeInfo: 'Decimal' + }, { + name: 'discountAmount', + typeInfo: 'Decimal' + }, { + name: 'taxIncludedInTotal', + typeInfo: 'Boolean' + }, { + name: 'taxIsAfterDiscount', + typeInfo: 'Boolean' }] }, { localName: 'TransactionResponse.EmvResponse.Tags', @@ -1788,6 +1903,15 @@ var Schema_Module_Factory = function () { collection: true, typeInfo: '.PermissionType' }] + }, { + localName: 'ContactDetailType', + propertyInfos: [{ + name: 'email' + }, { + name: 'firstName' + }, { + name: 'lastName' + }] }, { localName: 'SolutionType', typeName: 'solutionType', @@ -2058,6 +2182,8 @@ var Schema_Module_Factory = function () { }, { name: 'profile', typeInfo: '.CustomerProfileIdType' + }, { + name: 'networkTransId' }] }, { localName: 'CustomerDataType', @@ -2660,8 +2786,20 @@ var Schema_Module_Factory = function () { }, { name: 'tip', typeInfo: '.ExtendedAmountType' + }, { + name: 'processingOptions', + typeInfo: '.ProcessingOptions' + }, { + name: 'subsequentAuthInformation', + typeInfo: '.SubsequentAuthInformation' + }, { + name: 'otherTax', + typeInfo: '.OtherTaxType' + }, { + name: 'shipFrom', + typeInfo: '.NameAndAddressType' }] - }, { + }, { localName: 'KeyValue', propertyInfos: [{ name: 'encoding', @@ -2737,6 +2875,12 @@ var Schema_Module_Factory = function () { name: 'cardCode' }, { name: 'splitTenderId' + }, { + name: 'processingOptions', + typeInfo: '.ProcessingOptions' + }, { + name: 'subsequentAuthInformation', + typeInfo: '.SubsequentAuthInformation' }] }, { localName: 'CustomerPaymentProfileListItemType', @@ -2782,6 +2926,27 @@ var Schema_Module_Factory = function () { }, { name: 'description' }] + }, { + localName: 'OtherTaxType', + typeName: 'otherTaxType', + propertyInfos: [{ + name: 'nationalTaxAmount', + typeInfo: 'Decimal' + }, { + name: 'localTaxAmount', + typeInfo: 'Decimal' + }, { + name: 'alternateTaxAmount', + typeInfo: 'Decimal' + }, { + name: 'alternateTaxId' + }, { + name: 'vatTaxRate', + typeInfo: 'Decimal' + }, { + name: 'vatTaxAmount', + typeInfo: 'Decimal' + }] }, { localName: 'ProfileTransVoidType', typeName: 'profileTransVoidType', @@ -3112,6 +3277,14 @@ var Schema_Module_Factory = function () { name: 'fraudAction', required: true }] + },{ + localName: 'SubsequentAuthInformation', + typeName: 'subsequentAuthInformation', + propertyInfos: [{ + name: 'originalNetworkTransId' + }, { + name: 'reason' + }] }, { localName: 'TransactionResponse.Messages.Message', typeName: null, @@ -3136,6 +3309,41 @@ var Schema_Module_Factory = function () { name: 'invoiceNumber' }, { name: 'description' + }, { + name: 'discountAmount', + typeInfo: 'Decimal' + }, { + name: 'taxIsAfterDiscount', + typeInfo: 'Boolean' + }, { + name: 'totalTaxTypeCode' + }, { + name: 'purchaserVATRegistrationNumber' + }, { + name: 'merchantVATRegistrationNumber' + }, { + name: 'vatInvoiceReferenceNumber' + }, { + name: 'purchaserCode' + }, { + name: 'summaryCommodityCode' + }, { + name: 'purchaseOrderDateUTC', + typeInfo: 'Date' + }, { + name: 'supplierOrderReference' + }, { + name: 'authorizedContactName' + }, { + name: 'cardAcceptorRefNumber' + }, { + name: 'amexDataTAA1' + }, { + name: 'amexDataTAA2' + }, { + name: 'amexDataTAA3' + }, { + name: 'amexDataTAA4' }] }, { localName: 'ReturnedItemType', @@ -3182,6 +3390,10 @@ var Schema_Module_Factory = function () { type: 'enumInfo', localName: 'CustomerProfileTypeEnum', values: ['regular', 'guest'] + }, { + type: 'enumInfo', + localName: 'MerchantInitTransReasonEnum', + values: ['resubmission', 'delayedCharge', 'reauthorization', 'noShow'] }, { type: 'enumInfo', localName: 'AfdsTransactionEnum', diff --git a/package.json b/package.json index fc484f9..3768b66 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "authorizenet", - "version": "1.0.6", + "version": "1.0.7", "description": "nodejs sdk for Authorize.Net", "main": "lib/authorizenet.js", "directories": { pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy