declare module "wix-billing-tax" {
  const __debug: {
      verboseLogging: {
          on: () => boolean;
          off: () => boolean;
      };
  };
  /**
   * Tax Group represents a tax category for a group of line items.
   * It is used as a way to connect a tax rate to a group of line items.
   */
  interface TaxGroup {
      /**
       * Tax Group ID.
       * @readonly
       */
      _id?: string | null;
      /** Tax Group Name - a non empty string that represents the tax category. */
      name?: string;
      /**
       * Represents the current state of an item. Each time the item is modified, its `revision` changes.
       * for an update operation to succeed, you MUST pass the latest revision.
       */
      revision?: string | null;
      /**
       * Represents the time this TaxGroup was created.
       * @readonly
       */
      _createdDate?: Date;
      /**
       * Represents the time this TaxGroup was last updated.
       * @readonly
       */
      _updatedDate?: Date;
  }
  interface CreateTaxGroupRequest {
      /** Tax Group to be created */
      taxGroup: TaxGroup;
  }
  interface CreateTaxGroupResponse {
      /** The created Tax Group */
      taxGroup?: TaxGroup;
  }
  interface GetTaxGroupRequest {
      /** Id of the Tax Group to retrieve */
      taxGroupId: string;
  }
  interface GetTaxGroupResponse {
      /** The retrieved Tax Group */
      taxGroup?: TaxGroup;
  }
  interface UpdateTaxGroupRequest {
      /** Tax Group to be updated, may be partial */
      taxGroup: TaxGroup;
      /**
       * Explicit list of fields to update
       * @internal
       */
      fieldMask?: string[];
  }
  interface UpdateTaxGroupResponse {
      /** The updated Tax Group */
      taxGroup?: TaxGroup;
  }
  interface DeleteTaxGroupRequest {
      /** Id of the Tax Group to delete */
      taxGroupId: string;
  }
  interface DeleteTaxGroupResponse {
  }
  interface QueryTaxGroupsRequest {
      /** WQL expression */
      query: QueryV2;
  }
  interface QueryV2 extends QueryV2PagingMethodOneOf {
      /** Paging options to limit and skip the number of items. */
      paging?: Paging;
      /** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */
      cursorPaging?: CursorPaging;
      /**
       * Filter object in the following format:
       * `"filter" : {
       * "fieldName1": "value1",
       * "fieldName2":{"$operator":"value2"}
       * }`
       * Example of operators: `$eq`, `$ne`, `$lt`, `$lte`, `$gt`, `$gte`, `$in`, `$hasSome`, `$hasAll`, `$startsWith`, `$contains`
       */
      filter?: Record<string, any> | null;
      /**
       * Sort object in the following format:
       * `[{"fieldName":"sortField1","order":"ASC"},{"fieldName":"sortField2","order":"DESC"}]`
       */
      sort?: Sorting[];
      /** Array of projected fields. A list of specific field names to return. If `fieldsets` are also specified, the union of `fieldsets` and `fields` is returned. */
      fields?: string[];
      /** Array of named, predefined sets of projected fields. A array of predefined named sets of fields to be returned. Specifying multiple `fieldsets` will return the union of fields from all sets. If `fields` are also specified, the union of `fieldsets` and `fields` is returned. */
      fieldsets?: string[];
  }
  /** @oneof */
  interface QueryV2PagingMethodOneOf {
      /** Paging options to limit and skip the number of items. */
      paging?: Paging;
      /** Cursor token pointing to a page of results. Not used in the first request. Following requests use the cursor token and not `filter` or `sort`. */
      cursorPaging?: CursorPaging;
  }
  interface Sorting {
      /** Name of the field to sort by. */
      fieldName?: string;
      /** Sort order. */
      order?: SortOrder;
  }
  enum SortOrder {
      ASC = "ASC",
      DESC = "DESC"
  }
  interface Paging {
      /** Number of items to load. */
      limit?: number | null;
      /** Number of items to skip in the current sort order. */
      offset?: number | null;
  }
  interface CursorPaging {
      /** Maximum number of items to return in the results. */
      limit?: number | null;
      /**
       * Pointer to the next or previous page in the list of results.
       *
       * Pass the relevant cursor token from the `pagingMetadata` object in the previous call's response.
       * Not relevant for the first request.
       */
      cursor?: string | null;
  }
  interface QueryTaxGroupsResponse {
      /** The retrieved Tax Groups */
      taxGroups?: TaxGroup[];
      /** Paging metadata */
      pagingMetadata?: CursorPagingMetadata;
  }
  interface CursorPagingMetadata {
      /** Number of items returned in the response. */
      count?: number | null;
      /** Cursor strings that point to the next page, previous page, or both. */
      cursors?: Cursors;
      /**
       * Whether there are more pages to retrieve following the current page.
       *
       * + `true`: Another page of results can be retrieved.
       * + `false`: This is the last page.
       */
      hasNext?: boolean | null;
  }
  interface Cursors {
      /** Cursor string pointing to the next page in the list of results. */
      next?: string | null;
      /** Cursor pointing to the previous page in the list of results. */
      prev?: string | null;
  }
  interface ListDefaultTaxGroupsRequest {
  }
  interface ListDefaultTaxGroupsResponse {
      /** The system defined groups for the installed apps (stores will return "all products", "shipping", "fees") */
      taxGroups?: TaxGroup[];
  }
  interface ListDefaultTaxGroupsByAppIdsRequest {
      /** The app ids to get the default tax groups for */
      appIds: string[];
  }
  interface ListDefaultTaxGroupsByAppIdsResponse {
      /** The default tax group for each app */
      results?: ListDefaultTaxGroupsByAppIdsResult[];
      /** Bulk action metadata. */
      bulkActionMetadata?: BulkActionMetadata;
  }
  interface ListDefaultTaxGroupsByAppIdsResult {
      /** Information about successful action or error for failure. */
      taxGroupMetadata?: ItemMetadata;
      /** The default TaxGroup for the app */
      taxGroup?: TaxGroup;
  }
  interface ItemMetadata {
      /** Item ID. Should always be available, unless it's impossible (for example, when failing to create an item). */
      _id?: string | null;
      /** Index of the item within the request array. Allows for correlation between request and response items. */
      originalIndex?: number;
      /** Whether the requested action was successful for this item. When `false`, the `error` field is populated. */
      success?: boolean;
      /** Details about the error in case of failure. */
      error?: ApplicationError;
  }
  interface ApplicationError {
      /** Error code. */
      code?: string;
      /** Description of the error. */
      description?: string;
      /** Data related to the error. */
      data?: Record<string, any> | null;
  }
  interface BulkActionMetadata {
      /** Number of items that were successfully processed. */
      totalSuccesses?: number;
      /** Number of items that couldn't be processed. */
      totalFailures?: number;
      /** Number of failures without details because detailed failure threshold was exceeded. */
      undetailedFailures?: number;
  }
  /**
   * Create a Tax Group
   * @param taxGroup - Tax Group to be created
   * @internal
   * @documentationMaturity preview
   * @requiredField taxGroup
   * @requiredField taxGroup.name
   * @adminMethod
   * @returns The created Tax Group
   */
  function createTaxGroup(taxGroup: TaxGroup): Promise<TaxGroup>;
  /**
   * Get a Tax Group
   * @param taxGroupId - Id of the Tax Group to retrieve
   * @internal
   * @documentationMaturity preview
   * @requiredField taxGroupId
   * @returns The retrieved Tax Group
   */
  function getTaxGroup(taxGroupId: string): Promise<TaxGroup>;
  /**
   * Update a Tax Group, supports partial update
   * Pass the latest `revision` for a successful update
   * @param _id - Tax Group ID.
   * @internal
   * @documentationMaturity preview
   * @requiredField _id
   * @requiredField taxGroup
   * @requiredField taxGroup.name
   * @requiredField taxGroup.revision
   * @adminMethod
   * @returns The updated Tax Group
   */
  function updateTaxGroup(_id: string | null, taxGroup: UpdateTaxGroup, options?: UpdateTaxGroupOptions): Promise<TaxGroup>;
  interface UpdateTaxGroup {
      /**
       * Tax Group ID.
       * @readonly
       */
      _id?: string | null;
      /** Tax Group Name - a non empty string that represents the tax category. */
      name?: string;
      /**
       * Represents the current state of an item. Each time the item is modified, its `revision` changes.
       * for an update operation to succeed, you MUST pass the latest revision.
       */
      revision?: string | null;
      /**
       * Represents the time this TaxGroup was created.
       * @readonly
       */
      _createdDate?: Date;
      /**
       * Represents the time this TaxGroup was last updated.
       * @readonly
       */
      _updatedDate?: Date;
  }
  interface UpdateTaxGroupOptions {
      /**
       * Explicit list of fields to update
       * @internal
       */
      fieldMask?: string[];
  }
  /**
   * Delete a Tax Group
   * @param taxGroupId - Id of the Tax Group to delete
   * @internal
   * @documentationMaturity preview
   * @requiredField taxGroupId
   * @adminMethod
   */
  function deleteTaxGroup(taxGroupId: string): Promise<void>;
  /**
   * Query Tax Groups using [WQL - Wix Query Language](https://dev.wix.com/api/rest/getting-started/api-query-language)
   * @internal
   * @documentationMaturity preview
   */
  function queryTaxGroups(): TaxGroupsQueryBuilder;
  interface QueryCursorResult {
      cursors: Cursors;
      hasNext: () => boolean;
      hasPrev: () => boolean;
      length: number;
      pageSize: number;
  }
  interface TaxGroupsQueryResult extends QueryCursorResult {
      items: TaxGroup[];
      query: TaxGroupsQueryBuilder;
      next: () => Promise<TaxGroupsQueryResult>;
      prev: () => Promise<TaxGroupsQueryResult>;
  }
  interface TaxGroupsQueryBuilder {
      /** @param propertyName - Property whose value is compared with `value`.
       * @param value - Value to compare against.
       * @documentationMaturity preview
       */
      eq: (propertyName: '_id' | 'name' | '_createdDate' | '_updatedDate', value: any) => TaxGroupsQueryBuilder;
      /** @param propertyName - Property whose value is compared with `value`.
       * @param value - Value to compare against.
       * @documentationMaturity preview
       */
      ne: (propertyName: '_id' | 'name' | '_createdDate' | '_updatedDate', value: any) => TaxGroupsQueryBuilder;
      /** @param propertyName - Property whose value is compared with `value`.
       * @param value - Value to compare against.
       * @documentationMaturity preview
       */
      ge: (propertyName: '_createdDate' | '_updatedDate', value: any) => TaxGroupsQueryBuilder;
      /** @param propertyName - Property whose value is compared with `value`.
       * @param value - Value to compare against.
       * @documentationMaturity preview
       */
      gt: (propertyName: '_createdDate' | '_updatedDate', value: any) => TaxGroupsQueryBuilder;
      /** @param propertyName - Property whose value is compared with `value`.
       * @param value - Value to compare against.
       * @documentationMaturity preview
       */
      le: (propertyName: '_createdDate' | '_updatedDate', value: any) => TaxGroupsQueryBuilder;
      /** @param propertyName - Property whose value is compared with `value`.
       * @param value - Value to compare against.
       * @documentationMaturity preview
       */
      lt: (propertyName: '_createdDate' | '_updatedDate', value: any) => TaxGroupsQueryBuilder;
      /** @param propertyName - Property whose value is compared with `values`.
       * @param values - List of values to compare against.
       * @documentationMaturity preview
       */
      hasSome: (propertyName: '_createdDate' | '_updatedDate', value: any[]) => TaxGroupsQueryBuilder;
      /** @documentationMaturity preview */
      in: (propertyName: '_id' | 'name' | '_createdDate' | '_updatedDate', value: any) => TaxGroupsQueryBuilder;
      /** @documentationMaturity preview */
      exists: (propertyName: '_createdDate' | '_updatedDate', value: boolean) => TaxGroupsQueryBuilder;
      /** @param propertyNames - Properties used in the sort. To sort by multiple properties, pass properties as additional arguments.
       * @documentationMaturity preview
       */
      ascending: (...propertyNames: Array<'_id' | 'name' | '_createdDate' | '_updatedDate'>) => TaxGroupsQueryBuilder;
      /** @param propertyNames - Properties used in the sort. To sort by multiple properties, pass properties as additional arguments.
       * @documentationMaturity preview
       */
      descending: (...propertyNames: Array<'_id' | 'name' | '_createdDate' | '_updatedDate'>) => TaxGroupsQueryBuilder;
      /** @param limit - Number of items to return, which is also the `pageSize` of the results object.
       * @documentationMaturity preview
       */
      limit: (limit: number) => TaxGroupsQueryBuilder;
      /** @param cursor - A pointer to specific record
       * @documentationMaturity preview
       */
      skipTo: (cursor: string) => TaxGroupsQueryBuilder;
      /** @documentationMaturity preview */
      find: () => Promise<TaxGroupsQueryResult>;
  }
  /**
   * ListDefaultTaxGroups - will return all default tax groups for the installed apps for the given metasite.
   * for example, if stores is installed then its default tax group - "Products" will be returned.
   * if bookings is installed then its default tax group - "services" will be returned.
   * The language of the default tax group will be the language of the metasite.
   * Default tax groups are defined via the Default Tax Group spi configuration.
   * @internal
   * @documentationMaturity preview
   */
  function listDefaultTaxGroups(): Promise<ListDefaultTaxGroupsResponse>;
  /**
   * ListDefaultTaxGroupsByAppIds - will return all default tax groups for the given app ids if they are installed for the given metasite and the app has default tax groups extension.
   * for example, if online stores is installed and its app id is given then its default tax group - "Products" will be returned.
   * if bookings is not installed, even if you will send its app id you will not get the tax group back.
   * @param appIds - The app ids to get the default tax groups for
   * @internal
   * @documentationMaturity preview
   * @requiredField appIds
   */
  function listDefaultTaxGroupsByAppIds(appIds: string[]): Promise<ListDefaultTaxGroupsByAppIdsResponse>;
  
