@wix/auto_sdk_app-management_apps 1.0.0 → 1.0.1
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.d.ts +14 -14
- package/build/cjs/index.js.map +1 -1
- package/build/cjs/index.typings.d.ts +161 -77
- package/build/cjs/index.typings.js.map +1 -1
- package/build/cjs/meta.d.ts +122 -56
- package/build/cjs/meta.js.map +1 -1
- package/build/es/index.d.mts +14 -14
- package/build/es/index.mjs.map +1 -1
- package/build/es/index.typings.d.mts +161 -77
- package/build/es/index.typings.mjs.map +1 -1
- package/build/es/meta.d.mts +122 -56
- package/build/es/meta.mjs.map +1 -1
- package/build/internal/cjs/index.d.ts +14 -14
- package/build/internal/cjs/index.typings.d.ts +161 -77
- package/build/internal/cjs/meta.d.ts +122 -56
- package/build/internal/es/index.d.mts +14 -14
- package/build/internal/es/index.typings.d.mts +161 -77
- package/build/internal/es/meta.d.mts +122 -56
- package/package.json +2 -2
|
@@ -12,7 +12,9 @@ interface V1App {
|
|
|
12
12
|
*/
|
|
13
13
|
_id?: string | null;
|
|
14
14
|
/**
|
|
15
|
-
* The display name
|
|
15
|
+
* The display name shown to users and in App Market after publication, separate from the namespace, slug, and code identifier.
|
|
16
|
+
* On creation and update, `<`, `>`, double quotes, and apostrophes are escaped as
|
|
17
|
+
* `<`, `>`, `"`, and `'`. Responses contain the escaped value, which can be longer than the submitted name.
|
|
16
18
|
* @maxLength 50
|
|
17
19
|
*/
|
|
18
20
|
name?: string;
|
|
@@ -22,7 +24,11 @@ interface V1App {
|
|
|
22
24
|
* @format GUID
|
|
23
25
|
*/
|
|
24
26
|
accountId?: string | null;
|
|
25
|
-
/**
|
|
27
|
+
/**
|
|
28
|
+
* Secrets for authentication and webhooks. Omitted from Get App responses by default.
|
|
29
|
+
* To retrieve them, include `APP_SECRETS` in Get App's `additionalFields`.
|
|
30
|
+
* Requires authorization to access the app's secrets.
|
|
31
|
+
*/
|
|
26
32
|
appSecrets?: AppSecrets;
|
|
27
33
|
/**
|
|
28
34
|
* Is Wix owned the application
|
|
@@ -30,13 +36,18 @@ interface V1App {
|
|
|
30
36
|
*/
|
|
31
37
|
wixApp?: boolean;
|
|
32
38
|
/**
|
|
33
|
-
* App namespace, combining an account or company identifier with an app-name component.
|
|
39
|
+
* App namespace, combining an account or company identifier with an app-name component.
|
|
40
|
+
* For example, `@example-company/bookings-helper`.
|
|
41
|
+
* Assign it once through Set Namespace after creating the app. Don't supply it to Create App
|
|
42
|
+
* or Update App. Set Namespace fails if the app already has a namespace.
|
|
34
43
|
* @minLength 1
|
|
35
44
|
* @maxLength 150
|
|
36
45
|
*/
|
|
37
46
|
namespace?: string | null;
|
|
38
47
|
/**
|
|
39
|
-
*
|
|
48
|
+
* An identifier for referencing the app in code, separate from its display name, namespace, and slug.
|
|
49
|
+
* Must start with a letter, underscore, or dollar sign; remaining characters can also include digits.
|
|
50
|
+
* JavaScript reserved words aren't rejected. Choose a non-reserved identifier if using this value as a JavaScript variable name.
|
|
40
51
|
* Unique for non-companion apps. Companion apps return the shared value `companionApp`; use `id` to uniquely identify an app.
|
|
41
52
|
* For example, the namespace `@app-builder/my-cool-app` can be represented by the code identifier `AppBuilderMyCoolApp`.
|
|
42
53
|
* @minLength 3
|
|
@@ -50,7 +61,12 @@ interface V1App {
|
|
|
50
61
|
* @internal
|
|
51
62
|
*/
|
|
52
63
|
appType?: AppTypeWithLiterals;
|
|
53
|
-
/**
|
|
64
|
+
/**
|
|
65
|
+
* Revision number, which increments by 1 each time the app is updated.
|
|
66
|
+
* To prevent conflicting changes, supply the current revision when calling Update App.
|
|
67
|
+
* Retrieve the latest revision through Get App before updating.
|
|
68
|
+
* Ignored when creating an app.
|
|
69
|
+
*/
|
|
54
70
|
revision?: string | null;
|
|
55
71
|
/**
|
|
56
72
|
* A human-readable, URL-friendly identifier for the app.
|
|
@@ -67,7 +83,9 @@ interface V1App {
|
|
|
67
83
|
/** URLs used by the app's OAuth flow. */
|
|
68
84
|
appUrls?: AppUrls;
|
|
69
85
|
/**
|
|
70
|
-
* Identity of the user or app that created the app, including its source template when applicable.
|
|
86
|
+
* Identity and creation channel of the user or app that created the app, including its source template when applicable.
|
|
87
|
+
* Create App derives `id` and `type` from the caller's identity, replacing any supplied values.
|
|
88
|
+
* You can supply `sourceTemplateId` during creation. Creator information can't be changed through Update App.
|
|
71
89
|
* @immutable
|
|
72
90
|
*/
|
|
73
91
|
createdBy?: CreatedBy;
|
|
@@ -83,7 +101,7 @@ interface V1App {
|
|
|
83
101
|
* @readonly
|
|
84
102
|
*/
|
|
85
103
|
_updatedDate?: Date | null;
|
|
86
|
-
/**
|
|
104
|
+
/** Event-based tracking of unreleased changes, grouped by type. Updates asynchronously; see each flag for its tracking scope. */
|
|
87
105
|
unreleasedChanges?: UnreleasedChanges;
|
|
88
106
|
/**
|
|
89
107
|
* The ownership tag of the application
|
|
@@ -139,6 +157,8 @@ interface V1App {
|
|
|
139
157
|
interface AppSecrets {
|
|
140
158
|
/**
|
|
141
159
|
* App authentication secret. Keep this value in a secure backend secret store.
|
|
160
|
+
* During rotation, this field contains the previous secret while both secrets exist.
|
|
161
|
+
* After the previous secret is retired, this field contains the replacement secret.
|
|
142
162
|
* @readonly
|
|
143
163
|
* @format GUID
|
|
144
164
|
*/
|
|
@@ -150,7 +170,8 @@ interface AppSecrets {
|
|
|
150
170
|
*/
|
|
151
171
|
webhookPublicKey?: string;
|
|
152
172
|
/**
|
|
153
|
-
*
|
|
173
|
+
* Replacement authentication secret used during rotation. Present while the app has two secrets.
|
|
174
|
+
* After the previous secret is retired, this value moves to `appSecret` and this field is cleared.
|
|
154
175
|
* @readonly
|
|
155
176
|
* @format GUID
|
|
156
177
|
*/
|
|
@@ -219,49 +240,71 @@ interface AppUrls {
|
|
|
219
240
|
}
|
|
220
241
|
interface CreatedBy {
|
|
221
242
|
/**
|
|
222
|
-
* ID
|
|
243
|
+
* Creator ID derived from the caller's identity; a supplied value is replaced during creation.
|
|
244
|
+
* Identifies a user for `USER`, `CODE_GEN`, and `APP_BUILDER_SELF_HOSTED`, or an app for `APP`.
|
|
223
245
|
* @format GUID
|
|
224
246
|
*/
|
|
225
247
|
_id?: string;
|
|
226
|
-
/**
|
|
248
|
+
/** Creator identity or creation channel, derived from the caller's identity rather than a supplied value. */
|
|
227
249
|
type?: CreatedByTypeWithLiterals;
|
|
228
250
|
/**
|
|
229
|
-
* ID of the template
|
|
251
|
+
* ID of the source template, when applicable. Can be supplied to Create App.
|
|
230
252
|
* @format GUID
|
|
231
253
|
*/
|
|
232
254
|
sourceTemplateId?: string | null;
|
|
233
255
|
}
|
|
234
256
|
declare enum CreatedByType {
|
|
257
|
+
/** Created by a user; `id` is the user's ID. */
|
|
235
258
|
USER = "USER",
|
|
259
|
+
/** Created by an app; `id` is the app's ID. */
|
|
236
260
|
APP = "APP",
|
|
261
|
+
/** Created through code generation; `id` is the initiating user's ID. */
|
|
237
262
|
CODE_GEN = "CODE_GEN",
|
|
263
|
+
/** Created through the self-hosted app builder; `id` is the initiating user's ID. */
|
|
238
264
|
APP_BUILDER_SELF_HOSTED = "APP_BUILDER_SELF_HOSTED"
|
|
239
265
|
}
|
|
240
266
|
/** @enumType */
|
|
241
267
|
type CreatedByTypeWithLiterals = CreatedByType | 'USER' | 'APP' | 'CODE_GEN' | 'APP_BUILDER_SELF_HOSTED';
|
|
242
268
|
interface InstallationPreferences extends InstallationPreferencesOpenButtonOptionsOneOf {
|
|
243
|
-
/** Component to open when `openButtonAction` is `OPEN_COMPONENT_ID`. */
|
|
269
|
+
/** Component to open. Supply `componentId` when `openButtonAction` is `OPEN_COMPONENT_ID`. */
|
|
244
270
|
openComponentIdOptions?: OpenComponentId;
|
|
245
|
-
/**
|
|
271
|
+
/**
|
|
272
|
+
* Preferred destination after installing an app with both editor and dashboard components.
|
|
273
|
+
* A recognized dashboard page in `postInstallationComponentId` takes precedence over this preference.
|
|
274
|
+
* Otherwise, `DASHBOARD` selects the dashboard and `EDITOR` selects the editor.
|
|
275
|
+
* On sites without an editor, `EDITOR` falls back to the dashboard.
|
|
276
|
+
* `UNKNOWN_REDIRECT_TARGET` leaves the default installation navigation unchanged.
|
|
277
|
+
*/
|
|
246
278
|
overridePostInstallationRedirect?: RedirectTargetWithLiterals;
|
|
247
279
|
/**
|
|
248
|
-
* ID of the
|
|
280
|
+
* Optional ID of the app's dashboard page to open after installation.
|
|
281
|
+
* A recognized dashboard page takes precedence over `overridePostInstallationRedirect`.
|
|
282
|
+
* If omitted or not recognized as a dashboard page, navigation uses the redirect preference
|
|
283
|
+
* or the default installation flow. This field doesn't select an editor component.
|
|
249
284
|
* @format GUID
|
|
250
285
|
*/
|
|
251
286
|
postInstallationComponentId?: string | null;
|
|
252
|
-
/**
|
|
287
|
+
/**
|
|
288
|
+
* Action performed when the user selects the app's Open button after installation.
|
|
289
|
+
* For `OPEN_COMPONENT_ID`, supply `openComponentIdOptions.componentId`.
|
|
290
|
+
* `UNKNOWN_ACTION` means no explicit component-opening action is selected.
|
|
291
|
+
*/
|
|
253
292
|
openButtonAction?: OpenButtonActionWithLiterals;
|
|
254
293
|
/**
|
|
255
294
|
* Indicates the different consent options the app could define post installation
|
|
256
295
|
* @internal
|
|
257
296
|
*/
|
|
258
297
|
consentOptions?: ConsentOptions;
|
|
259
|
-
/**
|
|
298
|
+
/**
|
|
299
|
+
* Custom warning shown when a user tries to uninstall the app.
|
|
300
|
+
* Select `NO_ACTION` for no custom warning; `NONE_ACTION` represents an unspecified preference.
|
|
301
|
+
* The product and shipping values select warning text, rather than performing cleanup.
|
|
302
|
+
*/
|
|
260
303
|
uninstallAction?: UninstallActionsWithLiterals;
|
|
261
304
|
}
|
|
262
305
|
/** @oneof */
|
|
263
306
|
interface InstallationPreferencesOpenButtonOptionsOneOf {
|
|
264
|
-
/** Component to open when `openButtonAction` is `OPEN_COMPONENT_ID`. */
|
|
307
|
+
/** Component to open. Supply `componentId` when `openButtonAction` is `OPEN_COMPONENT_ID`. */
|
|
265
308
|
openComponentIdOptions?: OpenComponentId;
|
|
266
309
|
}
|
|
267
310
|
declare enum ShowConsentBehaviour {
|
|
@@ -272,14 +315,19 @@ declare enum ShowConsentBehaviour {
|
|
|
272
315
|
/** @enumType */
|
|
273
316
|
type ShowConsentBehaviourWithLiterals = ShowConsentBehaviour | 'DEFAULT_BEHAVIOUR' | 'SHOW_CONSENT' | 'SKIP_CONSENT';
|
|
274
317
|
declare enum RedirectTarget {
|
|
318
|
+
/** Use the default installation navigation. */
|
|
275
319
|
UNKNOWN_REDIRECT_TARGET = "UNKNOWN_REDIRECT_TARGET",
|
|
320
|
+
/** Prefer the site dashboard for an app with editor and dashboard components. */
|
|
276
321
|
DASHBOARD = "DASHBOARD",
|
|
322
|
+
/** Prefer the editor; use the dashboard on sites without an editor. */
|
|
277
323
|
EDITOR = "EDITOR"
|
|
278
324
|
}
|
|
279
325
|
/** @enumType */
|
|
280
326
|
type RedirectTargetWithLiterals = RedirectTarget | 'UNKNOWN_REDIRECT_TARGET' | 'DASHBOARD' | 'EDITOR';
|
|
281
327
|
declare enum OpenButtonAction {
|
|
328
|
+
/** No explicit component-opening action is selected. */
|
|
282
329
|
UNKNOWN_ACTION = "UNKNOWN_ACTION",
|
|
330
|
+
/** Open the component specified by `openComponentIdOptions.componentId`. */
|
|
283
331
|
OPEN_COMPONENT_ID = "OPEN_COMPONENT_ID"
|
|
284
332
|
}
|
|
285
333
|
/** @enumType */
|
|
@@ -296,28 +344,46 @@ interface OpenComponentId {
|
|
|
296
344
|
componentId?: string;
|
|
297
345
|
}
|
|
298
346
|
declare enum UninstallActions {
|
|
347
|
+
/** Unspecified warning preference. Use `NO_ACTION` to explicitly select no custom warning. */
|
|
299
348
|
NONE_ACTION = "NONE_ACTION",
|
|
349
|
+
/** Show the standard uninstall message without a custom warning. Default when no preference is stored. */
|
|
300
350
|
NO_ACTION = "NO_ACTION",
|
|
351
|
+
/** Warn users to remove all products associated with the app from their store. */
|
|
301
352
|
REMOVE_ALL_PRODUCT = "REMOVE_ALL_PRODUCT",
|
|
353
|
+
/** Warn users that shipping to regions served only by the app will be removed from checkout. */
|
|
302
354
|
SHIPPING_RATES_REGION = "SHIPPING_RATES_REGION"
|
|
303
355
|
}
|
|
304
356
|
/** @enumType */
|
|
305
357
|
type UninstallActionsWithLiterals = UninstallActions | 'NONE_ACTION' | 'NO_ACTION' | 'REMOVE_ALL_PRODUCT' | 'SHIPPING_RATES_REGION';
|
|
358
|
+
/**
|
|
359
|
+
* Event-based tracking of changes not yet included in a released app version.
|
|
360
|
+
* Flags update asynchronously and reset when a production app version is created or updated.
|
|
361
|
+
*/
|
|
306
362
|
interface UnreleasedChanges {
|
|
307
|
-
/**
|
|
363
|
+
/** Whether components have unreleased creation, update, or deletion changes. */
|
|
308
364
|
componentsChanges?: boolean;
|
|
309
|
-
/**
|
|
365
|
+
/** Whether app translations have unreleased creation or update changes. */
|
|
310
366
|
appTranslationsChanges?: boolean;
|
|
311
|
-
/**
|
|
367
|
+
/**
|
|
368
|
+
* Whether component translations have unreleased update changes.
|
|
369
|
+
* Component-translation creation events currently aren't reflected in this flag.
|
|
370
|
+
*/
|
|
312
371
|
componentsTranslationChanges?: boolean;
|
|
313
372
|
/**
|
|
314
373
|
* Indicate components experiments changes (create, update, delete)
|
|
315
374
|
* @internal
|
|
316
375
|
*/
|
|
317
376
|
componentsExperimentsChanges?: boolean;
|
|
318
|
-
/**
|
|
377
|
+
/**
|
|
378
|
+
* Whether app permissions have unreleased creation or update changes.
|
|
379
|
+
* Permission-deletion events currently aren't reflected in this flag.
|
|
380
|
+
*/
|
|
319
381
|
appPermissionsChanges?: boolean;
|
|
320
|
-
/**
|
|
382
|
+
/**
|
|
383
|
+
* Whether app identity fields have unreleased changes, such as `name`, `slug`, `namespace`, and `codeIdentifier`.
|
|
384
|
+
* Doesn't track changes to `appUrls` or `installationPreferences`.
|
|
385
|
+
* Updates asynchronously after the app's update event; the update response may not yet reflect this flag.
|
|
386
|
+
*/
|
|
321
387
|
appEntityChanges?: boolean;
|
|
322
388
|
}
|
|
323
389
|
interface AppComponentMetadata {
|
|
@@ -509,7 +575,7 @@ interface AccountInfo {
|
|
|
509
575
|
}
|
|
510
576
|
interface AppOwnerChangedEvent {
|
|
511
577
|
/**
|
|
512
|
-
*
|
|
578
|
+
* App ID.
|
|
513
579
|
* @format GUID
|
|
514
580
|
*/
|
|
515
581
|
appId?: string;
|
|
@@ -525,16 +591,16 @@ interface AppOwnerChangedEvent {
|
|
|
525
591
|
previousAccountId?: string;
|
|
526
592
|
}
|
|
527
593
|
interface CreateAppRequest {
|
|
528
|
-
/** App to
|
|
594
|
+
/** App to create. */
|
|
529
595
|
app: V1App;
|
|
530
596
|
}
|
|
531
597
|
interface CreateAppResponse {
|
|
532
|
-
/**
|
|
598
|
+
/** Created app. */
|
|
533
599
|
app?: V1App;
|
|
534
600
|
}
|
|
535
601
|
interface GetAppRequest {
|
|
536
602
|
/**
|
|
537
|
-
*
|
|
603
|
+
* App ID.
|
|
538
604
|
* @format GUID
|
|
539
605
|
*/
|
|
540
606
|
appId: string;
|
|
@@ -561,11 +627,11 @@ declare enum RequestedFields {
|
|
|
561
627
|
/** @enumType */
|
|
562
628
|
type RequestedFieldsWithLiterals = RequestedFields | 'APP_SECRETS';
|
|
563
629
|
interface GetAppResponse {
|
|
564
|
-
/**
|
|
630
|
+
/** Retrieved app. */
|
|
565
631
|
app?: V1App;
|
|
566
632
|
}
|
|
567
633
|
interface UpdateAppRequest {
|
|
568
|
-
/** App to
|
|
634
|
+
/** App to update. Specify the app ID, current revision, and fields to change. */
|
|
569
635
|
app: V1App;
|
|
570
636
|
/**
|
|
571
637
|
* Explicit list of fields to update
|
|
@@ -574,23 +640,23 @@ interface UpdateAppRequest {
|
|
|
574
640
|
mask?: string[];
|
|
575
641
|
}
|
|
576
642
|
interface UpdateAppResponse {
|
|
577
|
-
/**
|
|
643
|
+
/** Updated app. */
|
|
578
644
|
app?: V1App;
|
|
579
645
|
}
|
|
580
646
|
interface GenerateSlugRequest {
|
|
581
647
|
/**
|
|
582
|
-
*
|
|
648
|
+
* App ID.
|
|
583
649
|
* @format GUID
|
|
584
650
|
*/
|
|
585
651
|
appId: string;
|
|
586
652
|
}
|
|
587
653
|
interface GenerateSlugResponse {
|
|
588
|
-
/**
|
|
654
|
+
/** App with its generated or existing slug. */
|
|
589
655
|
app?: V1App;
|
|
590
656
|
}
|
|
591
657
|
interface RenameSlugRequest {
|
|
592
658
|
/**
|
|
593
|
-
*
|
|
659
|
+
* App ID.
|
|
594
660
|
* @format GUID
|
|
595
661
|
*/
|
|
596
662
|
appId?: string;
|
|
@@ -602,12 +668,12 @@ interface RenameSlugRequest {
|
|
|
602
668
|
newSlug?: string;
|
|
603
669
|
}
|
|
604
670
|
interface RenameSlugResponse {
|
|
605
|
-
/**
|
|
671
|
+
/** App with its slug updated to the requested `newSlug`. */
|
|
606
672
|
app?: V1App;
|
|
607
673
|
}
|
|
608
674
|
interface RenameCodeIdentifierRequest {
|
|
609
675
|
/**
|
|
610
|
-
*
|
|
676
|
+
* App ID.
|
|
611
677
|
* @format GUID
|
|
612
678
|
*/
|
|
613
679
|
appId?: string;
|
|
@@ -619,12 +685,12 @@ interface RenameCodeIdentifierRequest {
|
|
|
619
685
|
newCodeIdentifier?: string;
|
|
620
686
|
}
|
|
621
687
|
interface RenameCodeIdentifierResponse {
|
|
622
|
-
/**
|
|
688
|
+
/** App with its updated code identifier. */
|
|
623
689
|
app?: V1App;
|
|
624
690
|
}
|
|
625
691
|
interface GetNamespaceSuggestionRequest {
|
|
626
692
|
/**
|
|
627
|
-
*
|
|
693
|
+
* App ID.
|
|
628
694
|
* @format GUID
|
|
629
695
|
*/
|
|
630
696
|
appId: string;
|
|
@@ -640,12 +706,12 @@ declare enum NamespaceType {
|
|
|
640
706
|
/** @enumType */
|
|
641
707
|
type NamespaceTypeWithLiterals = NamespaceType | 'ACCOUNT' | 'COMPANY';
|
|
642
708
|
interface GetNamespaceSuggestionResponse {
|
|
643
|
-
/**
|
|
709
|
+
/** Suggested namespace. */
|
|
644
710
|
namespace?: string;
|
|
645
711
|
}
|
|
646
712
|
interface GetNamespaceSuggestionByNameRequest {
|
|
647
713
|
/**
|
|
648
|
-
*
|
|
714
|
+
* App display name used to derive a namespace suggestion.
|
|
649
715
|
* @maxLength 50
|
|
650
716
|
*/
|
|
651
717
|
name: string;
|
|
@@ -654,7 +720,7 @@ interface GetNamespaceSuggestionByNameRequest {
|
|
|
654
720
|
}
|
|
655
721
|
interface GetNamespaceSuggestionByNameResponse {
|
|
656
722
|
/**
|
|
657
|
-
*
|
|
723
|
+
* Suggested namespace.
|
|
658
724
|
* @minLength 1
|
|
659
725
|
* @maxLength 150
|
|
660
726
|
*/
|
|
@@ -662,12 +728,12 @@ interface GetNamespaceSuggestionByNameResponse {
|
|
|
662
728
|
}
|
|
663
729
|
interface SetNamespaceRequest {
|
|
664
730
|
/**
|
|
665
|
-
*
|
|
731
|
+
* App ID.
|
|
666
732
|
* @format GUID
|
|
667
733
|
*/
|
|
668
734
|
appId: string;
|
|
669
735
|
/**
|
|
670
|
-
* Name used to derive the app's namespace component
|
|
736
|
+
* Name used to derive the app's namespace component.
|
|
671
737
|
* Lowercased; runs of non-alphanumeric characters (including spaces and underscores) become hyphens, with leading/trailing separators removed.
|
|
672
738
|
* For example, `Bookings Helper` and `Bookings_Helper` become `bookings-helper`. If no letters or digits remain, uses `untitled`.
|
|
673
739
|
* Subject to the reserved-name restrictions documented on Set Namespace. For permitted Wix-owned apps, `wix` is removed before normalization.
|
|
@@ -703,7 +769,7 @@ interface SuggestCodeIdentifierResponse {
|
|
|
703
769
|
}
|
|
704
770
|
interface SetCodeIdentifierRequest {
|
|
705
771
|
/**
|
|
706
|
-
*
|
|
772
|
+
* App ID.
|
|
707
773
|
* @format GUID
|
|
708
774
|
*/
|
|
709
775
|
appId?: string;
|
|
@@ -910,7 +976,7 @@ interface Cursors {
|
|
|
910
976
|
}
|
|
911
977
|
interface SetPrivateAppRequest {
|
|
912
978
|
/**
|
|
913
|
-
*
|
|
979
|
+
* App ID.
|
|
914
980
|
* @format GUID
|
|
915
981
|
*/
|
|
916
982
|
appId?: string;
|
|
@@ -920,7 +986,7 @@ interface SetPrivateAppRequest {
|
|
|
920
986
|
revision?: string;
|
|
921
987
|
}
|
|
922
988
|
interface SetPrivateAppResponse {
|
|
923
|
-
/**
|
|
989
|
+
/** App with its `privateApp` setting updated to the requested value. */
|
|
924
990
|
app?: V1App;
|
|
925
991
|
}
|
|
926
992
|
interface AppChangedEvent {
|
|
@@ -1009,7 +1075,7 @@ interface AppSlugChanged {
|
|
|
1009
1075
|
}
|
|
1010
1076
|
interface SetAppOwnerRequest {
|
|
1011
1077
|
/**
|
|
1012
|
-
*
|
|
1078
|
+
* App ID.
|
|
1013
1079
|
* @format GUID
|
|
1014
1080
|
*/
|
|
1015
1081
|
appId?: string;
|
|
@@ -1022,7 +1088,7 @@ interface SetAppOwnerRequest {
|
|
|
1022
1088
|
revision?: string;
|
|
1023
1089
|
}
|
|
1024
1090
|
interface SetAppOwnerResponse {
|
|
1025
|
-
/**
|
|
1091
|
+
/** App owned by the requested `accountId`. */
|
|
1026
1092
|
app?: V1App;
|
|
1027
1093
|
}
|
|
1028
1094
|
interface AppUrlsChangedInOldServiceEvent extends AppUrlsChangedInOldServiceEventChangedUrlOneOf {
|
|
@@ -1031,7 +1097,7 @@ interface AppUrlsChangedInOldServiceEvent extends AppUrlsChangedInOldServiceEven
|
|
|
1031
1097
|
/** redirect uris */
|
|
1032
1098
|
redirectUriMessage?: RedirectUrlMessage;
|
|
1033
1099
|
/**
|
|
1034
|
-
*
|
|
1100
|
+
* App ID.
|
|
1035
1101
|
* @format GUID
|
|
1036
1102
|
*/
|
|
1037
1103
|
appId?: string;
|
|
@@ -1053,7 +1119,7 @@ interface RedirectUrlMessage {
|
|
|
1053
1119
|
}
|
|
1054
1120
|
interface CreateSecondarySecretRequest {
|
|
1055
1121
|
/**
|
|
1056
|
-
*
|
|
1122
|
+
* App ID.
|
|
1057
1123
|
* @format GUID
|
|
1058
1124
|
*/
|
|
1059
1125
|
appId: string;
|
|
@@ -1077,7 +1143,7 @@ interface ActivateSecondarySecretResponse {
|
|
|
1077
1143
|
}
|
|
1078
1144
|
interface RotateSecretRequest {
|
|
1079
1145
|
/**
|
|
1080
|
-
*
|
|
1146
|
+
* App ID.
|
|
1081
1147
|
* @format GUID
|
|
1082
1148
|
*/
|
|
1083
1149
|
appId?: string;
|
|
@@ -1088,7 +1154,7 @@ interface RotateSecretResponse {
|
|
|
1088
1154
|
}
|
|
1089
1155
|
interface RollbackSecretRequest {
|
|
1090
1156
|
/**
|
|
1091
|
-
*
|
|
1157
|
+
* App ID.
|
|
1092
1158
|
* @format GUID
|
|
1093
1159
|
*/
|
|
1094
1160
|
appId?: string;
|
|
@@ -1099,24 +1165,24 @@ interface RollbackSecretResponse {
|
|
|
1099
1165
|
}
|
|
1100
1166
|
interface RevokeSecretRequest {
|
|
1101
1167
|
/**
|
|
1102
|
-
*
|
|
1168
|
+
* App ID.
|
|
1103
1169
|
* @format GUID
|
|
1104
1170
|
*/
|
|
1105
1171
|
appId: string;
|
|
1106
|
-
/**
|
|
1172
|
+
/** Credential to revoke. The app must have both a previous and a replacement secret. */
|
|
1107
1173
|
secretToRevoke: SecretToRevokeWithLiterals;
|
|
1108
1174
|
}
|
|
1109
|
-
/**
|
|
1175
|
+
/** Credential to revoke during app-secret rotation. */
|
|
1110
1176
|
declare enum SecretToRevoke {
|
|
1111
|
-
/**
|
|
1177
|
+
/** Switch signing to the replacement secret and schedule retirement of the previous secret. */
|
|
1112
1178
|
PREVIOUS_SECRET = "PREVIOUS_SECRET",
|
|
1113
|
-
/**
|
|
1179
|
+
/** Discard the replacement secret and restore signing with the previous secret. */
|
|
1114
1180
|
NEW_SECRET = "NEW_SECRET"
|
|
1115
1181
|
}
|
|
1116
1182
|
/** @enumType */
|
|
1117
1183
|
type SecretToRevokeWithLiterals = SecretToRevoke | 'PREVIOUS_SECRET' | 'NEW_SECRET';
|
|
1118
1184
|
interface RevokeSecretResponse {
|
|
1119
|
-
/** Scheduled retirement time of the previous secret.
|
|
1185
|
+
/** Scheduled retirement time of the previous secret. Returned for `PREVIOUS_SECRET` and omitted for `NEW_SECRET`. Use the latest returned timestamp. */
|
|
1120
1186
|
previousSecretRevokeAt?: Date | null;
|
|
1121
1187
|
}
|
|
1122
1188
|
/** payload for kafka event for this version on app submit */
|
|
@@ -1316,13 +1382,13 @@ interface AssociateServiceAppResponse {
|
|
|
1316
1382
|
* Setting `companionApp` to `true` is restricted to authorized companion-app provisioning services.
|
|
1317
1383
|
* A supplied `slug` is ignored except for authorized companion-app provisioning callers; use Generate Slug after creation.
|
|
1318
1384
|
* A supplied `codeIdentifier` must not contain `wix` (case-insensitive).
|
|
1319
|
-
* @param app - App to
|
|
1385
|
+
* @param app - App to create.
|
|
1320
1386
|
* @public
|
|
1321
1387
|
* @documentationMaturity preview
|
|
1322
1388
|
* @requiredField app
|
|
1323
1389
|
* @permissionId DEV_CENTER.MANAGE_APPS
|
|
1324
1390
|
* @permissionId DEV_CENTER.CREATE_APP
|
|
1325
|
-
* @returns
|
|
1391
|
+
* @returns Created app.
|
|
1326
1392
|
* @fqn wix.devcenter.apps.v1.AppsService.CreateApp
|
|
1327
1393
|
*/
|
|
1328
1394
|
declare function createApp(app: V1App): Promise<NonNullablePaths<V1App, `name` | `appSecrets.appSecret` | `appSecrets.webhookPublicKey` | `appSecrets.secondarySecretActive` | `status` | `appUrls.redirectUris` | `createdBy._id` | `createdBy.type` | `installationPreferences.openComponentIdOptions.componentId` | `installationPreferences.overridePostInstallationRedirect` | `installationPreferences.openButtonAction` | `installationPreferences.uninstallAction` | `unreleasedChanges.componentsChanges` | `unreleasedChanges.appTranslationsChanges` | `unreleasedChanges.componentsTranslationChanges` | `unreleasedChanges.appPermissionsChanges` | `unreleasedChanges.appEntityChanges`, 2>>;
|
|
@@ -1330,13 +1396,13 @@ declare function createApp(app: V1App): Promise<NonNullablePaths<V1App, `name` |
|
|
|
1330
1396
|
* Retrieves an app by ID. App secrets are omitted by default.
|
|
1331
1397
|
* To include `appSecrets`, add `APP_SECRETS` to `additionalFields`.
|
|
1332
1398
|
* Retrieving secrets requires authorization to access the app's secrets.
|
|
1333
|
-
* @param appId -
|
|
1399
|
+
* @param appId - App ID.
|
|
1334
1400
|
* @public
|
|
1335
1401
|
* @documentationMaturity preview
|
|
1336
1402
|
* @requiredField appId
|
|
1337
1403
|
* @permissionId WIX_DEVELOPERS.READ_APPS
|
|
1338
1404
|
* @permissionId DEV_CENTER.READ_APPS
|
|
1339
|
-
* @returns
|
|
1405
|
+
* @returns Retrieved app.
|
|
1340
1406
|
* @fqn wix.devcenter.apps.v1.AppsService.GetApp
|
|
1341
1407
|
*/
|
|
1342
1408
|
declare function getApp(appId: string, options?: GetAppOptions): Promise<NonNullablePaths<V1App, `name` | `appSecrets.appSecret` | `appSecrets.webhookPublicKey` | `appSecrets.secondarySecretActive` | `status` | `appUrls.redirectUris` | `createdBy._id` | `createdBy.type` | `installationPreferences.openComponentIdOptions.componentId` | `installationPreferences.overridePostInstallationRedirect` | `installationPreferences.openButtonAction` | `installationPreferences.uninstallAction` | `unreleasedChanges.componentsChanges` | `unreleasedChanges.appTranslationsChanges` | `unreleasedChanges.componentsTranslationChanges` | `unreleasedChanges.appPermissionsChanges` | `unreleasedChanges.appEntityChanges`, 2>>;
|
|
@@ -1359,7 +1425,7 @@ interface GetAppOptions {
|
|
|
1359
1425
|
*
|
|
1360
1426
|
* This method cannot update `appSecrets`, `accountId`, `namespace`, `slug`, `createdBy`,
|
|
1361
1427
|
* `companionApp`, or `codeIdentifier`. Including any of these fields or their nested fields in the
|
|
1362
|
-
*
|
|
1428
|
+
* request causes the entire request to fail; they aren't silently ignored.
|
|
1363
1429
|
* Use Set Namespace to assign a namespace and Generate Slug to generate a slug. To rotate app
|
|
1364
1430
|
* secrets, use Create Secondary Secret and Revoke Secret. This method does not support changing
|
|
1365
1431
|
* the owning account, creator, companion-app designation, or code identifier.
|
|
@@ -1374,7 +1440,7 @@ interface GetAppOptions {
|
|
|
1374
1440
|
* @permissionId DEV_CENTER.MODIFY_APP_PROPERTIES
|
|
1375
1441
|
* @permissionId DEV_CENTER.WIX_BLOCKS_REQUESTS
|
|
1376
1442
|
* @permissionId DEV_CENTER.WRITE_APP
|
|
1377
|
-
* @returns
|
|
1443
|
+
* @returns Updated app.
|
|
1378
1444
|
* @fqn wix.devcenter.apps.v1.AppsService.UpdateApp
|
|
1379
1445
|
*/
|
|
1380
1446
|
declare function updateApp(_id: string, app: NonNullablePaths<UpdateApp, `revision`, 0>): Promise<NonNullablePaths<V1App, `name` | `appSecrets.appSecret` | `appSecrets.webhookPublicKey` | `appSecrets.secondarySecretActive` | `status` | `appUrls.redirectUris` | `createdBy._id` | `createdBy.type` | `installationPreferences.openComponentIdOptions.componentId` | `installationPreferences.overridePostInstallationRedirect` | `installationPreferences.openButtonAction` | `installationPreferences.uninstallAction` | `unreleasedChanges.componentsChanges` | `unreleasedChanges.appTranslationsChanges` | `unreleasedChanges.componentsTranslationChanges` | `unreleasedChanges.appPermissionsChanges` | `unreleasedChanges.appEntityChanges`, 2>>;
|
|
@@ -1385,7 +1451,9 @@ interface UpdateApp {
|
|
|
1385
1451
|
*/
|
|
1386
1452
|
_id?: string | null;
|
|
1387
1453
|
/**
|
|
1388
|
-
* The display name
|
|
1454
|
+
* The display name shown to users and in App Market after publication, separate from the namespace, slug, and code identifier.
|
|
1455
|
+
* On creation and update, `<`, `>`, double quotes, and apostrophes are escaped as
|
|
1456
|
+
* `<`, `>`, `"`, and `'`. Responses contain the escaped value, which can be longer than the submitted name.
|
|
1389
1457
|
* @maxLength 50
|
|
1390
1458
|
*/
|
|
1391
1459
|
name?: string;
|
|
@@ -1395,7 +1463,11 @@ interface UpdateApp {
|
|
|
1395
1463
|
* @format GUID
|
|
1396
1464
|
*/
|
|
1397
1465
|
accountId?: string | null;
|
|
1398
|
-
/**
|
|
1466
|
+
/**
|
|
1467
|
+
* Secrets for authentication and webhooks. Omitted from Get App responses by default.
|
|
1468
|
+
* To retrieve them, include `APP_SECRETS` in Get App's `additionalFields`.
|
|
1469
|
+
* Requires authorization to access the app's secrets.
|
|
1470
|
+
*/
|
|
1399
1471
|
appSecrets?: AppSecrets;
|
|
1400
1472
|
/**
|
|
1401
1473
|
* Is Wix owned the application
|
|
@@ -1403,13 +1475,18 @@ interface UpdateApp {
|
|
|
1403
1475
|
*/
|
|
1404
1476
|
wixApp?: boolean;
|
|
1405
1477
|
/**
|
|
1406
|
-
* App namespace, combining an account or company identifier with an app-name component.
|
|
1478
|
+
* App namespace, combining an account or company identifier with an app-name component.
|
|
1479
|
+
* For example, `@example-company/bookings-helper`.
|
|
1480
|
+
* Assign it once through Set Namespace after creating the app. Don't supply it to Create App
|
|
1481
|
+
* or Update App. Set Namespace fails if the app already has a namespace.
|
|
1407
1482
|
* @minLength 1
|
|
1408
1483
|
* @maxLength 150
|
|
1409
1484
|
*/
|
|
1410
1485
|
namespace?: string | null;
|
|
1411
1486
|
/**
|
|
1412
|
-
*
|
|
1487
|
+
* An identifier for referencing the app in code, separate from its display name, namespace, and slug.
|
|
1488
|
+
* Must start with a letter, underscore, or dollar sign; remaining characters can also include digits.
|
|
1489
|
+
* JavaScript reserved words aren't rejected. Choose a non-reserved identifier if using this value as a JavaScript variable name.
|
|
1413
1490
|
* Unique for non-companion apps. Companion apps return the shared value `companionApp`; use `id` to uniquely identify an app.
|
|
1414
1491
|
* For example, the namespace `@app-builder/my-cool-app` can be represented by the code identifier `AppBuilderMyCoolApp`.
|
|
1415
1492
|
* @minLength 3
|
|
@@ -1423,7 +1500,12 @@ interface UpdateApp {
|
|
|
1423
1500
|
* @internal
|
|
1424
1501
|
*/
|
|
1425
1502
|
appType?: AppTypeWithLiterals;
|
|
1426
|
-
/**
|
|
1503
|
+
/**
|
|
1504
|
+
* Revision number, which increments by 1 each time the app is updated.
|
|
1505
|
+
* To prevent conflicting changes, supply the current revision when calling Update App.
|
|
1506
|
+
* Retrieve the latest revision through Get App before updating.
|
|
1507
|
+
* Ignored when creating an app.
|
|
1508
|
+
*/
|
|
1427
1509
|
revision?: string | null;
|
|
1428
1510
|
/**
|
|
1429
1511
|
* A human-readable, URL-friendly identifier for the app.
|
|
@@ -1440,7 +1522,9 @@ interface UpdateApp {
|
|
|
1440
1522
|
/** URLs used by the app's OAuth flow. */
|
|
1441
1523
|
appUrls?: AppUrls;
|
|
1442
1524
|
/**
|
|
1443
|
-
* Identity of the user or app that created the app, including its source template when applicable.
|
|
1525
|
+
* Identity and creation channel of the user or app that created the app, including its source template when applicable.
|
|
1526
|
+
* Create App derives `id` and `type` from the caller's identity, replacing any supplied values.
|
|
1527
|
+
* You can supply `sourceTemplateId` during creation. Creator information can't be changed through Update App.
|
|
1444
1528
|
* @immutable
|
|
1445
1529
|
*/
|
|
1446
1530
|
createdBy?: CreatedBy;
|
|
@@ -1456,7 +1540,7 @@ interface UpdateApp {
|
|
|
1456
1540
|
* @readonly
|
|
1457
1541
|
*/
|
|
1458
1542
|
_updatedDate?: Date | null;
|
|
1459
|
-
/**
|
|
1543
|
+
/** Event-based tracking of unreleased changes, grouped by type. Updates asynchronously; see each flag for its tracking scope. */
|
|
1460
1544
|
unreleasedChanges?: UnreleasedChanges;
|
|
1461
1545
|
/**
|
|
1462
1546
|
* The ownership tag of the application
|
|
@@ -1514,7 +1598,7 @@ interface UpdateApp {
|
|
|
1514
1598
|
* Does not generate a slug for companion apps; a companion app without a slug is returned unchanged.
|
|
1515
1599
|
* When generating a slug, the stored app name must not contain `wix` for non-Wix apps (case-insensitive).
|
|
1516
1600
|
* The exact names `google`, `facebook`, and `amazon` require privileged authorization (case-insensitive).
|
|
1517
|
-
* @param appId -
|
|
1601
|
+
* @param appId - App ID.
|
|
1518
1602
|
* @public
|
|
1519
1603
|
* @documentationMaturity preview
|
|
1520
1604
|
* @requiredField appId
|
|
@@ -1531,7 +1615,7 @@ declare function generateSlug(appId: string): Promise<NonNullablePaths<GenerateS
|
|
|
1531
1615
|
* The exact names `google`, `facebook`, and `amazon` require privileged authorization (case-insensitive).
|
|
1532
1616
|
* If the base namespace is already used, suggests an alternative with a numeric suffix. Suggestions do not reserve a namespace.
|
|
1533
1617
|
* Set Namespace derives its own namespace from `appName` without automatically adding a collision suffix. Choose a different `appName` and retry if it conflicts.
|
|
1534
|
-
* @param appId -
|
|
1618
|
+
* @param appId - App ID.
|
|
1535
1619
|
* @public
|
|
1536
1620
|
* @documentationMaturity preview
|
|
1537
1621
|
* @requiredField appId
|
|
@@ -1552,7 +1636,7 @@ interface GetNamespaceSuggestionOptions {
|
|
|
1552
1636
|
* The exact names `google`, `facebook`, and `amazon` require privileged authorization (case-insensitive).
|
|
1553
1637
|
* If the base namespace is already used, suggests an alternative with a numeric suffix. Suggestions do not reserve a namespace.
|
|
1554
1638
|
* Set Namespace derives its own namespace from `appName` without automatically adding a collision suffix. Choose a different `appName` and retry if it conflicts.
|
|
1555
|
-
* @param name -
|
|
1639
|
+
* @param name - App display name used to derive a namespace suggestion.
|
|
1556
1640
|
* @public
|
|
1557
1641
|
* @documentationMaturity preview
|
|
1558
1642
|
* @requiredField name
|
|
@@ -1571,8 +1655,8 @@ interface GetNamespaceSuggestionByNameOptions {
|
|
|
1571
1655
|
* The exact names `google`, `facebook`, and `amazon` require privileged authorization (case-insensitive).
|
|
1572
1656
|
* Unlike namespace suggestions, this method does not automatically add a suffix when the derived namespace is already used.
|
|
1573
1657
|
* Suggestions are not reservations; on a collision, choose a different `appName` and retry.
|
|
1574
|
-
* @param appId -
|
|
1575
|
-
* @param appName - Name used to derive the app's namespace component
|
|
1658
|
+
* @param appId - App ID.
|
|
1659
|
+
* @param appName - Name used to derive the app's namespace component.
|
|
1576
1660
|
* Lowercased; runs of non-alphanumeric characters (including spaces and underscores) become hyphens, with leading/trailing separators removed.
|
|
1577
1661
|
* For example, `Bookings Helper` and `Bookings_Helper` become `bookings-helper`. If no letters or digits remain, uses `untitled`.
|
|
1578
1662
|
* Subject to the reserved-name restrictions documented on Set Namespace. For permitted Wix-owned apps, `wix` is removed before normalization.
|
|
@@ -1595,7 +1679,7 @@ interface SetNamespaceOptions {
|
|
|
1595
1679
|
* (adding one here would break consistent-audience-for-shared-permission across all of them).
|
|
1596
1680
|
* Renaming the permission would change who is actually authorized, so it stays as-is —
|
|
1597
1681
|
* the real check is the MANUAL validateUpdateAppPermission(...) in code.
|
|
1598
|
-
* @param appId -
|
|
1682
|
+
* @param appId - App ID.
|
|
1599
1683
|
* @public
|
|
1600
1684
|
* @documentationMaturity preview
|
|
1601
1685
|
* @requiredField appId
|
|
@@ -1612,8 +1696,8 @@ interface CreateSecondarySecretOptions {
|
|
|
1612
1696
|
* (adding one here would break consistent-audience-for-shared-permission across all of them).
|
|
1613
1697
|
* Renaming the permission would change who is actually authorized, so it stays as-is —
|
|
1614
1698
|
* the real check is the MANUAL validateUpdateAppPermission(...) in code.
|
|
1615
|
-
* @param appId -
|
|
1616
|
-
* @param secretToRevoke -
|
|
1699
|
+
* @param appId - App ID.
|
|
1700
|
+
* @param secretToRevoke - Credential to revoke. The app must have both a previous and a replacement secret.
|
|
1617
1701
|
* @public
|
|
1618
1702
|
* @documentationMaturity preview
|
|
1619
1703
|
* @requiredField appId
|