@wix/auto_sdk_restaurants_menus 1.0.93 → 1.0.94

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.
@@ -1,4 +1,4 @@
1
- import { CreateMenuRequest as CreateMenuRequest$1, CreateMenuResponse as CreateMenuResponse$1, BulkCreateMenusRequest as BulkCreateMenusRequest$1, BulkCreateMenusResponse as BulkCreateMenusResponse$1, GetMenuRequest as GetMenuRequest$1, GetMenuResponse as GetMenuResponse$1, ListMenusRequest as ListMenusRequest$1, ListMenusResponse as ListMenusResponse$1, QueryMenusRequest as QueryMenusRequest$1, QueryMenusResponse as QueryMenusResponse$1, UpdateMenuRequest as UpdateMenuRequest$1, UpdateMenuResponse as UpdateMenuResponse$1, BulkUpdateMenuRequest as BulkUpdateMenuRequest$1, BulkUpdateMenuResponse as BulkUpdateMenuResponse$1, UpdateExtendedFieldsRequest as UpdateExtendedFieldsRequest$1, UpdateExtendedFieldsResponse as UpdateExtendedFieldsResponse$1, DeleteMenuRequest as DeleteMenuRequest$1, DeleteMenuResponse as DeleteMenuResponse$1, DuplicateMenuRequest as DuplicateMenuRequest$1, DuplicateMenuResponse as DuplicateMenuResponse$1, GetMenuSiteUrlRequest as GetMenuSiteUrlRequest$1, GetMenuSiteUrlResponse as GetMenuSiteUrlResponse$1, QueryMenusSiteUrlRequest as QueryMenusSiteUrlRequest$1, QueryMenusSiteUrlResponse as QueryMenusSiteUrlResponse$1 } from './index.typings.mjs';
1
+ import { DuplicateMenuRequest as DuplicateMenuRequest$1, DuplicateMenuResponse as DuplicateMenuResponse$1, GetMenuSiteUrlRequest as GetMenuSiteUrlRequest$1, GetMenuSiteUrlResponse as GetMenuSiteUrlResponse$1, QueryMenusSiteUrlRequest as QueryMenusSiteUrlRequest$1, QueryMenusSiteUrlResponse as QueryMenusSiteUrlResponse$1, CreateMenuRequest as CreateMenuRequest$1, CreateMenuResponse as CreateMenuResponse$1, BulkCreateMenusRequest as BulkCreateMenusRequest$1, BulkCreateMenusResponse as BulkCreateMenusResponse$1, GetMenuRequest as GetMenuRequest$1, GetMenuResponse as GetMenuResponse$1, ListMenusRequest as ListMenusRequest$1, ListMenusResponse as ListMenusResponse$1, QueryMenusRequest as QueryMenusRequest$1, QueryMenusResponse as QueryMenusResponse$1, UpdateMenuRequest as UpdateMenuRequest$1, UpdateMenuResponse as UpdateMenuResponse$1, BulkUpdateMenuRequest as BulkUpdateMenuRequest$1, BulkUpdateMenuResponse as BulkUpdateMenuResponse$1, UpdateExtendedFieldsRequest as UpdateExtendedFieldsRequest$1, UpdateExtendedFieldsResponse as UpdateExtendedFieldsResponse$1, DeleteMenuRequest as DeleteMenuRequest$1, DeleteMenuResponse as DeleteMenuResponse$1 } from './index.typings.mjs';
2
2
  import '@wix/sdk-types';
3
3
 
