@wix/categories 1.0.13 → 1.0.15

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (31) hide show
  1. package/build/cjs/src/categories-v1-category.http.d.ts +5 -1
  2. package/build/cjs/src/categories-v1-category.http.js +116 -1
  3. package/build/cjs/src/categories-v1-category.http.js.map +1 -1
  4. package/build/cjs/src/categories-v1-category.meta.d.ts +2 -0
  5. package/build/cjs/src/categories-v1-category.meta.js +39 -1
  6. package/build/cjs/src/categories-v1-category.meta.js.map +1 -1
  7. package/build/cjs/src/categories-v1-category.public.d.ts +5 -3
  8. package/build/cjs/src/categories-v1-category.public.js +20 -1
  9. package/build/cjs/src/categories-v1-category.public.js.map +1 -1
  10. package/build/cjs/src/categories-v1-category.types.d.ts +785 -0
  11. package/build/cjs/src/categories-v1-category.types.js +39 -1
  12. package/build/cjs/src/categories-v1-category.types.js.map +1 -1
  13. package/build/cjs/src/categories-v1-category.universal.d.ts +826 -10
  14. package/build/cjs/src/categories-v1-category.universal.js +160 -1
  15. package/build/cjs/src/categories-v1-category.universal.js.map +1 -1
  16. package/build/es/src/categories-v1-category.http.d.ts +5 -1
  17. package/build/es/src/categories-v1-category.http.js +113 -0
  18. package/build/es/src/categories-v1-category.http.js.map +1 -1
  19. package/build/es/src/categories-v1-category.meta.d.ts +2 -0
  20. package/build/es/src/categories-v1-category.meta.js +36 -0
  21. package/build/es/src/categories-v1-category.meta.js.map +1 -1
  22. package/build/es/src/categories-v1-category.public.d.ts +5 -3
  23. package/build/es/src/categories-v1-category.public.js +12 -2
  24. package/build/es/src/categories-v1-category.public.js.map +1 -1
  25. package/build/es/src/categories-v1-category.types.d.ts +785 -0
  26. package/build/es/src/categories-v1-category.types.js +38 -0
  27. package/build/es/src/categories-v1-category.types.js.map +1 -1
  28. package/build/es/src/categories-v1-category.universal.d.ts +826 -10
  29. package/build/es/src/categories-v1-category.universal.js +156 -0
  30. package/build/es/src/categories-v1-category.universal.js.map +1 -1
  31. package/package.json +2 -2
@@ -1538,6 +1538,238 @@ export interface Cursors {
1538
1538
  /** Cursor pointing to previous page in the list of results. */
1539
1539
  prev?: string | null;
1540
1540
  }
