import { HttpClient } from '@wix/sdk-types'; import { AddTipDistributionsToOrderOptions, AddTipDistributionsToOrderResponse, AddTipDistributionsToOrderResponseNonNullableFields, GetTipByDraftOrderIdResponse, GetTipByDraftOrderIdResponseNonNullableFields, GetTipByOrderIdResponse, GetTipByOrderIdResponseNonNullableFields, GetTipChoiceResponse, GetTipChoiceResponseNonNullableFields, LineItemInfo, PreviewTipOptions, PreviewTipResponse, PreviewTipResponseNonNullableFields, RemoveTipFromOrderOptions, RemoveTipFromOrderResponse, RemoveTipFromOrderResponseNonNullableFields, SetTipOnOrderOptions, SetTipOnOrderResponse, SetTipOnOrderResponseNonNullableFields, SumTipDistributionAmountsResponse, TipChoice, TipDistributionsQueryBuilder, UpdateTipChoiceOptions, UpdateTipChoiceResponse, UpdateTipChoiceResponseNonNullableFields } from './tips-v1-tip-tips.universal.js'; export declare const __metadata: { PACKAGE_NAME: string; }; export declare function previewTip(httpClient: HttpClient): PreviewTipSignature; interface PreviewTipSignature { /** * Previews a tip for a list of line items. * * * If you provide the Wix Bookings app ID `13d21c63-b5ec-5912-8397-c3a5ddb27a97` as `lineItemInfo.catalogReference.appId`, the response includes tip * distributions for each associated Bookings staff member. * * If you don't provide a `tipSettingsId`, the `staffDistributionMethod` is * based on the site's default tip settings. * @param - Information about the line items to preview the tip for. * * Min: 1 line item * Max: 50 line items * @param - Options to use when previewing a tip. */ (lineItemInfo: LineItemInfo[], options?: PreviewTipOptions | undefined): Promise; } export declare function getTipByOrderId(httpClient: HttpClient): GetTipByOrderIdSignature; interface GetTipByOrderIdSignature { /** * Retrieves the tip that's associated with an * [eCommerce order](https://dev.wix.com/docs/sdk/backend-modules/ecom/orders/setup). * @param - ID of the order to retrieve the tip for. */ (orderId: string | null): Promise; } export declare function getTipByDraftOrderId(httpClient: HttpClient): GetTipByDraftOrderIdSignature; interface GetTipByDraftOrderIdSignature { /** * Retrieves the tip that's associated with an eCommerce draft order. * * *
* * __Important:__ * The eCommerce Draft Orders API is currently under development and not yet available to users. * *
* @param - ID of the draft order to retrieve the tip for. */ (draftOrderId: string | null): Promise; } export declare function getTipChoice(httpClient: HttpClient): GetTipChoiceSignature; interface GetTipChoiceSignature { /** * Retrieves the tip choice that's currently selected by the customer for a specific [eCommerce checkout](https://dev.wix.com/docs/sdk/backend-modules/ecom/checkout/setup). * If the customer hasn't yet selected a tip choice, the response is empty. * @param - ID of the [eCommerce purchase flow](https://dev.wix.com/docs/rest/business-solutions/e-commerce/wix-e-commerce-platform-handbook/overview/architecture-data-flow) * to retrieve the tip choice for. */ (purchaseFlowId: string | null): Promise; } export declare function updateTipChoice(httpClient: HttpClient): UpdateTipChoiceSignature; interface UpdateTipChoiceSignature { /** * Updates the tip choice that's currently selected by the customer for a specific [eCommerce checkout](https://dev.wix.com/docs/sdk/backend-modules/ecom/checkout/setup). * @param - Tip choice to select for the purchase flow. The call fails if you provide a * value for `tipChoice.tipType` that doesn't match the relevant tip settings * configuration. For example: * + `AMOUNT` when `tipSettings.tipType` isn't `AMOUNT`. * + `PERCENTAGE` when `tipSettings.tipType` isn't `PERCENTAGE`. * + `CUSTOM` when `tipSettings.allowCustomTip` is `false`. * @param - Options to use when updating a tip choice. */ (tipChoice: TipChoice, options: UpdateTipChoiceOptions): Promise; } export declare function setTipOnOrder(httpClient: HttpClient): SetTipOnOrderSignature; interface SetTipOnOrderSignature { /** * Updates the tip choice that's currently selected by the customer for a specific [eCommerce checkout](https://dev.wix.com/docs/sdk/backend-modules/ecom/checkout/setup). * @param - Options to use when setting a tip on an order. */ (options?: SetTipOnOrderOptions | undefined): Promise; } export declare function removeTipFromOrder(httpClient: HttpClient): RemoveTipFromOrderSignature; interface RemoveTipFromOrderSignature { /** * Removes a tip from an * [eCommerce order](https://dev.wix.com/docs/rest/business-solutions/e-commerce/orders/introduction). * * * If no tip exists on the order, the call succeeds and the response contains an * empty `OrderInfo` object. * * The call fails if the customer has already been charged for at least one of * the associated tip distributions. * @param - Options to use when removing a tip from an order. */ (options?: RemoveTipFromOrderOptions | undefined): Promise; } export declare function addTipDistributionsToOrder(httpClient: HttpClient): AddTipDistributionsToOrderSignature; interface AddTipDistributionsToOrderSignature { /** * Adds tip distributions to an * [eCommerce order](https://dev.wix.com/docs/rest/business-solutions/e-commerce/orders/introduction). * * * If no tip exists on the order, an `additionalFee` is added and the total tip * amount is equal to the sum of all distribution amounts. If a tip is already * present, the existing `additionalFee` is replaced and the total tip amount is * increased by the sum of the new tip distributions. * * The call fails if: * + The order's `paymentStatus` is either `FULLY_REFUNDED` or `PARTIALLY_REFUNDED`. * + Any of the tip distribution amounts is zero or negative. * @param - Options to use when adding tip distributions to an order. */ (options?: AddTipDistributionsToOrderOptions | undefined): Promise; } export declare function queryTipDistributions(httpClient: HttpClient): QueryTipDistributionsSignature; interface QueryTipDistributionsSignature { /** * Creates a query to retrieve a list of tip distributions. * * The `queryTipDistributions()` function builds a query to retrieve a list of tip distributions and returns a `TipDistributionsQueryBuilder` object. * * The returned object contains the query definition, which is typically used to run the query using the [find()](https://dev.wix.com/docs/sdk/backend-modules/ecom/tips/tip-distributions-query-builder/find) function. * * You can refine the query by chaining `TipDistributionsQueryBuilder` functions onto the query. `TipDistributionsQueryBuilder` functions enable you to sort, filter, and control the results that `queryTipDistributions()` returns. * * `queryTipDistributions()` runs with the following `TipDistributionsQueryBuilder` default that you can override: * * + `limit` is `50` * * The functions that are chained to `queryTipDistributions()` are applied in the order they are called. For example, if you apply `ascending("transaction.transactionDate")` and then `ascending("staff.id")`, the results are sorted first by the `"transaction.transactionDate"`, and then, if there are multiple results with the same `"transaction.transactionDate"`, the items are sorted by `"staff.id"`. * * When setting a date filter remember to use * [UTC time](https://en.wikipedia.org/wiki/Coordinated_Universal_Time). * * The following `TipDistributionsQueryBuilder` functions are supported for the `queryTipDistributions()` function. For a full description of the tip distributions object, see the object returned for the [items](https://dev.wix.com/docs/sdk/backend-modules/ecom/tips/tip-distributions-query-result/items) property in `TipDistributionsQueryResult`. * */ (): TipDistributionsQueryBuilder; } export declare function sumTipDistributionAmounts(httpClient: HttpClient): SumTipDistributionAmountsSignature; interface SumTipDistributionAmountsSignature { /** * Sums tip distribution amounts, given the provided filtering. * @param - 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 | null): Promise; } export { ActionEvent, AddTipDistributionsToOrderOptions, AddTipDistributionsToOrderRequest, AddTipDistributionsToOrderRequestIdentifierOneOf, AddTipDistributionsToOrderResponse, AddTipDistributionsToOrderResponseNonNullableFields, ApplyTipDistributionsRequest, ApplyTipDistributionsResponse, CatalogReference, CommonIdentificationData, CommonIdentificationDataIdOneOf, CreateTipDistributionsRequest, CreateTipDistributionsResponse, CursorPaging, CursorPagingMetadata, CursorQuery, CursorQueryPagingMethodOneOf, Cursors, DeleteTipDistributionsRequest, DeleteTipDistributionsRequestDeleteByOneOf, DeleteTipDistributionsResponse, DomainEvent, DomainEventBodyOneOf, EntityCreatedEvent, EntityDeletedEvent, EntityUpdatedEvent, GetTipByDraftOrderIdRequest, GetTipByDraftOrderIdResponse, GetTipByDraftOrderIdResponseNonNullableFields, GetTipByOrderIdRequest, GetTipByOrderIdResponse, GetTipByOrderIdResponseNonNullableFields, GetTipChoiceRequest, GetTipChoiceResponse, GetTipChoiceResponseNonNullableFields, IdentificationData, IdentificationDataIdOneOf, IdentityType, LineItemInfo, MessageEnvelope, OrderInfo, OrderInfoIdentifierOneOf, PreviewTipOptions, PreviewTipRequest, PreviewTipResponse, PreviewTipResponseNonNullableFields, Price, PublishTipDistributionsCreatedEventRequest, PublishTipDistributionsCreatedEventResponse, QueryBy, QueryTipDistributionsRequest, QueryTipDistributionsResponse, QueryTipDistributionsResponseNonNullableFields, RemoveTipFromOrderOptions, RemoveTipFromOrderRequest, RemoveTipFromOrderRequestIdentifierOneOf, RemoveTipFromOrderResponse, RemoveTipFromOrderResponseNonNullableFields, RestoreInfo, SetTipOnOrderOptions, SetTipOnOrderRequest, SetTipOnOrderRequestIdentifierOneOf, SetTipOnOrderResponse, SetTipOnOrderResponseNonNullableFields, SortOrder, Sorting, Source, Staff, SumTipDistributionAmountsRequest, SumTipDistributionAmountsResponse, Tip, TipChoice, TipDistribution, TipDistributionsCreated, TipDistributionsQueryBuilder, TipDistributionsQueryResult, TipType, Transaction, UpdateTipChoiceOptions, UpdateTipChoiceRequest, UpdateTipChoiceResponse, UpdateTipChoiceResponseNonNullableFields, WebhookIdentityType, } from './tips-v1-tip-tips.universal.js';