declare module "wix-ecom.v2" { const __debug: { verboseLogging: { on: () => boolean; off: () => boolean; }; }; interface BackInStockNotificationRequest { /** * Request id (autogenerated upon creation) * @readonly */ _id?: string | null; /** Item identifier */ catalogReference?: CatalogReference; /** Email that will receive notification about item being back in stock */ email?: string; /** * Contact id (autogenerated upon creation) which is associated with given email. Will receive all notifications * @readonly */ contactId?: string | null; /** * Request status * @readonly */ status?: Status; /** * Describes how notification was made: automatically or manually by store owner * @readonly */ autoNotified?: boolean | null; /** * Order creation date and time. * @readonly */ _createdDate?: Date; /** override default item url returned from the implementer */ itemUrl?: string | null; } /** Used for grouping line items and is sent on add to cart */ interface CatalogReference { /** ID of the item within its Wix or 3rd-party catalog. For example, `productId` for Wix Stores or `bookingId` for Wix Bookings. */ catalogItemId?: string; /** * ID of the catalog app. For items from Wix apps, the following values always apply: * + Wix Stores: `"215238eb-22a5-4c36-9e7b-e7c08025e04e"` * + Wix Bookings: `"13d21c63-b5ec-5912-8397-c3a5ddb27a97"` */ appId?: string; /** * Additional info in key:value form. For example, to specify Wix Stores product options or variants: * + `{"options": {"options": {"Size": "M", "Color": "Red"}}}` * + `{"options": {"variantId": ""}}` */ options?: Record | null; } enum Status { UNSPECIFIED = "UNSPECIFIED", /** initial status of all new requests */ RECEIVED = "RECEIVED", PROCESSING = "PROCESSING", NOTIFICATION_SENT = "NOTIFICATION_SENT", FAILED = "FAILED" } interface InvalidateCache extends InvalidateCacheGetByOneOf { /** Invalidate by msId. NOT recommended, as this will invalidate the entire site cache! */ metaSiteId?: string; /** Invalidate by Site ID. NOT recommended, as this will invalidate the entire site cache! */ siteId?: string; /** Invalidate by App */ app?: App; /** Invalidate by page id */ page?: Page; /** Invalidate by URI path */ uri?: URI; /** tell us why you're invalidating the cache. You don't need to add your app name */ reason?: string | null; /** Is local DS */ localDc?: boolean; } /** @oneof */ interface InvalidateCacheGetByOneOf { /** Invalidate by msId. NOT recommended, as this will invalidate the entire site cache! */ metaSiteId?: string; /** Invalidate by Site ID. NOT recommended, as this will invalidate the entire site cache! */ siteId?: string; /** Invalidate by App */ app?: App; /** Invalidate by page id */ page?: Page; /** Invalidate by URI path */ uri?: URI; } interface App { /** The AppDefId */ appDefId?: string; /** The instance Id */ instanceId?: string; } interface Page { /** the msid the page is on */ metaSiteId?: string; /** Invalidate by Page ID */ pageId?: string; } interface URI { /** the msid the URI is on */ metaSiteId?: string; /** URI path to invalidate (e.g. page/my/path) - without leading/trailing slashes */ uriPath?: string; } interface CreateBackInStockNotificationRequestRequest { /** Notification request data (id is ignored, as it's generated by server) */ request: BackInStockNotificationRequest; /** Item data used in email and chat notifications */ itemDetails: BackInStockItemDetails; } interface BackInStockItemDetails { /** Item name */ name?: string; /** Item price */ price?: string; /** Item image */ image?: string; } interface CreateBackInStockNotificationRequestResponse { /** Created BackInStockNotificationRequest */ request?: BackInStockNotificationRequest; } interface GetBackInStockNotificationRequestRequest { /** BackInStockNotificationRequest id */ _id: string; } interface GetBackInStockNotificationRequestResponse { /** Requested BackInStockNotificationRequest */ request?: BackInStockNotificationRequest; } interface DeleteBackInStockNotificationRequestRequest { /** BackInStockNotificationRequest id */ _id: string; } interface DeleteBackInStockNotificationRequestResponse { } interface MarkAsNotificationSentRequest { /** BackInStockNotificationRequest id */ _id: string; } interface MarkAsNotificationSentResponse { /** Updated BackInStockNotificationRequest */ request?: BackInStockNotificationRequest; } interface QueryBackInStockNotificationRequestsRequest { /** Query options */ query: PlatformQuery; } interface PlatformQuery extends PlatformQueryPagingMethodOneOf { /** Pointer to page of results using offset. Cannot be used together with `cursorPaging`. */ paging?: PlatformPaging; /** Cursor pointing to page of results. Cannot be used together with `paging`. `cursorPaging.cursor` can not be used together with `filter` or `sort`. */ cursorPaging?: CursorPaging; /** Filter object. */ filter?: Record | null; /** Sorting options. For example, `[{"fieldName":"sortField1"},{"fieldName":"sortField2","direction":"DESC"}]`. */ sort?: Sorting[]; } /** @oneof */ interface PlatformQueryPagingMethodOneOf { /** Pointer to page of results using offset. Cannot be used together with `cursorPaging`. */ paging?: PlatformPaging; /** Cursor pointing to page of results. Cannot be used together with `paging`. `cursorPaging.cursor` can not be used together with `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 PlatformPaging { /** Number of items to load. */ limit?: number | null; /** Number of items to skip in the current sort order. */ offset?: number | null; } interface CursorPaging { /** Number of items to load. */ limit?: number | null; /** * Pointer to the next or previous page in the list of results. * * You can get the relevant cursor token * from the `pagingMetadata` object in the previous call's response. * Not relevant for the first request. */ cursor?: string | null; } interface QueryBackInStockNotificationRequestsResponse { /** Matching BackInStockNotificationRequests */ requests?: BackInStockNotificationRequest[]; /** Details on the paged set of results returned. */ metadata?: PlatformPagingMetadata; } interface PlatformPagingMetadata { /** The number of items returned in this response. */ count?: number | null; /** The offset which was requested. Returned if offset paging was used. */ offset?: number | null; /** The total number of items that match the query. Returned if offset paging was used. */ total?: number | null; /** Cursors to navigate through result pages. Returned if cursor paging was used. */ cursors?: Cursors; } interface Cursors { /** Cursor pointing to next page in the list of results. */ next?: string | null; /** Cursor pointing to previous page in the list of results. */ prev?: string | null; } interface GetBackInStockNotificationRequestsCountByCatalogReferencesRequest { /** Back in stock requests to be counted identified by their CatalogReference. */ catalogReferences: CatalogReference[]; } interface GetBackInStockNotificationRequestsCountByCatalogReferencesResponse { /** The number of back in stock notifications for each of the catalog references requested. */ countsPerCatalogReference?: BackInStockNotificationRequestsCount[]; } /** Maps each back in stock CatalogReference to the results (the number of unique occurrences). */ interface BackInStockNotificationRequestsCount { /** Catalog and item reference. Holds IDs for the item and the catalog it came from. */ catalogReference?: CatalogReference; /** The number of unique occurrences of back in stock requests for given CatalogReference. */ count?: number; } interface ReportItemsBackInStockRequest { /** * Item identifier. All BackInStockNotificationRequests for this item identifier will be processed. * Cannot be used with `request_ids`. */ catalogReference?: CatalogReference; /** * Identifiers of BackInStockNotificationRequest that need to be handled. * Cannot be used with `catalog_reference`. */ requestIds?: string[]; /** * Item data used in email and chat notifications. * Item details values will also be passed into automation template which is used for actual back in stock notification to User of User * (item_details.price will be passed as `item.price`, item_details.name - as `item.name`, item_details.image.url as `item.image.url` * In case when automation template contains only [`item.price`, `item.name`, `item.image.url`] placeholders, * `extra_automation_template_parameters` may be left empty * In case when automation template is defined without using [`item.price`, `item.name`, `item.image.url`] placeholders, * values should be passed in `extra_automation_template_parameters` */ itemDetails: BackInStockItemDetails; /** * Extra key-value pairs that will be passed to back in stock notification email template * [`item.price`, `item.name`, `item.image.url`] placeholder values that are taken from item_details field may be overridden by values from this map */ extraAutomationTemplateParameters?: Record; } interface ReportItemsBackInStockResponse { } interface DomainEvent extends DomainEventBodyOneOf { createdEvent?: EntityCreatedEvent; updatedEvent?: EntityUpdatedEvent; deletedEvent?: EntityDeletedEvent; actionEvent?: ActionEvent; extendedFieldsUpdatedEvent?: ExtendedFieldsUpdatedEvent; /** random GUID so clients can tell if event was already handled */ _id?: string; /** * Assumes actions are also always typed to an entity_type * Example: wix.stores.catalog.product, wix.bookings.session, wix.payments.transaction */ entityFqdn?: string; /** * This is top level to ease client code dispatching of messages (switch on entity_fqdn+slug) * This is although the created/updated/deleted notion is duplication of the oneof types * Example: created/updated/deleted/started/completed/email_opened */ slug?: string; /** * Assuming that all messages including Actions have id * Example: The id of the specific order, the id of a specific campaign */ entityId?: string; /** The time of the event. Useful if there was a delay in dispatching */ eventTime?: Date; /** * A field that should be set if this event was triggered by an anonymize request. * For example you must set it to true when sending an event as a result of a GDPR right to be forgotten request. * NOTE: This field is not relevant for `EntityCreatedEvent` but is located here for better ergonomics of consumers. */ triggeredByAnonymizeRequest?: boolean | null; /** If present, indicates the action that triggered the event. */ originatedFrom?: string | null; /** * A sequence number defining the order of updates to the underlying entity. * For example, given that some entity was updated at 16:00 and than again at 16:01, * it is guaranteed that the sequence number of the second update is strictly higher than the first. * As the consumer, you can use this value to ensure that you handle messages in the correct order. * To do so, you will need to persist this number on your end, and compare the sequence number from the * message against the one you have stored. Given that the stored number is higher, you should ignore the message. */ entityEventSequence?: string | null; } /** @oneof */ interface DomainEventBodyOneOf { createdEvent?: EntityCreatedEvent; updatedEvent?: EntityUpdatedEvent; deletedEvent?: EntityDeletedEvent; actionEvent?: ActionEvent; extendedFieldsUpdatedEvent?: ExtendedFieldsUpdatedEvent; } interface EntityCreatedEvent { entityAsJson?: string; /** * Indicates the event was triggered by a restore-from-trashbin operation for a previously deleted entity * @internal */ triggeredByUndelete?: boolean | null; } interface EntityUpdatedEvent { /** * Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff. * This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects. * We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it. */ currentEntityAsJson?: string; /** * This field is currently part of the of the EntityUpdatedEvent msg, but scala/node libraries which implements the domain events standard * wont populate it / have any reference to it in the API. * The main reason for it is that fetching the old entity from the DB will have a performance hit on an update operation so unless truly needed, * the developer should send only the new (current) entity. * An additional reason is not wanting to send this additional entity over the wire (kafka) since in some cases it can be really big * Developers that must reflect the old entity will have to implement their own domain event sender mechanism which will follow the DomainEvent proto message. * @internal */ previousEntityAsJson?: string | null; /** * WIP - This property will hold both names and values of the updated fields of the entity. * For more details please see [adr](https://docs.google.com/document/d/1PdqsOM20Ph2HAkmx8zvUnzzk3Sekp3BR9h34wSvsRnI/edit#heading=h.phlw87mh2imx) or [issue](https://github.com/wix-private/nile-tracker/issues/363) * @internal */ entityUpdates?: Record; } interface EntityDeletedEvent { /** * Indicates if the entity is sent to trash-bin. only available when trash-bin is enabled * @internal */ movedToTrash?: boolean | null; } interface ActionEvent { bodyAsJson?: string; } interface ExtendedFieldsUpdatedEvent { currentEntityAsJson?: string; } interface Empty { } /** * Create a BackInStockNotificationRequest. May not create new entry if there is existing non resolved request * for same CatalogReference and email (will return existing request in response) * @param request - Notification request data (id is ignored, as it's generated by server) * @public * @documentationMaturity preview * @requiredField options * @requiredField options.itemDetails * @requiredField options.itemDetails.name * @requiredField options.itemDetails.price * @requiredField request * @requiredField request.catalogReference * @requiredField request.catalogReference.appId * @requiredField request.catalogReference.catalogItemId * @requiredField request.email * @returns Created BackInStockNotificationRequest */ function createBackInStockNotificationRequest(request: BackInStockNotificationRequest, options: CreateBackInStockNotificationRequestOptions): Promise; interface CreateBackInStockNotificationRequestOptions { /** Item data used in email and chat notifications */ itemDetails: BackInStockItemDetails; } /** * Get BackInStockNotificationRequest by id * @param _id - BackInStockNotificationRequest id * @public * @documentationMaturity preview * @requiredField _id * @returns Requested BackInStockNotificationRequest */ function getBackInStockNotificationRequest(_id: string): Promise; /** * Delete BackInStockNotificationRequest by id * @param _id - BackInStockNotificationRequest id * @public * @documentationMaturity preview * @requiredField _id */ function deleteBackInStockNotificationRequest(_id: string): Promise; /** * Update BackInStockNotificationRequest status to `NOTIFICATION_SENT` * @param _id - BackInStockNotificationRequest id * @public * @documentationMaturity preview * @requiredField _id */ function markAsNotificationSent(_id: string): Promise; /** * Returns BackInStockNotificationRequests matching given search parameters * @internal * @documentationMaturity preview */ function queryBackInStockNotificationRequests(): RequestsQueryBuilder; interface QueryCursorResult { cursors: Cursors; hasNext: () => boolean; hasPrev: () => boolean; length: number; pageSize: number; } interface RequestsQueryResult extends QueryCursorResult { items: BackInStockNotificationRequest[]; query: RequestsQueryBuilder; next: () => Promise; prev: () => Promise; } interface RequestsQueryBuilder { /** @param limit - Number of items to return, which is also the `pageSize` of the results object. * @documentationMaturity preview */ limit: (limit: number) => RequestsQueryBuilder; /** @param cursor - A pointer to specific record * @documentationMaturity preview */ skipTo: (cursor: string) => RequestsQueryBuilder; /** @documentationMaturity preview */ find: () => Promise; } /** * Returns the number of BackInStockNotificationRequests for a given CatalogReferences. * @param catalogReferences - Back in stock requests to be counted identified by their CatalogReference. * @public * @documentationMaturity preview * @requiredField catalogReferences */ function getBackInStockNotificationRequestsCountByCatalogReferences(catalogReferences: CatalogReference[]): Promise; /** * Will handle all BackInStockNotificationRequests referencing given item (if `catalog_reference` parameter is present) * Otherwise (if `request_ids` parameter present) will handle BackInStockNotificationRequests with given ids * @public * @documentationMaturity preview * @requiredField options * @requiredField options.itemDetails * @requiredField options.itemDetails.name * @requiredField options.itemDetails.price */ function reportItemsBackInStock(options: ReportItemsBackInStockOptions): Promise; interface ReportItemsBackInStockOptions { /** * Item identifier. All BackInStockNotificationRequests for this item identifier will be processed. * Cannot be used with `request_ids`. */ catalogReference?: CatalogReference; /** * Identifiers of BackInStockNotificationRequest that need to be handled. * Cannot be used with `catalog_reference`. */ requestIds?: string[]; /** * Item data used in email and chat notifications. * Item details values will also be passed into automation template which is used for actual back in stock notification to User of User * (item_details.price will be passed as `item.price`, item_details.name - as `item.name`, item_details.image.url as `item.image.url` * In case when automation template contains only [`item.price`, `item.name`, `item.image.url`] placeholders, * `extra_automation_template_parameters` may be left empty * In case when automation template is defined without using [`item.price`, `item.name`, `item.image.url`] placeholders, * values should be passed in `extra_automation_template_parameters` */ itemDetails: BackInStockItemDetails; /** * Extra key-value pairs that will be passed to back in stock notification email template * [`item.price`, `item.name`, `item.image.url`] placeholder values that are taken from item_details field may be overridden by values from this map */ extraAutomationTemplateParameters?: Record; } const ecomV1BackInStockNotificationRequest_universal_d___debug: typeof __debug; type ecomV1BackInStockNotificationRequest_universal_d_BackInStockNotificationRequest = BackInStockNotificationRequest; type ecomV1BackInStockNotificationRequest_universal_d_CatalogReference = CatalogReference; type ecomV1BackInStockNotificationRequest_universal_d_Status = Status; const ecomV1BackInStockNotificationRequest_universal_d_Status: typeof Status; type ecomV1BackInStockNotificationRequest_universal_d_InvalidateCache = InvalidateCache; type ecomV1BackInStockNotificationRequest_universal_d_InvalidateCacheGetByOneOf = InvalidateCacheGetByOneOf; type ecomV1BackInStockNotificationRequest_universal_d_App = App; type ecomV1BackInStockNotificationRequest_universal_d_Page = Page; type ecomV1BackInStockNotificationRequest_universal_d_URI = URI; type ecomV1BackInStockNotificationRequest_universal_d_CreateBackInStockNotificationRequestRequest = CreateBackInStockNotificationRequestRequest; type ecomV1BackInStockNotificationRequest_universal_d_BackInStockItemDetails = BackInStockItemDetails; type ecomV1BackInStockNotificationRequest_universal_d_CreateBackInStockNotificationRequestResponse = CreateBackInStockNotificationRequestResponse; type ecomV1BackInStockNotificationRequest_universal_d_GetBackInStockNotificationRequestRequest = GetBackInStockNotificationRequestRequest; type ecomV1BackInStockNotificationRequest_universal_d_GetBackInStockNotificationRequestResponse = GetBackInStockNotificationRequestResponse; type ecomV1BackInStockNotificationRequest_universal_d_DeleteBackInStockNotificationRequestRequest = DeleteBackInStockNotificationRequestRequest; type ecomV1BackInStockNotificationRequest_universal_d_DeleteBackInStockNotificationRequestResponse = DeleteBackInStockNotificationRequestResponse; type ecomV1BackInStockNotificationRequest_universal_d_MarkAsNotificationSentRequest = MarkAsNotificationSentRequest; type ecomV1BackInStockNotificationRequest_universal_d_MarkAsNotificationSentResponse = MarkAsNotificationSentResponse; type ecomV1BackInStockNotificationRequest_universal_d_QueryBackInStockNotificationRequestsRequest = QueryBackInStockNotificationRequestsRequest; type ecomV1BackInStockNotificationRequest_universal_d_PlatformQuery = PlatformQuery; type ecomV1BackInStockNotificationRequest_universal_d_PlatformQueryPagingMethodOneOf = PlatformQueryPagingMethodOneOf; type ecomV1BackInStockNotificationRequest_universal_d_Sorting = Sorting; type ecomV1BackInStockNotificationRequest_universal_d_SortOrder = SortOrder; const ecomV1BackInStockNotificationRequest_universal_d_SortOrder: typeof SortOrder; type ecomV1BackInStockNotificationRequest_universal_d_PlatformPaging = PlatformPaging; type ecomV1BackInStockNotificationRequest_universal_d_CursorPaging = CursorPaging; type ecomV1BackInStockNotificationRequest_universal_d_QueryBackInStockNotificationRequestsResponse = QueryBackInStockNotificationRequestsResponse; type ecomV1BackInStockNotificationRequest_universal_d_PlatformPagingMetadata = PlatformPagingMetadata; type ecomV1BackInStockNotificationRequest_universal_d_Cursors = Cursors; type ecomV1BackInStockNotificationRequest_universal_d_GetBackInStockNotificationRequestsCountByCatalogReferencesRequest = GetBackInStockNotificationRequestsCountByCatalogReferencesRequest; type ecomV1BackInStockNotificationRequest_universal_d_GetBackInStockNotificationRequestsCountByCatalogReferencesResponse = GetBackInStockNotificationRequestsCountByCatalogReferencesResponse; type ecomV1BackInStockNotificationRequest_universal_d_BackInStockNotificationRequestsCount = BackInStockNotificationRequestsCount; type ecomV1BackInStockNotificationRequest_universal_d_ReportItemsBackInStockRequest = ReportItemsBackInStockRequest; type ecomV1BackInStockNotificationRequest_universal_d_ReportItemsBackInStockResponse = ReportItemsBackInStockResponse; type ecomV1BackInStockNotificationRequest_universal_d_DomainEvent = DomainEvent; type ecomV1BackInStockNotificationRequest_universal_d_DomainEventBodyOneOf = DomainEventBodyOneOf; type ecomV1BackInStockNotificationRequest_universal_d_EntityCreatedEvent = EntityCreatedEvent; type ecomV1BackInStockNotificationRequest_universal_d_EntityUpdatedEvent = EntityUpdatedEvent; type ecomV1BackInStockNotificationRequest_universal_d_EntityDeletedEvent = EntityDeletedEvent; type ecomV1BackInStockNotificationRequest_universal_d_ActionEvent = ActionEvent; type ecomV1BackInStockNotificationRequest_universal_d_ExtendedFieldsUpdatedEvent = ExtendedFieldsUpdatedEvent; type ecomV1BackInStockNotificationRequest_universal_d_Empty = Empty; const ecomV1BackInStockNotificationRequest_universal_d_createBackInStockNotificationRequest: typeof createBackInStockNotificationRequest; type ecomV1BackInStockNotificationRequest_universal_d_CreateBackInStockNotificationRequestOptions = CreateBackInStockNotificationRequestOptions; const ecomV1BackInStockNotificationRequest_universal_d_getBackInStockNotificationRequest: typeof getBackInStockNotificationRequest; const ecomV1BackInStockNotificationRequest_universal_d_deleteBackInStockNotificationRequest: typeof deleteBackInStockNotificationRequest; const ecomV1BackInStockNotificationRequest_universal_d_markAsNotificationSent: typeof markAsNotificationSent; const ecomV1BackInStockNotificationRequest_universal_d_queryBackInStockNotificationRequests: typeof queryBackInStockNotificationRequests; type ecomV1BackInStockNotificationRequest_universal_d_RequestsQueryResult = RequestsQueryResult; type ecomV1BackInStockNotificationRequest_universal_d_RequestsQueryBuilder = RequestsQueryBuilder; const ecomV1BackInStockNotificationRequest_universal_d_getBackInStockNotificationRequestsCountByCatalogReferences: typeof getBackInStockNotificationRequestsCountByCatalogReferences; const ecomV1BackInStockNotificationRequest_universal_d_reportItemsBackInStock: typeof reportItemsBackInStock; type ecomV1BackInStockNotificationRequest_universal_d_ReportItemsBackInStockOptions = ReportItemsBackInStockOptions; namespace ecomV1BackInStockNotificationRequest_universal_d { export { ecomV1BackInStockNotificationRequest_universal_d___debug as __debug, ecomV1BackInStockNotificationRequest_universal_d_BackInStockNotificationRequest as BackInStockNotificationRequest, ecomV1BackInStockNotificationRequest_universal_d_CatalogReference as CatalogReference, ecomV1BackInStockNotificationRequest_universal_d_Status as Status, ecomV1BackInStockNotificationRequest_universal_d_InvalidateCache as InvalidateCache, ecomV1BackInStockNotificationRequest_universal_d_InvalidateCacheGetByOneOf as InvalidateCacheGetByOneOf, ecomV1BackInStockNotificationRequest_universal_d_App as App, ecomV1BackInStockNotificationRequest_universal_d_Page as Page, ecomV1BackInStockNotificationRequest_universal_d_URI as URI, ecomV1BackInStockNotificationRequest_universal_d_CreateBackInStockNotificationRequestRequest as CreateBackInStockNotificationRequestRequest, ecomV1BackInStockNotificationRequest_universal_d_BackInStockItemDetails as BackInStockItemDetails, ecomV1BackInStockNotificationRequest_universal_d_CreateBackInStockNotificationRequestResponse as CreateBackInStockNotificationRequestResponse, ecomV1BackInStockNotificationRequest_universal_d_GetBackInStockNotificationRequestRequest as GetBackInStockNotificationRequestRequest, ecomV1BackInStockNotificationRequest_universal_d_GetBackInStockNotificationRequestResponse as GetBackInStockNotificationRequestResponse, ecomV1BackInStockNotificationRequest_universal_d_DeleteBackInStockNotificationRequestRequest as DeleteBackInStockNotificationRequestRequest, ecomV1BackInStockNotificationRequest_universal_d_DeleteBackInStockNotificationRequestResponse as DeleteBackInStockNotificationRequestResponse, ecomV1BackInStockNotificationRequest_universal_d_MarkAsNotificationSentRequest as MarkAsNotificationSentRequest, ecomV1BackInStockNotificationRequest_universal_d_MarkAsNotificationSentResponse as MarkAsNotificationSentResponse, ecomV1BackInStockNotificationRequest_universal_d_QueryBackInStockNotificationRequestsRequest as QueryBackInStockNotificationRequestsRequest, ecomV1BackInStockNotificationRequest_universal_d_PlatformQuery as PlatformQuery, ecomV1BackInStockNotificationRequest_universal_d_PlatformQueryPagingMethodOneOf as PlatformQueryPagingMethodOneOf, ecomV1BackInStockNotificationRequest_universal_d_Sorting as Sorting, ecomV1BackInStockNotificationRequest_universal_d_SortOrder as SortOrder, ecomV1BackInStockNotificationRequest_universal_d_PlatformPaging as PlatformPaging, ecomV1BackInStockNotificationRequest_universal_d_CursorPaging as CursorPaging, ecomV1BackInStockNotificationRequest_universal_d_QueryBackInStockNotificationRequestsResponse as QueryBackInStockNotificationRequestsResponse, ecomV1BackInStockNotificationRequest_universal_d_PlatformPagingMetadata as PlatformPagingMetadata, ecomV1BackInStockNotificationRequest_universal_d_Cursors as Cursors, ecomV1BackInStockNotificationRequest_universal_d_GetBackInStockNotificationRequestsCountByCatalogReferencesRequest as GetBackInStockNotificationRequestsCountByCatalogReferencesRequest, ecomV1BackInStockNotificationRequest_universal_d_GetBackInStockNotificationRequestsCountByCatalogReferencesResponse as GetBackInStockNotificationRequestsCountByCatalogReferencesResponse, ecomV1BackInStockNotificationRequest_universal_d_BackInStockNotificationRequestsCount as BackInStockNotificationRequestsCount, ecomV1BackInStockNotificationRequest_universal_d_ReportItemsBackInStockRequest as ReportItemsBackInStockRequest, ecomV1BackInStockNotificationRequest_universal_d_ReportItemsBackInStockResponse as ReportItemsBackInStockResponse, ecomV1BackInStockNotificationRequest_universal_d_DomainEvent as DomainEvent, ecomV1BackInStockNotificationRequest_universal_d_DomainEventBodyOneOf as DomainEventBodyOneOf, ecomV1BackInStockNotificationRequest_universal_d_EntityCreatedEvent as EntityCreatedEvent, ecomV1BackInStockNotificationRequest_universal_d_EntityUpdatedEvent as EntityUpdatedEvent, ecomV1BackInStockNotificationRequest_universal_d_EntityDeletedEvent as EntityDeletedEvent, ecomV1BackInStockNotificationRequest_universal_d_ActionEvent as ActionEvent, ecomV1BackInStockNotificationRequest_universal_d_ExtendedFieldsUpdatedEvent as ExtendedFieldsUpdatedEvent, ecomV1BackInStockNotificationRequest_universal_d_Empty as Empty, ecomV1BackInStockNotificationRequest_universal_d_createBackInStockNotificationRequest as createBackInStockNotificationRequest, ecomV1BackInStockNotificationRequest_universal_d_CreateBackInStockNotificationRequestOptions as CreateBackInStockNotificationRequestOptions, ecomV1BackInStockNotificationRequest_universal_d_getBackInStockNotificationRequest as getBackInStockNotificationRequest, ecomV1BackInStockNotificationRequest_universal_d_deleteBackInStockNotificationRequest as deleteBackInStockNotificationRequest, ecomV1BackInStockNotificationRequest_universal_d_markAsNotificationSent as markAsNotificationSent, ecomV1BackInStockNotificationRequest_universal_d_queryBackInStockNotificationRequests as queryBackInStockNotificationRequests, ecomV1BackInStockNotificationRequest_universal_d_RequestsQueryResult as RequestsQueryResult, ecomV1BackInStockNotificationRequest_universal_d_RequestsQueryBuilder as RequestsQueryBuilder, ecomV1BackInStockNotificationRequest_universal_d_getBackInStockNotificationRequestsCountByCatalogReferences as getBackInStockNotificationRequestsCountByCatalogReferences, ecomV1BackInStockNotificationRequest_universal_d_reportItemsBackInStock as reportItemsBackInStock, ecomV1BackInStockNotificationRequest_universal_d_ReportItemsBackInStockOptions as ReportItemsBackInStockOptions, }; } interface CurrencyRate { } interface ListCurrenciesRequest { } interface ListCurrenciesResponse { /** Supported currencies. */ currencies?: Currency[]; } interface Currency { /** A 3-letter [ISO-4217](https://en.wikipedia.org/wiki/ISO_4217) currency code. */ code?: string; /** Currency symbol. */ symbol?: string; } interface ConvertCurrencyRequest { /** Amounts to convert. */ amounts?: DecimalValue[]; /** Original currency to convert from as a 3-letter [ISO-4217](https://en.wikipedia.org/wiki/ISO_4217) code. The `from` currency code must exist in the array returned by the [`listCurrencies()`](#listcurrencies) function. */ from: string; /** Target currency to convert to as a 3-letter [ISO-4217](https://en.wikipedia.org/wiki/ISO_4217) code. The `to` currency code must exist in the array returned by the [`listCurrencies()`](#listcurrencies) function. */ to: string; } interface DecimalValue { /** The value without decimal points. For example, the number `10.95` becomes `1095`. */ value?: string; /** Decimal places to apply. For example, the number of decimal places for `10.95` is `2`. */ decimalPlaces?: number; } interface ConvertCurrencyResponse { /** Converted amounts. */ amounts?: DecimalValue[]; /** Date and time the conversion rate was last updated. */ rateTimestamp?: Date | null; } interface ConversionRateRequest { /** Original currency to get the rate for as a 3-letter [ISO-4217](https://en.wikipedia.org/wiki/ISO_4217) code. The `from` currency code must exist in the array returned by the [`listCurrencies()`](#listcurrencies) function. */ from: string; /** Target currency to get the rate for as a 3-letter [ISO-4217](https://en.wikipedia.org/wiki/ISO_4217) code. The `to` currency code must exist in the array returned by the [`listCurrencies()`](#listcurrencies) function. */ to: string; } interface ConversionRateResponse { /** Conversion rate between 2 currencies. */ rate?: DecimalValue; /** Date and time the conversion rate was last updated. */ rateTimestamp?: Date | null; } /** * Returns an array of currencies. The array lists all currencies for which Wix supports conversion and their symbols. * @public * @permissionId CURRENCY_CONVERTER.READ_CURRENCIES * @adminMethod */ function listCurrencies(): Promise; /** * Returns an array of amounts converted from the original (`from`) currency to the target (`to`) currency and the timestamp for the conversion rate used. * * * Use the `convertCurrency()` function to convert an array of one or more amounts between two currencies. The `convertCurrency()` function returns an array of converted amounts and the timestamp for the conversion rate used. * * > **Note**: The currency codes used must exist in the array of supported currencies returned by the [`listCurrencies()`](#listcurrencies) function. * * @param amounts - Amounts to convert. * @public * @requiredField amounts * @requiredField identifiers * @requiredField identifiers.from * @requiredField identifiers.to * @param identifiers - Identifying details needed to determine which currency rate to convert. The combination of the `from` and `to` properties together comprise the unique ID. * @param options - Options to use when converting currency. * @permissionId CURRENCY_CONVERTER.READ_CURRENCIES * @adminMethod */ function convertCurrency(identifiers: ConvertCurrencyIdentifiers, amounts: DecimalValue[]): Promise; interface ConvertCurrencyIdentifiers { /** Original currency to convert from as a 3-letter [ISO-4217](https://en.wikipedia.org/wiki/ISO_4217) code. The `from` currency code must exist in the array returned by the [`listCurrencies()`](#listcurrencies) function. */ from: string; /** Target currency to convert to as a 3-letter [ISO-4217](https://en.wikipedia.org/wiki/ISO_4217) code. The `to` currency code must exist in the array returned by the [`listCurrencies()`](#listcurrencies) function. */ to: string; } /** * Returns the conversion rate between 2 currencies. * @public * @requiredField identifiers * @requiredField identifiers.from * @requiredField identifiers.to * @param identifiers - Identifying details needed to get the conversion rate. The combination of the `from` and `to` properties together comprise the unique ID. * @permissionId CURRENCY_CONVERTER.READ_CURRENCIES * @adminMethod */ function getConversionRate(identifiers: GetConversionRateIdentifiers): Promise; interface GetConversionRateIdentifiers { /** Original currency to get the rate for as a 3-letter [ISO-4217](https://en.wikipedia.org/wiki/ISO_4217) code. The `from` currency code must exist in the array returned by the [`listCurrencies()`](#listcurrencies) function. */ from: string; /** Target currency to get the rate for as a 3-letter [ISO-4217](https://en.wikipedia.org/wiki/ISO_4217) code. The `to` currency code must exist in the array returned by the [`listCurrencies()`](#listcurrencies) function. */ to: string; } type ecommerceCurrencyConverterV1CurrencyRate_universal_d_CurrencyRate = CurrencyRate; type ecommerceCurrencyConverterV1CurrencyRate_universal_d_ListCurrenciesRequest = ListCurrenciesRequest; type ecommerceCurrencyConverterV1CurrencyRate_universal_d_ListCurrenciesResponse = ListCurrenciesResponse; type ecommerceCurrencyConverterV1CurrencyRate_universal_d_Currency = Currency; type ecommerceCurrencyConverterV1CurrencyRate_universal_d_ConvertCurrencyRequest = ConvertCurrencyRequest; type ecommerceCurrencyConverterV1CurrencyRate_universal_d_DecimalValue = DecimalValue; type ecommerceCurrencyConverterV1CurrencyRate_universal_d_ConvertCurrencyResponse = ConvertCurrencyResponse; type ecommerceCurrencyConverterV1CurrencyRate_universal_d_ConversionRateRequest = ConversionRateRequest; type ecommerceCurrencyConverterV1CurrencyRate_universal_d_ConversionRateResponse = ConversionRateResponse; const ecommerceCurrencyConverterV1CurrencyRate_universal_d_listCurrencies: typeof listCurrencies; const ecommerceCurrencyConverterV1CurrencyRate_universal_d_convertCurrency: typeof convertCurrency; type ecommerceCurrencyConverterV1CurrencyRate_universal_d_ConvertCurrencyIdentifiers = ConvertCurrencyIdentifiers; const ecommerceCurrencyConverterV1CurrencyRate_universal_d_getConversionRate: typeof getConversionRate; type ecommerceCurrencyConverterV1CurrencyRate_universal_d_GetConversionRateIdentifiers = GetConversionRateIdentifiers; namespace ecommerceCurrencyConverterV1CurrencyRate_universal_d { export { ecommerceCurrencyConverterV1CurrencyRate_universal_d_CurrencyRate as CurrencyRate, ecommerceCurrencyConverterV1CurrencyRate_universal_d_ListCurrenciesRequest as ListCurrenciesRequest, ecommerceCurrencyConverterV1CurrencyRate_universal_d_ListCurrenciesResponse as ListCurrenciesResponse, ecommerceCurrencyConverterV1CurrencyRate_universal_d_Currency as Currency, ecommerceCurrencyConverterV1CurrencyRate_universal_d_ConvertCurrencyRequest as ConvertCurrencyRequest, ecommerceCurrencyConverterV1CurrencyRate_universal_d_DecimalValue as DecimalValue, ecommerceCurrencyConverterV1CurrencyRate_universal_d_ConvertCurrencyResponse as ConvertCurrencyResponse, ecommerceCurrencyConverterV1CurrencyRate_universal_d_ConversionRateRequest as ConversionRateRequest, ecommerceCurrencyConverterV1CurrencyRate_universal_d_ConversionRateResponse as ConversionRateResponse, ecommerceCurrencyConverterV1CurrencyRate_universal_d_listCurrencies as listCurrencies, ecommerceCurrencyConverterV1CurrencyRate_universal_d_convertCurrency as convertCurrency, ecommerceCurrencyConverterV1CurrencyRate_universal_d_ConvertCurrencyIdentifiers as ConvertCurrencyIdentifiers, ecommerceCurrencyConverterV1CurrencyRate_universal_d_getConversionRate as getConversionRate, ecommerceCurrencyConverterV1CurrencyRate_universal_d_GetConversionRateIdentifiers as GetConversionRateIdentifiers, }; } export { ecomV1BackInStockNotificationRequest_universal_d as backInStockNotification, ecommerceCurrencyConverterV1CurrencyRate_universal_d as currencies }; }