1541
+ export interface SearchCategoriesRequest {
1542
+ /** WQL query expression. */
1543
+ search?: CursorSearch;
1544
+ /**
1545
+ * A reference to the tree that contains this category.
1546
+ * Used only in the first request. Following requests use the cursor token.
1547
+ */
1548
+ treeReference: TreeReference;
1549
+ /**
1550
+ * Whether hidden categories should be included in the response. Default is `false`.
1551
+ * Used only in the first request. Following requests use the cursor token.
1552
+ */
1553
+ includeHidden?: boolean;
1554
+ /** Fields to return in the response. When not provided, these fields are not returned. */
1555
+ fields?: RequestedFields[];
1556
+ }
1557
+ export interface CursorSearch extends CursorSearchPagingMethodOneOf {
1558
+ /** Cursor pointing to page of results. Can't be used together with 'paging'. 'cursor_paging.cursor' can not be used together with 'filter' or 'sort' */
1559
+ cursorPaging?: CursorPaging;
1560
+ /** A filter object. See documentation [here](https://bo.wix.com/wix-docs/rnd/platformization-guidelines/api-query-language#platformization-guidelines_api-query-language_defining-in-protobuf) */
1561
+ filter?: Record<string, any> | null;
1562
+ /** Sort object in the form [{"fieldName":"sortField1"},{"fieldName":"sortField2","direction":"DESC"}] */
1563
+ sort?: Sorting[];
1564
+ /** Aggregations | Faceted search: refers to a way to explore large amounts of data by displaying summaries about various partitions of the data and later allowing to narrow the navigation to a specific partition. */
1565
+ aggregations?: Aggregation[];
1566
+ /** free text to match in searchable fields */
1567
+ search?: SearchDetails;
1568
+ }
1569
+ /** @oneof */
1570
+ export interface CursorSearchPagingMethodOneOf {
1571
+ /** Cursor pointing to page of results. Can't be used together with 'paging'. 'cursor_paging.cursor' can not be used together with 'filter' or 'sort' */
1572
+ cursorPaging?: CursorPaging;
1573
+ }
1574
+ export interface Aggregation extends AggregationKindOneOf {
1575
+ value?: ValueAggregation;
1576
+ range?: RangeAggregation;
1577
+ scalar?: ScalarAggregation;
1578
+ name?: string | null;
1579
+ type?: AggregationType;
1580
+ fieldPath?: string;
1581
+ groupBy?: GroupByAggregation;
1582
+ }
1583
+ /** @oneof */
1584
+ export interface AggregationKindOneOf {
1585
+ value?: ValueAggregation;
1586
+ range?: RangeAggregation;
1587
+ scalar?: ScalarAggregation;
1588
+ }
1589
+ export interface RangeBucket {
1590
+ /** Inclusive lower bound of the range. Required if to is not given. */
1591
+ from?: number | null;
1592
+ /** Exclusive upper bound of the range. Required if from is not given. */
1593
+ to?: number | null;
1594
+ }
1595
+ export declare enum SortType {
1596
+ COUNT = "COUNT",
1597
+ VALUE = "VALUE"
1598
+ }
1599
+ export declare enum SortDirection {
1600
+ DESC = "DESC",
1601
+ ASC = "ASC"
1602
+ }
1603
+ export declare enum MissingValues {
1604
+ EXCLUDE = "EXCLUDE",
1605
+ INCLUDE = "INCLUDE"
1606
+ }
1607
+ export interface IncludeMissingValuesOptions {
1608
+ /** can specify custom bucket name. Defaults are [string -> "N/A"], [int -> "0"], [bool -> "false"] ... */
1609
+ addToBucket?: string;
1610
+ }
1611
+ export declare enum ScalarType {
1612
+ UNKNOWN_SCALAR_TYPE = "UNKNOWN_SCALAR_TYPE",
1613
+ COUNT_DISTINCT = "COUNT_DISTINCT",
1614
+ MIN = "MIN",
1615
+ MAX = "MAX",
1616
+ SUM = "SUM",
1617
+ AVG = "AVG"
1618
+ }
1619
+ export interface ValueAggregation extends ValueAggregationOptionsOneOf {
1620
+ /** options for including missing values */
1621
+ includeOptions?: IncludeMissingValuesOptions;
1622
+ sortType?: SortType;
1623
+ sortDirection?: SortDirection;
1624
+ /** How many aggregations would you like to return? Can be between 1 and 250. 10 is the default. */
1625
+ limit?: number | null;
1626
+ /** should missing values be included or excluded from the aggregation results. Default is EXCLUDE */
1627
+ missingValues?: MissingValues;
1628
+ }
1629
+ /** @oneof */
1630
+ export interface ValueAggregationOptionsOneOf {
1631
+ /** options for including missing values */
1632
+ includeOptions?: IncludeMissingValuesOptions;
1633
+ }
1634
+ export declare enum AggregationType {
1635
+ UNKNOWN_AGGREGATION_TYPE = "UNKNOWN_AGGREGATION_TYPE",
1636
+ VALUE = "VALUE",
1637
+ RANGE = "RANGE",
1638
+ SCALAR = "SCALAR"
1639
+ }
1640
+ export interface RangeAggregation {
1641
+ buckets?: RangeBucket[];
1642
+ }
1643
+ export interface ScalarAggregation {
1644
+ type?: ScalarType;
1645
+ }
1646
+ export interface GroupByAggregation extends GroupByAggregationKindOneOf {
1647
+ value?: ValueAggregation;
1648
+ name?: string | null;
1649
+ fieldPath?: string;
1650
+ }
1651
+ /** @oneof */
1652
+ export interface GroupByAggregationKindOneOf {
1653
+ value?: ValueAggregation;
1654
+ }
1655
+ export interface SearchDetails {
1656
+ /** boolean search mode */
1657
+ mode?: Mode;
1658
+ /** search term or expression */
1659
+ expression?: string | null;
1660
+ /** fields to search in. if empty - server will search in own default fields */
1661
+ fields?: string[];
1662
+ /** flag if should use auto fuzzy search (allowing typos by a managed proximity algorithm) */
1663
+ fuzzy?: boolean;
1664
+ }
1665
+ export declare enum Mode {
1666
+ /** any */
1667
+ OR = "OR",
1668
+ /** all */
1669
+ AND = "AND"
1670
+ }
1671
+ export interface SearchCategoriesResponse {
1672
+ /** Categories which satisfy the provided query. */
1673
+ categories?: Category[];
1674
+ /** Paging metadata. Contains cursor which can be used in next query. */
1675
+ pagingMetadata?: CursorPagingMetadata;
1676
+ /** Aggregation data. */
1677
+ aggregationData?: AggregationData;
1678
+ }
1679
+ export interface CursorPagingMetadata {
1680
+ /** Number of items returned in the response. */
1681
+ count?: number | null;
1682
+ /** Offset that was requested. */
1683
+ cursors?: Cursors;
1684
+ /**
1685
+ * Indicates if there are more results after the current page.
1686
+ * If `true`, another page of results can be retrieved.
1687
+ * If `false`, this is the last page.
1688
+ */
1689
+ hasNext?: boolean | null;
1690
+ }
1691
+ export interface AggregationData {
1692
+ /** key = aggregation name (as derived from search request) */
1693
+ results?: AggregationResults[];
1694
+ }
1695
+ export interface ValueAggregationResult {
1696
+ value?: string;
1697
+ count?: number;
1698
+ }
1699
+ export interface RangeAggregationResult {
1700
+ from?: number | null;
1701
+ to?: number | null;
1702
+ count?: number;
1703
+ }
1704
+ export interface NestedAggregationResults extends NestedAggregationResultsResultOneOf {
1705
+ values?: ValueResults;
1706
+ ranges?: RangeResults;
1707
+ scalar?: ScalarResult;
1708
+ name?: string;
1709
+ type?: AggregationType;
1710
+ fieldPath?: string;
1711
+ }
1712
+ /** @oneof */
1713
+ export interface NestedAggregationResultsResultOneOf {
1714
+ values?: ValueResults;
1715
+ ranges?: RangeResults;
1716
+ scalar?: ScalarResult;
1717
+ }
1718
+ export interface ValueResults {
1719
+ results?: ValueAggregationResult[];
1720
+ }
1721
+ export interface RangeResults {
1722
+ results?: RangeAggregationResult[];
1723
+ }
1724
+ export interface ScalarResult {
1725
+ type?: ScalarType;
1726
+ value?: number;
1727
+ }
1728
+ export interface NestedValueAggregationResult {
1729
+ value?: string;
1730
+ nestedResults?: NestedAggregationResults;
1731
+ }
1732
+ export interface GroupByValueResults {
1733
+ results?: NestedValueAggregationResult[];
1734
+ }
1735
+ export interface AggregationResults extends AggregationResultsResultOneOf {
1736
+ values?: ValueResults;
1737
+ ranges?: RangeResults;
1738
+ scalar?: ScalarResult;
1739
+ groupedByValue?: GroupByValueResults;
1740
+ name?: string;
1741
+ type?: AggregationType;
1742
+ fieldPath?: string;
1743
+ }
1744
+ /** @oneof */
1745
+ export interface AggregationResultsResultOneOf {
1746
+ values?: ValueResults;
1747
+ ranges?: RangeResults;
1748
+ scalar?: ScalarResult;
1749
+ groupedByValue?: GroupByValueResults;
1750
+ }
1751
+ export interface CountCategoriesRequest {
1752
+ /**
1753
+ * A filter object. See documentation [here](https://bo.wix.com/wix-docs/rnd/platformization-guidelines/api-query-language#platformization-guidelines_api-query-language_defining-in-protobuf)
1754
+ * To understand supported filters and limitations see `SearchCategories` method.
1755
+ */
1756
+ filter?: Record<string, any> | null;
1757
+ /** free text to match in searchable fields */
1758
+ search?: SearchDetails;
1759
+ /**
1760
+ * A reference to the tree that contains this category.
1761
+ * Used only in the first request. Following requests use the cursor token.
1762
+ */
1763
+ treeReference: TreeReference;
1764
+ /**
1765
+ * Whether hidden categories should be included in the response. Default is `false`.
1766
+ * Used only in the first request. Following requests use the cursor token.
1767
+ */
1768
+ includeHidden?: boolean;
1769
+ }
1770
+ export interface CountCategoriesResponse {
1771
+ count?: number;
1772
+ }
1541
1773
  export interface MoveCategoryRequest {
1542
1774
  /** ID of category to place. */
1543
1775
  categoryId: string;
@@ -2006,7 +2238,486 @@ export interface ActionEvent {
2006
2238
  }
2007
2239
  export interface Empty {
2008
2240
  }
2009
- export interface CreateCategoryResponseNonNullableFields {
2241
+ export interface CreateCategoryResponseNonNullableFields {
2242
+ category?: {
2243
+ image: string;
2244
+ numberOfItems: number;
2245
+ breadcrumbs?: {
2246
+ values: {
2247
+ categoryId: string;
2248
+ categoryName: string;
2249
+ categorySlug: string;
2250
+ }[];
2251
+ };
2252
+ richContentDescription?: {
2253
+ nodes: {
2254
+ buttonData?: {
2255
+ containerData?: {
2256
+ width?: {
2257
+ size: WidthType;
2258
+ };
2259
+ alignment: PluginContainerDataAlignment;
2260
+ };
2261
+ type: Type;
2262
+ link?: {
2263
+ url: string;
2264
+ anchor: string;
2265
+ target: Target;
2266
+ };
2267
+ };
2268
+ codeBlockData?: {
2269
+ textStyle?: {
2270
+ textAlignment: TextAlignment;
2271
+ };
2272
+ };
2273
+ dividerData?: {
2274
+ containerData?: {
2275
+ width?: {
2276
+ size: WidthType;
2277
+ };
2278
+ alignment: PluginContainerDataAlignment;
2279
+ };
2280
+ lineStyle: LineStyle;
2281
+ width: Width;
2282
+ alignment: Alignment;
2283
+ };
2284
+ fileData?: {
2285
+ containerData?: {
2286
+ width?: {
2287
+ size: WidthType;
2288
+ };
2289
+ alignment: PluginContainerDataAlignment;
2290
+ };
2291
+ pdfSettings?: {
2292
+ viewMode: ViewMode;
2293
+ };
2294
+ };
2295
+ galleryData?: {
2296
+ containerData?: {
2297
+ width?: {
2298
+ size: WidthType;
2299
+ };
2300
+ alignment: PluginContainerDataAlignment;
2301
+ };
2302
+ items: {
2303
+ image?: {
2304
+ link?: {
2305
+ url: string;
2306
+ anchor: string;
2307
+ target: Target;
2308
+ };
2309
+ };
2310
+ }[];
2311
+ options?: {
2312
+ layout?: {
2313
+ type: LayoutType;
2314
+ orientation: Orientation;
2315
+ };
2316
+ item?: {
2317
+ crop: Crop;
2318
+ };
2319
+ thumbnails?: {
2320
+ placement: ThumbnailsAlignment;
2321
+ };
2322
+ };
2323
+ };
2324
+ gifData?: {
2325
+ containerData?: {
2326
+ width?: {
2327
+ size: WidthType;
2328
+ };
2329
+ alignment: PluginContainerDataAlignment;
2330
+ };
2331
+ height: number;
2332
+ width: number;
2333
+ };
2334
+ headingData?: {
2335
+ level: number;
2336
+ textStyle?: {
2337
+ textAlignment: TextAlignment;
2338
+ };
2339
+ };
2340
+ htmlData?: {
2341
+ url: string;
2342
+ html: string;
2343
+ containerData?: {
2344
+ width?: {
2345
+ size: WidthType;
2346
+ };
2347
+ alignment: PluginContainerDataAlignment;
2348
+ };
2349
+ source: Source;
2350
+ };
2351
+ imageData?: {
2352
+ containerData?: {
2353
+ width?: {
2354
+ size: WidthType;
2355
+ };
2356
+ alignment: PluginContainerDataAlignment;
2357
+ };
2358
+ link?: {
2359
+ url: string;
2360
+ anchor: string;
2361
+ target: Target;
2362
+ };
2363
+ };
2364
+ linkPreviewData?: {
2365
+ containerData?: {
2366
+ width?: {
2367
+ size: WidthType;
2368
+ };
2369
+ alignment: PluginContainerDataAlignment;
2370
+ };
2371
+ link?: {
2372
+ url: string;
2373
+ anchor: string;
2374
+ target: Target;
2375
+ };
2376
+ };
2377
+ mapData?: {
2378
+ containerData?: {
2379
+ width?: {
2380
+ size: WidthType;
2381
+ };
2382
+ alignment: PluginContainerDataAlignment;
2383
+ };
2384
+ mapSettings?: {
2385
+ mapType: MapType;
2386
+ };
2387
+ };
2388
+ paragraphData?: {
2389
+ textStyle?: {
2390
+ textAlignment: TextAlignment;
2391
+ };
2392
+ };
2393
+ pollData?: {
2394
+ containerData?: {
2395
+ width?: {
2396
+ size: WidthType;
2397
+ };
2398
+ alignment: PluginContainerDataAlignment;
2399
+ };
2400
+ poll?: {
2401
+ options: Option[];
2402
+ settings?: {
2403
+ permissions?: {
2404
+ view: ViewRole;
2405
+ vote: VoteRole;
2406
+ };
2407
+ };
2408
+ };
2409
+ layout?: {
2410
+ poll?: {
2411
+ type: PollLayoutType;
2412
+ direction: PollLayoutDirection;
2413
+ };
2414
+ };
2415
+ design?: {
2416
+ poll?: {
2417
+ background?: {
2418
+ type: BackgroundType;
2419
+ };
2420
+ };
2421
+ };
2422
+ };
2423
+ textData?: {
2424
+ text: string;
2425
+ decorations: {
2426
+ anchorData?: {
2427
+ anchor: string;
2428
+ };
2429
+ linkData?: {
2430
+ link?: {
2431
+ url: string;
2432
+ anchor: string;
2433
+ target: Target;
2434
+ };
2435
+ };
2436
+ mentionData?: {
2437
+ name: string;
2438
+ slug: string;
2439
+ };
2440
+ fontSizeData?: {
2441
+ unit: FontType;
2442
+ };
2443
+ type: DecorationType;
2444
+ }[];
2445
+ };
2446
+ appEmbedData?: {
2447
+ type: AppType;
2448
+ };
2449
+ videoData?: {
2450
+ containerData?: {
2451
+ width?: {
2452
+ size: WidthType;
2453
+ };
2454
+ alignment: PluginContainerDataAlignment;
2455
+ };
2456
+ };
2457
+ embedData?: {
2458
+ containerData?: {
2459
+ width?: {
2460
+ size: WidthType;
2461
+ };
2462
+ alignment: PluginContainerDataAlignment;
2463
+ };
2464
+ };
2465
+ collapsibleListData?: {
2466
+ containerData?: {
2467
+ width?: {
2468
+ size: WidthType;
2469
+ };
2470
+ alignment: PluginContainerDataAlignment;
2471
+ };
2472
+ initialExpandedItems: InitialExpandedItems;
2473
+ direction: Direction;
2474
+ };
2475
+ tableData?: {
2476
+ containerData?: {
2477
+ width?: {
2478
+ size: WidthType;
2479
+ };
2480
+ alignment: PluginContainerDataAlignment;
2481
+ };
2482
+ dimensions?: {
2483
+ colsWidthRatio: number[];
2484
+ rowsHeight: number[];
2485
+ colsMinWidth: number[];
2486
+ };
2487
+ };
2488
+ tableCellData?: {
2489
+ cellStyle?: {
2490
+ verticalAlignment: VerticalAlignment;
2491
+ };
2492
+ };
2493
+ audioData?: {
2494
+ containerData?: {
2495
+ width?: {
2496
+ size: WidthType;
2497
+ };
2498
+ alignment: PluginContainerDataAlignment;
2499
+ };
2500
+ };
2501
+ orderedListData?: {
2502
+ indentation: number;
2503
+ };
2504
+ bulletedListData?: {
2505
+ indentation: number;
2506
+ };
2507
+ blockquoteData?: {
2508
+ indentation: number;
2509
+ };
2510
+ type: NodeType;
2511
+ _id: string;
2512
+ nodes: NonNullable<NonNullable<NonNullable<CreateCategoryResponseNonNullableFields>['category']>['richContentDescription']>['nodes'][];
2513
+ }[];
2514
+ metadata?: {
2515
+ version: number;
2516
+ };
2517
+ documentStyle?: {
2518
+ headerOne?: {
2519
+ decorations: {
2520
+ anchorData?: {
2521
+ anchor: string;
2522
+ };
2523
+ linkData?: {
2524
+ link?: {
2525
+ url: string;
2526
+ anchor: string;
2527
+ target: Target;
2528
+ };
2529
+ };
2530
+ mentionData?: {
2531
+ name: string;
2532
+ slug: string;
2533
+ };
2534
+ fontSizeData?: {
2535
+ unit: FontType;
2536
+ };
2537
+ type: DecorationType;
2538
+ }[];
2539
+ };
2540
+ headerTwo?: {
2541
+ decorations: {
2542
+ anchorData?: {
2543
+ anchor: string;
2544
+ };
2545
+ linkData?: {
2546
+ link?: {
2547
+ url: string;
2548
+ anchor: string;
2549
+ target: Target;
2550
+ };
2551
+ };
2552
+ mentionData?: {
2553
+ name: string;
2554
+ slug: string;
2555
+ };
2556
+ fontSizeData?: {
2557
+ unit: FontType;
2558
+ };
2559
+ type: DecorationType;
2560
+ }[];
2561
+ };
2562
+ headerThree?: {
2563
+ decorations: {
2564
+ anchorData?: {
2565
+ anchor: string;
2566
+ };
2567
+ linkData?: {
2568
+ link?: {
2569
+ url: string;
2570
+ anchor: string;
2571
+ target: Target;
2572
+ };
2573
+ };
2574
+ mentionData?: {
2575
+ name: string;
2576
+ slug: string;
2577
+ };
2578
+ fontSizeData?: {
2579
+ unit: FontType;
2580
+ };
2581
+ type: DecorationType;
2582
+ }[];
2583
+ };
2584
+ headerFour?: {
2585
+ decorations: {
2586
+ anchorData?: {
2587
+ anchor: string;
2588
+ };
2589
+ linkData?: {
2590
+ link?: {
2591
+ url: string;
2592
+ anchor: string;
2593
+ target: Target;
2594
+ };
2595
+ };
2596
+ mentionData?: {
2597
+ name: string;
2598
+ slug: string;
2599
+ };
2600
+ fontSizeData?: {
2601
+ unit: FontType;
2602
+ };
2603
+ type: DecorationType;
2604
+ }[];
2605
+ };
2606
+ headerFive?: {
2607
+ decorations: {
2608
+ anchorData?: {
2609
+ anchor: string;
2610
+ };
2611
+ linkData?: {
2612
+ link?: {
2613
+ url: string;
2614
+ anchor: string;
2615
+ target: Target;
2616
+ };
2617
+ };
2618
+ mentionData?: {
2619
+ name: string;
2620
+ slug: string;
2621
+ };
2622
+ fontSizeData?: {
2623
+ unit: FontType;
2624
+ };
2625
+ type: DecorationType;
2626
+ }[];
2627
+ };
2628
+ headerSix?: {
2629
+ decorations: {
2630
+ anchorData?: {
2631
+ anchor: string;
2632
+ };
2633
+ linkData?: {
2634
+ link?: {
2635
+ url: string;
2636
+ anchor: string;
2637
+ target: Target;
2638
+ };
2639
+ };
2640
+ mentionData?: {
2641
+ name: string;
2642
+ slug: string;
2643
+ };
2644
+ fontSizeData?: {
2645
+ unit: FontType;
2646
+ };
2647
+ type: DecorationType;
2648
+ }[];
2649
+ };
2650
+ paragraph?: {
2651
+ decorations: {
2652
+ anchorData?: {
2653
+ anchor: string;
2654
+ };
2655
+ linkData?: {
2656
+ link?: {
2657
+ url: string;
2658
+ anchor: string;
2659
+ target: Target;
2660
+ };
2661
+ };
2662
+ mentionData?: {
2663
+ name: string;
2664
+ slug: string;
2665
+ };
2666
+ fontSizeData?: {
2667
+ unit: FontType;
2668
+ };
2669
+ type: DecorationType;
2670
+ }[];
2671
+ };
2672
+ blockquote?: {
2673
+ decorations: {
2674
+ anchorData?: {
2675
+ anchor: string;
2676
+ };
2677
+ linkData?: {
2678
+ link?: {
2679
+ url: string;
2680
+ anchor: string;
2681
+ target: Target;
2682
+ };
2683
+ };
2684
+ mentionData?: {
2685
+ name: string;
2686
+ slug: string;
2687
+ };
2688
+ fontSizeData?: {
2689
+ unit: FontType;
2690
+ };
2691
+ type: DecorationType;
2692
+ }[];
2693
+ };
2694
+ codeBlock?: {
2695
+ decorations: {
2696
+ anchorData?: {
2697
+ anchor: string;
2698
+ };
2699
+ linkData?: {
2700
+ link?: {
2701
+ url: string;
2702
+ anchor: string;
2703
+ target: Target;
2704
+ };
2705
+ };
2706
+ mentionData?: {
2707
+ name: string;
2708
+ slug: string;
2709
+ };
2710
+ fontSizeData?: {
2711
+ unit: FontType;
2712
+ };
2713
+ type: DecorationType;
2714
+ }[];
2715
+ };
2716
+ };
2717
+ };
2718
+ };
2719
+ }
2720
+ export interface GetCategoryResponseNonNullableFields {
2010
2721
  category?: {
2011
2722
  image: string;
2012
2723
  numberOfItems: number;
@@ -2277,7 +2988,7 @@ export interface CreateCategoryResponseNonNullableFields {
2277
2988
  };
2278
2989
  type: NodeType;
2279
2990
  _id: string;
2280
- nodes: NonNullable<NonNullable<NonNullable<CreateCategoryResponseNonNullableFields>['category']>['richContentDescription']>['nodes'][];
2991
+ nodes: NonNullable<NonNullable<NonNullable<GetCategoryResponseNonNullableFields>['category']>['richContentDescription']>['nodes'][];
2281
2992
  }[];
2282
2993
  metadata?: {
2283
2994
  version: number;
@@ -2485,7 +3196,7 @@ export interface CreateCategoryResponseNonNullableFields {
2485
3196
  };
2486
3197
  };
2487
3198
  }
2488
- export interface GetCategoryResponseNonNullableFields {
3199
+ export interface UpdateCategoryResponseNonNullableFields {
2489
3200
  category?: {
2490
3201
  image: string;
2491
3202
  numberOfItems: number;
@@ -2756,7 +3467,7 @@ export interface GetCategoryResponseNonNullableFields {
2756
3467
  };
2757
3468
  type: NodeType;
2758
3469
  _id: string;
2759
- nodes: NonNullable<NonNullable<NonNullable<GetCategoryResponseNonNullableFields>['category']>['richContentDescription']>['nodes'][];
3470
+ nodes: NonNullable<NonNullable<NonNullable<UpdateCategoryResponseNonNullableFields>['category']>['richContentDescription']>['nodes'][];
2760
3471
  }[];
2761
3472
  metadata?: {
2762
3473
  version: number;
@@ -2964,8 +3675,8 @@ export interface GetCategoryResponseNonNullableFields {
2964
3675
  };
2965
3676
  };
2966
3677
  }
2967
- export interface UpdateCategoryResponseNonNullableFields {
2968
- category?: {
3678
+ export interface QueryCategoriesResponseNonNullableFields {
3679
+ categories: {
2969
3680
  image: string;
2970
3681
  numberOfItems: number;
2971
3682
  breadcrumbs?: {
@@ -3235,7 +3946,7 @@ export interface UpdateCategoryResponseNonNullableFields {
3235
3946
  };
3236
3947
  type: NodeType;
3237
3948
  _id: string;
3238
- nodes: NonNullable<NonNullable<NonNullable<UpdateCategoryResponseNonNullableFields>['category']>['richContentDescription']>['nodes'][];
3949
+ nodes: NonNullable<NonNullable<NonNullable<QueryCategoriesResponseNonNullableFields>['categories'][0]>['richContentDescription']>['nodes'][];
3239
3950
  }[];
3240
3951
  metadata?: {
3241
3952
  version: number;
@@ -3441,9 +4152,9 @@ export interface UpdateCategoryResponseNonNullableFields {
3441
4152
  };
3442
4153
  };
3443
4154
  };
3444
- };
4155
+ }[];
3445
4156
  }
3446
- export interface QueryCategoriesResponseNonNullableFields {
4157
+ export interface SearchCategoriesResponseNonNullableFields {
3447
4158
  categories: {
3448
4159
  image: string;
3449
4160
  numberOfItems: number;
@@ -3714,7 +4425,7 @@ export interface QueryCategoriesResponseNonNullableFields {
3714
4425
  };
3715
4426
  type: NodeType;
3716
4427
  _id: string;
3717
- nodes: NonNullable<NonNullable<NonNullable<QueryCategoriesResponseNonNullableFields>['categories'][0]>['richContentDescription']>['nodes'][];
4428
+ nodes: NonNullable<NonNullable<NonNullable<SearchCategoriesResponseNonNullableFields>['categories'][0]>['richContentDescription']>['nodes'][];
3718
4429
  }[];
3719
4430
  metadata?: {
3720
4431
  version: number;
@@ -3921,6 +4632,56 @@ export interface QueryCategoriesResponseNonNullableFields {
3921
4632
  };
3922
4633
  };
3923
4634
  }[];
4635
+ aggregationData?: {
4636
+ results: {
4637
+ values?: {
4638
+ results: {
4639
+ value: string;
4640
+ count: number;
4641
+ }[];
4642
+ };
4643
+ ranges?: {
4644
+ results: {
4645
+ count: number;
4646
+ }[];
4647
+ };
4648
+ scalar?: {
4649
+ type: ScalarType;
4650
+ value: number;
4651
+ };
4652
+ groupedByValue?: {
4653
+ results: {
4654
+ value: string;
4655
+ nestedResults?: {
4656
+ values?: {
4657
+ results: {
4658
+ value: string;
4659
+ count: number;
4660
+ }[];
4661
+ };
4662
+ ranges?: {
4663
+ results: {
4664
+ count: number;
4665
+ }[];
4666
+ };
4667
+ scalar?: {
4668
+ type: ScalarType;
4669
+ value: number;
4670
+ };
4671
+ name: string;
4672
+ type: AggregationType;
4673
+ fieldPath: string;
4674
+ };
4675
+ }[];
4676
+ };
4677
+ name: string;
4678
+ type: AggregationType;
4679
+ fieldPath: string;
4680
+ }[];
4681
+ };
4682
+ }
4683
+ export interface CountCategoriesResponseNonNullableFields {
4684
+ count: number;
3924
4685
  }
3925
4686
  export interface MoveCategoryResponseNonNullableFields {
3926
4687
  categoriesAfterMove: string[];
@@ -5239,6 +6000,61 @@ export interface CategoriesQueryBuilder {
5239
6000
  /** @documentationMaturity preview */
5240
6001
  find: () => Promise<CategoriesQueryResult>;
5241
6002
  }
6003
+ /**
6004
+ * Search Categories using [WQL - Wix Query Language](https://dev.wix.com/api/rest/getting-started/api-query-language)
6005
+ * @public
6006
+ * @documentationMaturity preview
6007
+ * @requiredField options.treeReference
6008
+ * @requiredField options.treeReference.appNamespace
6009
+ * @applicableIdentity MEMBER
6010
+ * @applicableIdentity VISITOR
6011
+ */
6012
+ export declare function searchCategories(options?: SearchCategoriesOptions): Promise<SearchCategoriesResponse & SearchCategoriesResponseNonNullableFields>;
6013
+ export interface SearchCategoriesOptions {
6014
+ /** WQL query expression. */
6015
+ search?: CursorSearch;
6016
+ /**
6017
+ * A reference to the tree that contains this category.
6018
+ * Used only in the first request. Following requests use the cursor token.
6019
+ */
6020
+ treeReference: TreeReference;
6021
+ /**
6022
+ * Whether hidden categories should be included in the response. Default is `false`.
6023
+ * Used only in the first request. Following requests use the cursor token.
6024
+ */
6025
+ includeHidden?: boolean;
6026
+ /** Fields to return in the response. When not provided, these fields are not returned. */
6027
+ fields?: RequestedFields[];
6028
+ }
6029
+ /**
6030
+ * Returns total count of categories satisfying filter and/or search
6031
+ * @public
6032
+ * @documentationMaturity preview
6033
+ * @requiredField options.treeReference
6034
+ * @requiredField options.treeReference.appNamespace
6035
+ * @applicableIdentity MEMBER
6036
+ * @applicableIdentity VISITOR
6037
+ */
6038
+ export declare function countCategories(options?: CountCategoriesOptions): Promise<CountCategoriesResponse & CountCategoriesResponseNonNullableFields>;
6039
+ export interface CountCategoriesOptions {
6040
+ /**
6041
+ * A filter object. See documentation [here](https://bo.wix.com/wix-docs/rnd/platformization-guidelines/api-query-language#platformization-guidelines_api-query-language_defining-in-protobuf)
6042
+ * To understand supported filters and limitations see `SearchCategories` method.
6043
+ */
6044
+ filter?: Record<string, any> | null;
6045
+ /** free text to match in searchable fields */
6046
+ search?: SearchDetails;
6047
+ /**
6048
+ * A reference to the tree that contains this category.
6049
+ * Used only in the first request. Following requests use the cursor token.
6050
+ */
6051
+ treeReference: TreeReference;
6052
+ /**
6053
+ * Whether hidden categories should be included in the response. Default is `false`.
6054
+ * Used only in the first request. Following requests use the cursor token.
6055
+ */
6056
+ includeHidden?: boolean;
6057
+ }
5242
6058
  /**
5243
6059
  * Moves a category.
5244
6060
  * This operation updates `parentCategory` (`id` and `index`) for category with `categoryId`.