4
4
  interface Menu {
@@ -88,73 +88,117 @@ interface ExtendedFields {
88
88
  namespaces?: Record<string, Record<string, any>>;
89
89
  }
90
90
  /**
91
- * 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.
92
- * The search engines use this information for ranking purposes, or to display snippets in the search results.
93
- * 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.
91
+ * The SEO data for a single page or dynamic item, in the shape stored today.
92
+ *
93
+ * FROZEN. Existing server code maps onto this message field by field, so its
94
+ * field set must never change (see the file header). New writers use
95
+ * `SeoSchemaV2`.
96
+ *
97
+ * These tags are rendered into the <head> of the HTML document and are not
98
+ * visible on the page itself. They override every other source of tags
99
+ * (site defaults, vertical presets, patterns) for this page.
94
100
  */
95
101
  interface SeoSchema {
96
- /** SEO tag information. */
102
+ /**
103
+ * The tags rendered into <head>, in no particular order. Render order is
104
+ * decided by the renderer, not by position in this list.
105
+ *
106
+ * No maxSize: this list is already populated by data written years ago, and
107
+ * a bound added now could reject a page that is already stored.
108
+ */
97
109
  tags?: Tag[];
98
- /** SEO general settings. */
110
+ /** Page-level SEO settings that are not themselves tags. */
99
111
  settings?: Settings;
100
112
  }
113
+ /** A keyword term the user is targeting. */
101
114
  interface Keyword {
102
- /** Keyword value. */
115
+ /**
116
+ * The term itself, e.g. "trail running shoes".
117
+ *
118
+ * No maxLength, for the same reason as the legacy tag fields: keywords are
119
+ * already stored, and a bound added now could reject a record written
120
+ * before the bound existed. The flynt `missing-string-validations` warning
121
+ * on this field is accepted deliberately.
122
+ */
103
123
  term?: string;
104
- /** Whether the keyword is the main focus keyword. */
124
+ /** Whether this is the page's primary focus keyword. At most one per page. */
105
125
  isMain?: boolean;
106
126
  /**
107
- * The source that added the keyword terms to the SEO settings.
127
+ * Which surface added the term, e.g. a panel or a suggestion flow. Used for
128
+ * attribution in BI. Opaque to the renderer.
108
129
  * @maxLength 1000
109
130
  */
110
131
  origin?: string | null;
111
132
  }
133
+ /**
134
+ * One tag in the page's <head>.
135
+ *
136
+ * Not deprecated, and with no removal date, deliberately: stored data is
137
+ * never migrated, so this shape stays valid input forever. `seo-renderer`
138
+ * normalizes both shapes on READ.
139
+ */
112
140
  interface Tag {
113
141
  /**
114
- * SEO tag type.
142
+ * Legacy. Was a free-form string: "title" | "meta" | "script" | "link".
143
+ * The typed replacement is the `kind` oneof on `SeoSchemaV2.Tag`, which makes
144
+ * the invalid combinations unrepresentable rather than merely discouraged.
115
145
  *
116
- *
117
- * Supported values: `title`, `meta`, `script`, `link`.
118
- *
119
- * Which of these an API actually accepts depends on where the tag is being set: this
120
- * list is not a blanket guarantee across every API that reuses this message. Site SEO
121
- * Tags in particular accepts only `meta` (see `SiteSeoTags.tags`) and rejects
122
- * `title`/`script`/`link` with a validation error even though they appear here —
123
- * check the field description of the specific `tags`-typed field you're writing to
124
- * for the types it actually supports and the error it returns.
146
+ * Which of these an API actually accepts depends on where the tag is being
147
+ * set: this list is not a blanket guarantee across every API that reuses
148
+ * this message. Site SEO Tags in particular accepts only `meta` (see
149
+ * `SiteSeoTags.tags`) and rejects `title`/`script`/`link` with a validation
150
+ * error even though they appear here — check the field description of the
151
+ * specific `tags`-typed field you are writing to.
125
152
  *
126
153
  * Limitation: `title` and `script` (e.g. a `script` tag with `props.type`
127
- * `"application/ld+json"` carrying structured data) are supported only when
128
- * `custom` is unset or `false`. Setting `custom: true` on a `title` or `script`
129
- * tag is rejected with `TAG_TYPE_NOT_ALLOWED`, because `custom: true` routes the
130
- * write through the site's Advanced/Custom Tags list. To write structured data,
131
- * omit `custom` (or set it to `false`).
154
+ * "application/ld+json" carrying structured data) are supported only when
155
+ * `custom` is unset or `false`. Setting `custom: true` on a `title` or
156
+ * `script` tag is rejected with `TAG_TYPE_NOT_ALLOWED`, because
157
+ * `custom: true` routes the write through the site's Advanced/Custom Tags
158
+ * list. To write structured data, omit `custom` (or set it to `false`).
159
+ *
160
+ * No length limit: this field holds data written years ago by writers we
161
+ * are not migrating. A constraint here could reject a record that is
162
+ * already stored, which is exactly the promise this design makes.
132
163
  */
133
164
  type?: string;
134
165
  /**
135
- * A `{"key": "value"}` pair object where each SEO tag property (`"name"`, `"content"`, `"rel"`, `"href"`) contains a value.
136
- * For example: `{"name": "description", "content": "the description itself"}`.
166
+ * Legacy. Was an untyped bag of HTML attributes.
167
+ * Typed replacement: `SeoSchemaV2.TitleTag` / `MetaTag` / `LinkTag`.
137
168
  */
138
169
  props?: Record<string, any> | null;
139
- /** SEO tag metadata. For example, `{"height": 300, "width": 240}`. */
170
+ /**
171
+ * Legacy. Was an untyped bag of 16 mixed-purpose keys. In `SeoSchemaV2`
172
+ * its contents are split by purpose: per-page structured-data state moves to
173
+ * StructuredDataTag, authorship to `written_by`, and render-time preset
174
+ * logic (variants, enabledByExperiment, removeSchemaIf*) moved out of the
175
+ * stored document entirely — it belongs to the preset definition, not to the
176
+ * page. See the design log for the full key-by-key mapping.
177
+ */
140
178
  meta?: Record<string, any> | null;
141
- /** SEO tag inner content. For example, `<title> inner content </title>`. */
179
+ /**
180
+ * Legacy. Was the tag's inner content, doubling as the JSON-LD payload
181
+ * for script tags. Typed replacement: `SeoSchemaV2.TitleTag.text` and
182
+ * `StructuredDataTag.json_ld`.
183
+ * No length limit, for the same reason as `type` above.
184
+ */
142
185
  children?: string;
143
186
  /**
144
187
  * Whether the tag is a [custom tag](https://support.wix.com/en/article/adding-additional-meta-tags-to-your-sites-pages) —
145
188
  * i.e. an entry from the site's Advanced/Custom Tags list.
146
189
  *
147
- * Setting this to `true` on a write restricts which `type` values are accepted
148
- * — the same restriction the Advanced/Custom Tags UI enforces. `title` and
149
- * `script` tags (including JSON-LD structured data) must be sent with `custom`
150
- * omitted or `false`; sending them with `custom: true` is rejected with
151
- * `TAG_TYPE_NOT_ALLOWED`.
190
+ * Setting this to `true` on a write restricts which `type` values are
191
+ * accepted — the same restriction the Advanced/Custom Tags UI enforces.
192
+ * `title` and `script` tags (including JSON-LD structured data) must be sent
193
+ * with `custom` omitted or `false`; sending them with `custom: true` is
194
+ * rejected with `TAG_TYPE_NOT_ALLOWED`.
152
195
  *
153
- * Note this is a separate restriction from Site SEO Tags' own type restriction on
154
- * `SiteSeoTags.tags`: even with `custom` unset, Site SEO Tags rejects `script` (e.g.
155
- * for site-wide structured data) unconditionally. There is currently no way to set
156
- * site-wide, every-page structured data through any of these APIs — write a per-page
157
- * `script` tag through the Item SEO Tags API instead.
196
+ * Note this is a separate restriction from Site SEO Tags' own type
197
+ * restriction on `SiteSeoTags.tags`: even with `custom` unset, Site SEO Tags
198
+ * rejects `script` (e.g. for site-wide structured data) unconditionally.
199
+ * There is currently no way to set site-wide, every-page structured data
200
+ * through any of these APIs — write a per-page `script` tag through the Item
201
+ * SEO Tags API instead.
158
202
  *
159
203
  * This flag is scoped to that feature only. It is NOT an indicator of whether a standard tag
160
204
  * (`title`, `description`, Open Graph, etc.) reflects a manually configured value versus a computed
@@ -167,22 +211,39 @@ interface Tag {
167
211
  * or Wix Studio pages, so even genuine Advanced/Custom Tags saved on those pages are missing from the
168
212
  * response entirely — there, `false` means this API could not tell, not that no custom tag exists.
169
213
  * Pass `seoData` explicitly to resolve against a known set of tags.
214
+ *
215
+ * `SeoSchemaV2.Tag` expresses this as `written_by = USER_CUSTOM`.
170
216
  */
171
217
  custom?: boolean;
172
- /** Whether the tag is disabled. If the tag is disabled, people can't find your page when searching for this phrase in search engines. */
218
+ /**
219
+ * Whether the tag is excluded from the rendered <head>.
220
+ *
221
+ * A disabled tag is still stored, so the user can re-enable it and so a
222
+ * pattern-provided tag stays suppressed on this page. Default false.
223
+ */
173
224
  disabled?: boolean;
174
225
  }
226
+ /** Page-level SEO settings that are not tags. */
175
227
  interface Settings {
176
228
  /**
177
- * Whether the [automatical redirect visits](https://support.wix.com/en/article/customizing-your-pages-seo-settings-in-the-seo-panel) from the old URL to the new one is enabled.
178
- *
229
+ * Whether to suppress the automatic redirect from this page's previous URL to
230
+ * its current one after a slug change.
179
231
  *
180
- * Default: `false` (automatical redirect is enabled).
232
+ * Default false, meaning the redirect IS created. The field is named for the
233
+ * exception rather than the rule, which reads backwards; kept as-is because
234
+ * renaming a stored boolean is not worth the migration.
181
235
  */
182
236
  preventAutoRedirect?: boolean;
183
237
  /**
184
- * User-selected keyword terms for a specific page.
185
- * @maxSize 5
238
+ * Keyword terms the user is targeting for this page. Used by the SEO
239
+ * assistant and checklist; never rendered into <head>.
240
+ *
241
+ * 20 is a sanity bound, not the product limit. v1 declared 5 — the number
242
+ * the panel happens to allow today — which is exactly the mistake we are
243
+ * fixing for structured data. A product decision to allow 8 should not need
244
+ * a proto release, so the panel owns that number and the proto only stops
245
+ * something absurd.
246
+ * @maxSize 20
186
247
  */
187
248
  keywords?: Keyword[];
188
249
  }
@@ -222,288 +283,249 @@ interface ExternalReferenceInfo {
222
283
  /** Whether the connection to the external system is currently active. */
223
284
  connected?: boolean | null;
224
285
  }
225
- interface InvalidateCache extends InvalidateCacheGetByOneOf {
286
+ interface DuplicateMenuRequest {
226
287
  /**
227
- * Invalidate by msId. NOT recommended, as this will invalidate the entire site cache!
288
+ * Menu id to be duplicated.
228
289
  * @format GUID
229
290
  */
230
- metaSiteId?: string;
291
+ id: string;
231
292
  /**
232
- * Invalidate by Site ID. NOT recommended, as this will invalidate the entire site cache!
293
+ * Business location ids to duplicate the menu to.
233
294
  * @format GUID
295
+ * @maxSize 100
234
296
  */
235
- siteId?: string;
236
- /** Invalidate by App */
237
- app?: App;
238
- /** Invalidate by page id */
239
- page?: Page;
240
- /** Invalidate by URI path */
241
- uri?: URI;
242
- /** Invalidate by file (for media files such as PDFs) */
243
- file?: File;
244
- /** Invalidate by custom tag. Tags used in BO invalidation are disabled for this endpoint (more info: https://wix-bo.com/dev/clear-ssr-cache) */
245
- customTag?: CustomTag;
246
- /** Invalidate by multiple page ids */
247
- pages?: Pages;
248
- /** Invalidate by multiple URI paths */
249
- uris?: URIs;
297
+ businessLocationIds?: string[] | null;
298
+ /** Indicates whether sub-entities (such as items) should be duplicated as well. */
299
+ duplicateSubEntities?: boolean | null;
250
300
  /**
251
- * tell us why you're invalidating the cache. You don't need to add your app name
252
- * @maxLength 256
301
+ * The new name of the duplicated menu.
302
+ * @maxLength 500
253
303
  */
254
- reason?: string | null;
255
- /** Is local DS */
256
- localDc?: boolean;
257
- hardPurge?: boolean;
304
+ menuName?: string | null;
305
+ }
306
+ interface DuplicateMenuResponse {
307
+ /** @format GUID */
308
+ menuIds?: string[];
309
+ }
310
+ interface DomainEvent extends DomainEventBodyOneOf {
311
+ createdEvent?: EntityCreatedEvent;
312
+ updatedEvent?: EntityUpdatedEvent;
313
+ deletedEvent?: EntityDeletedEvent;
314
+ actionEvent?: ActionEvent;
315
+ /** Event ID. With this ID you can easily spot duplicated events and ignore them. */
316
+ id?: string;
258
317
  /**
259
- * Optional caller-provided ID for tracking this invalidation through the system.
260
- * When set, the corresponding CDN purge completion event will include this ID,
261
- * allowing you to confirm when the invalidation has fully propagated.
262
- * Example: generate a UUID, pass it here, and later match it in the CDN purge completion event.
263
- * @maxLength 256
318
+ * Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities.
319
+ * For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`.
264
320
  */
265
- correlationId?: string | null;
321
+ entityFqdn?: string;
322
+ /**
323
+ * Event action name, placed at the top level to make it easier for users to dispatch messages.
324
+ * For example: `created`/`updated`/`deleted`/`started`/`completed`/`email_opened`.
325
+ */
326
+ slug?: string;
327
+ /** ID of the entity associated with the event. */
328
+ entityId?: string;
329
+ /** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example, `2020-04-26T13:57:50.699Z`. */
330
+ eventTime?: Date | null;
331
+ /**
332
+ * Whether the event was triggered as a result of a privacy regulation application
333
+ * (for example, GDPR).
334
+ */
335
+ triggeredByAnonymizeRequest?: boolean | null;
336
+ /** If present, indicates the action that triggered the event. */
337
+ originatedFrom?: string | null;
338
+ /**
339
+ * A sequence number that indicates the order of updates to an entity. For example, if an entity was updated at `16:00` and then again at `16:01`, the second update will always have a higher sequence number.
340
+ * You can use this number to make sure you're handling updates in the right order. Just save the latest sequence number on your end and compare it to the one in each new message. If the new message has an older (lower) number, you can safely ignore it.
341
+ */
342
+ entityEventSequence?: string | null;
266
343
  }
267
344
  /** @oneof */
268
- interface InvalidateCacheGetByOneOf {
345
+ interface DomainEventBodyOneOf {
346
+ createdEvent?: EntityCreatedEvent;
347
+ updatedEvent?: EntityUpdatedEvent;
348
+ deletedEvent?: EntityDeletedEvent;
349
+ actionEvent?: ActionEvent;
350
+ }
351
+ interface EntityCreatedEvent {
352
+ entityAsJson?: string;
269
353
  /**
270
- * Invalidate by msId. NOT recommended, as this will invalidate the entire site cache!
271
- * @format GUID
354
+ * Indicates the event was triggered by a restore-from-trashbin operation for a previously deleted entity
355
+ * @internal
272
356
  */
273
- metaSiteId?: string;
357
+ triggeredByUndelete?: boolean | null;
358
+ /** Indicates the event was triggered by a restore-from-trashbin operation for a previously deleted entity */
359
+ restoreInfo?: RestoreInfo;
274
360
  /**
275
- * Invalidate by Site ID. NOT recommended, as this will invalidate the entire site cache!
276
- * @format GUID
361
+ * Optional domain-specific metadata defined by the API owner, encoded as JSON.
362
+ * @internal
277
363
  */
278
- siteId?: string;
279
- /** Invalidate by App */
280
- app?: App;
281
- /** Invalidate by page id */
282
- page?: Page;
283
- /** Invalidate by URI path */
284
- uri?: URI;
285
- /** Invalidate by file (for media files such as PDFs) */
286
- file?: File;
287
- /** Invalidate by custom tag. Tags used in BO invalidation are disabled for this endpoint (more info: https://wix-bo.com/dev/clear-ssr-cache) */
288
- customTag?: CustomTag;
289
- /** Invalidate by multiple page ids */
290
- pages?: Pages;
291
- /** Invalidate by multiple URI paths */
292
- uris?: URIs;
364
+ additionalMetadataAsJson?: string | null;
293
365
  }
294
- interface App {
366
+ interface RestoreInfo {
367
+ deletedDate?: Date | null;
368
+ }
369
+ interface EntityUpdatedEvent {
295
370
  /**
296
- * The AppDefId
297
- * @minLength 1
371
+ * Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.
372
+ * This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.
373
+ * We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.
298
374
  */
299
- appDefId?: string;
375
+ currentEntityAsJson?: string;
300
376
  /**
301
- * The instance Id
302
- * @format GUID
377
+ * This field is currently part of the of the EntityUpdatedEvent msg, but scala/node libraries which implements the domain events standard
378
+ * wont populate it / have any reference to it in the API.
379
+ * The main reason for it is that fetching the old entity from the DB will have a performance hit on an update operation so unless truly needed,
380
+ * the developer should send only the new (current) entity.
381
+ * An additional reason is not wanting to send this additional entity over the wire (kafka) since in some cases it can be really big
382
+ * Developers that must reflect the old entity will have to implement their own domain event sender mechanism which will follow the DomainEvent proto message.
383
+ * @internal
384
+ * @deprecated
303
385
  */
304
- instanceId?: string;
305
- }
306
- interface Page {
386
+ previousEntityAsJson?: string | null;
307
387
  /**
308
- * the msid the page is on
309
- * @format GUID
388
+ * Map of fully qualified field paths to their previous values for fields that changed.
389
+ * For more details please see [AIP](https://dev.wix.com/docs/rnd-general/articles/p13n-guidelines-aips/guidance-aips/design-patterns/7016-events#modified-fields-format)
390
+ * @internal
310
391
  */
311
- metaSiteId?: string;
392
+ modifiedFields?: Record<string, any>;
312
393
  /**
313
- * Invalidate by Page ID
314
- * @minLength 1
394
+ * Optional domain-specific metadata defined by the API owner, encoded as JSON.
395
+ * @internal
315
396
  */
316
- pageId?: string;
397
+ additionalMetadataAsJson?: string | null;
317
398
  }
318
- interface URI {
399
+ interface EntityDeletedEvent {
319
400
  /**
320
- * the msid the URI is on
321
- * @format GUID
401
+ * Indicates if the entity is sent to trash-bin. only available when trash-bin is enabled
402
+ * @internal
322
403
  */
323
- metaSiteId?: string;
404
+ movedToTrash?: boolean | null;
405
+ /** Entity that was deleted. */
406
+ deletedEntityAsJson?: string | null;
324
407
  /**
325
- * URI path to invalidate (e.g. page/my/path) - without leading/trailing slashes
326
- * @minLength 1
408
+ * Optional domain-specific metadata defined by the API owner, encoded as JSON.
409
+ * @internal
327
410
  */
328
- uriPath?: string;
411
+ additionalMetadataAsJson?: string | null;
329
412
  }
330
- interface File {
413
+ interface ActionEvent {
414
+ bodyAsJson?: string;
415
+ }
416
+ interface MessageEnvelope {
331
417
  /**
332
- * the msid the file is related to
418
+ * App instance ID.
333
419
  * @format GUID
334
420
  */
335
- metaSiteId?: string;
421
+ instanceId?: string | null;
336
422
  /**
337
- * Invalidate by filename (for media files such as PDFs)
338
- * @minLength 1
339
- * @maxLength 256
423
+ * Event type.
424
+ * @maxLength 150
340
425
  */
341
- fileName?: string;
426
+ eventType?: string;
427
+ /** The identification type and identity data. */
428
+ identity?: IdentificationData;
429
+ /** Stringify payload. */
430
+ data?: string;
431
+ /** Details related to the account */
432
+ accountInfo?: AccountInfo;
342
433
  }
343
- interface CustomTag {
434
+ interface IdentificationData extends IdentificationDataIdOneOf {
344
435
  /**
345
- * the msid the tag is related to
436
+ * ID of a site visitor that has not logged in to the site.
346
437
  * @format GUID
347
438
  */
348
- metaSiteId?: string;
439
+ anonymousVisitorId?: string;
349
440
  /**
350
- * Tag to invalidate by
351
- * @minLength 1
352
- * @maxLength 256
441
+ * ID of a site visitor that has logged in to the site.
442
+ * @format GUID
353
443
  */
354
- tag?: string;
355
- }
356
- interface Pages {
444
+ memberId?: string;
357
445
  /**
358
- * the msid the pages are on
446
+ * ID of a Wix user (site owner, contributor, etc.).
359
447
  * @format GUID
360
448
  */
361
- metaSiteId?: string;
449
+ wixUserId?: string;
362
450
  /**
363
- * Invalidate by multiple Page IDs in a single message
364
- * @maxSize 100
365
- * @minLength 1
451
+ * ID of an app.
452
+ * @format GUID
366
453
  */
367
- pageIds?: string[];
454
+ appId?: string;
455
+ /** @readonly */
456
+ identityType?: WebhookIdentityTypeWithLiterals;
368
457
  }
369
- interface URIs {
458
+ /** @oneof */
459
+ interface IdentificationDataIdOneOf {
370
460
  /**
371
- * the msid the URIs are on
461
+ * ID of a site visitor that has not logged in to the site.
372
462
  * @format GUID
373
463
  */
374
- metaSiteId?: string;
464
+ anonymousVisitorId?: string;
375
465
  /**
376
- * URI paths to invalidate (e.g. page/my/path) - without leading/trailing slashes
377
- * @maxSize 100
378
- * @minLength 1
466
+ * ID of a site visitor that has logged in to the site.
467
+ * @format GUID
379
468
  */
380
- uriPaths?: string[];
381
- }
382
- interface DeleteOrphanSections {
383
- /** Menu id */
384
- menuId?: string;
385
- }
386
- interface MenusDataCloningCompleted {
387
- }
388
- interface CreateMenuRequest {
389
- /** Menu details. */
390
- menu: Menu;
391
- }
392
- interface CreateMenuResponse {
393
- /** Menu. */
394
- menu?: Menu;
395
- }
396
- interface BulkCreateMenusRequest {
469
+ memberId?: string;
397
470
  /**
398
- * Menu details.
399
- * @maxSize 100
471
+ * ID of a Wix user (site owner, contributor, etc.).
472
+ * @format GUID
400
473
  */
401
- menus: Menu[];
402
- /** Whether to receive the created menus in the response. */
403
- returnEntity?: boolean;
404
- }
405
- interface BulkCreateMenusResponse {
406
- /** Information about the created menus. */
407
- results?: BulkCreateMenuResult[];
408
- /** Metadata for the API call. */
409
- bulkActionMetadata?: BulkActionMetadata;
410
- }
411
- interface BulkCreateMenuResult {
412
- /** Whether to receive the created menus in the response. */
413
- menuMetadata?: ItemMetadata;
414
- /** Created menu. */
415
- menu?: Menu;
416
- }
417
- interface ItemMetadata {
418
- /** Item ID. Should always be available, unless it's impossible (for example, when failing to create an item). */
419
- id?: string | null;
420
- /** Index of the item within the request array. Allows for correlation between request and response items. */
421
- originalIndex?: number;
422
- /** Whether the requested action was successful for this item. When `false`, the `error` field is populated. */
423
- success?: boolean;
424
- /** Details about the error in case of failure. */
425
- error?: ApplicationError;
426
- }
427
- interface ApplicationError {
428
- /** Error code. */
429
- code?: string;
430
- /** Description of the error. */
431
- description?: string;
432
- /** Data related to the error. */
433
- data?: Record<string, any> | null;
434
- }
435
- interface BulkActionMetadata {
436
- /** Number of items that were successfully processed. */
437
- totalSuccesses?: number;
438
- /** Number of items that couldn't be processed. */
439
- totalFailures?: number;
440
- /** Number of failures without details because detailed failure threshold was exceeded. */
441
- undetailedFailures?: number;
442
- }
443
- interface GetMenuRequest {
474
+ wixUserId?: string;
444
475
  /**
445
- * Menu ID.
476
+ * ID of an app.
446
477
  * @format GUID
447
478
  */
448
- menuId: string;
479
+ appId?: string;
449
480
  }
450
- interface GetMenuResponse {
451
- /** Menu. */
452
- menu?: Menu;
481
+ declare enum WebhookIdentityType {
482
+ UNKNOWN = "UNKNOWN",
483
+ ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR",
484
+ MEMBER = "MEMBER",
485
+ WIX_USER = "WIX_USER",
486
+ APP = "APP"
453
487
  }
454
- interface ListMenusRequest {
488
+ /** @enumType */
489
+ type WebhookIdentityTypeWithLiterals = WebhookIdentityType | 'UNKNOWN' | 'ANONYMOUS_VISITOR' | 'MEMBER' | 'WIX_USER' | 'APP';
490
+ interface AccountInfo {
455
491
  /**
456
- * Menu IDs.
492
+ * ID of the Wix account associated with the event.
457
493
  * @format GUID
458
- * @maxSize 500
459
494
  */
460
- menuIds?: string[];
461
- /** The metadata of the paginated results. */
462
- paging?: CursorPaging;
463
- /** Whether to return only menus that are visible to site visitors. */
464
- onlyVisible?: boolean | null;
465
- }
466
- interface CursorPaging {
495
+ accountId?: string | null;
467
496
  /**
468
- * Number of items to load.
469
- * @max 500
497
+ * ID of the parent Wix account. Only included when accountId belongs to a child account.
498
+ * @format GUID
470
499
  */
471
- limit?: number | null;
500
+ parentAccountId?: string | null;
472
501
  /**
473
- * Pointer to the next or previous page in the list of results.
474
- *
475
- * You can get the relevant cursor token
476
- * from the `pagingMetadata` object in the previous call's response.
477
- * Not relevant for the first request.
502
+ * ID of the Wix site associated with the event. Only included when the event is tied to a specific site.
503
+ * @format GUID
478
504
  */
479
- cursor?: string | null;
480
- }
481
- interface ListMenusResponse {
482
- /** Retrieved menus. */
483
- menus?: Menu[];
484
- /** The metadata of the paginated results. */
485
- pagingMetadata?: CursorPagingMetadata;
505
+ siteId?: string | null;
486
506
  }
487
- interface CursorPagingMetadata {
488
- /** Number of items returned in the response. */
489
- count?: number | null;
490
- /** Offset that was requested. */
491
- cursors?: Cursors;
507
+ interface GetMenuSiteUrlRequest {
492
508
  /**
493
- * Indicates if there are more results after the current page.
494
- * If `true`, another page of results can be retrieved.
495
- * If `false`, this is the last page.
509
+ * Menu ID.
510
+ * @format GUID
511
+ * @readonly
496
512
  */
497
- hasNext?: boolean | null;
513
+ id: string | null;
498
514
  }
499
- interface Cursors {
500
- /** Cursor pointing to next page in the list of results. */
501
- next?: string | null;
502
- /** Cursor pointing to previous page in the list of results. */
503
- prev?: string | null;
515
+ interface GetMenuSiteUrlResponse {
516
+ /** Retrieved menuInfo with path url. */
517
+ menuSiteUrl?: MenuSiteUrl;
504
518
  }
505
- interface QueryMenusRequest {
506
- /** Query options. */
519
+ interface MenuSiteUrl {
520
+ /**
521
+ * Path URL.
522
+ * @minLength 1
523
+ * @maxLength 1000
524
+ */
525
+ path?: string;
526
+ }
527
+ interface QueryMenusSiteUrlRequest {
528
+ /** Query options */
507
529
  query?: CursorQuery;
508
530
  }
509
531
  interface CursorQuery extends CursorQueryPagingMethodOneOf {
@@ -569,369 +591,408 @@ interface AddressLocation {
569
591
  /** Address longitude. */
570
592
  longitude?: number | null;
571
593
  }
572
- interface QueryMenusResponse {
573
- /** Retrieved menus. */
574
- menus?: Menu[];
575
- /** The metadata of the paginated results. */
576
- pagingMetadata?: CursorPagingMetadata;
577
- }
578
- interface UpdateMenuRequest {
579
- /** Menu to update. */
580
- menu: Menu;
594
+ interface CursorPaging {
581
595
  /**
582
- * Explicit list of fields to update.
583
- * @internal
596
+ * Number of items to load.
597
+ * @max 500
584
598
  */
585
- mask?: string[];
586
- }
587
- interface UpdateMenuResponse {
588
- /** Updated menu. */
589
- menu?: Menu;
590
- }
591
- interface BulkUpdateMenuRequest {
599
+ limit?: number | null;
592
600
  /**
593
- * Menus to update.
594
- * @minSize 1
595
- * @maxSize 100
601
+ * Pointer to the next or previous page in the list of results.
602
+ *
603
+ * You can get the relevant cursor token
604
+ * from the `pagingMetadata` object in the previous call's response.
605
+ * Not relevant for the first request.
596
606
  */
597
- menus: MaskedMenu[];
598
- /** Whether to receive the entity in the response. */
599
- returnEntity?: boolean;
607
+ cursor?: string | null;
600
608
  }
601
- interface MaskedMenu {
602
- /** Menu to updated. */
603
- menu?: Menu;
604
- /** Explicit list of fields to update. */
605
- mask?: string[];
609
+ interface QueryMenusSiteUrlResponse {
610
+ /** Retrieved menuInfos with path urls. */
611
+ menuSiteUrls?: MenuSiteUrl[];
612
+ /** The metadata of the paginated results. */
613
+ pagingMetadata?: CursorPagingMetadata;
606
614
  }
607
- interface BulkUpdateMenuResponse {
615
+ interface CursorPagingMetadata {
616
+ /** Number of items returned in the response. */
617
+ count?: number | null;
618
+ /** Offset that was requested. */
619
+ cursors?: Cursors;
608
620
  /**
609
- * Results of bulk menu update.
610
- * @minSize 1
611
- * @maxSize 100
621
+ * Indicates if there are more results after the current page.
622
+ * If `true`, another page of results can be retrieved.
623
+ * If `false`, this is the last page.
612
624
  */
613
- results?: BulkMenuResult[];
614
- /** Metadata for the API call. */
615
- bulkActionMetadata?: BulkActionMetadata;
616
- }
617
- interface BulkMenuResult {
618
- /** Metadata for menu update. */
619
- menuMetadata?: ItemMetadata;
620
- /** Updated menu. Only returned if `returnEntity` is set to `true`. */
621
- menu?: Menu;
622
- }
623
- interface UpdateExtendedFieldsRequest {
624
- /** ID of the entity to update. */
625
- id: string;
626
- /** Identifier for the app whose extended fields are being updated. */
627
- namespace: string;
628
- /** Data to update. Structured according to the [schema](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields#json-schema-for-extended-fields) defined when the extended fields were configured. */
629
- namespaceData: Record<string, any> | null;
625
+ hasNext?: boolean | null;
630
626
  }
631
- interface UpdateExtendedFieldsResponse {
632
- /** Namespace of the app. */
633
- namespace?: string;
634
- /** Updated extended fields data. */
635
- namespaceData?: Record<string, any> | null;
627
+ interface Cursors {
628
+ /** Cursor pointing to next page in the list of results. */
629
+ next?: string | null;
630
+ /** Cursor pointing to previous page in the list of results. */
631
+ prev?: string | null;
636
632
  }
637
- interface DeleteMenuRequest {
633
+ interface InvalidateCache extends InvalidateCacheGetByOneOf {
638
634
  /**
639
- * Menu ID.
635
+ * Invalidate by msId. NOT recommended, as this will invalidate the entire site cache!
640
636
  * @format GUID
641
637
  */
642
- menuId: string;
643
- }
644
- interface DeleteMenuResponse {
645
- }
646
- interface RunMenusMultiLocationMigrationRequest {
638
+ metaSiteId?: string;
647
639
  /**
648
- * business location id
640
+ * Invalidate by Site ID. NOT recommended, as this will invalidate the entire site cache!
649
641
  * @format GUID
650
642
  */
651
- businessLocationId?: string;
652
- }
653
- interface RunMenusMultiLocationMigrationResponse {
654
- /** Whether menus multi-location migration finished successfully */
655
- success?: boolean;
656
- }
657
- interface UpdateBusinessLocationIdRequest {
658
- /** @format GUID */
659
- menuId?: string;
660
- /** @format GUID */
661
- businessLocationId?: string | null;
662
- }
663
- interface UpdateBusinessLocationIdResponse {
664
- }
665
- interface CloneMenusRequest {
666
- /**
667
- * The MetaSiteId to clone from.
668
- * @format GUID
669
- */
670
- metaSiteId?: string;
671
- }
672
- interface CloneMenusResponse {
673
- }
674
- interface DomainEvent extends DomainEventBodyOneOf {
675
- createdEvent?: EntityCreatedEvent;
676
- updatedEvent?: EntityUpdatedEvent;
677
- deletedEvent?: EntityDeletedEvent;
678
- actionEvent?: ActionEvent;
679
- /** Event ID. With this ID you can easily spot duplicated events and ignore them. */
680
- id?: string;
681
- /**
682
- * Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities.
683
- * For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`.
684
- */
685
- entityFqdn?: string;
686
- /**
687
- * Event action name, placed at the top level to make it easier for users to dispatch messages.
688
- * For example: `created`/`updated`/`deleted`/`started`/`completed`/`email_opened`.
689
- */
690
- slug?: string;
691
- /** ID of the entity associated with the event. */
692
- entityId?: string;
693
- /** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example, `2020-04-26T13:57:50.699Z`. */
694
- eventTime?: Date | null;
643
+ siteId?: string;
644
+ /** Invalidate by App */
645
+ app?: App;
646
+ /** Invalidate by page id */
647
+ page?: Page;
648
+ /** Invalidate by URI path */
649
+ uri?: URI;
650
+ /** Invalidate by file (for media files such as PDFs) */
651
+ file?: File;
652
+ /** Invalidate by custom tag. Tags used in BO invalidation are disabled for this endpoint (more info: https://wix-bo.com/dev/clear-ssr-cache) */
653
+ customTag?: CustomTag;
654
+ /** Invalidate by multiple page ids */
655
+ pages?: Pages;
656
+ /** Invalidate by multiple URI paths */
657
+ uris?: URIs;
695
658
  /**
696
- * Whether the event was triggered as a result of a privacy regulation application
697
- * (for example, GDPR).
659
+ * tell us why you're invalidating the cache. You don't need to add your app name
660
+ * @maxLength 256
698
661
  */
699
- triggeredByAnonymizeRequest?: boolean | null;
700
- /** If present, indicates the action that triggered the event. */
701
- originatedFrom?: string | null;
662
+ reason?: string | null;
663
+ /** Is local DS */
664
+ localDc?: boolean;
665
+ hardPurge?: boolean;
702
666
  /**
703
- * A sequence number that indicates the order of updates to an entity. For example, if an entity was updated at `16:00` and then again at `16:01`, the second update will always have a higher sequence number.
704
- * You can use this number to make sure you're handling updates in the right order. Just save the latest sequence number on your end and compare it to the one in each new message. If the new message has an older (lower) number, you can safely ignore it.
667
+ * Optional caller-provided ID for tracking this invalidation through the system.
668
+ * When set, the corresponding CDN purge completion event will include this ID,
669
+ * allowing you to confirm when the invalidation has fully propagated.
670
+ * Example: generate a UUID, pass it here, and later match it in the CDN purge completion event.
671
+ * @maxLength 256
705
672
  */
706
- entityEventSequence?: string | null;
673
+ correlationId?: string | null;
707
674
  }
708
675
  /** @oneof */
709
- interface DomainEventBodyOneOf {
710
- createdEvent?: EntityCreatedEvent;
711
- updatedEvent?: EntityUpdatedEvent;
712
- deletedEvent?: EntityDeletedEvent;
713
- actionEvent?: ActionEvent;
714
- }
715
- interface EntityCreatedEvent {
716
- entityAsJson?: string;
676
+ interface InvalidateCacheGetByOneOf {
717
677
  /**
718
- * Indicates the event was triggered by a restore-from-trashbin operation for a previously deleted entity
719
- * @internal
678
+ * Invalidate by msId. NOT recommended, as this will invalidate the entire site cache!
679
+ * @format GUID
720
680
  */
721
- triggeredByUndelete?: boolean | null;
722
- /** Indicates the event was triggered by a restore-from-trashbin operation for a previously deleted entity */
723
- restoreInfo?: RestoreInfo;
681
+ metaSiteId?: string;
724
682
  /**
725
- * Optional domain-specific metadata defined by the API owner, encoded as JSON.
726
- * @internal
683
+ * Invalidate by Site ID. NOT recommended, as this will invalidate the entire site cache!
684
+ * @format GUID
727
685
  */
728
- additionalMetadataAsJson?: string | null;
729
- }
730
- interface RestoreInfo {
731
- deletedDate?: Date | null;
686
+ siteId?: string;
687
+ /** Invalidate by App */
688
+ app?: App;
689
+ /** Invalidate by page id */
690
+ page?: Page;
691
+ /** Invalidate by URI path */
692
+ uri?: URI;
693
+ /** Invalidate by file (for media files such as PDFs) */
694
+ file?: File;
695
+ /** Invalidate by custom tag. Tags used in BO invalidation are disabled for this endpoint (more info: https://wix-bo.com/dev/clear-ssr-cache) */
696
+ customTag?: CustomTag;
697
+ /** Invalidate by multiple page ids */
698
+ pages?: Pages;
699
+ /** Invalidate by multiple URI paths */
700
+ uris?: URIs;
732
701
  }
733
- interface EntityUpdatedEvent {
734
- /**
735
- * Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.
736
- * This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.
737
- * We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.
738
- */
739
- currentEntityAsJson?: string;
740
- /**
741
- * This field is currently part of the of the EntityUpdatedEvent msg, but scala/node libraries which implements the domain events standard
742
- * wont populate it / have any reference to it in the API.
743
- * The main reason for it is that fetching the old entity from the DB will have a performance hit on an update operation so unless truly needed,
744
- * the developer should send only the new (current) entity.
745
- * An additional reason is not wanting to send this additional entity over the wire (kafka) since in some cases it can be really big
746
- * Developers that must reflect the old entity will have to implement their own domain event sender mechanism which will follow the DomainEvent proto message.
747
- * @internal
748
- * @deprecated
749
- */
750
- previousEntityAsJson?: string | null;
702
+ interface App {
751
703
  /**
752
- * Map of fully qualified field paths to their previous values for fields that changed.
753
- * For more details please see [AIP](https://dev.wix.com/docs/rnd-general/articles/p13n-guidelines-aips/guidance-aips/design-patterns/7016-events#modified-fields-format)
754
- * @internal
704
+ * The AppDefId
705
+ * @minLength 1
755
706
  */
756
- modifiedFields?: Record<string, any>;
707
+ appDefId?: string;
757
708
  /**
758
- * Optional domain-specific metadata defined by the API owner, encoded as JSON.
759
- * @internal
709
+ * The instance Id
710
+ * @format GUID
760
711
  */
761
- additionalMetadataAsJson?: string | null;
712
+ instanceId?: string;
762
713
  }
763
- interface EntityDeletedEvent {
714
+ interface Page {
764
715
  /**
765
- * Indicates if the entity is sent to trash-bin. only available when trash-bin is enabled
766
- * @internal
716
+ * the msid the page is on
717
+ * @format GUID
767
718
  */
768
- movedToTrash?: boolean | null;
769
- /** Entity that was deleted. */
770
- deletedEntityAsJson?: string | null;
719
+ metaSiteId?: string;
771
720
  /**
772
- * Optional domain-specific metadata defined by the API owner, encoded as JSON.
773
- * @internal
721
+ * Invalidate by Page ID
722
+ * @minLength 1
774
723
  */
775
- additionalMetadataAsJson?: string | null;
776
- }
777
- interface ActionEvent {
778
- bodyAsJson?: string;
779
- }
780
- interface Empty {
724
+ pageId?: string;
781
725
  }
782
- interface SyncContentToMultilingualRequest {
726
+ interface URI {
783
727
  /**
784
- * MetaSite ID
728
+ * the msid the URI is on
785
729
  * @format GUID
786
730
  */
787
731
  metaSiteId?: string;
732
+ /**
733
+ * URI path to invalidate (e.g. page/my/path) - without leading/trailing slashes
734
+ * @minLength 1
735
+ */
736
+ uriPath?: string;
788
737
  }
789
- interface SyncContentToMultilingualResponse {
790
- }
791
- interface MessageEnvelope {
738
+ interface File {
792
739
  /**
793
- * App instance ID.
740
+ * the msid the file is related to
794
741
  * @format GUID
795
742
  */
796
- instanceId?: string | null;
743
+ metaSiteId?: string;
797
744
  /**
798
- * Event type.
799
- * @maxLength 150
745
+ * Invalidate by filename (for media files such as PDFs)
746
+ * @minLength 1
747
+ * @maxLength 256
800
748
  */
801
- eventType?: string;
802
- /** The identification type and identity data. */
803
- identity?: IdentificationData;
804
- /** Stringify payload. */
805
- data?: string;
806
- /** Details related to the account */
807
- accountInfo?: AccountInfo;
749
+ fileName?: string;
808
750
  }
809
- interface IdentificationData extends IdentificationDataIdOneOf {
751
+ interface CustomTag {
810
752
  /**
811
- * ID of a site visitor that has not logged in to the site.
753
+ * the msid the tag is related to
812
754
  * @format GUID
813
755
  */
814
- anonymousVisitorId?: string;
756
+ metaSiteId?: string;
815
757
  /**
816
- * ID of a site visitor that has logged in to the site.
817
- * @format GUID
758
+ * Tag to invalidate by
759
+ * @minLength 1
760
+ * @maxLength 256
818
761
  */
819
- memberId?: string;
762
+ tag?: string;
763
+ }
764
+ interface Pages {
820
765
  /**
821
- * ID of a Wix user (site owner, contributor, etc.).
766
+ * the msid the pages are on
822
767
  * @format GUID
823
768
  */
824
- wixUserId?: string;
769
+ metaSiteId?: string;
825
770
  /**
826
- * ID of an app.
827
- * @format GUID
771
+ * Invalidate by multiple Page IDs in a single message
772
+ * @maxSize 100
773
+ * @minLength 1
828
774
  */
829
- appId?: string;
830
- /** @readonly */
831
- identityType?: WebhookIdentityTypeWithLiterals;
775
+ pageIds?: string[];
832
776
  }
833
- /** @oneof */
834
- interface IdentificationDataIdOneOf {
777
+ interface URIs {
835
778
  /**
836
- * ID of a site visitor that has not logged in to the site.
779
+ * the msid the URIs are on
837
780
  * @format GUID
838
781
  */
839
- anonymousVisitorId?: string;
782
+ metaSiteId?: string;
840
783
  /**
841
- * ID of a site visitor that has logged in to the site.
842
- * @format GUID
784
+ * URI paths to invalidate (e.g. page/my/path) - without leading/trailing slashes
785
+ * @maxSize 100
786
+ * @minLength 1
843
787
  */
844
- memberId?: string;
788
+ uriPaths?: string[];
789
+ }
790
+ interface DeleteOrphanSections {
791
+ /** Menu id */
792
+ menuId?: string;
793
+ }
794
+ interface MenusDataCloningCompleted {
795
+ }
796
+ interface CreateMenuRequest {
797
+ /** Menu details. */
798
+ menu: Menu;
799
+ }
800
+ interface CreateMenuResponse {
801
+ /** Menu. */
802
+ menu?: Menu;
803
+ }
804
+ interface BulkCreateMenusRequest {
845
805
  /**
846
- * ID of a Wix user (site owner, contributor, etc.).
847
- * @format GUID
806
+ * Menu details.
807
+ * @maxSize 100
848
808
  */
849
- wixUserId?: string;
809
+ menus: Menu[];
810
+ /** Whether to receive the created menus in the response. */
811
+ returnEntity?: boolean;
812
+ }
813
+ interface BulkCreateMenusResponse {
814
+ /** Information about the created menus. */
815
+ results?: BulkCreateMenuResult[];
816
+ /** Metadata for the API call. */
817
+ bulkActionMetadata?: BulkActionMetadata;
818
+ }
819
+ interface BulkCreateMenuResult {
820
+ /** Whether to receive the created menus in the response. */
821
+ menuMetadata?: ItemMetadata;
822
+ /** Created menu. */
823
+ menu?: Menu;
824
+ }
825
+ interface ItemMetadata {
826
+ /** Item ID. Should always be available, unless it's impossible (for example, when failing to create an item). */
827
+ id?: string | null;
828
+ /** Index of the item within the request array. Allows for correlation between request and response items. */
829
+ originalIndex?: number;
830
+ /** Whether the requested action was successful for this item. When `false`, the `error` field is populated. */
831
+ success?: boolean;
832
+ /** Details about the error in case of failure. */
833
+ error?: ApplicationError;
834
+ }
835
+ interface ApplicationError {
836
+ /** Error code. */
837
+ code?: string;
838
+ /** Description of the error. */
839
+ description?: string;
840
+ /** Data related to the error. */
841
+ data?: Record<string, any> | null;
842
+ }
843
+ interface BulkActionMetadata {
844
+ /** Number of items that were successfully processed. */
845
+ totalSuccesses?: number;
846
+ /** Number of items that couldn't be processed. */
847
+ totalFailures?: number;
848
+ /** Number of failures without details because detailed failure threshold was exceeded. */
849
+ undetailedFailures?: number;
850
+ }
851
+ interface GetMenuRequest {
850
852
  /**
851
- * ID of an app.
853
+ * Menu ID.
852
854
  * @format GUID
853
855
  */
854
- appId?: string;
856
+ menuId: string;
855
857
  }
856
- declare enum WebhookIdentityType {
857
- UNKNOWN = "UNKNOWN",
858
- ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR",
859
- MEMBER = "MEMBER",
860
- WIX_USER = "WIX_USER",
861
- APP = "APP"
858
+ interface GetMenuResponse {
859
+ /** Menu. */
860
+ menu?: Menu;
862
861
  }
863
- /** @enumType */
864
- type WebhookIdentityTypeWithLiterals = WebhookIdentityType | 'UNKNOWN' | 'ANONYMOUS_VISITOR' | 'MEMBER' | 'WIX_USER' | 'APP';
865
- interface AccountInfo {
862
+ interface ListMenusRequest {
866
863
  /**
867
- * ID of the Wix account associated with the event.
864
+ * Menu IDs.
868
865
  * @format GUID
866
+ * @maxSize 500
869
867
  */
870
- accountId?: string | null;
868
+ menuIds?: string[];
869
+ /** The metadata of the paginated results. */
870
+ paging?: CursorPaging;
871
+ /** Whether to return only menus that are visible to site visitors. */
872
+ onlyVisible?: boolean | null;
873
+ }
874
+ interface ListMenusResponse {
875
+ /** Retrieved menus. */
876
+ menus?: Menu[];
877
+ /** The metadata of the paginated results. */
878
+ pagingMetadata?: CursorPagingMetadata;
879
+ }
880
+ interface QueryMenusRequest {
881
+ /** Query options. */
882
+ query?: CursorQuery;
883
+ }
884
+ interface QueryMenusResponse {
885
+ /** Retrieved menus. */
886
+ menus?: Menu[];
887
+ /** The metadata of the paginated results. */
888
+ pagingMetadata?: CursorPagingMetadata;
889
+ }
890
+ interface UpdateMenuRequest {
891
+ /** Menu to update. */
892
+ menu: Menu;
871
893
  /**
872
- * ID of the parent Wix account. Only included when accountId belongs to a child account.
873
- * @format GUID
894
+ * Explicit list of fields to update.
895
+ * @internal
874
896
  */
875
- parentAccountId?: string | null;
897
+ mask?: string[];
898
+ }
899
+ interface UpdateMenuResponse {
900
+ /** Updated menu. */
901
+ menu?: Menu;
902
+ }
903
+ interface BulkUpdateMenuRequest {
876
904
  /**
877
- * ID of the Wix site associated with the event. Only included when the event is tied to a specific site.
878
- * @format GUID
905
+ * Menus to update.
906
+ * @minSize 1
907
+ * @maxSize 100
879
908
  */
880
- siteId?: string | null;
909
+ menus: MaskedMenu[];
910
+ /** Whether to receive the entity in the response. */
911
+ returnEntity?: boolean;
881
912
  }
882
- interface DuplicateMenuRequest {
913
+ interface MaskedMenu {
914
+ /** Menu to updated. */
915
+ menu?: Menu;
916
+ /** Explicit list of fields to update. */
917
+ mask?: string[];
918
+ }
919
+ interface BulkUpdateMenuResponse {
883
920
  /**
884
- * Menu id to be duplicated.
885
- * @format GUID
921
+ * Results of bulk menu update.
922
+ * @minSize 1
923
+ * @maxSize 100
886
924
  */
925
+ results?: BulkMenuResult[];
926
+ /** Metadata for the API call. */
927
+ bulkActionMetadata?: BulkActionMetadata;
928
+ }
929
+ interface BulkMenuResult {
930
+ /** Metadata for menu update. */
931
+ menuMetadata?: ItemMetadata;
932
+ /** Updated menu. Only returned if `returnEntity` is set to `true`. */
933
+ menu?: Menu;
934
+ }
935
+ interface UpdateExtendedFieldsRequest {
936
+ /** ID of the entity to update. */
887
937
  id: string;
938
+ /** Identifier for the app whose extended fields are being updated. */
939
+ namespace: string;
940
+ /** Data to update. Structured according to the [schema](https://dev.wix.com/docs/rest/articles/getting-started/extended-fields#json-schema-for-extended-fields) defined when the extended fields were configured. */
941
+ namespaceData: Record<string, any> | null;
942
+ }
943
+ interface UpdateExtendedFieldsResponse {
944
+ /** Namespace of the app. */
945
+ namespace?: string;
946
+ /** Updated extended fields data. */
947
+ namespaceData?: Record<string, any> | null;
948
+ }
949
+ interface DeleteMenuRequest {
888
950
  /**
889
- * Business location ids to duplicate the menu to.
951
+ * Menu ID.
890
952
  * @format GUID
891
- * @maxSize 100
892
953
  */
893
- businessLocationIds?: string[] | null;
894
- /** Indicates whether sub-entities (such as items) should be duplicated as well. */
895
- duplicateSubEntities?: boolean | null;
954
+ menuId: string;
955
+ }
956
+ interface DeleteMenuResponse {
957
+ }
958
+ interface RunMenusMultiLocationMigrationRequest {
896
959
  /**
897
- * The new name of the duplicated menu.
898
- * @maxLength 500
960
+ * business location id
961
+ * @format GUID
899
962
  */
900
- menuName?: string | null;
963
+ businessLocationId?: string;
901
964
  }
902
- interface DuplicateMenuResponse {
965
+ interface RunMenusMultiLocationMigrationResponse {
966
+ /** Whether menus multi-location migration finished successfully */
967
+ success?: boolean;
968
+ }
969
+ interface UpdateBusinessLocationIdRequest {
903
970
  /** @format GUID */
904
- menuIds?: string[];
971
+ menuId?: string;
972
+ /** @format GUID */
973
+ businessLocationId?: string | null;
905
974
  }
906
- interface GetMenuSiteUrlRequest {
975
+ interface UpdateBusinessLocationIdResponse {
976
+ }
977
+ interface CloneMenusRequest {
907
978
  /**
908
- * Menu ID.
979
+ * The MetaSiteId to clone from.
909
980
  * @format GUID
910
- * @readonly
911
981
  */
912
- id: string | null;
982
+ metaSiteId?: string;
913
983
  }
914
- interface GetMenuSiteUrlResponse {
915
- /** Retrieved menuInfo with path url. */
916
- menuSiteUrl?: MenuSiteUrl;
984
+ interface CloneMenusResponse {
917
985
  }
918
- interface MenuSiteUrl {
986
+ interface Empty {
987
+ }
988
+ interface SyncContentToMultilingualRequest {
919
989
  /**
920
- * Path URL.
921
- * @minLength 1
922
- * @maxLength 1000
990
+ * MetaSite ID
991
+ * @format GUID
923
992
  */
924
- path?: string;
925
- }
926
- interface QueryMenusSiteUrlRequest {
927
- /** Query options */
928
- query?: CursorQuery;
993
+ metaSiteId?: string;
929
994
  }
930
- interface QueryMenusSiteUrlResponse {
931
- /** Retrieved menuInfos with path urls. */
932
- menuSiteUrls?: MenuSiteUrl[];
933
- /** The metadata of the paginated results. */
934
- pagingMetadata?: CursorPagingMetadata;
995
+ interface SyncContentToMultilingualResponse {
935
996
  }
936
997
 
937
998
  type __PublicMethodMetaInfo<K = string, M = unknown, T = unknown, S = unknown, Q = unknown, R = unknown> = {
@@ -944,6 +1005,13 @@ type __PublicMethodMetaInfo<K = string, M = unknown, T = unknown, S = unknown, Q
944
1005
  __responseType: Q;
945
1006
  __originalResponseType: R;
946
1007
  };
1008
+ declare function duplicateMenu(): __PublicMethodMetaInfo<'POST', {
1009
+ id: string;
1010
+ }, DuplicateMenuRequest$1, DuplicateMenuRequest, DuplicateMenuResponse$1, DuplicateMenuResponse>;
1011
+ declare function getMenuSiteUrl(): __PublicMethodMetaInfo<'GET', {
1012
+ id: string;
1013
+ }, GetMenuSiteUrlRequest$1, GetMenuSiteUrlRequest, GetMenuSiteUrlResponse$1, GetMenuSiteUrlResponse>;
1014
+ declare function queryMenusSiteUrl(): __PublicMethodMetaInfo<'POST', {}, QueryMenusSiteUrlRequest$1, QueryMenusSiteUrlRequest, QueryMenusSiteUrlResponse$1, QueryMenusSiteUrlResponse>;
947
1015
  declare function createMenu(): __PublicMethodMetaInfo<'POST', {}, CreateMenuRequest$1, CreateMenuRequest, CreateMenuResponse$1, CreateMenuResponse>;
948
1016
  declare function bulkCreateMenus(): __PublicMethodMetaInfo<'POST', {}, BulkCreateMenusRequest$1, BulkCreateMenusRequest, BulkCreateMenusResponse$1, BulkCreateMenusResponse>;
949
1017
  declare function getMenu(): __PublicMethodMetaInfo<'GET', {
@@ -961,12 +1029,5 @@ declare function updateExtendedFields(): __PublicMethodMetaInfo<'POST', {
961
1029
  declare function deleteMenu(): __PublicMethodMetaInfo<'DELETE', {
962
1030
  menuId: string;
963
1031
  }, DeleteMenuRequest$1, DeleteMenuRequest, DeleteMenuResponse$1, DeleteMenuResponse>;
964
- declare function duplicateMenu(): __PublicMethodMetaInfo<'POST', {
965
- id: string;
966
- }, DuplicateMenuRequest$1, DuplicateMenuRequest, DuplicateMenuResponse$1, DuplicateMenuResponse>;
967
- declare function getMenuSiteUrl(): __PublicMethodMetaInfo<'GET', {
968
- id: string;
969
- }, GetMenuSiteUrlRequest$1, GetMenuSiteUrlRequest, GetMenuSiteUrlResponse$1, GetMenuSiteUrlResponse>;
970
- declare function queryMenusSiteUrl(): __PublicMethodMetaInfo<'POST', {}, QueryMenusSiteUrlRequest$1, QueryMenusSiteUrlRequest, QueryMenusSiteUrlResponse$1, QueryMenusSiteUrlResponse>;
971
1032
 
972
1033
  export { type AccountInfo as AccountInfoOriginal, type ActionEvent as ActionEventOriginal, type AddressLocation as AddressLocationOriginal, type App as AppOriginal, type ApplicationError as ApplicationErrorOriginal, type BulkActionMetadata as BulkActionMetadataOriginal, type BulkCreateMenuResult as BulkCreateMenuResultOriginal, type BulkCreateMenusRequest as BulkCreateMenusRequestOriginal, type BulkCreateMenusResponse as BulkCreateMenusResponseOriginal, type BulkMenuResult as BulkMenuResultOriginal, type BulkUpdateMenuRequest as BulkUpdateMenuRequestOriginal, type BulkUpdateMenuResponse as BulkUpdateMenuResponseOriginal, type BusinessLocationDetails as BusinessLocationDetailsOriginal, type CloneMenusRequest as CloneMenusRequestOriginal, type CloneMenusResponse as CloneMenusResponseOriginal, type CreateMenuRequest as CreateMenuRequestOriginal, type CreateMenuResponse as CreateMenuResponseOriginal, type CursorPagingMetadata as CursorPagingMetadataOriginal, type CursorPaging as CursorPagingOriginal, type CursorQuery as CursorQueryOriginal, type CursorQueryPagingMethodOneOf as CursorQueryPagingMethodOneOfOriginal, type Cursors as CursorsOriginal, type CustomTag as CustomTagOriginal, type DeleteMenuRequest as DeleteMenuRequestOriginal, type DeleteMenuResponse as DeleteMenuResponseOriginal, type DeleteOrphanSections as DeleteOrphanSectionsOriginal, type DomainEventBodyOneOf as DomainEventBodyOneOfOriginal, type DomainEvent as DomainEventOriginal, type DuplicateMenuRequest as DuplicateMenuRequestOriginal, type DuplicateMenuResponse as DuplicateMenuResponseOriginal, type Empty as EmptyOriginal, type EntityCreatedEvent as EntityCreatedEventOriginal, type EntityDeletedEvent as EntityDeletedEventOriginal, type EntityUpdatedEvent as EntityUpdatedEventOriginal, type ExtendedFields as ExtendedFieldsOriginal, type ExternalReferenceInfo as ExternalReferenceInfoOriginal, type File as FileOriginal, type GetMenuRequest as GetMenuRequestOriginal, type GetMenuResponse as GetMenuResponseOriginal, type GetMenuSiteUrlRequest as GetMenuSiteUrlRequestOriginal, type GetMenuSiteUrlResponse as GetMenuSiteUrlResponseOriginal, type IdentificationDataIdOneOf as IdentificationDataIdOneOfOriginal, type IdentificationData as IdentificationDataOriginal, type InvalidateCacheGetByOneOf as InvalidateCacheGetByOneOfOriginal, type InvalidateCache as InvalidateCacheOriginal, type ItemMetadata as ItemMetadataOriginal, type Keyword as KeywordOriginal, type ListMenusRequest as ListMenusRequestOriginal, type ListMenusResponse as ListMenusResponseOriginal, type MaskedMenu as MaskedMenuOriginal, type Menu as MenuOriginal, type MenuSiteUrl as MenuSiteUrlOriginal, type MenusDataCloningCompleted as MenusDataCloningCompletedOriginal, type MessageEnvelope as MessageEnvelopeOriginal, type Page as PageOriginal, type Pages as PagesOriginal, type QueryMenusRequest as QueryMenusRequestOriginal, type QueryMenusResponse as QueryMenusResponseOriginal, type QueryMenusSiteUrlRequest as QueryMenusSiteUrlRequestOriginal, type QueryMenusSiteUrlResponse as QueryMenusSiteUrlResponseOriginal, type RestoreInfo as RestoreInfoOriginal, type RunMenusMultiLocationMigrationRequest as RunMenusMultiLocationMigrationRequestOriginal, type RunMenusMultiLocationMigrationResponse as RunMenusMultiLocationMigrationResponseOriginal, type SeoSchema as SeoSchemaOriginal, type Settings as SettingsOriginal, SortOrder as SortOrderOriginal, type SortOrderWithLiterals as SortOrderWithLiteralsOriginal, type Sorting as SortingOriginal, type SyncContentToMultilingualRequest as SyncContentToMultilingualRequestOriginal, type SyncContentToMultilingualResponse as SyncContentToMultilingualResponseOriginal, type Tag as TagOriginal, type URI as URIOriginal, type URIs as URIsOriginal, type UpdateBusinessLocationIdRequest as UpdateBusinessLocationIdRequestOriginal, type UpdateBusinessLocationIdResponse as UpdateBusinessLocationIdResponseOriginal, type UpdateExtendedFieldsRequest as UpdateExtendedFieldsRequestOriginal, type UpdateExtendedFieldsResponse as UpdateExtendedFieldsResponseOriginal, type UpdateMenuRequest as UpdateMenuRequestOriginal, type UpdateMenuResponse as UpdateMenuResponseOriginal, WebhookIdentityType as WebhookIdentityTypeOriginal, type WebhookIdentityTypeWithLiterals as WebhookIdentityTypeWithLiteralsOriginal, type __PublicMethodMetaInfo, bulkCreateMenus, bulkUpdateMenu, createMenu, deleteMenu, duplicateMenu, getMenu, getMenuSiteUrl, listMenus, queryMenus, queryMenusSiteUrl, updateExtendedFields, updateMenu };