  const billingV1TaxGroup_universal_d___debug: typeof __debug;
  type billingV1TaxGroup_universal_d_TaxGroup = TaxGroup;
  type billingV1TaxGroup_universal_d_CreateTaxGroupRequest = CreateTaxGroupRequest;
  type billingV1TaxGroup_universal_d_CreateTaxGroupResponse = CreateTaxGroupResponse;
  type billingV1TaxGroup_universal_d_GetTaxGroupRequest = GetTaxGroupRequest;
  type billingV1TaxGroup_universal_d_GetTaxGroupResponse = GetTaxGroupResponse;
  type billingV1TaxGroup_universal_d_UpdateTaxGroupRequest = UpdateTaxGroupRequest;
  type billingV1TaxGroup_universal_d_UpdateTaxGroupResponse = UpdateTaxGroupResponse;
  type billingV1TaxGroup_universal_d_DeleteTaxGroupRequest = DeleteTaxGroupRequest;
  type billingV1TaxGroup_universal_d_DeleteTaxGroupResponse = DeleteTaxGroupResponse;
  type billingV1TaxGroup_universal_d_QueryTaxGroupsRequest = QueryTaxGroupsRequest;
  type billingV1TaxGroup_universal_d_QueryV2 = QueryV2;
  type billingV1TaxGroup_universal_d_QueryV2PagingMethodOneOf = QueryV2PagingMethodOneOf;
  type billingV1TaxGroup_universal_d_Sorting = Sorting;
  type billingV1TaxGroup_universal_d_SortOrder = SortOrder;
  const billingV1TaxGroup_universal_d_SortOrder: typeof SortOrder;
  type billingV1TaxGroup_universal_d_Paging = Paging;
  type billingV1TaxGroup_universal_d_CursorPaging = CursorPaging;
  type billingV1TaxGroup_universal_d_QueryTaxGroupsResponse = QueryTaxGroupsResponse;
  type billingV1TaxGroup_universal_d_CursorPagingMetadata = CursorPagingMetadata;
  type billingV1TaxGroup_universal_d_Cursors = Cursors;
  type billingV1TaxGroup_universal_d_ListDefaultTaxGroupsRequest = ListDefaultTaxGroupsRequest;
  type billingV1TaxGroup_universal_d_ListDefaultTaxGroupsResponse = ListDefaultTaxGroupsResponse;
  type billingV1TaxGroup_universal_d_ListDefaultTaxGroupsByAppIdsRequest = ListDefaultTaxGroupsByAppIdsRequest;
  type billingV1TaxGroup_universal_d_ListDefaultTaxGroupsByAppIdsResponse = ListDefaultTaxGroupsByAppIdsResponse;
  type billingV1TaxGroup_universal_d_ListDefaultTaxGroupsByAppIdsResult = ListDefaultTaxGroupsByAppIdsResult;
  type billingV1TaxGroup_universal_d_ItemMetadata = ItemMetadata;
  type billingV1TaxGroup_universal_d_ApplicationError = ApplicationError;
  type billingV1TaxGroup_universal_d_BulkActionMetadata = BulkActionMetadata;
  const billingV1TaxGroup_universal_d_createTaxGroup: typeof createTaxGroup;
  const billingV1TaxGroup_universal_d_getTaxGroup: typeof getTaxGroup;
  const billingV1TaxGroup_universal_d_updateTaxGroup: typeof updateTaxGroup;
  type billingV1TaxGroup_universal_d_UpdateTaxGroup = UpdateTaxGroup;
  type billingV1TaxGroup_universal_d_UpdateTaxGroupOptions = UpdateTaxGroupOptions;
  const billingV1TaxGroup_universal_d_deleteTaxGroup: typeof deleteTaxGroup;
  const billingV1TaxGroup_universal_d_queryTaxGroups: typeof queryTaxGroups;
  type billingV1TaxGroup_universal_d_TaxGroupsQueryResult = TaxGroupsQueryResult;
  type billingV1TaxGroup_universal_d_TaxGroupsQueryBuilder = TaxGroupsQueryBuilder;
  const billingV1TaxGroup_universal_d_listDefaultTaxGroups: typeof listDefaultTaxGroups;
  const billingV1TaxGroup_universal_d_listDefaultTaxGroupsByAppIds: typeof listDefaultTaxGroupsByAppIds;
  namespace billingV1TaxGroup_universal_d {
    export {
      billingV1TaxGroup_universal_d___debug as __debug,
      billingV1TaxGroup_universal_d_TaxGroup as TaxGroup,
      billingV1TaxGroup_universal_d_CreateTaxGroupRequest as CreateTaxGroupRequest,
      billingV1TaxGroup_universal_d_CreateTaxGroupResponse as CreateTaxGroupResponse,
      billingV1TaxGroup_universal_d_GetTaxGroupRequest as GetTaxGroupRequest,
      billingV1TaxGroup_universal_d_GetTaxGroupResponse as GetTaxGroupResponse,
      billingV1TaxGroup_universal_d_UpdateTaxGroupRequest as UpdateTaxGroupRequest,
      billingV1TaxGroup_universal_d_UpdateTaxGroupResponse as UpdateTaxGroupResponse,
      billingV1TaxGroup_universal_d_DeleteTaxGroupRequest as DeleteTaxGroupRequest,
      billingV1TaxGroup_universal_d_DeleteTaxGroupResponse as DeleteTaxGroupResponse,
      billingV1TaxGroup_universal_d_QueryTaxGroupsRequest as QueryTaxGroupsRequest,
      billingV1TaxGroup_universal_d_QueryV2 as QueryV2,
      billingV1TaxGroup_universal_d_QueryV2PagingMethodOneOf as QueryV2PagingMethodOneOf,
      billingV1TaxGroup_universal_d_Sorting as Sorting,
      billingV1TaxGroup_universal_d_SortOrder as SortOrder,
      billingV1TaxGroup_universal_d_Paging as Paging,
      billingV1TaxGroup_universal_d_CursorPaging as CursorPaging,
      billingV1TaxGroup_universal_d_QueryTaxGroupsResponse as QueryTaxGroupsResponse,
      billingV1TaxGroup_universal_d_CursorPagingMetadata as CursorPagingMetadata,
      billingV1TaxGroup_universal_d_Cursors as Cursors,
      billingV1TaxGroup_universal_d_ListDefaultTaxGroupsRequest as ListDefaultTaxGroupsRequest,
      billingV1TaxGroup_universal_d_ListDefaultTaxGroupsResponse as ListDefaultTaxGroupsResponse,
      billingV1TaxGroup_universal_d_ListDefaultTaxGroupsByAppIdsRequest as ListDefaultTaxGroupsByAppIdsRequest,
      billingV1TaxGroup_universal_d_ListDefaultTaxGroupsByAppIdsResponse as ListDefaultTaxGroupsByAppIdsResponse,
      billingV1TaxGroup_universal_d_ListDefaultTaxGroupsByAppIdsResult as ListDefaultTaxGroupsByAppIdsResult,
      billingV1TaxGroup_universal_d_ItemMetadata as ItemMetadata,
      billingV1TaxGroup_universal_d_ApplicationError as ApplicationError,
      billingV1TaxGroup_universal_d_BulkActionMetadata as BulkActionMetadata,
      billingV1TaxGroup_universal_d_createTaxGroup as createTaxGroup,
      billingV1TaxGroup_universal_d_getTaxGroup as getTaxGroup,
      billingV1TaxGroup_universal_d_updateTaxGroup as updateTaxGroup,
      billingV1TaxGroup_universal_d_UpdateTaxGroup as UpdateTaxGroup,
      billingV1TaxGroup_universal_d_UpdateTaxGroupOptions as UpdateTaxGroupOptions,
      billingV1TaxGroup_universal_d_deleteTaxGroup as deleteTaxGroup,
      billingV1TaxGroup_universal_d_queryTaxGroups as queryTaxGroups,
      billingV1TaxGroup_universal_d_TaxGroupsQueryResult as TaxGroupsQueryResult,
      billingV1TaxGroup_universal_d_TaxGroupsQueryBuilder as TaxGroupsQueryBuilder,
      billingV1TaxGroup_universal_d_listDefaultTaxGroups as listDefaultTaxGroups,
      billingV1TaxGroup_universal_d_listDefaultTaxGroupsByAppIds as listDefaultTaxGroupsByAppIds,
    };
  }
  
  export { billingV1TaxGroup_universal_d as taxGroups };
}
