import { IApiSuccess } from '../../../../../_common';
import { ITenantAttributeLanguage, ITenantAttributeScope } from '../../../../../DataHub';
import { IDataHubEntitiesAttributeInSetCache } from '../../../DataHub';
import { ITaxClass } from '../TaxClasses';
import { ITaxZone } from '../TaxZones';
import { ITaxZoneMatchCriterium } from '../MatchRules';

export interface ITaxRate {
    taxClass: ITaxClass;
    taxZone: ITaxZone;
    rate: number;
    fromDate?: string | null;
    toDate?: string | null;
    taxKey: string;
    createdByUsername: string;
    modifiedByUsername: string;
    created: string;
    createdBy: number;
    modified: string;
    modifiedBy: number;
    id: number;
}
interface ITaxesAmountDependentInformationContainer {
    taxRate: number;
    taxKey: number;
    totalGross: number;
}
export interface ITaxClassAndTaxZoneRequest {
    taxClass: number;
    taxZone: number;
    date: string;
}
export interface ITaxRateResponse extends IApiSuccess {
    taxRate: ITaxRate;
}
export interface IFindTaxRateAndTaxZoneRequest {
    taxClass: number;
    shipToCountry: string;
    shipToPostalCode: string;
    sourceCountry: string;
    date: string;
    goodsValueTotalNet: number;
    billCurrency: string;
    receipientHasVatId: boolean;
    addGoodsValueNet: number;
}
export interface IFoundTaxRateAndTaxZoneResponse extends IApiSuccess {
    taxRate: ITaxRate;
    match: ITaxZoneMatchCriterium;
    needRecalculate: boolean;
    amountDependentInformation: ITaxesAmountDependentInformationContainer[];
}
export interface ILanguagesScopesAndFieldsResponse extends IApiSuccess {
    languages: ITenantAttributeLanguage[];
    scopes: ITenantAttributeScope[];
    attributes: IDataHubEntitiesAttributeInSetCache[];
}
export interface INewTaxRate {
    id?: number;
    taxClass: Pick<ITaxClass, "id">;
    taxZone: Pick<ITaxZone, "id">;
    taxKey: string;
    rate: number;
    fromDate?: string;
    toDate?: string;
}
export {};
