@wix/auto_sdk_blog_draft-posts 1.0.119 → 1.0.120
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/index.js +13 -13
- package/build/cjs/index.js.map +1 -1
- package/build/cjs/index.typings.d.ts +375 -314
- package/build/cjs/index.typings.js +13 -13
- package/build/cjs/index.typings.js.map +1 -1
- package/build/cjs/meta.d.ts +378 -317
- package/build/cjs/meta.js +13 -13
- package/build/cjs/meta.js.map +1 -1
- package/build/es/index.mjs +13 -13
- package/build/es/index.mjs.map +1 -1
- package/build/es/index.typings.d.mts +375 -314
- package/build/es/index.typings.mjs +13 -13
- package/build/es/index.typings.mjs.map +1 -1
- package/build/es/meta.d.mts +378 -317
- package/build/es/meta.mjs +13 -13
- package/build/es/meta.mjs.map +1 -1
- package/build/internal/cjs/index.typings.d.ts +404 -343
- package/build/internal/cjs/meta.d.ts +832 -771
- package/build/internal/es/index.typings.d.mts +404 -343
- package/build/internal/es/meta.d.mts +832 -771
- package/package.json +4 -4
package/build/es/meta.d.mts
CHANGED
|
@@ -3119,73 +3119,117 @@ declare enum ModerationStatusStatus {
|
|
|
3119
3119
|
/** @enumType */
|
|
3120
3120
|
type ModerationStatusStatusWithLiterals = ModerationStatusStatus | 'UNKNOWN' | 'APPROVED' | 'REJECTED';
|
|
3121
3121
|
/**
|
|
3122
|
-
* The SEO
|
|
3123
|
-
*
|
|
3124
|
-
*
|
|
3122
|
+
* The SEO data for a single page or dynamic item, in the shape stored today.
|
|
3123
|
+
*
|
|
3124
|
+
* FROZEN. Existing server code maps onto this message field by field, so its
|
|
3125
|
+
* field set must never change (see the file header). New writers use
|
|
3126
|
+
* `SeoSchemaV2`.
|
|
3127
|
+
*
|
|
3128
|
+
* These tags are rendered into the <head> of the HTML document and are not
|
|
3129
|
+
* visible on the page itself. They override every other source of tags
|
|
3130
|
+
* (site defaults, vertical presets, patterns) for this page.
|
|
3125
3131
|
*/
|
|
3126
3132
|
interface SeoSchema {
|
|
3127
|
-
/**
|
|
3133
|
+
/**
|
|
3134
|
+
* The tags rendered into <head>, in no particular order. Render order is
|
|
3135
|
+
* decided by the renderer, not by position in this list.
|
|
3136
|
+
*
|
|
3137
|
+
* No maxSize: this list is already populated by data written years ago, and
|
|
3138
|
+
* a bound added now could reject a page that is already stored.
|
|
3139
|
+
*/
|
|
3128
3140
|
tags?: Tag[];
|
|
3129
|
-
/** SEO
|
|
3141
|
+
/** Page-level SEO settings that are not themselves tags. */
|
|
3130
3142
|
settings?: Settings;
|
|
3131
3143
|
}
|
|
3144
|
+
/** A keyword term the user is targeting. */
|
|
3132
3145
|
interface Keyword {
|
|
3133
|
-
/**
|
|
3146
|
+
/**
|
|
3147
|
+
* The term itself, e.g. "trail running shoes".
|
|
3148
|
+
*
|
|
3149
|
+
* No maxLength, for the same reason as the legacy tag fields: keywords are
|
|
3150
|
+
* already stored, and a bound added now could reject a record written
|
|
3151
|
+
* before the bound existed. The flynt `missing-string-validations` warning
|
|
3152
|
+
* on this field is accepted deliberately.
|
|
3153
|
+
*/
|
|
3134
3154
|
term?: string;
|
|
3135
|
-
/** Whether
|
|
3155
|
+
/** Whether this is the page's primary focus keyword. At most one per page. */
|
|
3136
3156
|
isMain?: boolean;
|
|
3137
3157
|
/**
|
|
3138
|
-
*
|
|
3158
|
+
* Which surface added the term, e.g. a panel or a suggestion flow. Used for
|
|
3159
|
+
* attribution in BI. Opaque to the renderer.
|
|
3139
3160
|
* @maxLength 1000
|
|
3140
3161
|
*/
|
|
3141
3162
|
origin?: string | null;
|
|
3142
3163
|
}
|
|
3164
|
+
/**
|
|
3165
|
+
* One tag in the page's <head>.
|
|
3166
|
+
*
|
|
3167
|
+
* Not deprecated, and with no removal date, deliberately: stored data is
|
|
3168
|
+
* never migrated, so this shape stays valid input forever. `seo-renderer`
|
|
3169
|
+
* normalizes both shapes on READ.
|
|
3170
|
+
*/
|
|
3143
3171
|
interface Tag {
|
|
3144
3172
|
/**
|
|
3145
|
-
*
|
|
3146
|
-
*
|
|
3173
|
+
* Legacy. Was a free-form string: "title" | "meta" | "script" | "link".
|
|
3174
|
+
* The typed replacement is the `kind` oneof on `SeoSchemaV2.Tag`, which makes
|
|
3175
|
+
* the invalid combinations unrepresentable rather than merely discouraged.
|
|
3147
3176
|
*
|
|
3148
|
-
*
|
|
3149
|
-
*
|
|
3150
|
-
*
|
|
3151
|
-
*
|
|
3152
|
-
*
|
|
3153
|
-
* `
|
|
3154
|
-
* check the field description of the specific `tags`-typed field you're writing to
|
|
3155
|
-
* for the types it actually supports and the error it returns.
|
|
3177
|
+
* Which of these an API actually accepts depends on where the tag is being
|
|
3178
|
+
* set: this list is not a blanket guarantee across every API that reuses
|
|
3179
|
+
* this message. Site SEO Tags in particular accepts only `meta` (see
|
|
3180
|
+
* `SiteSeoTags.tags`) and rejects `title`/`script`/`link` with a validation
|
|
3181
|
+
* error even though they appear here — check the field description of the
|
|
3182
|
+
* specific `tags`-typed field you are writing to.
|
|
3156
3183
|
*
|
|
3157
3184
|
* Limitation: `title` and `script` (e.g. a `script` tag with `props.type`
|
|
3158
|
-
*
|
|
3159
|
-
* `custom` is unset or `false`. Setting `custom: true` on a `title` or
|
|
3160
|
-
* tag is rejected with `TAG_TYPE_NOT_ALLOWED`, because
|
|
3161
|
-
* write through the site's Advanced/Custom Tags
|
|
3162
|
-
* omit `custom` (or set it to `false`).
|
|
3185
|
+
* "application/ld+json" carrying structured data) are supported only when
|
|
3186
|
+
* `custom` is unset or `false`. Setting `custom: true` on a `title` or
|
|
3187
|
+
* `script` tag is rejected with `TAG_TYPE_NOT_ALLOWED`, because
|
|
3188
|
+
* `custom: true` routes the write through the site's Advanced/Custom Tags
|
|
3189
|
+
* list. To write structured data, omit `custom` (or set it to `false`).
|
|
3190
|
+
*
|
|
3191
|
+
* No length limit: this field holds data written years ago by writers we
|
|
3192
|
+
* are not migrating. A constraint here could reject a record that is
|
|
3193
|
+
* already stored, which is exactly the promise this design makes.
|
|
3163
3194
|
*/
|
|
3164
3195
|
type?: string;
|
|
3165
3196
|
/**
|
|
3166
|
-
*
|
|
3167
|
-
*
|
|
3197
|
+
* Legacy. Was an untyped bag of HTML attributes.
|
|
3198
|
+
* Typed replacement: `SeoSchemaV2.TitleTag` / `MetaTag` / `LinkTag`.
|
|
3168
3199
|
*/
|
|
3169
3200
|
props?: Record<string, any> | null;
|
|
3170
|
-
/**
|
|
3201
|
+
/**
|
|
3202
|
+
* Legacy. Was an untyped bag of 16 mixed-purpose keys. In `SeoSchemaV2`
|
|
3203
|
+
* its contents are split by purpose: per-page structured-data state moves to
|
|
3204
|
+
* StructuredDataTag, authorship to `written_by`, and render-time preset
|
|
3205
|
+
* logic (variants, enabledByExperiment, removeSchemaIf*) moved out of the
|
|
3206
|
+
* stored document entirely — it belongs to the preset definition, not to the
|
|
3207
|
+
* page. See the design log for the full key-by-key mapping.
|
|
3208
|
+
*/
|
|
3171
3209
|
meta?: Record<string, any> | null;
|
|
3172
|
-
/**
|
|
3210
|
+
/**
|
|
3211
|
+
* Legacy. Was the tag's inner content, doubling as the JSON-LD payload
|
|
3212
|
+
* for script tags. Typed replacement: `SeoSchemaV2.TitleTag.text` and
|
|
3213
|
+
* `StructuredDataTag.json_ld`.
|
|
3214
|
+
* No length limit, for the same reason as `type` above.
|
|
3215
|
+
*/
|
|
3173
3216
|
children?: string;
|
|
3174
3217
|
/**
|
|
3175
3218
|
* Whether the tag is a [custom tag](https://support.wix.com/en/article/adding-additional-meta-tags-to-your-sites-pages) —
|
|
3176
3219
|
* i.e. an entry from the site's Advanced/Custom Tags list.
|
|
3177
3220
|
*
|
|
3178
|
-
* Setting this to `true` on a write restricts which `type` values are
|
|
3179
|
-
* — the same restriction the Advanced/Custom Tags UI enforces.
|
|
3180
|
-
* `script` tags (including JSON-LD structured data) must be sent
|
|
3181
|
-
* omitted or `false`; sending them with `custom: true` is
|
|
3182
|
-
* `TAG_TYPE_NOT_ALLOWED`.
|
|
3221
|
+
* Setting this to `true` on a write restricts which `type` values are
|
|
3222
|
+
* accepted — the same restriction the Advanced/Custom Tags UI enforces.
|
|
3223
|
+
* `title` and `script` tags (including JSON-LD structured data) must be sent
|
|
3224
|
+
* with `custom` omitted or `false`; sending them with `custom: true` is
|
|
3225
|
+
* rejected with `TAG_TYPE_NOT_ALLOWED`.
|
|
3183
3226
|
*
|
|
3184
|
-
* Note this is a separate restriction from Site SEO Tags' own type
|
|
3185
|
-
* `SiteSeoTags.tags`: even with `custom` unset, Site SEO Tags
|
|
3186
|
-
* for site-wide structured data) unconditionally.
|
|
3187
|
-
* site-wide, every-page structured data
|
|
3188
|
-
* `script` tag through the Item
|
|
3227
|
+
* Note this is a separate restriction from Site SEO Tags' own type
|
|
3228
|
+
* restriction on `SiteSeoTags.tags`: even with `custom` unset, Site SEO Tags
|
|
3229
|
+
* rejects `script` (e.g. for site-wide structured data) unconditionally.
|
|
3230
|
+
* There is currently no way to set site-wide, every-page structured data
|
|
3231
|
+
* through any of these APIs — write a per-page `script` tag through the Item
|
|
3232
|
+
* SEO Tags API instead.
|
|
3189
3233
|
*
|
|
3190
3234
|
* This flag is scoped to that feature only. It is NOT an indicator of whether a standard tag
|
|
3191
3235
|
* (`title`, `description`, Open Graph, etc.) reflects a manually configured value versus a computed
|
|
@@ -3198,22 +3242,39 @@ interface Tag {
|
|
|
3198
3242
|
* or Wix Studio pages, so even genuine Advanced/Custom Tags saved on those pages are missing from the
|
|
3199
3243
|
* response entirely — there, `false` means this API could not tell, not that no custom tag exists.
|
|
3200
3244
|
* Pass `seoData` explicitly to resolve against a known set of tags.
|
|
3245
|
+
*
|
|
3246
|
+
* `SeoSchemaV2.Tag` expresses this as `written_by = USER_CUSTOM`.
|
|
3201
3247
|
*/
|
|
3202
3248
|
custom?: boolean;
|
|
3203
|
-
/**
|
|
3249
|
+
/**
|
|
3250
|
+
* Whether the tag is excluded from the rendered <head>.
|
|
3251
|
+
*
|
|
3252
|
+
* A disabled tag is still stored, so the user can re-enable it and so a
|
|
3253
|
+
* pattern-provided tag stays suppressed on this page. Default false.
|
|
3254
|
+
*/
|
|
3204
3255
|
disabled?: boolean;
|
|
3205
3256
|
}
|
|
3257
|
+
/** Page-level SEO settings that are not tags. */
|
|
3206
3258
|
interface Settings {
|
|
3207
3259
|
/**
|
|
3208
|
-
* Whether the
|
|
3260
|
+
* Whether to suppress the automatic redirect from this page's previous URL to
|
|
3261
|
+
* its current one after a slug change.
|
|
3209
3262
|
*
|
|
3210
|
-
*
|
|
3211
|
-
*
|
|
3263
|
+
* Default false, meaning the redirect IS created. The field is named for the
|
|
3264
|
+
* exception rather than the rule, which reads backwards; kept as-is because
|
|
3265
|
+
* renaming a stored boolean is not worth the migration.
|
|
3212
3266
|
*/
|
|
3213
3267
|
preventAutoRedirect?: boolean;
|
|
3214
3268
|
/**
|
|
3215
|
-
*
|
|
3216
|
-
*
|
|
3269
|
+
* Keyword terms the user is targeting for this page. Used by the SEO
|
|
3270
|
+
* assistant and checklist; never rendered into <head>.
|
|
3271
|
+
*
|
|
3272
|
+
* 20 is a sanity bound, not the product limit. v1 declared 5 — the number
|
|
3273
|
+
* the panel happens to allow today — which is exactly the mistake we are
|
|
3274
|
+
* fixing for structured data. A product decision to allow 8 should not need
|
|
3275
|
+
* a proto release, so the panel owns that number and the proto only stops
|
|
3276
|
+
* something absurd.
|
|
3277
|
+
* @maxSize 20
|
|
3217
3278
|
*/
|
|
3218
3279
|
keywords?: Keyword[];
|
|
3219
3280
|
}
|
|
@@ -3328,6 +3389,10 @@ interface DraftPostTranslation {
|
|
|
3328
3389
|
/** Post URL. */
|
|
3329
3390
|
url?: PageUrl;
|
|
3330
3391
|
}
|
|
3392
|
+
interface InitialDraftPostsCopied {
|
|
3393
|
+
/** Number of draft posts copied. */
|
|
3394
|
+
count?: number;
|
|
3395
|
+
}
|
|
3331
3396
|
interface DraftCategoriesUpdated {
|
|
3332
3397
|
/**
|
|
3333
3398
|
* Draft post ID.
|
|
@@ -3366,202 +3431,6 @@ interface DraftTagsUpdated {
|
|
|
3366
3431
|
*/
|
|
3367
3432
|
previousTags?: string[];
|
|
3368
3433
|
}
|
|
3369
|
-
interface GetDraftPostTotalsRequest {
|
|
3370
|
-
/**
|
|
3371
|
-
* Group results by fields (defaults to grouping by status).
|
|
3372
|
-
* If, for example, grouping by language is passed, language values in response will be filled.
|
|
3373
|
-
* If, for example, grouping by language is not passed, null values will be filled in language field in response.
|
|
3374
|
-
* @maxSize 10
|
|
3375
|
-
*/
|
|
3376
|
-
groupBy?: TotalDraftPostsGroupingFieldWithLiterals[];
|
|
3377
|
-
/**
|
|
3378
|
-
* Optional language filter by provided language code. Useful in multilingual context.
|
|
3379
|
-
* @format LANGUAGE_TAG
|
|
3380
|
-
*/
|
|
3381
|
-
language?: string | null;
|
|
3382
|
-
}
|
|
3383
|
-
declare enum TotalDraftPostsGroupingField {
|
|
3384
|
-
/** Groups results by status. */
|
|
3385
|
-
STATUS = "STATUS",
|
|
3386
|
-
/** Groups results by language. */
|
|
3387
|
-
LANGUAGE = "LANGUAGE"
|
|
3388
|
-
}
|
|
3389
|
-
/** @enumType */
|
|
3390
|
-
type TotalDraftPostsGroupingFieldWithLiterals = TotalDraftPostsGroupingField | 'STATUS' | 'LANGUAGE';
|
|
3391
|
-
interface GetDraftPostTotalsResponse {
|
|
3392
|
-
/** Draft post totals. */
|
|
3393
|
-
totalDraftPosts?: TotalDraftPosts[];
|
|
3394
|
-
}
|
|
3395
|
-
interface TotalDraftPosts {
|
|
3396
|
-
/** Draft post totals in that group. */
|
|
3397
|
-
total?: number;
|
|
3398
|
-
/** Draft post status (only has value when grouping by status, otherwise null). */
|
|
3399
|
-
status?: StatusWithLiterals;
|
|
3400
|
-
/**
|
|
3401
|
-
* Draft post language code (only has value when grouping by language, otherwise null).
|
|
3402
|
-
* @format LANGUAGE_TAG
|
|
3403
|
-
*/
|
|
3404
|
-
language?: string | null;
|
|
3405
|
-
}
|
|
3406
|
-
interface DomainEvent extends DomainEventBodyOneOf {
|
|
3407
|
-
createdEvent?: EntityCreatedEvent;
|
|
3408
|
-
updatedEvent?: EntityUpdatedEvent;
|
|
3409
|
-
deletedEvent?: EntityDeletedEvent;
|
|
3410
|
-
actionEvent?: ActionEvent;
|
|
3411
|
-
/** Event ID. With this ID you can easily spot duplicated events and ignore them. */
|
|
3412
|
-
id?: string;
|
|
3413
|
-
/**
|
|
3414
|
-
* Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities.
|
|
3415
|
-
* For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`.
|
|
3416
|
-
*/
|
|
3417
|
-
entityFqdn?: string;
|
|
3418
|
-
/**
|
|
3419
|
-
* Event action name, placed at the top level to make it easier for users to dispatch messages.
|
|
3420
|
-
* For example: `created`/`updated`/`deleted`/`started`/`completed`/`email_opened`.
|
|
3421
|
-
*/
|
|
3422
|
-
slug?: string;
|
|
3423
|
-
/** ID of the entity associated with the event. */
|
|
3424
|
-
entityId?: string;
|
|
3425
|
-
/** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example, `2020-04-26T13:57:50.699Z`. */
|
|
3426
|
-
eventTime?: Date | null;
|
|
3427
|
-
/**
|
|
3428
|
-
* Whether the event was triggered as a result of a privacy regulation application
|
|
3429
|
-
* (for example, GDPR).
|
|
3430
|
-
*/
|
|
3431
|
-
triggeredByAnonymizeRequest?: boolean | null;
|
|
3432
|
-
/** If present, indicates the action that triggered the event. */
|
|
3433
|
-
originatedFrom?: string | null;
|
|
3434
|
-
/**
|
|
3435
|
-
* 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.
|
|
3436
|
-
* 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.
|
|
3437
|
-
*/
|
|
3438
|
-
entityEventSequence?: string | null;
|
|
3439
|
-
}
|
|
3440
|
-
/** @oneof */
|
|
3441
|
-
interface DomainEventBodyOneOf {
|
|
3442
|
-
createdEvent?: EntityCreatedEvent;
|
|
3443
|
-
updatedEvent?: EntityUpdatedEvent;
|
|
3444
|
-
deletedEvent?: EntityDeletedEvent;
|
|
3445
|
-
actionEvent?: ActionEvent;
|
|
3446
|
-
}
|
|
3447
|
-
interface EntityCreatedEvent {
|
|
3448
|
-
entityAsJson?: string;
|
|
3449
|
-
/** Indicates the event was triggered by a restore-from-trashbin operation for a previously deleted entity */
|
|
3450
|
-
restoreInfo?: RestoreInfo;
|
|
3451
|
-
}
|
|
3452
|
-
interface RestoreInfo {
|
|
3453
|
-
deletedDate?: Date | null;
|
|
3454
|
-
}
|
|
3455
|
-
interface EntityUpdatedEvent {
|
|
3456
|
-
/**
|
|
3457
|
-
* Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.
|
|
3458
|
-
* This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.
|
|
3459
|
-
* We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.
|
|
3460
|
-
*/
|
|
3461
|
-
currentEntityAsJson?: string;
|
|
3462
|
-
}
|
|
3463
|
-
interface EntityDeletedEvent {
|
|
3464
|
-
/** Entity that was deleted. */
|
|
3465
|
-
deletedEntityAsJson?: string | null;
|
|
3466
|
-
}
|
|
3467
|
-
interface ActionEvent {
|
|
3468
|
-
bodyAsJson?: string;
|
|
3469
|
-
}
|
|
3470
|
-
interface MessageEnvelope {
|
|
3471
|
-
/**
|
|
3472
|
-
* App instance ID.
|
|
3473
|
-
* @format GUID
|
|
3474
|
-
*/
|
|
3475
|
-
instanceId?: string | null;
|
|
3476
|
-
/**
|
|
3477
|
-
* Event type.
|
|
3478
|
-
* @maxLength 150
|
|
3479
|
-
*/
|
|
3480
|
-
eventType?: string;
|
|
3481
|
-
/** The identification type and identity data. */
|
|
3482
|
-
identity?: IdentificationData;
|
|
3483
|
-
/** Stringify payload. */
|
|
3484
|
-
data?: string;
|
|
3485
|
-
/** Details related to the account */
|
|
3486
|
-
accountInfo?: AccountInfo;
|
|
3487
|
-
}
|
|
3488
|
-
interface IdentificationData extends IdentificationDataIdOneOf {
|
|
3489
|
-
/**
|
|
3490
|
-
* ID of a site visitor that has not logged in to the site.
|
|
3491
|
-
* @format GUID
|
|
3492
|
-
*/
|
|
3493
|
-
anonymousVisitorId?: string;
|
|
3494
|
-
/**
|
|
3495
|
-
* ID of a site visitor that has logged in to the site.
|
|
3496
|
-
* @format GUID
|
|
3497
|
-
*/
|
|
3498
|
-
memberId?: string;
|
|
3499
|
-
/**
|
|
3500
|
-
* ID of a Wix user (site owner, contributor, etc.).
|
|
3501
|
-
* @format GUID
|
|
3502
|
-
*/
|
|
3503
|
-
wixUserId?: string;
|
|
3504
|
-
/**
|
|
3505
|
-
* ID of an app.
|
|
3506
|
-
* @format GUID
|
|
3507
|
-
*/
|
|
3508
|
-
appId?: string;
|
|
3509
|
-
/** @readonly */
|
|
3510
|
-
identityType?: WebhookIdentityTypeWithLiterals;
|
|
3511
|
-
}
|
|
3512
|
-
/** @oneof */
|
|
3513
|
-
interface IdentificationDataIdOneOf {
|
|
3514
|
-
/**
|
|
3515
|
-
* ID of a site visitor that has not logged in to the site.
|
|
3516
|
-
* @format GUID
|
|
3517
|
-
*/
|
|
3518
|
-
anonymousVisitorId?: string;
|
|
3519
|
-
/**
|
|
3520
|
-
* ID of a site visitor that has logged in to the site.
|
|
3521
|
-
* @format GUID
|
|
3522
|
-
*/
|
|
3523
|
-
memberId?: string;
|
|
3524
|
-
/**
|
|
3525
|
-
* ID of a Wix user (site owner, contributor, etc.).
|
|
3526
|
-
* @format GUID
|
|
3527
|
-
*/
|
|
3528
|
-
wixUserId?: string;
|
|
3529
|
-
/**
|
|
3530
|
-
* ID of an app.
|
|
3531
|
-
* @format GUID
|
|
3532
|
-
*/
|
|
3533
|
-
appId?: string;
|
|
3534
|
-
}
|
|
3535
|
-
declare enum WebhookIdentityType {
|
|
3536
|
-
UNKNOWN = "UNKNOWN",
|
|
3537
|
-
ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR",
|
|
3538
|
-
MEMBER = "MEMBER",
|
|
3539
|
-
WIX_USER = "WIX_USER",
|
|
3540
|
-
APP = "APP"
|
|
3541
|
-
}
|
|
3542
|
-
/** @enumType */
|
|
3543
|
-
type WebhookIdentityTypeWithLiterals = WebhookIdentityType | 'UNKNOWN' | 'ANONYMOUS_VISITOR' | 'MEMBER' | 'WIX_USER' | 'APP';
|
|
3544
|
-
interface AccountInfo {
|
|
3545
|
-
/**
|
|
3546
|
-
* ID of the Wix account associated with the event.
|
|
3547
|
-
* @format GUID
|
|
3548
|
-
*/
|
|
3549
|
-
accountId?: string | null;
|
|
3550
|
-
/**
|
|
3551
|
-
* ID of the parent Wix account. Only included when accountId belongs to a child account.
|
|
3552
|
-
* @format GUID
|
|
3553
|
-
*/
|
|
3554
|
-
parentAccountId?: string | null;
|
|
3555
|
-
/**
|
|
3556
|
-
* ID of the Wix site associated with the event. Only included when the event is tied to a specific site.
|
|
3557
|
-
* @format GUID
|
|
3558
|
-
*/
|
|
3559
|
-
siteId?: string | null;
|
|
3560
|
-
}
|
|
3561
|
-
interface InitialDraftPostsCopied {
|
|
3562
|
-
/** Number of draft posts copied. */
|
|
3563
|
-
count?: number;
|
|
3564
|
-
}
|
|
3565
3434
|
interface CreateDraftPostRequest {
|
|
3566
3435
|
/** Draft post to create. */
|
|
3567
3436
|
draftPost: DraftPost;
|
|
@@ -4142,116 +4011,197 @@ interface DraftPostCount {
|
|
|
4142
4011
|
/** Number of posts. */
|
|
4143
4012
|
postCount?: number;
|
|
4144
4013
|
}
|
|
4145
|
-
interface
|
|
4014
|
+
interface DomainEvent extends DomainEventBodyOneOf {
|
|
4015
|
+
createdEvent?: EntityCreatedEvent;
|
|
4016
|
+
updatedEvent?: EntityUpdatedEvent;
|
|
4017
|
+
deletedEvent?: EntityDeletedEvent;
|
|
4018
|
+
actionEvent?: ActionEvent;
|
|
4019
|
+
/** Event ID. With this ID you can easily spot duplicated events and ignore them. */
|
|
4020
|
+
id?: string;
|
|
4146
4021
|
/**
|
|
4147
|
-
*
|
|
4148
|
-
*
|
|
4149
|
-
* @maxSize 100
|
|
4150
|
-
* @format GUID
|
|
4022
|
+
* Fully Qualified Domain Name of an entity. This is a unique identifier assigned to the API main business entities.
|
|
4023
|
+
* For example, `wix.stores.catalog.product`, `wix.bookings.session`, `wix.payments.transaction`.
|
|
4151
4024
|
*/
|
|
4152
|
-
|
|
4153
|
-
/** Should full draft post be returned. */
|
|
4154
|
-
returnFullEntity?: boolean;
|
|
4155
|
-
}
|
|
4156
|
-
interface BulkRevertToUnpublishedResponse {
|
|
4157
|
-
/** Bulk action results. */
|
|
4158
|
-
results?: BulkDraftPostResult[];
|
|
4159
|
-
/** Bulk action metadata. */
|
|
4160
|
-
bulkActionMetadata?: BulkActionMetadata;
|
|
4161
|
-
}
|
|
4162
|
-
interface BulkRejectDraftPostRequest {
|
|
4025
|
+
entityFqdn?: string;
|
|
4163
4026
|
/**
|
|
4164
|
-
*
|
|
4165
|
-
*
|
|
4166
|
-
|
|
4167
|
-
|
|
4168
|
-
|
|
4169
|
-
|
|
4170
|
-
/**
|
|
4171
|
-
|
|
4027
|
+
* Event action name, placed at the top level to make it easier for users to dispatch messages.
|
|
4028
|
+
* For example: `created`/`updated`/`deleted`/`started`/`completed`/`email_opened`.
|
|
4029
|
+
*/
|
|
4030
|
+
slug?: string;
|
|
4031
|
+
/** ID of the entity associated with the event. */
|
|
4032
|
+
entityId?: string;
|
|
4033
|
+
/** Event timestamp in [ISO-8601](https://en.wikipedia.org/wiki/ISO_8601) format and UTC time. For example, `2020-04-26T13:57:50.699Z`. */
|
|
4034
|
+
eventTime?: Date | null;
|
|
4035
|
+
/**
|
|
4036
|
+
* Whether the event was triggered as a result of a privacy regulation application
|
|
4037
|
+
* (for example, GDPR).
|
|
4038
|
+
*/
|
|
4039
|
+
triggeredByAnonymizeRequest?: boolean | null;
|
|
4040
|
+
/** If present, indicates the action that triggered the event. */
|
|
4041
|
+
originatedFrom?: string | null;
|
|
4042
|
+
/**
|
|
4043
|
+
* 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.
|
|
4044
|
+
* 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.
|
|
4045
|
+
*/
|
|
4046
|
+
entityEventSequence?: string | null;
|
|
4172
4047
|
}
|
|
4173
|
-
|
|
4174
|
-
|
|
4175
|
-
|
|
4176
|
-
|
|
4177
|
-
|
|
4048
|
+
/** @oneof */
|
|
4049
|
+
interface DomainEventBodyOneOf {
|
|
4050
|
+
createdEvent?: EntityCreatedEvent;
|
|
4051
|
+
updatedEvent?: EntityUpdatedEvent;
|
|
4052
|
+
deletedEvent?: EntityDeletedEvent;
|
|
4053
|
+
actionEvent?: ActionEvent;
|
|
4178
4054
|
}
|
|
4179
|
-
interface
|
|
4055
|
+
interface EntityCreatedEvent {
|
|
4056
|
+
entityAsJson?: string;
|
|
4057
|
+
/** Indicates the event was triggered by a restore-from-trashbin operation for a previously deleted entity */
|
|
4058
|
+
restoreInfo?: RestoreInfo;
|
|
4059
|
+
}
|
|
4060
|
+
interface RestoreInfo {
|
|
4061
|
+
deletedDate?: Date | null;
|
|
4062
|
+
}
|
|
4063
|
+
interface EntityUpdatedEvent {
|
|
4180
4064
|
/**
|
|
4181
|
-
*
|
|
4065
|
+
* Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.
|
|
4066
|
+
* This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.
|
|
4067
|
+
* We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.
|
|
4068
|
+
*/
|
|
4069
|
+
currentEntityAsJson?: string;
|
|
4070
|
+
}
|
|
4071
|
+
interface EntityDeletedEvent {
|
|
4072
|
+
/** Entity that was deleted. */
|
|
4073
|
+
deletedEntityAsJson?: string | null;
|
|
4074
|
+
}
|
|
4075
|
+
interface ActionEvent {
|
|
4076
|
+
bodyAsJson?: string;
|
|
4077
|
+
}
|
|
4078
|
+
interface MessageEnvelope {
|
|
4079
|
+
/**
|
|
4080
|
+
* App instance ID.
|
|
4182
4081
|
* @format GUID
|
|
4183
4082
|
*/
|
|
4184
|
-
|
|
4083
|
+
instanceId?: string | null;
|
|
4185
4084
|
/**
|
|
4186
|
-
*
|
|
4187
|
-
*
|
|
4188
|
-
* Example: When URL fieldset is selected, returned draft post will have a set of base properties and draft post preview url.
|
|
4189
|
-
* @maxSize 10
|
|
4085
|
+
* Event type.
|
|
4086
|
+
* @maxLength 150
|
|
4190
4087
|
*/
|
|
4191
|
-
|
|
4192
|
-
|
|
4193
|
-
|
|
4194
|
-
/**
|
|
4195
|
-
|
|
4088
|
+
eventType?: string;
|
|
4089
|
+
/** The identification type and identity data. */
|
|
4090
|
+
identity?: IdentificationData;
|
|
4091
|
+
/** Stringify payload. */
|
|
4092
|
+
data?: string;
|
|
4093
|
+
/** Details related to the account */
|
|
4094
|
+
accountInfo?: AccountInfo;
|
|
4196
4095
|
}
|
|
4197
|
-
interface
|
|
4096
|
+
interface IdentificationData extends IdentificationDataIdOneOf {
|
|
4198
4097
|
/**
|
|
4199
|
-
*
|
|
4098
|
+
* ID of a site visitor that has not logged in to the site.
|
|
4200
4099
|
* @format GUID
|
|
4201
4100
|
*/
|
|
4202
|
-
|
|
4101
|
+
anonymousVisitorId?: string;
|
|
4203
4102
|
/**
|
|
4204
|
-
*
|
|
4205
|
-
*
|
|
4206
|
-
* Example: When URL fieldset is selected, returned draft post will have a set of base properties and draft post preview url.
|
|
4207
|
-
* @maxSize 10
|
|
4103
|
+
* ID of a site visitor that has logged in to the site.
|
|
4104
|
+
* @format GUID
|
|
4208
4105
|
*/
|
|
4209
|
-
|
|
4210
|
-
|
|
4211
|
-
|
|
4212
|
-
|
|
4213
|
-
|
|
4106
|
+
memberId?: string;
|
|
4107
|
+
/**
|
|
4108
|
+
* ID of a Wix user (site owner, contributor, etc.).
|
|
4109
|
+
* @format GUID
|
|
4110
|
+
*/
|
|
4111
|
+
wixUserId?: string;
|
|
4112
|
+
/**
|
|
4113
|
+
* ID of an app.
|
|
4114
|
+
* @format GUID
|
|
4115
|
+
*/
|
|
4116
|
+
appId?: string;
|
|
4117
|
+
/** @readonly */
|
|
4118
|
+
identityType?: WebhookIdentityTypeWithLiterals;
|
|
4214
4119
|
}
|
|
4215
|
-
|
|
4120
|
+
/** @oneof */
|
|
4121
|
+
interface IdentificationDataIdOneOf {
|
|
4216
4122
|
/**
|
|
4217
|
-
*
|
|
4123
|
+
* ID of a site visitor that has not logged in to the site.
|
|
4218
4124
|
* @format GUID
|
|
4219
4125
|
*/
|
|
4220
|
-
|
|
4126
|
+
anonymousVisitorId?: string;
|
|
4221
4127
|
/**
|
|
4222
|
-
*
|
|
4223
|
-
* @
|
|
4128
|
+
* ID of a site visitor that has logged in to the site.
|
|
4129
|
+
* @format GUID
|
|
4224
4130
|
*/
|
|
4225
|
-
|
|
4131
|
+
memberId?: string;
|
|
4226
4132
|
/**
|
|
4227
|
-
*
|
|
4228
|
-
*
|
|
4229
|
-
* Example: When URL fieldset is selected, returned draft post will have a set of base properties and draft post preview url.
|
|
4230
|
-
* @maxSize 10
|
|
4133
|
+
* ID of a Wix user (site owner, contributor, etc.).
|
|
4134
|
+
* @format GUID
|
|
4231
4135
|
*/
|
|
4232
|
-
|
|
4136
|
+
wixUserId?: string;
|
|
4137
|
+
/**
|
|
4138
|
+
* ID of an app.
|
|
4139
|
+
* @format GUID
|
|
4140
|
+
*/
|
|
4141
|
+
appId?: string;
|
|
4233
4142
|
}
|
|
4234
|
-
|
|
4235
|
-
|
|
4236
|
-
|
|
4143
|
+
declare enum WebhookIdentityType {
|
|
4144
|
+
UNKNOWN = "UNKNOWN",
|
|
4145
|
+
ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR",
|
|
4146
|
+
MEMBER = "MEMBER",
|
|
4147
|
+
WIX_USER = "WIX_USER",
|
|
4148
|
+
APP = "APP"
|
|
4237
4149
|
}
|
|
4238
|
-
|
|
4150
|
+
/** @enumType */
|
|
4151
|
+
type WebhookIdentityTypeWithLiterals = WebhookIdentityType | 'UNKNOWN' | 'ANONYMOUS_VISITOR' | 'MEMBER' | 'WIX_USER' | 'APP';
|
|
4152
|
+
interface AccountInfo {
|
|
4239
4153
|
/**
|
|
4240
|
-
*
|
|
4241
|
-
* @
|
|
4154
|
+
* ID of the Wix account associated with the event.
|
|
4155
|
+
* @format GUID
|
|
4242
4156
|
*/
|
|
4243
|
-
|
|
4157
|
+
accountId?: string | null;
|
|
4244
4158
|
/**
|
|
4245
|
-
*
|
|
4246
|
-
*
|
|
4247
|
-
|
|
4159
|
+
* ID of the parent Wix account. Only included when accountId belongs to a child account.
|
|
4160
|
+
* @format GUID
|
|
4161
|
+
*/
|
|
4162
|
+
parentAccountId?: string | null;
|
|
4163
|
+
/**
|
|
4164
|
+
* ID of the Wix site associated with the event. Only included when the event is tied to a specific site.
|
|
4165
|
+
* @format GUID
|
|
4166
|
+
*/
|
|
4167
|
+
siteId?: string | null;
|
|
4168
|
+
}
|
|
4169
|
+
interface GetDraftPostTotalsRequest {
|
|
4170
|
+
/**
|
|
4171
|
+
* Group results by fields (defaults to grouping by status).
|
|
4172
|
+
* If, for example, grouping by language is passed, language values in response will be filled.
|
|
4173
|
+
* If, for example, grouping by language is not passed, null values will be filled in language field in response.
|
|
4248
4174
|
* @maxSize 10
|
|
4249
4175
|
*/
|
|
4250
|
-
|
|
4176
|
+
groupBy?: TotalDraftPostsGroupingFieldWithLiterals[];
|
|
4177
|
+
/**
|
|
4178
|
+
* Optional language filter by provided language code. Useful in multilingual context.
|
|
4179
|
+
* @format LANGUAGE_TAG
|
|
4180
|
+
*/
|
|
4181
|
+
language?: string | null;
|
|
4251
4182
|
}
|
|
4252
|
-
|
|
4253
|
-
/**
|
|
4254
|
-
|
|
4183
|
+
declare enum TotalDraftPostsGroupingField {
|
|
4184
|
+
/** Groups results by status. */
|
|
4185
|
+
STATUS = "STATUS",
|
|
4186
|
+
/** Groups results by language. */
|
|
4187
|
+
LANGUAGE = "LANGUAGE"
|
|
4188
|
+
}
|
|
4189
|
+
/** @enumType */
|
|
4190
|
+
type TotalDraftPostsGroupingFieldWithLiterals = TotalDraftPostsGroupingField | 'STATUS' | 'LANGUAGE';
|
|
4191
|
+
interface GetDraftPostTotalsResponse {
|
|
4192
|
+
/** Draft post totals. */
|
|
4193
|
+
totalDraftPosts?: TotalDraftPosts[];
|
|
4194
|
+
}
|
|
4195
|
+
interface TotalDraftPosts {
|
|
4196
|
+
/** Draft post totals in that group. */
|
|
4197
|
+
total?: number;
|
|
4198
|
+
/** Draft post status (only has value when grouping by status, otherwise null). */
|
|
4199
|
+
status?: StatusWithLiterals;
|
|
4200
|
+
/**
|
|
4201
|
+
* Draft post language code (only has value when grouping by language, otherwise null).
|
|
4202
|
+
* @format LANGUAGE_TAG
|
|
4203
|
+
*/
|
|
4204
|
+
language?: string | null;
|
|
4255
4205
|
}
|
|
4256
4206
|
interface TranslateDraftRequest {
|
|
4257
4207
|
/**
|
|
@@ -4338,6 +4288,117 @@ interface UpdateDraftPostLanguageResponse {
|
|
|
4338
4288
|
/** Updated draft post. */
|
|
4339
4289
|
draftPost?: DraftPost;
|
|
4340
4290
|
}
|
|
4291
|
+
interface BulkRevertToUnpublishedRequest {
|
|
4292
|
+
/**
|
|
4293
|
+
* Source post IDs.
|
|
4294
|
+
* @minSize 1
|
|
4295
|
+
* @maxSize 100
|
|
4296
|
+
* @format GUID
|
|
4297
|
+
*/
|
|
4298
|
+
postIds?: string[];
|
|
4299
|
+
/** Should full draft post be returned. */
|
|
4300
|
+
returnFullEntity?: boolean;
|
|
4301
|
+
}
|
|
4302
|
+
interface BulkRevertToUnpublishedResponse {
|
|
4303
|
+
/** Bulk action results. */
|
|
4304
|
+
results?: BulkDraftPostResult[];
|
|
4305
|
+
/** Bulk action metadata. */
|
|
4306
|
+
bulkActionMetadata?: BulkActionMetadata;
|
|
4307
|
+
}
|
|
4308
|
+
interface BulkRejectDraftPostRequest {
|
|
4309
|
+
/**
|
|
4310
|
+
* Source post IDs.
|
|
4311
|
+
* @minSize 1
|
|
4312
|
+
* @maxSize 100
|
|
4313
|
+
* @format GUID
|
|
4314
|
+
*/
|
|
4315
|
+
postIds?: string[];
|
|
4316
|
+
/** Should full draft post be returned. */
|
|
4317
|
+
returnFullEntity?: boolean;
|
|
4318
|
+
}
|
|
4319
|
+
interface BulkRejectDraftPostResponse {
|
|
4320
|
+
/** Bulk action results. */
|
|
4321
|
+
results?: BulkDraftPostResult[];
|
|
4322
|
+
/** Bulk action metadata. */
|
|
4323
|
+
bulkActionMetadata?: BulkActionMetadata;
|
|
4324
|
+
}
|
|
4325
|
+
interface RevertToUnpublishedRequest {
|
|
4326
|
+
/**
|
|
4327
|
+
* Source post ID.
|
|
4328
|
+
* @format GUID
|
|
4329
|
+
*/
|
|
4330
|
+
postId?: string;
|
|
4331
|
+
/**
|
|
4332
|
+
* List of draft post fields to be included if entities are present in the response.
|
|
4333
|
+
* Base fieldset, which is default, will return all core draft post properties.
|
|
4334
|
+
* Example: When URL fieldset is selected, returned draft post will have a set of base properties and draft post preview url.
|
|
4335
|
+
* @maxSize 10
|
|
4336
|
+
*/
|
|
4337
|
+
fieldsets?: FieldWithLiterals[];
|
|
4338
|
+
}
|
|
4339
|
+
interface RevertToUnpublishedResponse {
|
|
4340
|
+
/** Updated post draft. */
|
|
4341
|
+
draftPost?: DraftPost;
|
|
4342
|
+
}
|
|
4343
|
+
interface RejectDraftPostRequest {
|
|
4344
|
+
/**
|
|
4345
|
+
* Source post ID.
|
|
4346
|
+
* @format GUID
|
|
4347
|
+
*/
|
|
4348
|
+
postId?: string;
|
|
4349
|
+
/**
|
|
4350
|
+
* List of draft post fields to be included if entities are present in the response.
|
|
4351
|
+
* Base fieldset, which is default, will return all core draft post properties.
|
|
4352
|
+
* Example: When URL fieldset is selected, returned draft post will have a set of base properties and draft post preview url.
|
|
4353
|
+
* @maxSize 10
|
|
4354
|
+
*/
|
|
4355
|
+
fieldsets?: FieldWithLiterals[];
|
|
4356
|
+
}
|
|
4357
|
+
interface RejectDraftPostResponse {
|
|
4358
|
+
/** Draft post. */
|
|
4359
|
+
draftPost?: DraftPost;
|
|
4360
|
+
}
|
|
4361
|
+
interface ApproveDraftPostRequest {
|
|
4362
|
+
/**
|
|
4363
|
+
* Source post ID.
|
|
4364
|
+
* @format GUID
|
|
4365
|
+
*/
|
|
4366
|
+
postId?: string;
|
|
4367
|
+
/**
|
|
4368
|
+
* Scheduled publish date if should be not immediately published.
|
|
4369
|
+
* @maxLength 24
|
|
4370
|
+
*/
|
|
4371
|
+
scheduledPublishDate?: string | null;
|
|
4372
|
+
/**
|
|
4373
|
+
* List of draft post fields to be included if entities are present in the response.
|
|
4374
|
+
* Base fieldset, which is default, will return all core draft post properties.
|
|
4375
|
+
* Example: When URL fieldset is selected, returned draft post will have a set of base properties and draft post preview url.
|
|
4376
|
+
* @maxSize 10
|
|
4377
|
+
*/
|
|
4378
|
+
fieldsets?: FieldWithLiterals[];
|
|
4379
|
+
}
|
|
4380
|
+
interface ApproveDraftPostResponse {
|
|
4381
|
+
/** Updated post draft. */
|
|
4382
|
+
draftPost?: DraftPost;
|
|
4383
|
+
}
|
|
4384
|
+
interface MarkPostAsInModerationRequest {
|
|
4385
|
+
/**
|
|
4386
|
+
* Source post ID.
|
|
4387
|
+
* @maxLength 38
|
|
4388
|
+
*/
|
|
4389
|
+
postId?: string;
|
|
4390
|
+
/**
|
|
4391
|
+
* List of draft post fields to be included if entities are present in the response.
|
|
4392
|
+
* Base fieldset, which is default, will return all core draft post properties.
|
|
4393
|
+
* Example: When URL fieldset is selected, returned draft post will have a set of base properties and draft post preview url.
|
|
4394
|
+
* @maxSize 10
|
|
4395
|
+
*/
|
|
4396
|
+
fieldsets?: FieldWithLiterals[];
|
|
4397
|
+
}
|
|
4398
|
+
interface MarkPostAsInModerationResponse {
|
|
4399
|
+
/** Updated post draft. */
|
|
4400
|
+
draftPost?: DraftPost;
|
|
4401
|
+
}
|
|
4341
4402
|
|
|
4342
4403
|
type __PublicMethodMetaInfo<K = string, M = unknown, T = unknown, S = unknown, Q = unknown, R = unknown> = {
|
|
4343
4404
|
getUrl: (context: any) => string;
|