Skip to content

Commit

Permalink
Merge pull request #293 from avadev/24.4.2
Browse files Browse the repository at this point in the history
Update for 24.4.2
  • Loading branch information
svc-developer authored Apr 23, 2024
2 parents 71365f4 + bd0fed9 commit d6c9a4c
Show file tree
Hide file tree
Showing 32 changed files with 965 additions and 194 deletions.
157 changes: 15 additions & 142 deletions lib/AvaTaxClient.ts

Large diffs are not rendered by default.

53 changes: 53 additions & 0 deletions lib/enums/APStatus.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
/*
* AvaTax Software Development Kit for JavaScript
*
* (c) 2004-2022 Avalara, Inc.
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*
* @author Jonathan Wenger <[email protected]>
* @author Sachin Baijal <[email protected]>
* @copyright 2004-2018 Avalara, Inc.
* @license https://www.apache.org/licenses/LICENSE-2.0
* @link https://github.com/avadev/AvaTax-REST-V2-JS-SDK
*/

import { JsonConverter, JsonCustomConvert } from "json2typescript";

/**
* @export
* @enum {string}
*/
export enum APStatus {
PayAsBilledMatch = 0,
ShortPayItemsAccrueMatch = 1,
MarkForReviewMatch = 2,
RejectMatch = 3,
PayAsBilledNoAccrual = 4,
PayAsBilledAccrueUndercharge = 5,
ShortPayItemsAccrueUndercharge = 6,
MarkForReviewUndercharge = 7,
RejectUndercharge = 8,
PayAsBilledOvercharge = 9,
ShortPayAvalaraCalculated = 10,
ShortPayItemsAccrueOvercharge = 11,
MarkForReviewOvercharge = 12,
RejectOvercharge = 13,
AmountThresholdNotMet = 14,
CostCenterExempted = 15,
ItemExempted = 16,
TrustedVendor = 17,
AccruedByVendor = 18,
Ignored = 19,
}

@JsonConverter
export class APStatusConverter implements JsonCustomConvert<APStatus> {
serialize(data: APStatus) {
return data;
}
deserialize(enumType: string): APStatus {
return APStatus[enumType as keyof typeof APStatus];
}
}
35 changes: 35 additions & 0 deletions lib/enums/ApConfigToleranceType.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
/*
* AvaTax Software Development Kit for JavaScript
*
* (c) 2004-2022 Avalara, Inc.
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*
* @author Jonathan Wenger <[email protected]>
* @author Sachin Baijal <[email protected]>
* @copyright 2004-2018 Avalara, Inc.
* @license https://www.apache.org/licenses/LICENSE-2.0
* @link https://github.com/avadev/AvaTax-REST-V2-JS-SDK
*/

import { JsonConverter, JsonCustomConvert } from "json2typescript";

/**
* @export
* @enum {string}
*/
export enum ApConfigToleranceType {
RealTime = 0,
Batch = 1,
}

@JsonConverter
export class ApConfigToleranceTypeConverter implements JsonCustomConvert<ApConfigToleranceType> {
serialize(data: ApConfigToleranceType) {
return data;
}
deserialize(enumType: string): ApConfigToleranceType {
return ApConfigToleranceType[enumType as keyof typeof ApConfigToleranceType];
}
}
43 changes: 43 additions & 0 deletions lib/enums/BulkImportStatus.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
/*
* AvaTax Software Development Kit for JavaScript
*
* (c) 2004-2022 Avalara, Inc.
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*
* @author Jonathan Wenger <[email protected]>
* @author Sachin Baijal <[email protected]>
* @copyright 2004-2018 Avalara, Inc.
* @license https://www.apache.org/licenses/LICENSE-2.0
* @link https://github.com/avadev/AvaTax-REST-V2-JS-SDK
*/

import { JsonConverter, JsonCustomConvert } from "json2typescript";

/**
* @export
* @enum {string}
*/
export enum BulkImportStatus {
None = 0,
Success = 1,
Created = 2,
Updated = 4,
NotImported = 8,
Ignored = 16,
Error = 32,
ValidationFailed = 64,
PartialSuccess = 128,
Invalid = 256,
}

