@wix/blog 1.0.237 → 1.0.239
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.
- package/build/cjs/context.d.ts +4 -4
- package/build/cjs/context.js +4 -4
- package/build/cjs/context.js.map +1 -1
- package/build/cjs/index.d.ts +4 -4
- package/build/cjs/index.js +4 -4
- package/build/cjs/index.js.map +1 -1
- package/build/cjs/meta.d.ts +4 -4
- package/build/cjs/meta.js +4 -4
- package/build/cjs/meta.js.map +1 -1
- package/build/es/context.d.ts +4 -4
- package/build/es/context.js +4 -4
- package/build/es/context.js.map +1 -1
- package/build/es/index.d.ts +4 -4
- package/build/es/index.js +4 -4
- package/build/es/index.js.map +1 -1
- package/build/es/meta.d.ts +4 -4
- package/build/es/meta.js +4 -4
- package/build/es/meta.js.map +1 -1
- package/package.json +14 -9
- package/build/cjs/index.typings.d.ts +0 -4
- package/build/cjs/index.typings.js +0 -31
- package/build/cjs/index.typings.js.map +0 -1
- package/build/cjs/src/blog-v3-category.context.d.ts +0 -6
- package/build/cjs/src/blog-v3-category.context.js +0 -53
- package/build/cjs/src/blog-v3-category.context.js.map +0 -1
- package/build/cjs/src/blog-v3-category.http.d.ts +0 -43
- package/build/cjs/src/blog-v3-category.http.js +0 -355
- package/build/cjs/src/blog-v3-category.http.js.map +0 -1
- package/build/cjs/src/blog-v3-category.meta.d.ts +0 -20
- package/build/cjs/src/blog-v3-category.meta.js +0 -104
- package/build/cjs/src/blog-v3-category.meta.js.map +0 -1
- package/build/cjs/src/blog-v3-category.public.d.ts +0 -43
- package/build/cjs/src/blog-v3-category.public.js +0 -37
- package/build/cjs/src/blog-v3-category.public.js.map +0 -1
- package/build/cjs/src/blog-v3-category.types.d.ts +0 -910
- package/build/cjs/src/blog-v3-category.types.js +0 -24
- package/build/cjs/src/blog-v3-category.types.js.map +0 -1
- package/build/cjs/src/blog-v3-category.universal.d.ts +0 -956
- package/build/cjs/src/blog-v3-category.universal.js +0 -383
- package/build/cjs/src/blog-v3-category.universal.js.map +0 -1
- package/build/cjs/src/blog-v3-draft.context.d.ts +0 -16
- package/build/cjs/src/blog-v3-draft.context.js +0 -173
- package/build/cjs/src/blog-v3-draft.context.js.map +0 -1
- package/build/cjs/src/blog-v3-draft.http.d.ts +0 -79
- package/build/cjs/src/blog-v3-draft.http.js +0 -1498
- package/build/cjs/src/blog-v3-draft.http.js.map +0 -1
- package/build/cjs/src/blog-v3-draft.meta.d.ts +0 -40
- package/build/cjs/src/blog-v3-draft.meta.js +0 -294
- package/build/cjs/src/blog-v3-draft.meta.js.map +0 -1
- package/build/cjs/src/blog-v3-draft.public.d.ts +0 -22
- package/build/cjs/src/blog-v3-draft.public.js +0 -133
- package/build/cjs/src/blog-v3-draft.public.js.map +0 -1
- package/build/cjs/src/blog-v3-draft.types.d.ts +0 -9171
- package/build/cjs/src/blog-v3-draft.types.js +0 -456
- package/build/cjs/src/blog-v3-draft.types.js.map +0 -1
- package/build/cjs/src/blog-v3-draft.universal.d.ts +0 -8816
- package/build/cjs/src/blog-v3-draft.universal.js +0 -1585
- package/build/cjs/src/blog-v3-draft.universal.js.map +0 -1
- package/build/cjs/src/blog-v3-post.context.d.ts +0 -9
- package/build/cjs/src/blog-v3-post.context.js +0 -89
- package/build/cjs/src/blog-v3-post.context.js.map +0 -1
- package/build/cjs/src/blog-v3-post.http.d.ts +0 -80
- package/build/cjs/src/blog-v3-post.http.js +0 -893
- package/build/cjs/src/blog-v3-post.http.js.map +0 -1
- package/build/cjs/src/blog-v3-post.meta.d.ts +0 -25
- package/build/cjs/src/blog-v3-post.meta.js +0 -161
- package/build/cjs/src/blog-v3-post.meta.js.map +0 -1
- package/build/cjs/src/blog-v3-post.public.d.ts +0 -548
- package/build/cjs/src/blog-v3-post.public.js +0 -94
- package/build/cjs/src/blog-v3-post.public.js.map +0 -1
- package/build/cjs/src/blog-v3-post.types.d.ts +0 -5238
- package/build/cjs/src/blog-v3-post.types.js +0 -478
- package/build/cjs/src/blog-v3-post.types.js.map +0 -1
- package/build/cjs/src/blog-v3-post.universal.d.ts +0 -5216
- package/build/cjs/src/blog-v3-post.universal.js +0 -1112
- package/build/cjs/src/blog-v3-post.universal.js.map +0 -1
- package/build/cjs/src/blog-v3-tag.context.d.ts +0 -6
- package/build/cjs/src/blog-v3-tag.context.js +0 -53
- package/build/cjs/src/blog-v3-tag.context.js.map +0 -1
- package/build/cjs/src/blog-v3-tag.http.d.ts +0 -40
- package/build/cjs/src/blog-v3-tag.http.js +0 -348
- package/build/cjs/src/blog-v3-tag.http.js.map +0 -1
- package/build/cjs/src/blog-v3-tag.meta.d.ts +0 -22
- package/build/cjs/src/blog-v3-tag.meta.js +0 -104
- package/build/cjs/src/blog-v3-tag.meta.js.map +0 -1
- package/build/cjs/src/blog-v3-tag.public.d.ts +0 -20
- package/build/cjs/src/blog-v3-tag.public.js +0 -37
- package/build/cjs/src/blog-v3-tag.public.js.map +0 -1
- package/build/cjs/src/blog-v3-tag.types.d.ts +0 -663
- package/build/cjs/src/blog-v3-tag.types.js +0 -17
- package/build/cjs/src/blog-v3-tag.types.js.map +0 -1
- package/build/cjs/src/blog-v3-tag.universal.d.ts +0 -807
- package/build/cjs/src/blog-v3-tag.universal.js +0 -364
- package/build/cjs/src/blog-v3-tag.universal.js.map +0 -1
- package/build/es/index.typings.d.ts +0 -4
- package/build/es/index.typings.js +0 -5
- package/build/es/index.typings.js.map +0 -1
- package/build/es/src/blog-v3-category.context.d.ts +0 -6
- package/build/es/src/blog-v3-category.context.js +0 -46
- package/build/es/src/blog-v3-category.context.js.map +0 -1
- package/build/es/src/blog-v3-category.http.d.ts +0 -43
- package/build/es/src/blog-v3-category.http.js +0 -348
- package/build/es/src/blog-v3-category.http.js.map +0 -1
- package/build/es/src/blog-v3-category.meta.d.ts +0 -20
- package/build/es/src/blog-v3-category.meta.js +0 -74
- package/build/es/src/blog-v3-category.meta.js.map +0 -1
- package/build/es/src/blog-v3-category.public.d.ts +0 -43
- package/build/es/src/blog-v3-category.public.js +0 -25
- package/build/es/src/blog-v3-category.public.js.map +0 -1
- package/build/es/src/blog-v3-category.types.d.ts +0 -910
- package/build/es/src/blog-v3-category.types.js +0 -21
- package/build/es/src/blog-v3-category.types.js.map +0 -1
- package/build/es/src/blog-v3-category.universal.d.ts +0 -956
- package/build/es/src/blog-v3-category.universal.js +0 -353
- package/build/es/src/blog-v3-category.universal.js.map +0 -1
- package/build/es/src/blog-v3-draft.context.d.ts +0 -16
- package/build/es/src/blog-v3-draft.context.js +0 -156
- package/build/es/src/blog-v3-draft.context.js.map +0 -1
- package/build/es/src/blog-v3-draft.http.d.ts +0 -79
- package/build/es/src/blog-v3-draft.http.js +0 -1481
- package/build/es/src/blog-v3-draft.http.js.map +0 -1
- package/build/es/src/blog-v3-draft.meta.d.ts +0 -40
- package/build/es/src/blog-v3-draft.meta.js +0 -254
- package/build/es/src/blog-v3-draft.meta.js.map +0 -1
- package/build/es/src/blog-v3-draft.public.d.ts +0 -22
- package/build/es/src/blog-v3-draft.public.js +0 -75
- package/build/es/src/blog-v3-draft.public.js.map +0 -1
- package/build/es/src/blog-v3-draft.types.d.ts +0 -9171
- package/build/es/src/blog-v3-draft.types.js +0 -453
- package/build/es/src/blog-v3-draft.types.js.map +0 -1
- package/build/es/src/blog-v3-draft.universal.d.ts +0 -8816
- package/build/es/src/blog-v3-draft.universal.js +0 -1544
- package/build/es/src/blog-v3-draft.universal.js.map +0 -1
- package/build/es/src/blog-v3-post.context.d.ts +0 -9
- package/build/es/src/blog-v3-post.context.js +0 -79
- package/build/es/src/blog-v3-post.context.js.map +0 -1
- package/build/es/src/blog-v3-post.http.d.ts +0 -80
- package/build/es/src/blog-v3-post.http.js +0 -883
- package/build/es/src/blog-v3-post.http.js.map +0 -1
- package/build/es/src/blog-v3-post.meta.d.ts +0 -25
- package/build/es/src/blog-v3-post.meta.js +0 -128
- package/build/es/src/blog-v3-post.meta.js.map +0 -1
- package/build/es/src/blog-v3-post.public.d.ts +0 -548
- package/build/es/src/blog-v3-post.public.js +0 -40
- package/build/es/src/blog-v3-post.public.js.map +0 -1
- package/build/es/src/blog-v3-post.types.d.ts +0 -5238
- package/build/es/src/blog-v3-post.types.js +0 -475
- package/build/es/src/blog-v3-post.types.js.map +0 -1
- package/build/es/src/blog-v3-post.universal.d.ts +0 -5216
- package/build/es/src/blog-v3-post.universal.js +0 -1079
- package/build/es/src/blog-v3-post.universal.js.map +0 -1
- package/build/es/src/blog-v3-tag.context.d.ts +0 -6
- package/build/es/src/blog-v3-tag.context.js +0 -46
- package/build/es/src/blog-v3-tag.context.js.map +0 -1
- package/build/es/src/blog-v3-tag.http.d.ts +0 -40
- package/build/es/src/blog-v3-tag.http.js +0 -341
- package/build/es/src/blog-v3-tag.http.js.map +0 -1
- package/build/es/src/blog-v3-tag.meta.d.ts +0 -22
- package/build/es/src/blog-v3-tag.meta.js +0 -74
- package/build/es/src/blog-v3-tag.meta.js.map +0 -1
- package/build/es/src/blog-v3-tag.public.d.ts +0 -20
- package/build/es/src/blog-v3-tag.public.js +0 -25
- package/build/es/src/blog-v3-tag.public.js.map +0 -1
- package/build/es/src/blog-v3-tag.types.d.ts +0 -663
- package/build/es/src/blog-v3-tag.types.js +0 -14
- package/build/es/src/blog-v3-tag.types.js.map +0 -1
- package/build/es/src/blog-v3-tag.universal.d.ts +0 -807
- package/build/es/src/blog-v3-tag.universal.js +0 -334
- package/build/es/src/blog-v3-tag.universal.js.map +0 -1
|
@@ -1,956 +0,0 @@
|
|
|
1
|
-
import { EventDefinition } from '@wix/sdk-types';
|
|
2
|
-
export interface Category {
|
|
3
|
-
/**
|
|
4
|
-
* Category ID.
|
|
5
|
-
* @readonly
|
|
6
|
-
*/
|
|
7
|
-
_id?: string;
|
|
8
|
-
/** Category label. Displayed in the Category Menu. */
|
|
9
|
-
label?: string;
|
|
10
|
-
/**
|
|
11
|
-
* Number of posts in the category.
|
|
12
|
-
* @readonly
|
|
13
|
-
*/
|
|
14
|
-
postCount?: number;
|
|
15
|
-
/**
|
|
16
|
-
* Category URL.
|
|
17
|
-
*
|
|
18
|
-
*
|
|
19
|
-
* The `url` directs you to a page that lists every post with the specified category.
|
|
20
|
-
*
|
|
21
|
-
* @readonly
|
|
22
|
-
*/
|
|
23
|
-
url?: string;
|
|
24
|
-
/** Category description. */
|
|
25
|
-
description?: string | null;
|
|
26
|
-
/** Category title. */
|
|
27
|
-
title?: string;
|
|
28
|
-
/** Reserved for internal use. */
|
|
29
|
-
coverMedia?: CoverMedia;
|
|
30
|
-
/**
|
|
31
|
-
* Reserved for internal use.
|
|
32
|
-
* @readonly
|
|
33
|
-
*/
|
|
34
|
-
oldRank?: number;
|
|
35
|
-
/** Reserved for internal use. */
|
|
36
|
-
rank?: number | null;
|
|
37
|
-
/** Position of the category in the [Category Menu](https://support.wix.com/en/article/wix-blog-adding-and-customizing-a-category-menu). Categories with lower display position are displayed first. */
|
|
38
|
-
displayPosition?: number | null;
|
|
39
|
-
/**
|
|
40
|
-
* ID of the category's translations when [Wix Multilingual](https://support.wix.com/en/article/wix-multilingual-translating-your-blog) is installed on a site. All translations of a single category will share the same `translationId`.
|
|
41
|
-
* @readonly
|
|
42
|
-
*/
|
|
43
|
-
translationId?: string | null;
|
|
44
|
-
/**
|
|
45
|
-
* Category Language.
|
|
46
|
-
*
|
|
47
|
-
* 2-letter language code in [ISO 639-1 format](https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes).
|
|
48
|
-
*/
|
|
49
|
-
language?: string | null;
|
|
50
|
-
/**
|
|
51
|
-
* Part of a category's URL that refers to a specific category.
|
|
52
|
-
*
|
|
53
|
-
*
|
|
54
|
-
* For example, `'https:/example.com/blog/category/{my-category-slug}'`.
|
|
55
|
-
*/
|
|
56
|
-
slug?: string;
|
|
57
|
-
/**
|
|
58
|
-
* Reserved for internal use.
|
|
59
|
-
* @readonly
|
|
60
|
-
*/
|
|
61
|
-
internalId?: string | null;
|
|
62
|
-
/** SEO data. */
|
|
63
|
-
seoData?: SeoSchema;
|
|
64
|
-
/** Category cover image. */
|
|
65
|
-
coverImage?: string;
|
|
66
|
-
}
|
|
67
|
-
export interface CoverMedia extends CoverMediaMediaOneOf {
|
|
68
|
-
/** Image url. */
|
|
69
|
-
image?: string;
|
|
70
|
-
/** Video url. */
|
|
71
|
-
video?: string;
|
|
72
|
-
/**
|
|
73
|
-
* Is cover media enabled.
|
|
74
|
-
* Selected by user whether to display cover media on the feed
|
|
75
|
-
*/
|
|
76
|
-
enabled?: boolean;
|
|
77
|
-
/** Whether cover media is displayed. */
|
|
78
|
-
displayed?: boolean;
|
|
79
|
-
/** If `false`, the cover image is the first media item appearing in the content. */
|
|
80
|
-
custom?: boolean;
|
|
81
|
-
}
|
|
82
|
-
/** @oneof */
|
|
83
|
-
export interface CoverMediaMediaOneOf {
|
|
84
|
-
/** Image url. */
|
|
85
|
-
image?: string;
|
|
86
|
-
/** Video url. */
|
|
87
|
-
video?: string;
|
|
88
|
-
}
|
|
89
|
-
/**
|
|
90
|
-
* The SEO schema object contains data about different types of meta tags. It makes sure that the information about your page is presented properly to search engines.
|
|
91
|
-
* The search engines use this information for ranking purposes, or to display snippets in the search results.
|
|
92
|
-
* This data will override other sources of tags (for example patterns) and will be included in the <head> section of the HTML document, while not being displayed on the page itself.
|
|
93
|
-
*/
|
|
94
|
-
export interface SeoSchema {
|
|
95
|
-
/** SEO tag information. */
|
|
96
|
-
tags?: Tag[];
|
|
97
|
-
/** SEO general settings. */
|
|
98
|
-
settings?: Settings;
|
|
99
|
-
}
|
|
100
|
-
export interface Keyword {
|
|
101
|
-
/** Keyword value. */
|
|
102
|
-
term?: string;
|
|
103
|
-
/** Whether the keyword is the main focus keyword. */
|
|
104
|
-
isMain?: boolean;
|
|
105
|
-
}
|
|
106
|
-
export interface Tag {
|
|
107
|
-
/**
|
|
108
|
-
* SEO tag type.
|
|
109
|
-
*
|
|
110
|
-
*
|
|
111
|
-
* Supported values: `title`, `meta`, `script`, `link`.
|
|
112
|
-
*/
|
|
113
|
-
type?: string;
|
|
114
|
-
/**
|
|
115
|
-
* A `{'key':'value'}` pair object where each SEO tag property (`'name'`, `'content'`, `'rel'`, `'href'`) contains a value.
|
|
116
|
-
* For example: `{'name': 'description', 'content': 'the description itself'}`.
|
|
117
|
-
*/
|
|
118
|
-
props?: Record<string, any> | null;
|
|
119
|
-
/** SEO tag meta data. For example, `{height: 300, width: 240}`. */
|
|
120
|
-
meta?: Record<string, any> | null;
|
|
121
|
-
/** SEO tag inner content. For example, `<title> inner content </title>`. */
|
|
122
|
-
children?: string;
|
|
123
|
-
/** Whether the tag is a custom tag. */
|
|
124
|
-
custom?: boolean;
|
|
125
|
-
/** Whether the tag is disabled. */
|
|
126
|
-
disabled?: boolean;
|
|
127
|
-
}
|
|
128
|
-
export interface Settings {
|
|
129
|
-
/**
|
|
130
|
-
* Whether the Auto Redirect feature, which creates `301 redirects` on a slug change, is enabled.
|
|
131
|
-
*
|
|
132
|
-
*
|
|
133
|
-
* Default: `false` (Auto Redirect is enabled.)
|
|
134
|
-
*/
|
|
135
|
-
preventAutoRedirect?: boolean;
|
|
136
|
-
/** User-selected keyword terms for a specific page. */
|
|
137
|
-
keywords?: Keyword[];
|
|
138
|
-
}
|
|
139
|
-
export interface CategoryTranslation {
|
|
140
|
-
/** Category ID */
|
|
141
|
-
_id?: string;
|
|
142
|
-
/** Label which is presented in the categories menu on site */
|
|
143
|
-
label?: string | null;
|
|
144
|
-
/** Language of the category */
|
|
145
|
-
language?: string | null;
|
|
146
|
-
/** Url of this category page */
|
|
147
|
-
url?: string;
|
|
148
|
-
}
|
|
149
|
-
export interface InitialCategoriesCopied {
|
|
150
|
-
/** Number of categories copied. */
|
|
151
|
-
count?: number;
|
|
152
|
-
}
|
|
153
|
-
export interface CreateCategoryRequest {
|
|
154
|
-
/** Category info. */
|
|
155
|
-
category?: Category;
|
|
156
|
-
/**
|
|
157
|
-
* List of additional category fields to include in the response. For example, use the `URL` fieldset to retrieve the url field in
|
|
158
|
-
* the response in addition to the category’s base fields. Base fields don’t include any of the supported fieldset values. By default
|
|
159
|
-
* only the category’s base fields are returned.
|
|
160
|
-
*/
|
|
161
|
-
fieldsets?: Field[];
|
|
162
|
-
}
|
|
163
|
-
export declare enum Field {
|
|
164
|
-
UNKNOWN = "UNKNOWN",
|
|
165
|
-
/** Includes Category url. */
|
|
166
|
-
URL = "URL",
|
|
167
|
-
/**
|
|
168
|
-
* Includes internal id field.
|
|
169
|
-
* Reserved for internal use
|
|
170
|
-
*/
|
|
171
|
-
INTERNAL_ID = "INTERNAL_ID",
|
|
172
|
-
/** Includes SEO data. */
|
|
173
|
-
SEO = "SEO",
|
|
174
|
-
/** Includes translations. */
|
|
175
|
-
TRANSLATIONS = "TRANSLATIONS"
|
|
176
|
-
}
|
|
177
|
-
export interface CreateCategoryResponse {
|
|
178
|
-
/** Category info. */
|
|
179
|
-
category?: Category;
|
|
180
|
-
}
|
|
181
|
-
export interface BulkCreateCategoriesRequest {
|
|
182
|
-
/** Categories to create. */
|
|
183
|
-
categories?: Category[];
|
|
184
|
-
/** Whether to return the full created category entities in the response. */
|
|
185
|
-
returnFullEntity?: boolean;
|
|
186
|
-
/**
|
|
187
|
-
* List of additional category fields to include in the response. For example, use the `URL` fieldset to retrieve the url field in
|
|
188
|
-
* the response in addition to the category’s base fields. Base fields don’t include any of the supported fieldset values. By default
|
|
189
|
-
* only the category’s base fields are returned.
|
|
190
|
-
*/
|
|
191
|
-
fieldsets?: Field[];
|
|
192
|
-
}
|
|
193
|
-
export interface BulkCreateCategoriesResponse {
|
|
194
|
-
/** Categories created by bulk action. */
|
|
195
|
-
results?: BulkCategoryResult[];
|
|
196
|
-
/** Bulk action metadata. */
|
|
197
|
-
bulkActionMetadata?: BulkActionMetadata;
|
|
198
|
-
}
|
|
199
|
-
export interface BulkCategoryResult {
|
|
200
|
-
/** Bulk actions metadata for category. */
|
|
201
|
-
itemMetadata?: ItemMetadata;
|
|
202
|
-
/** Optional created category. */
|
|
203
|
-
item?: Category;
|
|
204
|
-
}
|
|
205
|
-
export interface ItemMetadata {
|
|
206
|
-
/** Item ID. Should always be available, unless it's impossible (for example, when failing to create an item). */
|
|
207
|
-
_id?: string | null;
|
|
208
|
-
/** Index of the item within the request array. Allows for correlation between request and response items. */
|
|
209
|
-
originalIndex?: number;
|
|
210
|
-
/** Whether the requested action was successful for this item. When `false`, the `error` field is populated. */
|
|
211
|
-
success?: boolean;
|
|
212
|
-
/** Details about the error in case of failure. */
|
|
213
|
-
error?: ApplicationError;
|
|
214
|
-
}
|
|
215
|
-
export interface ApplicationError {
|
|
216
|
-
/** Error code. */
|
|
217
|
-
code?: string;
|
|
218
|
-
/** Description of the error. */
|
|
219
|
-
description?: string;
|
|
220
|
-
/** Data related to the error. */
|
|
221
|
-
data?: Record<string, any> | null;
|
|
222
|
-
}
|
|
223
|
-
export interface BulkActionMetadata {
|
|
224
|
-
/** Number of items that were successfully processed. */
|
|
225
|
-
totalSuccesses?: number;
|
|
226
|
-
/** Number of items that couldn't be processed. */
|
|
227
|
-
totalFailures?: number;
|
|
228
|
-
/** Number of failures without details because detailed failure threshold was exceeded. */
|
|
229
|
-
undetailedFailures?: number;
|
|
230
|
-
}
|
|
231
|
-
export interface BulkUpdateCategoriesRequest {
|
|
232
|
-
/** Categories to update. */
|
|
233
|
-
categories?: MaskedCategory[];
|
|
234
|
-
/** Whether to return the full created category entities in the response. */
|
|
235
|
-
returnFullEntity?: boolean;
|
|
236
|
-
/**
|
|
237
|
-
* List of category fields to be included in the response if the entities are present.
|
|
238
|
-
* Base default fieldset returns all core category properties (all properties that are not a supported fieldset value).
|
|
239
|
-
* For example, when `URL` fieldset is selected, returned category will include the set of base properties and the category's preview url.
|
|
240
|
-
*/
|
|
241
|
-
fieldsets?: Field[];
|
|
242
|
-
}
|
|
243
|
-
export interface MaskedCategory {
|
|
244
|
-
/** Category */
|
|
245
|
-
category?: Category;
|
|
246
|
-
}
|
|
247
|
-
export interface BulkUpdateCategoriesResponse {
|
|
248
|
-
/** Categories updated by bulk action. */
|
|
249
|
-
results?: BulkCategoryResult[];
|
|
250
|
-
/** Bulk action metadata. */
|
|
251
|
-
bulkActionMetadata?: BulkActionMetadata;
|
|
252
|
-
}
|
|
253
|
-
export interface UpdateCategoryRequest {
|
|
254
|
-
/** Category info. */
|
|
255
|
-
category?: Category;
|
|
256
|
-
/**
|
|
257
|
-
* List of additional category fields to include in the response. For example, use the `URL` fieldset to retrieve the url field in
|
|
258
|
-
* the response in addition to the category’s base fields. Base fields don’t include any of the supported fieldset values. By default
|
|
259
|
-
* only the category’s base fields are returned.
|
|
260
|
-
*/
|
|
261
|
-
fieldsets?: Field[];
|
|
262
|
-
}
|
|
263
|
-
export interface UpdateCategoryResponse {
|
|
264
|
-
/** Category info. */
|
|
265
|
-
category?: Category;
|
|
266
|
-
}
|
|
267
|
-
export interface GetCategoriesCountByLanguageRequest {
|
|
268
|
-
}
|
|
269
|
-
export interface GetCategoriesCountByLanguageResponse {
|
|
270
|
-
/** The language and it's count. */
|
|
271
|
-
categoriesLanguageCount?: CategoryLanguageCount[];
|
|
272
|
-
}
|
|
273
|
-
export interface CategoryLanguageCount {
|
|
274
|
-
/** 2-letter language code in [ISO 639-1 alpha-2](https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes) format. */
|
|
275
|
-
languageCode?: string | null;
|
|
276
|
-
/** The count of Categories for the language. */
|
|
277
|
-
categoryCount?: number | null;
|
|
278
|
-
}
|
|
279
|
-
export interface GetCategoryRequest {
|
|
280
|
-
/** Category ID. */
|
|
281
|
-
categoryId: string;
|
|
282
|
-
/**
|
|
283
|
-
* __Deprecated.__ Use `fieldsets` instead.
|
|
284
|
-
* This parameter will be removed on June 30, 2023.
|
|
285
|
-
*
|
|
286
|
-
* List of category fields to be included in the response.
|
|
287
|
-
*/
|
|
288
|
-
fieldsToInclude?: Field[];
|
|
289
|
-
/**
|
|
290
|
-
* List of additional category fields to include in the response. For example, use the `URL` fieldset to retrieve the url field in
|
|
291
|
-
* the response in addition to the category’s base fields. Base fields don’t include any of the supported fieldset values. By default
|
|
292
|
-
* only the category’s base fields are returned.
|
|
293
|
-
*/
|
|
294
|
-
fieldsets?: Field[];
|
|
295
|
-
}
|
|
296
|
-
export interface GetCategoryResponse {
|
|
297
|
-
/** Category info. */
|
|
298
|
-
category?: Category;
|
|
299
|
-
}
|
|
300
|
-
export interface GetCategoryBySlugRequest {
|
|
301
|
-
/** Slug of the category to retrieve. */
|
|
302
|
-
slug: string;
|
|
303
|
-
/**
|
|
304
|
-
* __Deprecated.__ Use `fieldsets` instead.
|
|
305
|
-
*
|
|
306
|
-
* This parameter will be removed on June 30, 2023.
|
|
307
|
-
* List of category fields to be included in the response.
|
|
308
|
-
*/
|
|
309
|
-
fieldsToInclude?: Field[];
|
|
310
|
-
/**
|
|
311
|
-
* List of additional category fields to include in the response. For example, use the `URL` fieldset to retrieve the url field in
|
|
312
|
-
* the response in addition to the category’s base fields. Base fields don’t include any of the supported fieldset values. By default
|
|
313
|
-
* only the category’s base fields are returned.
|
|
314
|
-
*/
|
|
315
|
-
fieldsets?: Field[];
|
|
316
|
-
/**
|
|
317
|
-
* 2-letter language code in [ISO 639-1 alpha-2](https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes) format.
|
|
318
|
-
* Language of the category to retrieve.
|
|
319
|
-
*/
|
|
320
|
-
language?: string | null;
|
|
321
|
-
}
|
|
322
|
-
export interface GetCategoryBySlugResponse {
|
|
323
|
-
/** Category info. */
|
|
324
|
-
category?: Category;
|
|
325
|
-
}
|
|
326
|
-
export interface ListCategoriesRequest {
|
|
327
|
-
/** Pagination options. */
|
|
328
|
-
paging?: BlogPaging;
|
|
329
|
-
/**
|
|
330
|
-
* __Deprecated.__ Use `fieldsets` instead.
|
|
331
|
-
*
|
|
332
|
-
* This parameter will be removed on June 30, 2023.
|
|
333
|
-
*
|
|
334
|
-
* List of category fields to be included in the response.
|
|
335
|
-
*/
|
|
336
|
-
fieldsToInclude?: Field[];
|
|
337
|
-
/**
|
|
338
|
-
* List of additional category fields to include in the response. For example, use the `URL` fieldset to retrieve the url field in
|
|
339
|
-
* the response in addition to the category’s base fields. Base fields don’t include any of the supported fieldset values. By default
|
|
340
|
-
* only the category’s base fields are returned.
|
|
341
|
-
*/
|
|
342
|
-
fieldsets?: Field[];
|
|
343
|
-
/**
|
|
344
|
-
* Language filter.
|
|
345
|
-
*
|
|
346
|
-
* 2-letter language code in [ISO 639-1 alpha-2](https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes) format.
|
|
347
|
-
* Pass a language to only receive categories that are in that language.
|
|
348
|
-
* If omitted, categories in all languages are returned.
|
|
349
|
-
*/
|
|
350
|
-
language?: string | null;
|
|
351
|
-
}
|
|
352
|
-
export interface BlogPaging {
|
|
353
|
-
/** Number of categories to skip in the list. */
|
|
354
|
-
offset?: number;
|
|
355
|
-
/**
|
|
356
|
-
* Number of items to return.
|
|
357
|
-
*
|
|
358
|
-
* Default: `50`
|
|
359
|
-
*
|
|
360
|
-
* Max: `100`
|
|
361
|
-
*/
|
|
362
|
-
limit?: number;
|
|
363
|
-
/** Pointer to the next or previous page in the list of results. */
|
|
364
|
-
cursor?: string | null;
|
|
365
|
-
}
|
|
366
|
-
export interface ListCategoriesResponse {
|
|
367
|
-
/** List of categories. */
|
|
368
|
-
categories?: Category[];
|
|
369
|
-
/** Details on the paged set of results returned. */
|
|
370
|
-
metaData?: MetaData;
|
|
371
|
-
}
|
|
372
|
-
export interface MetaData {
|
|
373
|
-
/** Number of items returned in this response. */
|
|
374
|
-
count?: number;
|
|
375
|
-
/** Number of items skipped. */
|
|
376
|
-
offset?: number;
|
|
377
|
-
/** Total number of items that match the query. */
|
|
378
|
-
total?: number;
|
|
379
|
-
/** Pointer to the next or previous page in the list of results. */
|
|
380
|
-
cursor?: string | null;
|
|
381
|
-
}
|
|
382
|
-
export interface QueryCategoriesRequest {
|
|
383
|
-
/**
|
|
384
|
-
* __Deprecated.__ Use `query` instead.
|
|
385
|
-
* This parameter will be removed on June 30, 2023.
|
|
386
|
-
*
|
|
387
|
-
* Pagination options.
|
|
388
|
-
*/
|
|
389
|
-
paging?: BlogPaging;
|
|
390
|
-
/**
|
|
391
|
-
* __Deprecated.__ Use `query` instead.
|
|
392
|
-
* This parameter will be removed on June 30, 2023.
|
|
393
|
-
*
|
|
394
|
-
* Filter object.
|
|
395
|
-
*/
|
|
396
|
-
filter?: Record<string, any> | null;
|
|
397
|
-
/**
|
|
398
|
-
* __Deprecated.__ Use `query` instead.
|
|
399
|
-
* This parameter will be removed on June 3, 2023.
|
|
400
|
-
*
|
|
401
|
-
* Sorting options.
|
|
402
|
-
*/
|
|
403
|
-
sort?: Sorting[];
|
|
404
|
-
/**
|
|
405
|
-
* __Deprecated.__ Use `fieldsets` instead.
|
|
406
|
-
* This parameter will be removed on June 30, 2023.
|
|
407
|
-
*
|
|
408
|
-
* List of category fields to be included in the response.
|
|
409
|
-
*/
|
|
410
|
-
fieldsToInclude?: Field[];
|
|
411
|
-
/** Query options. */
|
|
412
|
-
query?: PlatformQuery;
|
|
413
|
-
/**
|
|
414
|
-
* List of additional category fields to include in the response. For example, use the `URL` fieldset to retrieve the url field in
|
|
415
|
-
* the response in addition to the category’s base fields. Base fields don’t include any of the supported fieldset values. By default
|
|
416
|
-
* only the category’s base fields are returned.
|
|
417
|
-
*/
|
|
418
|
-
fieldsets?: Field[];
|
|
419
|
-
}
|
|
420
|
-
export interface Sorting {
|
|
421
|
-
/** Name of the field to sort by. */
|
|
422
|
-
fieldName?: string;
|
|
423
|
-
/** Sort order. */
|
|
424
|
-
order?: SortOrder;
|
|
425
|
-
}
|
|
426
|
-
export declare enum SortOrder {
|
|
427
|
-
ASC = "ASC",
|
|
428
|
-
DESC = "DESC"
|
|
429
|
-
}
|
|
430
|
-
export interface PlatformQuery extends PlatformQueryPagingMethodOneOf {
|
|
431
|
-
/** Paging options to limit and skip the number of items. */
|
|
432
|
-
paging?: Paging;
|
|
433
|
-
/** 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`. */
|
|
434
|
-
cursorPaging?: CursorPaging;
|
|
435
|
-
/**
|
|
436
|
-
* Filter object in the following format:
|
|
437
|
-
* `"filter" : {
|
|
438
|
-
* "fieldName1": "value1",
|
|
439
|
-
* "fieldName2":{"$operator":"value2"}
|
|
440
|
-
* }`
|
|
441
|
-
* Example of operators: `$eq`, `$ne`, `$lt`, `$lte`, `$gt`, `$gte`, `$in`, `$hasSome`, `$hasAll`, `$startsWith`, `$contains`
|
|
442
|
-
*/
|
|
443
|
-
filter?: Record<string, any> | null;
|
|
444
|
-
/**
|
|
445
|
-
* Sort object in the following format:
|
|
446
|
-
* `[{"fieldName":"sortField1","order":"ASC"},{"fieldName":"sortField2","order":"DESC"}]`
|
|
447
|
-
*/
|
|
448
|
-
sort?: Sorting[];
|
|
449
|
-
}
|
|
450
|
-
/** @oneof */
|
|
451
|
-
export interface PlatformQueryPagingMethodOneOf {
|
|
452
|
-
/** Paging options to limit and skip the number of items. */
|
|
453
|
-
paging?: Paging;
|
|
454
|
-
/** 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`. */
|
|
455
|
-
cursorPaging?: CursorPaging;
|
|
456
|
-
}
|
|
457
|
-
export interface Paging {
|
|
458
|
-
/** Number of items to load. */
|
|
459
|
-
limit?: number | null;
|
|
460
|
-
/** Number of items to skip in the current sort order. */
|
|
461
|
-
offset?: number | null;
|
|
462
|
-
}
|
|
463
|
-
export interface CursorPaging {
|
|
464
|
-
/** Number of items to load. */
|
|
465
|
-
limit?: number | null;
|
|
466
|
-
/**
|
|
467
|
-
* Pointer to the next or previous page in the list of results.
|
|
468
|
-
*
|
|
469
|
-
* You can get the relevant cursor token
|
|
470
|
-
* from the `pagingMetadata` object in the previous call's response.
|
|
471
|
-
* Not relevant for the first request.
|
|
472
|
-
*/
|
|
473
|
-
cursor?: string | null;
|
|
474
|
-
}
|
|
475
|
-
export interface QueryCategoriesResponse {
|
|
476
|
-
/** List of categories. */
|
|
477
|
-
categories?: Category[];
|
|
478
|
-
/**
|
|
479
|
-
* __Deprecated.__ Use `pagingMetadata` instead.
|
|
480
|
-
* This property will be removed on June 30, 2023.
|
|
481
|
-
*
|
|
482
|
-
* Details on the paged set of results returned.
|
|
483
|
-
*/
|
|
484
|
-
metaData?: MetaData;
|
|
485
|
-
/** Details on the paged set of results returned. */
|
|
486
|
-
pagingMetadata?: PagingMetadataV2;
|
|
487
|
-
}
|
|
488
|
-
export interface PagingMetadataV2 {
|
|
489
|
-
/** Number of items returned in the response. */
|
|
490
|
-
count?: number | null;
|
|
491
|
-
/** Offset that was requested. */
|
|
492
|
-
offset?: number | null;
|
|
493
|
-
/** Total number of items that match the query. Returned if offset paging is used and the `tooManyToCount` flag is not set. */
|
|
494
|
-
total?: number | null;
|
|
495
|
-
/** Flag that indicates the server failed to calculate the `total` field. */
|
|
496
|
-
tooManyToCount?: boolean | null;
|
|
497
|
-
/** Cursors to navigate through the result pages using `next` and `prev`. Returned if cursor paging is used. */
|
|
498
|
-
cursors?: Cursors;
|
|
499
|
-
}
|
|
500
|
-
export interface Cursors {
|
|
501
|
-
/** Cursor pointing to next page in the list of results. */
|
|
502
|
-
next?: string | null;
|
|
503
|
-
/** Cursor pointing to previous page in the list of results. */
|
|
504
|
-
prev?: string | null;
|
|
505
|
-
}
|
|
506
|
-
export interface BulkDeleteCategoryRequest {
|
|
507
|
-
/** Category IDs. */
|
|
508
|
-
categoryIds?: string[];
|
|
509
|
-
}
|
|
510
|
-
export interface BulkDeleteCategoryResponse {
|
|
511
|
-
}
|
|
512
|
-
export interface DeleteCategoryRequest {
|
|
513
|
-
/** Category ID. */
|
|
514
|
-
categoryId?: string;
|
|
515
|
-
}
|
|
516
|
-
export interface DeleteCategoryResponse {
|
|
517
|
-
}
|
|
518
|
-
export interface DomainEvent<T = string> extends DomainEventBodyOneOf<T> {
|
|
519
|
-
createdEvent?: EntityCreatedEvent<T>;
|
|
520
|
-
updatedEvent?: EntityUpdatedEvent<T>;
|
|
521
|
-
deletedEvent?: EntityDeletedEvent<T>;
|
|
522
|
-
actionEvent?: ActionEvent<T>;
|
|
523
|
-
/**
|
|
524
|
-
* Unique event ID.
|
|
525
|
-
* Allows clients to ignore duplicate webhooks.
|
|
526
|
-
*/
|
|
527
|
-
_id?: string;
|
|
528
|
-
/**
|
|
529
|
-
* Assumes actions are also always typed to an entity_type
|
|
530
|
-
* Example: wix.stores.catalog.product, wix.bookings.session, wix.payments.transaction
|
|
531
|
-
*/
|
|
532
|
-
entityFqdn?: string;
|
|
533
|
-
/**
|
|
534
|
-
* This is top level to ease client code dispatching of messages (switch on entity_fqdn+slug)
|
|
535
|
-
* This is although the created/updated/deleted notion is duplication of the oneof types
|
|
536
|
-
* Example: created/updated/deleted/started/completed/email_opened
|
|
537
|
-
*/
|
|
538
|
-
slug?: string;
|
|
539
|
-
/** ID of the entity associated with the event. */
|
|
540
|
-
entityId?: string;
|
|
541
|
-
/** Event timestamp. */
|
|
542
|
-
eventTime?: Date;
|
|
543
|
-
/**
|
|
544
|
-
* Whether the event was triggered as a result of a privacy regulation application
|
|
545
|
-
* (for example, GDPR).
|
|
546
|
-
*/
|
|
547
|
-
triggeredByAnonymizeRequest?: boolean | null;
|
|
548
|
-
/** If present, indicates the action that triggered the event. */
|
|
549
|
-
originatedFrom?: string | null;
|
|
550
|
-
/**
|
|
551
|
-
* A sequence number defining the order of updates to the underlying entity.
|
|
552
|
-
* For example, given that some entity was updated at 16:00 and than again at 16:01,
|
|
553
|
-
* it is guaranteed that the sequence number of the second update is strictly higher than the first.
|
|
554
|
-
* As the consumer, you can use this value to ensure that you handle messages in the correct order.
|
|
555
|
-
* To do so, you will need to persist this number on your end, and compare the sequence number from the
|
|
556
|
-
* message against the one you have stored. Given that the stored number is higher, you should ignore the message.
|
|
557
|
-
*/
|
|
558
|
-
entityEventSequence?: string | null;
|
|
559
|
-
}
|
|
560
|
-
export interface DomainCreatedEvent<T> extends Omit<DomainEvent<T>, 'deletedEvent' | 'updatedEvent' | 'actionEvent'> {
|
|
561
|
-
}
|
|
562
|
-
export interface DomainDeletedEvent<T> extends Omit<DomainEvent<T>, 'createdEvent' | 'updatedEvent' | 'actionEvent'> {
|
|
563
|
-
}
|
|
564
|
-
export interface DomainUpdatedEvent<T> extends Omit<DomainEvent<T>, 'createdEvent' | 'deletedEvent' | 'actionEvent'> {
|
|
565
|
-
}
|
|
566
|
-
export interface DomainActionEvent<T> extends Omit<DomainEvent<T>, 'createdEvent' | 'deletedEvent' | 'updatedEvent'> {
|
|
567
|
-
}
|
|
568
|
-
/** @oneof */
|
|
569
|
-
export interface DomainEventBodyOneOf<T> {
|
|
570
|
-
createdEvent?: EntityCreatedEvent<T>;
|
|
571
|
-
updatedEvent?: EntityUpdatedEvent<T>;
|
|
572
|
-
deletedEvent?: EntityDeletedEvent<T>;
|
|
573
|
-
actionEvent?: ActionEvent<T>;
|
|
574
|
-
}
|
|
575
|
-
export interface EntityCreatedEvent<T> {
|
|
576
|
-
entity?: T;
|
|
577
|
-
}
|
|
578
|
-
export interface EntityUpdatedEvent<T> {
|
|
579
|
-
/**
|
|
580
|
-
* Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.
|
|
581
|
-
* This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.
|
|
582
|
-
* We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.
|
|
583
|
-
*/
|
|
584
|
-
currentEntity?: T;
|
|
585
|
-
}
|
|
586
|
-
export interface EntityDeletedEvent<T> {
|
|
587
|
-
/** Entity that was deleted */
|
|
588
|
-
deletedEntity?: T | null;
|
|
589
|
-
}
|
|
590
|
-
export interface ActionEvent<T> {
|
|
591
|
-
body?: T;
|
|
592
|
-
}
|
|
593
|
-
export interface GetCategoryResponseNonNullableFields {
|
|
594
|
-
category?: {
|
|
595
|
-
_id: string;
|
|
596
|
-
label: string;
|
|
597
|
-
postCount: number;
|
|
598
|
-
url: string;
|
|
599
|
-
title: string;
|
|
600
|
-
coverMedia?: {
|
|
601
|
-
image: string;
|
|
602
|
-
video: string;
|
|
603
|
-
enabled: boolean;
|
|
604
|
-
displayed: boolean;
|
|
605
|
-
custom: boolean;
|
|
606
|
-
};
|
|
607
|
-
oldRank: number;
|
|
608
|
-
slug: string;
|
|
609
|
-
seoData?: {
|
|
610
|
-
tags: {
|
|
611
|
-
type: string;
|
|
612
|
-
children: string;
|
|
613
|
-
custom: boolean;
|
|
614
|
-
disabled: boolean;
|
|
615
|
-
}[];
|
|
616
|
-
settings?: {
|
|
617
|
-
preventAutoRedirect: boolean;
|
|
618
|
-
keywords: {
|
|
619
|
-
term: string;
|
|
620
|
-
isMain: boolean;
|
|
621
|
-
}[];
|
|
622
|
-
};
|
|
623
|
-
};
|
|
624
|
-
coverImage: string;
|
|
625
|
-
};
|
|
626
|
-
}
|
|
627
|
-
export interface GetCategoryBySlugResponseNonNullableFields {
|
|
628
|
-
category?: {
|
|
629
|
-
_id: string;
|
|
630
|
-
label: string;
|
|
631
|
-
postCount: number;
|
|
632
|
-
url: string;
|
|
633
|
-
title: string;
|
|
634
|
-
coverMedia?: {
|
|
635
|
-
image: string;
|
|
636
|
-
video: string;
|
|
637
|
-
enabled: boolean;
|
|
638
|
-
displayed: boolean;
|
|
639
|
-
custom: boolean;
|
|
640
|
-
};
|
|
641
|
-
oldRank: number;
|
|
642
|
-
slug: string;
|
|
643
|
-
seoData?: {
|
|
644
|
-
tags: {
|
|
645
|
-
type: string;
|
|
646
|
-
children: string;
|
|
647
|
-
custom: boolean;
|
|
648
|
-
disabled: boolean;
|
|
649
|
-
}[];
|
|
650
|
-
settings?: {
|
|
651
|
-
preventAutoRedirect: boolean;
|
|
652
|
-
keywords: {
|
|
653
|
-
term: string;
|
|
654
|
-
isMain: boolean;
|
|
655
|
-
}[];
|
|
656
|
-
};
|
|
657
|
-
};
|
|
658
|
-
coverImage: string;
|
|
659
|
-
};
|
|
660
|
-
}
|
|
661
|
-
export interface ListCategoriesResponseNonNullableFields {
|
|
662
|
-
categories: {
|
|
663
|
-
_id: string;
|
|
664
|
-
label: string;
|
|
665
|
-
postCount: number;
|
|
666
|
-
url: string;
|
|
667
|
-
title: string;
|
|
668
|
-
coverMedia?: {
|
|
669
|
-
image: string;
|
|
670
|
-
video: string;
|
|
671
|
-
enabled: boolean;
|
|
672
|
-
displayed: boolean;
|
|
673
|
-
custom: boolean;
|
|
674
|
-
};
|
|
675
|
-
oldRank: number;
|
|
676
|
-
slug: string;
|
|
677
|
-
seoData?: {
|
|
678
|
-
tags: {
|
|
679
|
-
type: string;
|
|
680
|
-
children: string;
|
|
681
|
-
custom: boolean;
|
|
682
|
-
disabled: boolean;
|
|
683
|
-
}[];
|
|
684
|
-
settings?: {
|
|
685
|
-
preventAutoRedirect: boolean;
|
|
686
|
-
keywords: {
|
|
687
|
-
term: string;
|
|
688
|
-
isMain: boolean;
|
|
689
|
-
}[];
|
|
690
|
-
};
|
|
691
|
-
};
|
|
692
|
-
coverImage: string;
|
|
693
|
-
}[];
|
|
694
|
-
metaData?: {
|
|
695
|
-
count: number;
|
|
696
|
-
offset: number;
|
|
697
|
-
total: number;
|
|
698
|
-
};
|
|
699
|
-
}
|
|
700
|
-
export interface QueryCategoriesResponseNonNullableFields {
|
|
701
|
-
categories: {
|
|
702
|
-
_id: string;
|
|
703
|
-
label: string;
|
|
704
|
-
postCount: number;
|
|
705
|
-
url: string;
|
|
706
|
-
title: string;
|
|
707
|
-
coverMedia?: {
|
|
708
|
-
image: string;
|
|
709
|
-
video: string;
|
|
710
|
-
enabled: boolean;
|
|
711
|
-
displayed: boolean;
|
|
712
|
-
custom: boolean;
|
|
713
|
-
};
|
|
714
|
-
oldRank: number;
|
|
715
|
-
slug: string;
|
|
716
|
-
seoData?: {
|
|
717
|
-
tags: {
|
|
718
|
-
type: string;
|
|
719
|
-
children: string;
|
|
720
|
-
custom: boolean;
|
|
721
|
-
disabled: boolean;
|
|
722
|
-
}[];
|
|
723
|
-
settings?: {
|
|
724
|
-
preventAutoRedirect: boolean;
|
|
725
|
-
keywords: {
|
|
726
|
-
term: string;
|
|
727
|
-
isMain: boolean;
|
|
728
|
-
}[];
|
|
729
|
-
};
|
|
730
|
-
};
|
|
731
|
-
coverImage: string;
|
|
732
|
-
}[];
|
|
733
|
-
metaData?: {
|
|
734
|
-
count: number;
|
|
735
|
-
offset: number;
|
|
736
|
-
total: number;
|
|
737
|
-
};
|
|
738
|
-
}
|
|
739
|
-
export declare const onCategoryCreated: EventDefinition<DomainCreatedEvent<Category>, "wix.blog.category_created">;
|
|
740
|
-
export declare const onCategoryUpdated: EventDefinition<DomainUpdatedEvent<Category>, "wix.blog.category_updated">;
|
|
741
|
-
export declare const onCategoryDeleted: EventDefinition<DomainDeletedEvent<Category>, "wix.blog.category_deleted">;
|
|
742
|
-
/**
|
|
743
|
-
* Gets a category by the specified ID.
|
|
744
|
-
*
|
|
745
|
-
*
|
|
746
|
-
* The `getCategory()` function returns a Promise that resolves to a category whose ID matches the specified ID.
|
|
747
|
-
*
|
|
748
|
-
* @param categoryId - Category ID.
|
|
749
|
-
* @public
|
|
750
|
-
* @requiredField categoryId
|
|
751
|
-
* @param options - Options specifying which fields to return.
|
|
752
|
-
* @permissionScope Read Blog
|
|
753
|
-
* @permissionScopeId SCOPE.DC-BLOG.READ-BLOGS
|
|
754
|
-
* @permissionScope Manage Blog
|
|
755
|
-
* @permissionScopeId SCOPE.DC-BLOG.MANAGE-BLOG
|
|
756
|
-
* @permissionScope Read Draft Blog Posts
|
|
757
|
-
* @permissionScopeId SCOPE.DC-BLOG.READ-DRAFT-POSTS
|
|
758
|
-
* @applicableIdentity APP
|
|
759
|
-
* @applicableIdentity VISITOR
|
|
760
|
-
* @returns Category info.
|
|
761
|
-
*/
|
|
762
|
-
export declare function getCategory(categoryId: string, options?: GetCategoryOptions): Promise<Category & NonNullable<GetCategoryResponseNonNullableFields>['category']>;
|
|
763
|
-
export interface GetCategoryOptions {
|
|
764
|
-
/** @internal */
|
|
765
|
-
fieldsToInclude?: Field[];
|
|
766
|
-
/**
|
|
767
|
-
* List of category fields to be included in the response. By default, any fields not passed are not returned.
|
|
768
|
-
*
|
|
769
|
-
* Supported Values:
|
|
770
|
-
* `"SEO"` and `"URL"`.
|
|
771
|
-
*/
|
|
772
|
-
fieldsets?: Field[];
|
|
773
|
-
}
|
|
774
|
-
/**
|
|
775
|
-
* Gets a category by the specified slug.
|
|
776
|
-
*
|
|
777
|
-
*
|
|
778
|
-
* The `getCategoryBySlug()` function returns a Promise that resolves to a category whose slug matches the specified slug.
|
|
779
|
-
*
|
|
780
|
-
* The `slug` is the end of a category's URL that refers to a specific category. For example, if a category's URL is `https://example.com/blog/category/{my-category-slug}`, the slug is `my-post-slug`. The slug is case-sensitive string that is generally derived from the category's `label`, unless specified otherwise.
|
|
781
|
-
*
|
|
782
|
-
* @public
|
|
783
|
-
* @requiredField slug
|
|
784
|
-
* @param slug - Slug of the category to retrieve.
|
|
785
|
-
*
|
|
786
|
-
* The end of a category's URL. For example, `'https:/example.com/blog/category/{my-category-slug}'`. Case sensitive and generally based on the category `label` if not specified.
|
|
787
|
-
* @param options - Options specifying which fields to return.
|
|
788
|
-
* @permissionScope Read Blog
|
|
789
|
-
* @permissionScopeId SCOPE.DC-BLOG.READ-BLOGS
|
|
790
|
-
* @permissionScope Manage Blog
|
|
791
|
-
* @permissionScopeId SCOPE.DC-BLOG.MANAGE-BLOG
|
|
792
|
-
* @permissionScope Read Draft Blog Posts
|
|
793
|
-
* @permissionScopeId SCOPE.DC-BLOG.READ-DRAFT-POSTS
|
|
794
|
-
* @applicableIdentity APP
|
|
795
|
-
* @applicableIdentity VISITOR
|
|
796
|
-
*/
|
|
797
|
-
export declare function getCategoryBySlug(slug: string, options?: GetCategoryBySlugOptions): Promise<GetCategoryBySlugResponse & GetCategoryBySlugResponseNonNullableFields>;
|
|
798
|
-
export interface GetCategoryBySlugOptions {
|
|
799
|
-
/** @internal */
|
|
800
|
-
fieldsToInclude?: Field[];
|
|
801
|
-
/**
|
|
802
|
-
* List of category fields to be included in the response. By default, any fields not passed are not returned.
|
|
803
|
-
*
|
|
804
|
-
* Supported Values:
|
|
805
|
-
* `"SEO"` and `"URL"`.
|
|
806
|
-
*/
|
|
807
|
-
fieldsets?: Field[];
|
|
808
|
-
/**
|
|
809
|
-
* 2-letter language code in [ISO 639-1 alpha-2](https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes) format.
|
|
810
|
-
* Language of the category to retrieve.
|
|
811
|
-
*/
|
|
812
|
-
language?: string | null;
|
|
813
|
-
}
|
|
814
|
-
/**
|
|
815
|
-
* Retrieves a list of categories.
|
|
816
|
-
*
|
|
817
|
-
*
|
|
818
|
-
* The `listCategories()` function returns a Promise that resolves to a list of up to 100 categories per language in order of their `displayPosition` starting with `0`. The `displayPosition` is the position in which the categories are displayed in the Category Menu page. By default, categories get added to the bottom of the Category Menu with a `displayPosition` of `-1`.
|
|
819
|
-
* @public
|
|
820
|
-
* @param options - Filter and paging options.
|
|
821
|
-
* @permissionScope Read Blog
|
|
822
|
-
* @permissionScopeId SCOPE.DC-BLOG.READ-BLOGS
|
|
823
|
-
* @permissionScope Manage Blog
|
|
824
|
-
* @permissionScopeId SCOPE.DC-BLOG.MANAGE-BLOG
|
|
825
|
-
* @permissionScope Read Draft Blog Posts
|
|
826
|
-
* @permissionScopeId SCOPE.DC-BLOG.READ-DRAFT-POSTS
|
|
827
|
-
* @applicableIdentity APP
|
|
828
|
-
* @applicableIdentity VISITOR
|
|
829
|
-
*/
|
|
830
|
-
export declare function listCategories(options?: ListCategoriesOptions): Promise<ListCategoriesResponse & ListCategoriesResponseNonNullableFields>;
|
|
831
|
-
export interface ListCategoriesOptions {
|
|
832
|
-
/** Pagination options. */
|
|
833
|
-
paging?: BlogPaging;
|
|
834
|
-
/** @internal */
|
|
835
|
-
fieldsToInclude?: Field[];
|
|
836
|
-
/**
|
|
837
|
-
* List of category fields to be included in the response. By default, any fields not passed are not returned.
|
|
838
|
-
*
|
|
839
|
-
* Supported Values:
|
|
840
|
-
* `"SEO"` and `"URL"`.
|
|
841
|
-
*/
|
|
842
|
-
fieldsets?: Field[];
|
|
843
|
-
/**
|
|
844
|
-
* Language filter.
|
|
845
|
-
*
|
|
846
|
-
* 2-letter language code in [ISO 639-1 alpha-2](https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes) format.
|
|
847
|
-
* Pass a language to only receive categories that are in that language.
|
|
848
|
-
* If omitted, categories in all languages are returned.
|
|
849
|
-
*/
|
|
850
|
-
language?: string | null;
|
|
851
|
-
}
|
|
852
|
-
/**
|
|
853
|
-
* Creates a query to retrieve a list of categories.
|
|
854
|
-
*
|
|
855
|
-
*
|
|
856
|
-
* The `queryCategories()` function builds a query to retrieve a list of up to 100 categories per language, and returns a [`CategoriesQueryBuilder`](https://www.wix.com/velo/reference/wix-blog-backend/categories/categoriesquerybuilder) object.
|
|
857
|
-
*
|
|
858
|
-
* The returned object contains the query definition, which is typically used to run the query using the [`find()`](https://www.wix.com/velo/reference/wix-blog-backend/categories/categoriesquerybuilder/find) function.
|
|
859
|
-
*
|
|
860
|
-
* You can refine the query by chaining `CategoriesQueryBuilder` functions to the query. `CategoriesQueryBuilder` functions enable you to sort, filter, and control the results that `queryCategories` returns. Any functions chained to the `queryCategories()` function are applied in the order that they are called.
|
|
861
|
-
*
|
|
862
|
-
* `queryCategories()` runs with these `CategoriesQueryBuilder` defaults, which you can override.
|
|
863
|
-
* - [`limit(100)`](https://www.wix.com/velo/reference/wix-blog-backend/categories/categoriesquerybuilder/limit)
|
|
864
|
-
* - [`ascending(displayPosition)`](https://www.wix.com/velo/reference/wix-blog-backend/categories/categoriesquerybuilder/ascending)
|
|
865
|
-
*
|
|
866
|
-
* The following `CategoriesQueryBuilder` functions are supported for `queryCategories()`. For a full description of the `Categories` object, see the object returned for the [`items`](https://www.wix.com/velo/reference/wix-blog-backend/categories/categoriesqueryresult/items) property in [`CategoriesQueryResult`](https://www.wix.com/velo/reference/wix-blog-backend/categories/categoriesqueryresult).
|
|
867
|
-
* @public
|
|
868
|
-
* @param options - Options specifying which fields to return.
|
|
869
|
-
* @permissionScope Read Blog
|
|
870
|
-
* @permissionScopeId SCOPE.DC-BLOG.READ-BLOGS
|
|
871
|
-
* @permissionScope Manage Blog
|
|
872
|
-
* @permissionScopeId SCOPE.DC-BLOG.MANAGE-BLOG
|
|
873
|
-
* @permissionScope Read Draft Blog Posts
|
|
874
|
-
* @permissionScopeId SCOPE.DC-BLOG.READ-DRAFT-POSTS
|
|
875
|
-
* @applicableIdentity APP
|
|
876
|
-
* @applicableIdentity VISITOR
|
|
877
|
-
*/
|
|
878
|
-
export declare function queryCategories(options?: QueryCategoriesOptions): CategoriesQueryBuilder;
|
|
879
|
-
export interface QueryCategoriesOptions {
|
|
880
|
-
/** @internal */
|
|
881
|
-
paging?: BlogPaging | undefined;
|
|
882
|
-
/** @internal */
|
|
883
|
-
filter?: Record<string, any> | null | undefined;
|
|
884
|
-
/** @internal */
|
|
885
|
-
sort?: Sorting[] | undefined;
|
|
886
|
-
/** @internal */
|
|
887
|
-
fieldsToInclude?: Field[] | undefined;
|
|
888
|
-
/**
|
|
889
|
-
* List of category fields to be included in the response. By default, any fields not passed are not returned.
|
|
890
|
-
*
|
|
891
|
-
* Supported Values:
|
|
892
|
-
* `"SEO"` and `"URL"`.
|
|
893
|
-
*/
|
|
894
|
-
fieldsets?: Field[] | undefined;
|
|
895
|
-
}
|
|
896
|
-
interface QueryOffsetResult {
|
|
897
|
-
currentPage: number | undefined;
|
|
898
|
-
totalPages: number | undefined;
|
|
899
|
-
totalCount: number | undefined;
|
|
900
|
-
hasNext: () => boolean;
|
|
901
|
-
hasPrev: () => boolean;
|
|
902
|
-
length: number;
|
|
903
|
-
pageSize: number;
|
|
904
|
-
}
|
|
905
|
-
export interface CategoriesQueryResult extends QueryOffsetResult {
|
|
906
|
-
items: Category[];
|
|
907
|
-
query: CategoriesQueryBuilder;
|
|
908
|
-
next: () => Promise<CategoriesQueryResult>;
|
|
909
|
-
prev: () => Promise<CategoriesQueryResult>;
|
|
910
|
-
}
|
|
911
|
-
export interface CategoriesQueryBuilder {
|
|
912
|
-
/** @param propertyName - Property whose value is compared with `value`.
|
|
913
|
-
* @param value - Value to compare against.
|
|
914
|
-
*/
|
|
915
|
-
eq: (propertyName: '_id' | 'label' | 'postCount' | 'title' | 'rank' | 'displayPosition' | 'translationId' | 'language', value: any) => CategoriesQueryBuilder;
|
|
916
|
-
/** @param propertyName - Property whose value is compared with `value`.
|
|
917
|
-
* @param value - Value to compare against.
|
|
918
|
-
*/
|
|
919
|
-
ne: (propertyName: '_id' | 'label' | 'postCount' | 'title' | 'rank' | 'displayPosition' | 'translationId' | 'language', value: any) => CategoriesQueryBuilder;
|
|
920
|
-
/** @param propertyName - Property whose value is compared with `value`.
|
|
921
|
-
* @param value - Value to compare against.
|
|
922
|
-
*/
|
|
923
|
-
ge: (propertyName: 'postCount' | 'rank' | 'displayPosition', value: any) => CategoriesQueryBuilder;
|
|
924
|
-
/** @param propertyName - Property whose value is compared with `value`.
|
|
925
|
-
* @param value - Value to compare against.
|
|
926
|
-
*/
|
|
927
|
-
gt: (propertyName: 'postCount' | 'rank' | 'displayPosition', value: any) => CategoriesQueryBuilder;
|
|
928
|
-
/** @param propertyName - Property whose value is compared with `value`.
|
|
929
|
-
* @param value - Value to compare against.
|
|
930
|
-
*/
|
|
931
|
-
le: (propertyName: 'postCount' | 'rank' | 'displayPosition', value: any) => CategoriesQueryBuilder;
|
|
932
|
-
/** @param propertyName - Property whose value is compared with `value`.
|
|
933
|
-
* @param value - Value to compare against.
|
|
934
|
-
*/
|
|
935
|
-
lt: (propertyName: 'postCount' | 'rank' | 'displayPosition', value: any) => CategoriesQueryBuilder;
|
|
936
|
-
/** @param propertyName - Property whose value is compared with `string`.
|
|
937
|
-
* @param string - String to compare against. Case-insensitive.
|
|
938
|
-
*/
|
|
939
|
-
startsWith: (propertyName: 'label' | 'title', value: string) => CategoriesQueryBuilder;
|
|
940
|
-
/** @param propertyName - Property whose value is compared with `values`.
|
|
941
|
-
* @param values - List of values to compare against.
|
|
942
|
-
*/
|
|
943
|
-
hasSome: (propertyName: '_id' | 'label' | 'title' | 'slug', value: any[]) => CategoriesQueryBuilder;
|
|
944
|
-
in: (propertyName: 'label' | 'postCount' | 'title' | 'rank' | 'displayPosition' | 'translationId' | 'language', value: any) => CategoriesQueryBuilder;
|
|
945
|
-
exists: (propertyName: 'label' | 'title' | 'translationId' | 'language', value: boolean) => CategoriesQueryBuilder;
|
|
946
|
-
/** @param propertyNames - Properties used in the sort. To sort by multiple properties, pass properties as additional arguments. */
|
|
947
|
-
ascending: (...propertyNames: Array<'label' | 'postCount' | 'title' | 'rank' | 'displayPosition' | 'language' | 'slug'>) => CategoriesQueryBuilder;
|
|
948
|
-
/** @param propertyNames - Properties used in the sort. To sort by multiple properties, pass properties as additional arguments. */
|
|
949
|
-
descending: (...propertyNames: Array<'label' | 'postCount' | 'title' | 'rank' | 'displayPosition' | 'language' | 'slug'>) => CategoriesQueryBuilder;
|
|
950
|
-
/** @param limit - Number of items to return, which is also the `pageSize` of the results object. */
|
|
951
|
-
limit: (limit: number) => CategoriesQueryBuilder;
|
|
952
|
-
/** @param skip - Number of items to skip in the query results before returning the results. */
|
|
953
|
-
skip: (skip: number) => CategoriesQueryBuilder;
|
|
954
|
-
find: () => Promise<CategoriesQueryResult>;
|
|
955
|
-
}
|
|
956
|
-
export {};
|