/** * A brand is a visible property of a product. * Adding brands to your products can help improve site and product visibility on search engines. */ export interface Brand { /** * Brand ID. * @readonly */ _id?: string | null; /** * Revision number, which increments by 1 each time the brand is updated. * To prevent conflicting changes, * the current revision must be passed when updating the brand. * * Ignored when creating a brand. * @readonly */ revision?: string | null; /** * Date and time the brand was created. * @readonly */ _createdDate?: Date | null; /** * Date and time the brand was updated. * @readonly */ _updatedDate?: Date | null; /** * Brand name. * >**Note:** `name` must be unique. */ name?: string; /** * Number of products this brand is assigned to. * > **Note:** Returned only when you pass `"ASSIGNED_PRODUCTS_COUNT"` to the `fields` array in Brand API requests. * @readonly */ assignedProductsCount?: number | null; } export 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; /** Invalidate by file (for media files such as PDFs) */ file?: File; /** 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; hardPurge?: boolean; } /** @oneof */ export 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; /** Invalidate by file (for media files such as PDFs) */ file?: File; } export interface App { /** The AppDefId */ appDefId?: string; /** The instance Id */ instanceId?: string; } export interface Page { /** the msid the page is on */ metaSiteId?: string; /** Invalidate by Page ID */ pageId?: string; } export 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; } export interface File { /** the msid the file is related to */ metaSiteId?: string; /** Invalidate by filename (for media files such as PDFs) */ fileName?: string; } export interface CreateBrandRequest { /** Brand to create. */ brand: Brand; } export interface CreateBrandResponse { /** Created brand. */ brand?: Brand; } export interface GetBrandRequest { /** Brand ID. */ brandId: string; /** * Fields to include in the response. * * Supported values: `ASSIGNED_PRODUCTS_COUNT` */ fields?: RequestedFields[]; } export declare enum RequestedFields { UNKNOWN_REQUESTED_FIELD = "UNKNOWN_REQUESTED_FIELD", ASSIGNED_PRODUCTS_COUNT = "ASSIGNED_PRODUCTS_COUNT" } export interface GetBrandResponse { /** Brand. */ brand?: Brand; } export interface UpdateBrandRequest { /** Brand to update. */ brand: Brand; /** * Fields to include in the response. * * Supported values: `ASSIGNED_PRODUCTS_COUNT` */ fields?: RequestedFields[]; } export interface UpdateBrandResponse { /** Updated brand. */ brand?: Brand; } export interface DeleteBrandRequest { /** Brand ID. */ brandId: string; } export interface DeleteBrandResponse { } export interface QueryBrandsRequest { /** Query options. */ query?: CursorQuery; /** * Fields to include in the response. * * Supported values: `ASSIGNED_PRODUCTS_COUNT` */ fields?: RequestedFields[]; } export interface CursorQuery extends CursorQueryPagingMethodOneOf { /** 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 | null; /** * Sort object in the following format: * `[{"fieldName":"sortField1","order":"ASC"},{"fieldName":"sortField2","order":"DESC"}]` */ sort?: Sorting[]; } /** @oneof */ export interface CursorQueryPagingMethodOneOf { /** 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; } export interface Sorting { /** Name of the field to sort by. */ fieldName?: string; /** Sort order. */ order?: SortOrder; } export declare enum SortOrder { /** Ascending order. */ ASC = "ASC", /** Descending order. */ DESC = "DESC" } export 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; } export interface QueryBrandsResponse { /** List of brands. */ brands?: Brand[]; /** Paging metadata. */ pagingMetadata?: CursorPagingMetadata; } export 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; } export 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; } export interface BulkCreateBrandsRequest { /** Brands to create. */ brands: Brand[]; /** * Whether to return the full created brand entities in the response. * * Default: `false` */ returnEntity?: boolean; } export interface BulkCreateBrandsResponse { /** Brands created by bulk action. */ results?: BulkBrandsResult[]; /** Bulk action metadata. */ bulkActionMetadata?: BulkActionMetadata; } export interface BulkBrandsResult { /** Bulk action metadata for brand. */ itemMetadata?: ItemMetadata; /** * Full brand entity. * * Returned only if `returnEntity: true` is passed in the request. */ item?: Brand; } export 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; } export interface ApplicationError { /** Error code. */ code?: string; /** Description of the error. */ description?: string; /** Data related to the error. */ data?: Record | null; } export 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; } export interface BulkUpdateBrandsRequest { /** List of brands to update. */ brands: MaskedBrand[]; /** * Whether to return the full updated brand entities in the response. * * Default: `false` */ returnEntity?: boolean; /** * Fields to include in the response. * * Supported values: `ASSIGNED_PRODUCTS_COUNT` */ fields?: RequestedFields[]; } export interface MaskedBrand { /** Brand to update. */ brand?: Brand; /** Explicit list of fields to update. */ fieldMask?: string[]; } export interface BulkUpdateBrandsResponse { /** Brands updated by bulk action. */ results?: BulkBrandsResult[]; /** Bulk action metadata. */ bulkActionMetadata?: BulkActionMetadata; } export interface GetOrCreateBrandRequest { /** Brand name to retrieve or create. */ brandName: string; /** * Fields to include in the response. * * Supported values: `ASSIGNED_PRODUCTS_COUNT` */ fields?: RequestedFields[]; } export interface GetOrCreateBrandResponse { /** Brand. */ brand?: Brand; } export interface BulkGetOrCreateBrandsRequest { /** Brand names to retrieve or create. */ brandNames: string[]; /** * Fields to include in the response. * * Supported values: `ASSIGNED_PRODUCTS_COUNT` */ fields?: RequestedFields[]; } export interface BulkGetOrCreateBrandsResponse { /** Brands retrieved or created by bulk action. */ results?: BulkBrandsResult[]; /** Bulk action metadata. */ bulkActionMetadata?: BulkActionMetadata; } export interface BulkDeleteBrandsRequest { /** IDs of brands to delete. */ brandIds: string[]; } export interface BulkDeleteBrandsResponse { /** Brands deleted by bulk action. */ results?: BulkDeleteBrandsResponseBulkBrandsResult[]; /** Bulk action metadata. */ bulkActionMetadata?: BulkActionMetadata; } export interface BulkDeleteBrandsResponseBulkBrandsResult { /** Bulk action metadata for brand. */ itemMetadata?: ItemMetadata; } export interface DomainEvent extends DomainEventBodyOneOf { createdEvent?: EntityCreatedEvent; updatedEvent?: EntityUpdatedEvent; deletedEvent?: EntityDeletedEvent; actionEvent?: ActionEvent; /** * Unique event ID. * Allows clients to ignore duplicate webhooks. */ _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; /** ID of the entity associated with the event. */ entityId?: string; /** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example: 2020-04-26T13:57:50.699Z */ eventTime?: Date | null; /** * Whether the event was triggered as a result of a privacy regulation application * (for example, GDPR). */ 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 */ export interface DomainEventBodyOneOf { createdEvent?: EntityCreatedEvent; updatedEvent?: EntityUpdatedEvent; deletedEvent?: EntityDeletedEvent; actionEvent?: ActionEvent; } export interface EntityCreatedEvent { entity?: string; } export interface RestoreInfo { deletedDate?: Date | null; } export 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. */ currentEntity?: string; } export interface EntityDeletedEvent { /** Entity that was deleted */ deletedEntity?: string | null; } export interface ActionEvent { body?: string; } export interface Empty { } export interface MessageEnvelope { /** App instance ID. */ instanceId?: string | null; /** Event type. */ eventType?: string; /** The identification type and identity data. */ identity?: IdentificationData; /** Stringify payload. */ data?: string; } export interface IdentificationData extends IdentificationDataIdOneOf { /** ID of a site visitor that has not logged in to the site. */ anonymousVisitorId?: string; /** ID of a site visitor that has logged in to the site. */ memberId?: string; /** ID of a Wix user (site owner, contributor, etc.). */ wixUserId?: string; /** ID of an app. */ appId?: string; /** @readonly */ identityType?: WebhookIdentityType; } /** @oneof */ export interface IdentificationDataIdOneOf { /** ID of a site visitor that has not logged in to the site. */ anonymousVisitorId?: string; /** ID of a site visitor that has logged in to the site. */ memberId?: string; /** ID of a Wix user (site owner, contributor, etc.). */ wixUserId?: string; /** ID of an app. */ appId?: string; } export declare enum WebhookIdentityType { UNKNOWN = "UNKNOWN", ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR", MEMBER = "MEMBER", WIX_USER = "WIX_USER", APP = "APP" } export interface BrandNonNullableFields { name: string; } export interface CreateBrandResponseNonNullableFields { brand?: BrandNonNullableFields; } export interface GetBrandResponseNonNullableFields { brand?: BrandNonNullableFields; } export interface UpdateBrandResponseNonNullableFields { brand?: BrandNonNullableFields; } export interface QueryBrandsResponseNonNullableFields { brands: BrandNonNullableFields[]; } interface ApplicationErrorNonNullableFields { code: string; description: string; } interface ItemMetadataNonNullableFields { originalIndex: number; success: boolean; error?: ApplicationErrorNonNullableFields; } interface BulkBrandsResultNonNullableFields { itemMetadata?: ItemMetadataNonNullableFields; item?: BrandNonNullableFields; } interface BulkActionMetadataNonNullableFields { totalSuccesses: number; totalFailures: number; undetailedFailures: number; } export interface BulkCreateBrandsResponseNonNullableFields { results: BulkBrandsResultNonNullableFields[]; bulkActionMetadata?: BulkActionMetadataNonNullableFields; } export interface BulkUpdateBrandsResponseNonNullableFields { results: BulkBrandsResultNonNullableFields[]; bulkActionMetadata?: BulkActionMetadataNonNullableFields; } export interface GetOrCreateBrandResponseNonNullableFields { brand?: BrandNonNullableFields; } export interface BulkGetOrCreateBrandsResponseNonNullableFields { results: BulkBrandsResultNonNullableFields[]; bulkActionMetadata?: BulkActionMetadataNonNullableFields; } interface BulkDeleteBrandsResponseBulkBrandsResultNonNullableFields { itemMetadata?: ItemMetadataNonNullableFields; } export interface BulkDeleteBrandsResponseNonNullableFields { results: BulkDeleteBrandsResponseBulkBrandsResultNonNullableFields[]; bulkActionMetadata?: BulkActionMetadataNonNullableFields; } export interface BaseEventMetadata { /** App instance ID. */ instanceId?: string | null; /** Event type. */ eventType?: string; /** The identification type and identity data. */ identity?: IdentificationData; } export interface EventMetadata extends BaseEventMetadata { /** * Unique event ID. * Allows clients to ignore duplicate webhooks. */ _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; /** ID of the entity associated with the event. */ entityId?: string; /** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example: 2020-04-26T13:57:50.699Z */ eventTime?: Date | null; /** * Whether the event was triggered as a result of a privacy regulation application * (for example, GDPR). */ 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; } export interface BrandCreatedEnvelope { entity: Brand; metadata: EventMetadata; } /** * Triggered when a brand is created. * @permissionScope Read v3 catalog * @permissionScopeId SCOPE.STORES.CATALOG_READ * @permissionScope Manage Products * @permissionScopeId SCOPE.DC-STORES.MANAGE-PRODUCTS * @permissionScope Read Products * @permissionScopeId SCOPE.DC-STORES.READ-PRODUCTS * @permissionScope Product write in v3 catalog * @permissionScopeId SCOPE.STORES.PRODUCT_WRITE * @permissionScope Manage v3 catalog * @permissionScopeId SCOPE.STORES.CATALOG_WRITE * @permissionScope Read brands in catalog v3 * @permissionScopeId SCOPE.STORES.BRAND_READ * @permissionScope Manage Orders * @permissionScopeId SCOPE.DC-STORES.MANAGE-ORDERS * @permissionId WIX_STORES.BRAND_READ * @webhook * @eventType wix.stores.catalog.v3.brand_created * @documentationMaturity preview */ export declare function onBrandCreated(handler: (event: BrandCreatedEnvelope) => void | Promise): void; export interface BrandDeletedEnvelope { metadata: EventMetadata; } /** * Triggered when a brand is deleted. * @permissionScope Read v3 catalog * @permissionScopeId SCOPE.STORES.CATALOG_READ * @permissionScope Manage Products * @permissionScopeId SCOPE.DC-STORES.MANAGE-PRODUCTS * @permissionScope Read Products * @permissionScopeId SCOPE.DC-STORES.READ-PRODUCTS * @permissionScope Product write in v3 catalog * @permissionScopeId SCOPE.STORES.PRODUCT_WRITE * @permissionScope Manage v3 catalog * @permissionScopeId SCOPE.STORES.CATALOG_WRITE * @permissionScope Read brands in catalog v3 * @permissionScopeId SCOPE.STORES.BRAND_READ * @permissionScope Manage Orders * @permissionScopeId SCOPE.DC-STORES.MANAGE-ORDERS * @permissionId WIX_STORES.BRAND_READ * @webhook * @eventType wix.stores.catalog.v3.brand_deleted * @documentationMaturity preview */ export declare function onBrandDeleted(handler: (event: BrandDeletedEnvelope) => void | Promise): void; export interface BrandUpdatedEnvelope { entity: Brand; metadata: EventMetadata; } /** * Triggered when a brand is updated. * @permissionScope Read v3 catalog * @permissionScopeId SCOPE.STORES.CATALOG_READ * @permissionScope Manage Products * @permissionScopeId SCOPE.DC-STORES.MANAGE-PRODUCTS * @permissionScope Read Products * @permissionScopeId SCOPE.DC-STORES.READ-PRODUCTS * @permissionScope Product write in v3 catalog * @permissionScopeId SCOPE.STORES.PRODUCT_WRITE * @permissionScope Manage v3 catalog * @permissionScopeId SCOPE.STORES.CATALOG_WRITE * @permissionScope Read brands in catalog v3 * @permissionScopeId SCOPE.STORES.BRAND_READ * @permissionScope Manage Orders * @permissionScopeId SCOPE.DC-STORES.MANAGE-ORDERS * @permissionId WIX_STORES.BRAND_READ * @webhook * @eventType wix.stores.catalog.v3.brand_updated * @documentationMaturity preview */ export declare function onBrandUpdated(handler: (event: BrandUpdatedEnvelope) => void | Promise): void; /** * Creates a brand. * * To assign the brand to a product, include the `brand.id` or `brand.name` * when [creating](https://dev.wix.com/docs/rest/business-solutions/stores/catalog-v3/products-v3/create-product) or * [updating](https://dev.wix.com/docs/rest/business-solutions/stores/catalog-v3/products-v3/update-product) a product. * @param brand - Brand to create. * @public * @documentationMaturity preview * @requiredField brand * @requiredField brand.name * @permissionId WIX_STORES.BRAND_CREATE * @permissionScope Brand write in v3 catalog * @permissionScopeId SCOPE.STORES.BRAND_WRITE * @permissionScope Manage Products * @permissionScopeId SCOPE.DC-STORES.MANAGE-PRODUCTS * @permissionScope Product write in v3 catalog * @permissionScopeId SCOPE.STORES.PRODUCT_WRITE * @permissionScope Manage v3 catalog * @permissionScopeId SCOPE.STORES.CATALOG_WRITE * @applicableIdentity APP * @returns Created brand. * @fqn com.wix.stores.catalog.brand.v3.BrandService.CreateBrand */ export declare function createBrand(brand: Brand): Promise; /** * Retrieves a brand. * @param brandId - Brand ID. * @public * @documentationMaturity preview * @requiredField brandId * @permissionId WIX_STORES.BRAND_READ * @permissionScope Read v3 catalog * @permissionScopeId SCOPE.STORES.CATALOG_READ * @permissionScope Manage Products * @permissionScopeId SCOPE.DC-STORES.MANAGE-PRODUCTS * @permissionScope Read Products * @permissionScopeId SCOPE.DC-STORES.READ-PRODUCTS * @permissionScope Product write in v3 catalog * @permissionScopeId SCOPE.STORES.PRODUCT_WRITE * @permissionScope Manage v3 catalog * @permissionScopeId SCOPE.STORES.CATALOG_WRITE * @permissionScope Read brands in catalog v3 * @permissionScopeId SCOPE.STORES.BRAND_READ * @permissionScope Manage Orders * @permissionScopeId SCOPE.DC-STORES.MANAGE-ORDERS * @applicableIdentity APP * @applicableIdentity VISITOR * @returns Brand. * @fqn com.wix.stores.catalog.brand.v3.BrandService.GetBrand */ export declare function getBrand(brandId: string, options?: GetBrandOptions): Promise; export interface GetBrandOptions { /** * Fields to include in the response. * * Supported values: `ASSIGNED_PRODUCTS_COUNT` */ fields?: RequestedFields[]; } /** * Updates a brand. * * Each time the brand is updated, `revision` increments by 1. * The current `revision` must be passed when updating the brand. * This ensures you're working with the latest brand and prevents unintended overwrites. * @param _id - Brand ID. * @public * @documentationMaturity preview * @requiredField _id * @requiredField brand * @requiredField brand.revision * @permissionId WIX_STORES.BRAND_UPDATE * @permissionScope Brand write in v3 catalog * @permissionScopeId SCOPE.STORES.BRAND_WRITE * @permissionScope Manage Products * @permissionScopeId SCOPE.DC-STORES.MANAGE-PRODUCTS * @permissionScope Product write in v3 catalog * @permissionScopeId SCOPE.STORES.PRODUCT_WRITE * @permissionScope Manage v3 catalog * @permissionScopeId SCOPE.STORES.CATALOG_WRITE * @applicableIdentity APP * @returns Updated brand. * @fqn com.wix.stores.catalog.brand.v3.BrandService.UpdateBrand */ export declare function updateBrand(_id: string | null, brand: UpdateBrand, options?: UpdateBrandOptions): Promise; export interface UpdateBrand { /** * Brand ID. * @readonly */ _id?: string | null; /** * Revision number, which increments by 1 each time the brand is updated. * To prevent conflicting changes, * the current revision must be passed when updating the brand. * * Ignored when creating a brand. * @readonly */ revision?: string | null; /** * Date and time the brand was created. * @readonly */ _createdDate?: Date | null; /** * Date and time the brand was updated. * @readonly */ _updatedDate?: Date | null; /** * Brand name. * >**Note:** `name` must be unique. */ name?: string; /** * Number of products this brand is assigned to. * > **Note:** Returned only when you pass `"ASSIGNED_PRODUCTS_COUNT"` to the `fields` array in Brand API requests. * @readonly */ assignedProductsCount?: number | null; } export interface UpdateBrandOptions { /** * Fields to include in the response. * * Supported values: `ASSIGNED_PRODUCTS_COUNT` */ fields?: RequestedFields[]; } /** * Deletes a brand. * * > **Note:** Deleting a brand will also remove it from all products it is assigned to. * @param brandId - Brand ID. * @public * @documentationMaturity preview * @requiredField brandId * @permissionId WIX_STORES.BRAND_DELETE * @permissionScope Brand write in v3 catalog * @permissionScopeId SCOPE.STORES.BRAND_WRITE * @permissionScope Manage Products * @permissionScopeId SCOPE.DC-STORES.MANAGE-PRODUCTS * @permissionScope Product write in v3 catalog * @permissionScopeId SCOPE.STORES.PRODUCT_WRITE * @permissionScope Manage v3 catalog * @permissionScopeId SCOPE.STORES.CATALOG_WRITE * @applicableIdentity APP * @fqn com.wix.stores.catalog.brand.v3.BrandService.DeleteBrand */ export declare function deleteBrand(brandId: string): Promise; /** * Retrieves a list of up to 100 brands, given the provided filtering, sorting, and cursor paging. * Pass supported values to the `fields` array in the request to include those fields in the response. * * * Query Brands runs with these defaults, which you can override: * * - `createdDate` is sorted in `DESC` order * - `cursorPaging.limit` is `100` * * For field support for filters and sorting, * see [Brands: Supported Filters and Sorting](https://dev.wix.com/docs/rest/business-solutions/stores/catalog-v3/brands-v3/supported-filters-and-sorting). * * To learn about working with _Query_ endpoints, see * [API Query Language](https://dev.wix.com/docs/rest/articles/getting-started/api-query-language), * and [Sorting and Paging](https://dev.wix.com/docs/rest/articles/getting-started/sorting-and-paging). * @public * @documentationMaturity preview * @permissionScope Read v3 catalog * @permissionScopeId SCOPE.STORES.CATALOG_READ * @permissionScope Manage Products * @permissionScopeId SCOPE.DC-STORES.MANAGE-PRODUCTS * @permissionScope Read Products * @permissionScopeId SCOPE.DC-STORES.READ-PRODUCTS * @permissionScope Product write in v3 catalog * @permissionScopeId SCOPE.STORES.PRODUCT_WRITE * @permissionScope Manage v3 catalog * @permissionScopeId SCOPE.STORES.CATALOG_WRITE * @permissionScope Read brands in catalog v3 * @permissionScopeId SCOPE.STORES.BRAND_READ * @permissionScope Manage Orders * @permissionScopeId SCOPE.DC-STORES.MANAGE-ORDERS * @permissionId WIX_STORES.BRAND_READ * @applicableIdentity APP * @applicableIdentity VISITOR * @fqn com.wix.stores.catalog.brand.v3.BrandService.QueryBrands */ export declare function queryBrands(options?: QueryBrandsOptions): BrandsQueryBuilder; export interface QueryBrandsOptions { /** * Fields to include in the response. * * Supported values: `ASSIGNED_PRODUCTS_COUNT` */ fields?: RequestedFields[] | undefined; } interface QueryCursorResult { cursors: Cursors; hasNext: () => boolean; hasPrev: () => boolean; length: number; pageSize: number; } export interface BrandsQueryResult extends QueryCursorResult { items: Brand[]; query: BrandsQueryBuilder; next: () => Promise; prev: () => Promise; } export interface BrandsQueryBuilder { /** @param propertyName - Property whose value is compared with `value`. * @param value - Value to compare against. * @documentationMaturity preview */ eq: (propertyName: '_id' | '_createdDate' | '_updatedDate' | 'name', value: any) => BrandsQueryBuilder; /** @param propertyName - Property whose value is compared with `value`. * @param value - Value to compare against. * @documentationMaturity preview */ ne: (propertyName: '_id' | '_createdDate' | '_updatedDate' | 'name', value: any) => BrandsQueryBuilder; /** @param propertyName - Property whose value is compared with `value`. * @param value - Value to compare against. * @documentationMaturity preview */ ge: (propertyName: '_createdDate' | '_updatedDate', value: any) => BrandsQueryBuilder; /** @param propertyName - Property whose value is compared with `value`. * @param value - Value to compare against. * @documentationMaturity preview */ gt: (propertyName: '_createdDate' | '_updatedDate', value: any) => BrandsQueryBuilder; /** @param propertyName - Property whose value is compared with `value`. * @param value - Value to compare against. * @documentationMaturity preview */ le: (propertyName: '_createdDate' | '_updatedDate', value: any) => BrandsQueryBuilder; /** @param propertyName - Property whose value is compared with `value`. * @param value - Value to compare against. * @documentationMaturity preview */ lt: (propertyName: '_createdDate' | '_updatedDate', value: any) => BrandsQueryBuilder; /** @param propertyName - Property whose value is compared with `string`. * @param string - String to compare against. Case-insensitive. * @documentationMaturity preview */ startsWith: (propertyName: '_id' | 'name', value: string) => BrandsQueryBuilder; /** @param propertyName - Property whose value is compared with `values`. * @param values - List of values to compare against. * @documentationMaturity preview */ hasSome: (propertyName: '_id' | '_createdDate' | '_updatedDate' | 'name', value: any[]) => BrandsQueryBuilder; /** @documentationMaturity preview */ in: (propertyName: '_id' | '_createdDate' | '_updatedDate' | 'name', value: any) => BrandsQueryBuilder; /** @documentationMaturity preview */ exists: (propertyName: '_id' | '_createdDate' | '_updatedDate' | 'name', value: boolean) => BrandsQueryBuilder; /** @param propertyNames - Properties used in the sort. To sort by multiple properties, pass properties as additional arguments. * @documentationMaturity preview */ ascending: (...propertyNames: Array<'_createdDate' | '_updatedDate' | 'name'>) => BrandsQueryBuilder; /** @param propertyNames - Properties used in the sort. To sort by multiple properties, pass properties as additional arguments. * @documentationMaturity preview */ descending: (...propertyNames: Array<'_createdDate' | '_updatedDate' | 'name'>) => BrandsQueryBuilder; /** @param limit - Number of items to return, which is also the `pageSize` of the results object. * @documentationMaturity preview */ limit: (limit: number) => BrandsQueryBuilder; /** @param cursor - A pointer to specific record * @documentationMaturity preview */ skipTo: (cursor: string) => BrandsQueryBuilder; /** @documentationMaturity preview */ find: () => Promise; } /** * Creates multiple brands. * @param brands - Brands to create. * @public * @documentationMaturity preview * @requiredField brands * @requiredField brands.name * @permissionId WIX_STORES.BRAND_CREATE * @permissionScope Brand write in v3 catalog * @permissionScopeId SCOPE.STORES.BRAND_WRITE * @permissionScope Manage Products * @permissionScopeId SCOPE.DC-STORES.MANAGE-PRODUCTS * @permissionScope Product write in v3 catalog * @permissionScopeId SCOPE.STORES.PRODUCT_WRITE * @permissionScope Manage v3 catalog * @permissionScopeId SCOPE.STORES.CATALOG_WRITE * @applicableIdentity APP * @fqn com.wix.stores.catalog.brand.v3.BrandService.BulkCreateBrands */ export declare function bulkCreateBrands(brands: Brand[], options?: BulkCreateBrandsOptions): Promise; export interface BulkCreateBrandsOptions { /** * Whether to return the full created brand entities in the response. * * Default: `false` */ returnEntity?: boolean; } /** * Updates multiple brands. * * Each time a brand is updated, `revision` increments by 1. * The current `revision` must be passed when updating a brand. * This ensures you're working with the latest brand and prevents unintended overwrites. * @param brands - List of brands to update. * @public * @documentationMaturity preview * @requiredField brands * @requiredField brands.brand._id * @requiredField brands.brand.revision * @permissionId WIX_STORES.BRAND_UPDATE * @permissionScope Brand write in v3 catalog * @permissionScopeId SCOPE.STORES.BRAND_WRITE * @permissionScope Manage Products * @permissionScopeId SCOPE.DC-STORES.MANAGE-PRODUCTS * @permissionScope Product write in v3 catalog * @permissionScopeId SCOPE.STORES.PRODUCT_WRITE * @permissionScope Manage v3 catalog * @permissionScopeId SCOPE.STORES.CATALOG_WRITE * @applicableIdentity APP * @fqn com.wix.stores.catalog.brand.v3.BrandService.BulkUpdateBrands */ export declare function bulkUpdateBrands(brands: MaskedBrand[], options?: BulkUpdateBrandsOptions): Promise; export interface BulkUpdateBrandsOptions { /** * Whether to return the full updated brand entities in the response. * * Default: `false` */ returnEntity?: boolean; /** * Fields to include in the response. * * Supported values: `ASSIGNED_PRODUCTS_COUNT` */ fields?: RequestedFields[]; } /** * Retrieves a brand by name, or creates a brand if one with the passed `brandName` doesn't exist. * @param brandName - Brand name to retrieve or create. * @public * @documentationMaturity preview * @requiredField brandName * @permissionId WIX_STORES.BRAND_GET_OR_CREATE * @permissionScope Brand write in v3 catalog * @permissionScopeId SCOPE.STORES.BRAND_WRITE * @permissionScope Manage Products * @permissionScopeId SCOPE.DC-STORES.MANAGE-PRODUCTS * @permissionScope Product write in v3 catalog * @permissionScopeId SCOPE.STORES.PRODUCT_WRITE * @permissionScope Manage v3 catalog * @permissionScopeId SCOPE.STORES.CATALOG_WRITE * @applicableIdentity APP * @fqn com.wix.stores.catalog.brand.v3.BrandService.GetOrCreateBrand */ export declare function getOrCreateBrand(brandName: string, options?: GetOrCreateBrandOptions): Promise; export interface GetOrCreateBrandOptions { /** * Fields to include in the response. * * Supported values: `ASSIGNED_PRODUCTS_COUNT` */ fields?: RequestedFields[]; } /** * Retrieves multiple brands by name, or creates multiple brands if those with the passed `ribbonNames` don't exist. * @param brandNames - Brand names to retrieve or create. * @public * @documentationMaturity preview * @requiredField brandNames * @permissionId WIX_STORES.BRAND_GET_OR_CREATE * @permissionScope Brand write in v3 catalog * @permissionScopeId SCOPE.STORES.BRAND_WRITE * @permissionScope Manage Products * @permissionScopeId SCOPE.DC-STORES.MANAGE-PRODUCTS * @permissionScope Product write in v3 catalog * @permissionScopeId SCOPE.STORES.PRODUCT_WRITE * @permissionScope Manage v3 catalog * @permissionScopeId SCOPE.STORES.CATALOG_WRITE * @applicableIdentity APP * @fqn com.wix.stores.catalog.brand.v3.BrandService.BulkGetOrCreateBrands */ export declare function bulkGetOrCreateBrands(brandNames: string[], options?: BulkGetOrCreateBrandsOptions): Promise; export interface BulkGetOrCreateBrandsOptions { /** * Fields to include in the response. * * Supported values: `ASSIGNED_PRODUCTS_COUNT` */ fields?: RequestedFields[]; } /** * Deletes multiple brands. * @param brandIds - IDs of brands to delete. * @public * @documentationMaturity preview * @requiredField brandIds * @permissionId WIX_STORES.BRAND_DELETE * @permissionScope Brand write in v3 catalog * @permissionScopeId SCOPE.STORES.BRAND_WRITE * @permissionScope Manage Products * @permissionScopeId SCOPE.DC-STORES.MANAGE-PRODUCTS * @permissionScope Product write in v3 catalog * @permissionScopeId SCOPE.STORES.PRODUCT_WRITE * @permissionScope Manage v3 catalog * @permissionScopeId SCOPE.STORES.CATALOG_WRITE * @applicableIdentity APP * @fqn com.wix.stores.catalog.brand.v3.BrandService.BulkDeleteBrands */ export declare function bulkDeleteBrands(brandIds: string[]): Promise; export {};