@JsonConverter
export class BulkImportStatusConverter implements JsonCustomConvert<BulkImportStatus> {
serialize(data: BulkImportStatus) {
return data;
}
deserialize(enumType: string): BulkImportStatus {
return BulkImportStatus[enumType as keyof typeof BulkImportStatus];
}
}
2 changes: 2 additions & 0 deletions lib/enums/ErrorCodeId.ts
Original file line number Diff line number Diff line change
Expand Up @@ -321,6 +321,7 @@ import { JsonConverter, JsonCustomConvert } from "json2typescript";
InvalidFileName = 1737,
NoClassificationForSameHsCode = 1738,
InvalidValueError = 1739,
ItemDualWriteParameterValueMismatchError = 1740,
UnsupportedFileFormat = 1800,
UnsupportedOutputFileType = 1801,
TaxProfileNotProvided = 1900,
Expand Down Expand Up @@ -360,6 +361,7 @@ import { JsonConverter, JsonCustomConvert } from "json2typescript";
FieldLengthError = 2400,
InputContainsBlacklistedCharacters = 2401,
CannotCreateNestedObjects = 2402,
InvalidUsername = 2403,
UserSubjectIdNotUpdated = 2500,
BatchTransactionTypeError = 2501,
BatchTransactionLineLimitExceeded = 2502,
Expand Down
7 changes: 5 additions & 2 deletions lib/enums/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,10 +22,12 @@ export * from './UserDefinedFieldType';
export * from './POABusinessUnit';
export * from './POASubscriptionType';
export * from './StackAggregationOption';
export * from './ApConfigToleranceType';
export * from './AccountStatusId';
export * from './AccountTypeId';
export * from './ResolutionQuality';
export * from './AdjustmentReason';
export * from './BulkImportStatus';
export * from './ApiCallStatus';
export * from './FormTypeId';
export * from './FilingOptionTypeId';
Expand Down Expand Up @@ -75,10 +77,10 @@ export * from './BoundaryLevel';
export * from './MarketplaceLiabilityType';
export * from './AddressTypeId';
export * from './AddressCategoryId';
export * from './JurisTypeId';
export * from './NexusTypeId';
export * from './Sourcing';
export * from './LocalNexusTypeId';
export * from './JurisTypeId';
export * from './Sourcing';
export * from './CommentType';
export * from './NoticeCustomerType';
export * from './TaxNoticeFilingTypeId';
Expand All @@ -97,6 +99,7 @@ export * from './TaxRuleTypeId';
export * from './LiabilityType';
export * from './ChargedTo';
export * from './DeemedSellerType';
export * from './APStatus';
export * from './CompanyAccessLevel';
export * from './SecurityRoleId';
export * from './PasswordStatusId';
Expand Down
72 changes: 72 additions & 0 deletions lib/models/APConfigSettingRequestModel.ts
Original file line number Diff line number Diff line change
Expand Up @@ -48,4 +48,76 @@ import { DateConverter } from "../utils/dateConverter";
*/
@JsonProperty("variancePercent", Number, true)
variancePercent?: number | undefined = undefined;
/**
* @type {Enums.ApConfigToleranceType}
* @memberof APConfigSettingRequestModel
*/
@JsonProperty("apConfigToleranceType", Enums.ApConfigToleranceTypeConverter, true)
apConfigToleranceType?: Enums.ApConfigToleranceType | undefined = undefined;
/**
* @type {number}
* @memberof APConfigSettingRequestModel
*/
@JsonProperty("payAsBilledNoAccrual", Number, true)
payAsBilledNoAccrual?: number | undefined = undefined;
/**
* @type {number}
* @memberof APConfigSettingRequestModel
*/
@JsonProperty("payAsBilledAccrueUndercharge", Number, true)
payAsBilledAccrueUndercharge?: number | undefined = undefined;
/**
* @type {number}
* @memberof APConfigSettingRequestModel
*/
@JsonProperty("shortPayItemsAccrueUndercharge", Number, true)
shortPayItemsAccrueUndercharge?: number | undefined = undefined;
/**
* @type {number}
* @memberof APConfigSettingRequestModel
*/
@JsonProperty("markForReviewUndercharge", Number, true)
markForReviewUndercharge?: number | undefined = undefined;
/**
* @type {number}
* @memberof APConfigSettingRequestModel
*/
@JsonProperty("rejectUndercharge", Number, true)
rejectUndercharge?: number | undefined = undefined;
/**
* @type {number}
* @memberof APConfigSettingRequestModel
*/
@JsonProperty("payAsBilledOvercharge", Number, true)
payAsBilledOvercharge?: number | undefined = undefined;
/**
* @type {number}
* @memberof APConfigSettingRequestModel
*/
@JsonProperty("shortPayAvalaraCalculated", Number, true)
shortPayAvalaraCalculated?: number | undefined = undefined;
/**
* @type {number}
* @memberof APConfigSettingRequestModel
*/
@JsonProperty("shortPayItemsAccrueOvercharge", Number, true)
shortPayItemsAccrueOvercharge?: number | undefined = undefined;
/**
* @type {number}
* @memberof APConfigSettingRequestModel
*/
@JsonProperty("markForReviewOvercharge", Number, true)
markForReviewOvercharge?: number | undefined = undefined;
/**
* @type {number}
* @memberof APConfigSettingRequestModel
*/
@JsonProperty("rejectOvercharge", Number, true)
rejectOvercharge?: number | undefined = undefined;
/**
* @type {boolean}
* @memberof APConfigSettingRequestModel
*/
@JsonProperty("isActive", Boolean, true)
isActive?: boolean | undefined = undefined;
}
72 changes: 72 additions & 0 deletions lib/models/APConfigSettingSuccessResponseModel.ts
Original file line number Diff line number Diff line change
Expand Up @@ -67,4 +67,76 @@ import { DateConverter } from "../utils/dateConverter";
*/
@JsonProperty("variancePercent", Number, true)
variancePercent?: number | undefined = undefined;
/**
* @type {Enums.ApConfigToleranceType}
* @memberof APConfigSettingSuccessResponseModel
*/
@JsonProperty("apConfigToleranceType", Enums.ApConfigToleranceTypeConverter, true)
apConfigToleranceType?: Enums.ApConfigToleranceType | undefined = undefined;
/**
* @type {number}
* @memberof APConfigSettingSuccessResponseModel
*/
@JsonProperty("payAsBilledNoAccrual", Number, true)
payAsBilledNoAccrual?: number | undefined = undefined;
/**
* @type {number}
* @memberof APConfigSettingSuccessResponseModel
*/
@JsonProperty("payAsBilledAccrueUndercharge", Number, true)
payAsBilledAccrueUndercharge?: number | undefined = undefined;
/**
* @type {number}
* @memberof APConfigSettingSuccessResponseModel
*/
@JsonProperty("shortPayItemsAccrueUndercharge", Number, true)
shortPayItemsAccrueUndercharge?: number | undefined = undefined;
/**
* @type {number}
* @memberof APConfigSettingSuccessResponseModel
*/
@JsonProperty("markForReviewUndercharge", Number, true)
markForReviewUndercharge?: number | undefined = undefined;
/**
* @type {number}
* @memberof APConfigSettingSuccessResponseModel
*/
@JsonProperty("rejectUndercharge", Number, true)
rejectUndercharge?: number | undefined = undefined;
/**
* @type {number}
* @memberof APConfigSettingSuccessResponseModel
*/
@JsonProperty("payAsBilledOvercharge", Number, true)
payAsBilledOvercharge?: number | undefined = undefined;
/**
* @type {number}
* @memberof APConfigSettingSuccessResponseModel
*/
@JsonProperty("shortPayAvalaraCalculated", Number, true)
shortPayAvalaraCalculated?: number | undefined = undefined;
/**
* @type {number}
* @memberof APConfigSettingSuccessResponseModel
*/
@JsonProperty("shortPayItemsAccrueOvercharge", Number, true)
shortPayItemsAccrueOvercharge?: number | undefined = undefined;
/**
* @type {number}
* @memberof APConfigSettingSuccessResponseModel
*/
@JsonProperty("markForReviewOvercharge", Number, true)
markForReviewOvercharge?: number | undefined = undefined;
/**
* @type {number}
* @memberof APConfigSettingSuccessResponseModel
*/
@JsonProperty("rejectOvercharge", Number, true)
rejectOvercharge?: number | undefined = undefined;
/**
* @type {boolean}
* @memberof APConfigSettingSuccessResponseModel
*/
@JsonProperty("isActive", Boolean, true)
isActive?: boolean | undefined = undefined;
}
6 changes: 6 additions & 0 deletions lib/models/AccountModel.ts
Original file line number Diff line number Diff line change
Expand Up @@ -110,4 +110,10 @@ import { DateConverter } from "../utils/dateConverter";
*/
@JsonProperty("isSamlEnabled", Boolean, true)
isSamlEnabled?: boolean | undefined = undefined;
/**
* @type {boolean}
* @memberof AccountModel
*/
@JsonProperty("isDeleted", Boolean, true)
isDeleted?: boolean | undefined = undefined;
}
40 changes: 40 additions & 0 deletions lib/models/AdvancedRuleBulkImportModel.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
/*
* AvaTax Software Development Kit for JavaScript
*
* (c) 2004-2022 Avalara, Inc.
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*
* @author Jonathan Wenger <[email protected]>
* @author Sachin Baijal <[email protected]>
* @copyright 2004-2018 Avalara, Inc.
* @license https://www.apache.org/licenses/LICENSE-2.0
* @link https://github.com/avadev/AvaTax-REST-V2-JS-SDK
*/

import * as Enums from '../enums/index';
import { AdvancedRuleExecutionModel } from "./AdvancedRuleExecutionModel";
import { JsonObject, JsonProperty } from "json2typescript";
import { DateConverter } from "../utils/dateConverter";

/**
* Input model for the Advanced Rules bulk import API
* @export
* @class AdvancedRuleBulkImportModel
*/
@JsonObject("AdvancedRuleBulkImportModel")
export class AdvancedRuleBulkImportModel {
/**
* @type {boolean}
* @memberof AdvancedRuleBulkImportModel
*/
@JsonProperty("replaceExisting", Boolean, true)
replaceExisting?: boolean | undefined = undefined;
/**
* @type {AdvancedRuleExecutionModel[]}
* @memberof AdvancedRuleBulkImportModel
*/
@JsonProperty("executions", [AdvancedRuleExecutionModel])
executions: AdvancedRuleExecutionModel[] = undefined;
}
Loading

0 comments on commit d6c9a4c

Please sign in to comment.