@wix/auto_sdk_app-management_app-permissions 1.0.6 → 1.0.8
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/{internal/cjs/src/devcenter-apps-v1-app-permission-app-permissions.universal.d.ts → devcenter-apps-v1-app-permission-app-permissions.universal-ROYtr-wC.d.mts} +39 -102
- package/build/{cjs/src/devcenter-apps-v1-app-permission-app-permissions.universal.d.ts → devcenter-apps-v1-app-permission-app-permissions.universal-ROYtr-wC.d.ts} +39 -102
- package/build/index.d.mts +47 -0
- package/build/index.d.ts +47 -0
- package/build/index.js +351 -0
- package/build/index.js.map +1 -0
- package/build/index.mjs +320 -0
- package/build/index.mjs.map +1 -0
- package/build/{es/src/devcenter-apps-v1-app-permission-app-permissions.universal.d.ts → internal/devcenter-apps-v1-app-permission-app-permissions.universal-ROYtr-wC.d.mts} +39 -102
- package/build/internal/{es/src/devcenter-apps-v1-app-permission-app-permissions.universal.d.ts → devcenter-apps-v1-app-permission-app-permissions.universal-ROYtr-wC.d.ts} +39 -102
- package/build/internal/index.d.mts +47 -0
- package/build/internal/index.d.ts +47 -0
- package/build/internal/index.js +351 -0
- package/build/internal/index.js.map +1 -0
- package/build/internal/index.mjs +320 -0
- package/build/internal/index.mjs.map +1 -0
- package/build/internal/meta.d.mts +143 -0
- package/build/internal/meta.d.ts +143 -0
- package/build/internal/meta.js +220 -0
- package/build/internal/meta.js.map +1 -0
- package/build/internal/meta.mjs +191 -0
- package/build/internal/meta.mjs.map +1 -0
- package/build/meta.d.mts +143 -0
- package/build/meta.d.ts +143 -0
- package/build/meta.js +220 -0
- package/build/meta.js.map +1 -0
- package/build/meta.mjs +191 -0
- package/build/meta.mjs.map +1 -0
- package/package.json +13 -12
- package/build/cjs/index.d.ts +0 -1
- package/build/cjs/index.js +0 -18
- package/build/cjs/index.js.map +0 -1
- package/build/cjs/index.typings.d.ts +0 -1
- package/build/cjs/index.typings.js +0 -18
- package/build/cjs/index.typings.js.map +0 -1
- package/build/cjs/meta.d.ts +0 -1
- package/build/cjs/meta.js +0 -18
- package/build/cjs/meta.js.map +0 -1
- package/build/cjs/src/devcenter-apps-v1-app-permission-app-permissions.context.d.ts +0 -11
- package/build/cjs/src/devcenter-apps-v1-app-permission-app-permissions.context.js +0 -17
- package/build/cjs/src/devcenter-apps-v1-app-permission-app-permissions.context.js.map +0 -1
- package/build/cjs/src/devcenter-apps-v1-app-permission-app-permissions.http.d.ts +0 -7
- package/build/cjs/src/devcenter-apps-v1-app-permission-app-permissions.http.js +0 -138
- package/build/cjs/src/devcenter-apps-v1-app-permission-app-permissions.http.js.map +0 -1
- package/build/cjs/src/devcenter-apps-v1-app-permission-app-permissions.meta.d.ts +0 -15
- package/build/cjs/src/devcenter-apps-v1-app-permission-app-permissions.meta.js +0 -85
- package/build/cjs/src/devcenter-apps-v1-app-permission-app-permissions.meta.js.map +0 -1
- package/build/cjs/src/devcenter-apps-v1-app-permission-app-permissions.public.d.ts +0 -36
- package/build/cjs/src/devcenter-apps-v1-app-permission-app-permissions.public.js +0 -42
- package/build/cjs/src/devcenter-apps-v1-app-permission-app-permissions.public.js.map +0 -1
- package/build/cjs/src/devcenter-apps-v1-app-permission-app-permissions.types.d.ts +0 -313
- package/build/cjs/src/devcenter-apps-v1-app-permission-app-permissions.types.js +0 -22
- package/build/cjs/src/devcenter-apps-v1-app-permission-app-permissions.types.js.map +0 -1
- package/build/cjs/src/devcenter-apps-v1-app-permission-app-permissions.universal.js +0 -172
- package/build/cjs/src/devcenter-apps-v1-app-permission-app-permissions.universal.js.map +0 -1
- package/build/es/index.d.ts +0 -1
- package/build/es/index.js +0 -2
- package/build/es/index.js.map +0 -1
- package/build/es/index.typings.d.ts +0 -1
- package/build/es/index.typings.js +0 -2
- package/build/es/index.typings.js.map +0 -1
- package/build/es/meta.d.ts +0 -1
- package/build/es/meta.js +0 -2
- package/build/es/meta.js.map +0 -1
- package/build/es/src/devcenter-apps-v1-app-permission-app-permissions.context.d.ts +0 -11
- package/build/es/src/devcenter-apps-v1-app-permission-app-permissions.context.js +0 -11
- package/build/es/src/devcenter-apps-v1-app-permission-app-permissions.context.js.map +0 -1
- package/build/es/src/devcenter-apps-v1-app-permission-app-permissions.http.d.ts +0 -7
- package/build/es/src/devcenter-apps-v1-app-permission-app-permissions.http.js +0 -132
- package/build/es/src/devcenter-apps-v1-app-permission-app-permissions.http.js.map +0 -1
- package/build/es/src/devcenter-apps-v1-app-permission-app-permissions.meta.d.ts +0 -15
- package/build/es/src/devcenter-apps-v1-app-permission-app-permissions.meta.js +0 -56
- package/build/es/src/devcenter-apps-v1-app-permission-app-permissions.meta.js.map +0 -1
- package/build/es/src/devcenter-apps-v1-app-permission-app-permissions.public.d.ts +0 -36
- package/build/es/src/devcenter-apps-v1-app-permission-app-permissions.public.js +0 -33
- package/build/es/src/devcenter-apps-v1-app-permission-app-permissions.public.js.map +0 -1
- package/build/es/src/devcenter-apps-v1-app-permission-app-permissions.types.d.ts +0 -313
- package/build/es/src/devcenter-apps-v1-app-permission-app-permissions.types.js +0 -19
- package/build/es/src/devcenter-apps-v1-app-permission-app-permissions.types.js.map +0 -1
- package/build/es/src/devcenter-apps-v1-app-permission-app-permissions.universal.js +0 -143
- package/build/es/src/devcenter-apps-v1-app-permission-app-permissions.universal.js.map +0 -1
- package/build/internal/cjs/index.d.ts +0 -1
- package/build/internal/cjs/index.js +0 -18
- package/build/internal/cjs/index.js.map +0 -1
- package/build/internal/cjs/index.typings.d.ts +0 -1
- package/build/internal/cjs/index.typings.js +0 -18
- package/build/internal/cjs/index.typings.js.map +0 -1
- package/build/internal/cjs/meta.d.ts +0 -1
- package/build/internal/cjs/meta.js +0 -18
- package/build/internal/cjs/meta.js.map +0 -1
- package/build/internal/cjs/src/devcenter-apps-v1-app-permission-app-permissions.context.d.ts +0 -11
- package/build/internal/cjs/src/devcenter-apps-v1-app-permission-app-permissions.context.js +0 -17
- package/build/internal/cjs/src/devcenter-apps-v1-app-permission-app-permissions.context.js.map +0 -1
- package/build/internal/cjs/src/devcenter-apps-v1-app-permission-app-permissions.http.d.ts +0 -7
- package/build/internal/cjs/src/devcenter-apps-v1-app-permission-app-permissions.http.js +0 -138
- package/build/internal/cjs/src/devcenter-apps-v1-app-permission-app-permissions.http.js.map +0 -1
- package/build/internal/cjs/src/devcenter-apps-v1-app-permission-app-permissions.meta.d.ts +0 -15
- package/build/internal/cjs/src/devcenter-apps-v1-app-permission-app-permissions.meta.js +0 -85
- package/build/internal/cjs/src/devcenter-apps-v1-app-permission-app-permissions.meta.js.map +0 -1
- package/build/internal/cjs/src/devcenter-apps-v1-app-permission-app-permissions.public.d.ts +0 -36
- package/build/internal/cjs/src/devcenter-apps-v1-app-permission-app-permissions.public.js +0 -42
- package/build/internal/cjs/src/devcenter-apps-v1-app-permission-app-permissions.public.js.map +0 -1
- package/build/internal/cjs/src/devcenter-apps-v1-app-permission-app-permissions.types.d.ts +0 -313
- package/build/internal/cjs/src/devcenter-apps-v1-app-permission-app-permissions.types.js +0 -22
- package/build/internal/cjs/src/devcenter-apps-v1-app-permission-app-permissions.types.js.map +0 -1
- package/build/internal/cjs/src/devcenter-apps-v1-app-permission-app-permissions.universal.js +0 -172
- package/build/internal/cjs/src/devcenter-apps-v1-app-permission-app-permissions.universal.js.map +0 -1
- package/build/internal/es/index.d.ts +0 -1
- package/build/internal/es/index.js +0 -2
- package/build/internal/es/index.js.map +0 -1
- package/build/internal/es/index.typings.d.ts +0 -1
- package/build/internal/es/index.typings.js +0 -2
- package/build/internal/es/index.typings.js.map +0 -1
- package/build/internal/es/meta.d.ts +0 -1
- package/build/internal/es/meta.js +0 -2
- package/build/internal/es/meta.js.map +0 -1
- package/build/internal/es/src/devcenter-apps-v1-app-permission-app-permissions.context.d.ts +0 -11
- package/build/internal/es/src/devcenter-apps-v1-app-permission-app-permissions.context.js +0 -11
- package/build/internal/es/src/devcenter-apps-v1-app-permission-app-permissions.context.js.map +0 -1
- package/build/internal/es/src/devcenter-apps-v1-app-permission-app-permissions.http.d.ts +0 -7
- package/build/internal/es/src/devcenter-apps-v1-app-permission-app-permissions.http.js +0 -132
- package/build/internal/es/src/devcenter-apps-v1-app-permission-app-permissions.http.js.map +0 -1
- package/build/internal/es/src/devcenter-apps-v1-app-permission-app-permissions.meta.d.ts +0 -15
- package/build/internal/es/src/devcenter-apps-v1-app-permission-app-permissions.meta.js +0 -56
- package/build/internal/es/src/devcenter-apps-v1-app-permission-app-permissions.meta.js.map +0 -1
- package/build/internal/es/src/devcenter-apps-v1-app-permission-app-permissions.public.d.ts +0 -36
- package/build/internal/es/src/devcenter-apps-v1-app-permission-app-permissions.public.js +0 -33
- package/build/internal/es/src/devcenter-apps-v1-app-permission-app-permissions.public.js.map +0 -1
- package/build/internal/es/src/devcenter-apps-v1-app-permission-app-permissions.types.d.ts +0 -313
- package/build/internal/es/src/devcenter-apps-v1-app-permission-app-permissions.types.js +0 -19
- package/build/internal/es/src/devcenter-apps-v1-app-permission-app-permissions.types.js.map +0 -1
- package/build/internal/es/src/devcenter-apps-v1-app-permission-app-permissions.universal.js +0 -143
- package/build/internal/es/src/devcenter-apps-v1-app-permission-app-permissions.universal.js.map +0 -1
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
export interface AppPermission {
|
|
1
|
+
interface AppPermission {
|
|
3
2
|
/**
|
|
4
3
|
* [App ID](https://dev.wix.com/docs/build-apps/get-started/overview/glossary#app-id).
|
|
5
4
|
*
|
|
@@ -24,7 +23,7 @@ export interface AppPermission {
|
|
|
24
23
|
*/
|
|
25
24
|
_updatedDate?: Date | null;
|
|
26
25
|
}
|
|
27
|
-
|
|
26
|
+
interface V1Permission {
|
|
28
27
|
/**
|
|
29
28
|
* Permission ID.
|
|
30
29
|
*
|
|
@@ -34,15 +33,15 @@ export interface V1Permission {
|
|
|
34
33
|
*/
|
|
35
34
|
permissionId?: string;
|
|
36
35
|
}
|
|
37
|
-
|
|
36
|
+
interface CreateAppPermissionRequest {
|
|
38
37
|
/** Permission to add to the specified app. */
|
|
39
38
|
appPermission: AppPermission;
|
|
40
39
|
}
|
|
41
|
-
|
|
40
|
+
interface CreateAppPermissionResponse {
|
|
42
41
|
/** Details of permission that was added to the app. */
|
|
43
42
|
appPermission?: AppPermission;
|
|
44
43
|
}
|
|
45
|
-
|
|
44
|
+
interface GetAppPermissionRequest {
|
|
46
45
|
/**
|
|
47
46
|
* [App ID](https://dev.wix.com/docs/build-apps/get-started/overview/glossary#app-id).
|
|
48
47
|
*
|
|
@@ -59,11 +58,11 @@ export interface GetAppPermissionRequest {
|
|
|
59
58
|
*/
|
|
60
59
|
permissionId?: string;
|
|
61
60
|
}
|
|
62
|
-
|
|
61
|
+
interface GetAppPermissionResponse {
|
|
63
62
|
/** Details of the retrieved app permission. */
|
|
64
63
|
appPermission?: AppPermission;
|
|
65
64
|
}
|
|
66
|
-
|
|
65
|
+
interface ListAppPermissionsRequest {
|
|
67
66
|
/**
|
|
68
67
|
* [App ID](https://dev.wix.com/docs/build-apps/get-started/overview/glossary#app-id).
|
|
69
68
|
*
|
|
@@ -80,7 +79,7 @@ export interface ListAppPermissionsRequest {
|
|
|
80
79
|
/** Paging configuration. */
|
|
81
80
|
paging?: CursorPaging;
|
|
82
81
|
}
|
|
83
|
-
|
|
82
|
+
interface CursorPaging {
|
|
84
83
|
/**
|
|
85
84
|
* Maximum number of items to return in the results.
|
|
86
85
|
* @max 100
|
|
@@ -95,13 +94,13 @@ export interface CursorPaging {
|
|
|
95
94
|
*/
|
|
96
95
|
cursor?: string | null;
|
|
97
96
|
}
|
|
98
|
-
|
|
97
|
+
interface ListAppPermissionsResponse {
|
|
99
98
|
/** List of permissions for the specified app. */
|
|
100
99
|
appPermissions?: AppPermission[];
|
|
101
100
|
/** Paging metadata. */
|
|
102
101
|
pagingMetadata?: CursorPagingMetadata;
|
|
103
102
|
}
|
|
104
|
-
|
|
103
|
+
interface CursorPagingMetadata {
|
|
105
104
|
/** Number of items returned in current page. */
|
|
106
105
|
count?: number | null;
|
|
107
106
|
/** Cursor strings that point to the next page, previous page, or both. */
|
|
@@ -114,7 +113,7 @@ export interface CursorPagingMetadata {
|
|
|
114
113
|
*/
|
|
115
114
|
hasNext?: boolean | null;
|
|
116
115
|
}
|
|
117
|
-
|
|
116
|
+
interface Cursors {
|
|
118
117
|
/**
|
|
119
118
|
* Cursor string pointing to the next page in the list of results.
|
|
120
119
|
* @maxLength 16000
|
|
@@ -126,7 +125,7 @@ export interface Cursors {
|
|
|
126
125
|
*/
|
|
127
126
|
prev?: string | null;
|
|
128
127
|
}
|
|
129
|
-
|
|
128
|
+
interface DeleteAppPermissionRequest {
|
|
130
129
|
/**
|
|
131
130
|
* [App ID](https://dev.wix.com/docs/build-apps/get-started/overview/glossary#app-id).
|
|
132
131
|
*
|
|
@@ -143,18 +142,18 @@ export interface DeleteAppPermissionRequest {
|
|
|
143
142
|
*/
|
|
144
143
|
permissionId: string;
|
|
145
144
|
}
|
|
146
|
-
|
|
145
|
+
interface DeleteAppPermissionResponse {
|
|
147
146
|
}
|
|
148
|
-
|
|
147
|
+
interface PermissionActionDomainEventEntity {
|
|
149
148
|
/** The permission that had an event */
|
|
150
149
|
appPermission?: AppPermission;
|
|
151
150
|
/** The action which happened */
|
|
152
151
|
actionType?: ActionType;
|
|
153
152
|
}
|
|
154
|
-
|
|
153
|
+
declare enum ActionType {
|
|
155
154
|
APP_PERMISSION_DELETED = "APP_PERMISSION_DELETED"
|
|
156
155
|
}
|
|
157
|
-
|
|
156
|
+
interface DomainEvent extends DomainEventBodyOneOf {
|
|
158
157
|
createdEvent?: EntityCreatedEvent;
|
|
159
158
|
updatedEvent?: EntityUpdatedEvent;
|
|
160
159
|
deletedEvent?: EntityDeletedEvent;
|
|
@@ -197,19 +196,19 @@ export interface DomainEvent extends DomainEventBodyOneOf {
|
|
|
197
196
|
entityEventSequence?: string | null;
|
|
198
197
|
}
|
|
199
198
|
/** @oneof */
|
|
200
|
-
|
|
199
|
+
interface DomainEventBodyOneOf {
|
|
201
200
|
createdEvent?: EntityCreatedEvent;
|
|
202
201
|
updatedEvent?: EntityUpdatedEvent;
|
|
203
202
|
deletedEvent?: EntityDeletedEvent;
|
|
204
203
|
actionEvent?: ActionEvent;
|
|
205
204
|
}
|
|
206
|
-
|
|
205
|
+
interface EntityCreatedEvent {
|
|
207
206
|
entity?: string;
|
|
208
207
|
}
|
|
209
|
-
|
|
208
|
+
interface RestoreInfo {
|
|
210
209
|
deletedDate?: Date | null;
|
|
211
210
|
}
|
|
212
|
-
|
|
211
|
+
interface EntityUpdatedEvent {
|
|
213
212
|
/**
|
|
214
213
|
* Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.
|
|
215
214
|
* This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.
|
|
@@ -217,30 +216,30 @@ export interface EntityUpdatedEvent {
|
|
|
217
216
|
*/
|
|
218
217
|
currentEntity?: string;
|
|
219
218
|
}
|
|
220
|
-
|
|
219
|
+
interface EntityDeletedEvent {
|
|
221
220
|
/** Entity that was deleted */
|
|
222
221
|
deletedEntity?: string | null;
|
|
223
222
|
}
|
|
224
|
-
|
|
223
|
+
interface ActionEvent {
|
|
225
224
|
body?: string;
|
|
226
225
|
}
|
|
227
|
-
|
|
226
|
+
interface Empty {
|
|
228
227
|
}
|
|
229
|
-
|
|
228
|
+
interface OldPermissionChangedEvent {
|
|
230
229
|
/** @format GUID */
|
|
231
230
|
appId?: string;
|
|
232
231
|
permission?: Permission;
|
|
233
232
|
action?: Action;
|
|
234
233
|
}
|
|
235
|
-
|
|
234
|
+
interface Permission {
|
|
236
235
|
permissionId?: string;
|
|
237
236
|
}
|
|
238
|
-
|
|
237
|
+
declare enum Action {
|
|
239
238
|
CREATED = "CREATED",
|
|
240
239
|
UPDATED = "UPDATED",
|
|
241
240
|
DELETED = "DELETED"
|
|
242
241
|
}
|
|
243
|
-
|
|
242
|
+
interface MessageEnvelope {
|
|
244
243
|
/**
|
|
245
244
|
* App instance ID.
|
|
246
245
|
* @format GUID
|
|
@@ -256,7 +255,7 @@ export interface MessageEnvelope {
|
|
|
256
255
|
/** Stringify payload. */
|
|
257
256
|
data?: string;
|
|
258
257
|
}
|
|
259
|
-
|
|
258
|
+
interface IdentificationData extends IdentificationDataIdOneOf {
|
|
260
259
|
/**
|
|
261
260
|
* ID of a site visitor that has not logged in to the site.
|
|
262
261
|
* @format GUID
|
|
@@ -281,7 +280,7 @@ export interface IdentificationData extends IdentificationDataIdOneOf {
|
|
|
281
280
|
identityType?: WebhookIdentityType;
|
|
282
281
|
}
|
|
283
282
|
/** @oneof */
|
|
284
|
-
|
|
283
|
+
interface IdentificationDataIdOneOf {
|
|
285
284
|
/**
|
|
286
285
|
* ID of a site visitor that has not logged in to the site.
|
|
287
286
|
* @format GUID
|
|
@@ -303,14 +302,14 @@ export interface IdentificationDataIdOneOf {
|
|
|
303
302
|
*/
|
|
304
303
|
appId?: string;
|
|
305
304
|
}
|
|
306
|
-
|
|
305
|
+
declare enum WebhookIdentityType {
|
|
307
306
|
UNKNOWN = "UNKNOWN",
|
|
308
307
|
ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR",
|
|
309
308
|
MEMBER = "MEMBER",
|
|
310
309
|
WIX_USER = "WIX_USER",
|
|
311
310
|
APP = "APP"
|
|
312
311
|
}
|
|
313
|
-
|
|
312
|
+
interface BaseEventMetadata {
|
|
314
313
|
/**
|
|
315
314
|
* App instance ID.
|
|
316
315
|
* @format GUID
|
|
@@ -324,7 +323,7 @@ export interface BaseEventMetadata {
|
|
|
324
323
|
/** The identification type and identity data. */
|
|
325
324
|
identity?: IdentificationData;
|
|
326
325
|
}
|
|
327
|
-
|
|
326
|
+
interface EventMetadata extends BaseEventMetadata {
|
|
328
327
|
/**
|
|
329
328
|
* Unique event ID.
|
|
330
329
|
* Allows clients to ignore duplicate webhooks.
|
|
@@ -362,50 +361,14 @@ export interface EventMetadata extends BaseEventMetadata {
|
|
|
362
361
|
*/
|
|
363
362
|
entityEventSequence?: string | null;
|
|
364
363
|
}
|
|
365
|
-
|
|
364
|
+
interface AppPermissionCreatedEnvelope {
|
|
366
365
|
entity: AppPermission;
|
|
367
366
|
metadata: EventMetadata;
|
|
368
367
|
}
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
* @documentationMaturity preview
|
|
374
|
-
*/
|
|
375
|
-
export declare function onAppPermissionCreated(handler: (event: AppPermissionCreatedEnvelope) => void | Promise<void>): void;
|
|
376
|
-
type AppPermissionNonNullablePaths = `appId` | `permission.permissionId`;
|
|
377
|
-
/**
|
|
378
|
-
* Adds a permission to the specified app.
|
|
379
|
-
* @param appPermission - Permission to add to the specified app.
|
|
380
|
-
* @public
|
|
381
|
-
* @documentationMaturity preview
|
|
382
|
-
* @requiredField appPermission
|
|
383
|
-
* @requiredField appPermission.appId
|
|
384
|
-
* @requiredField appPermission.permission
|
|
385
|
-
* @requiredField appPermission.permission.permissionId
|
|
386
|
-
* @permissionId DEV_CENTER.CREATE_APP_PERMISSION
|
|
387
|
-
* @permissionScope Write Dev Center App Permissions
|
|
388
|
-
* @permissionScopeId SCOPE.DEV_CENTER.WRITE_PERMISSIONS
|
|
389
|
-
* @applicableIdentity APP
|
|
390
|
-
* @returns Details of permission that was added to the app.
|
|
391
|
-
* @fqn wix.devcenter.apps.permissions.v1.AppPermissionsService.CreateAppPermission
|
|
392
|
-
*/
|
|
393
|
-
export declare function createAppPermission(appPermission: NonNullablePaths<AppPermission, `appId` | `permission` | `permission.permissionId`>): Promise<NonNullablePaths<AppPermission, AppPermissionNonNullablePaths>>;
|
|
394
|
-
/**
|
|
395
|
-
* Lists all permissions for the specified app.
|
|
396
|
-
* @param appId - [App ID](https://dev.wix.com/docs/build-apps/get-started/overview/glossary#app-id).
|
|
397
|
-
*
|
|
398
|
-
* You can find the app ID on the [Home page](https://manage.wix.com/app-selector?title=Select+an+App&primaryButtonText=Select+Site&actionUrl=https%3A%2F%2Fdev.wix.com%2Fapps%2F%7BappId%7D%home) in the app's dashboard.
|
|
399
|
-
* @public
|
|
400
|
-
* @documentationMaturity preview
|
|
401
|
-
* @requiredField appId
|
|
402
|
-
* @permissionId DEV_CENTER.READ_APP_PERMISSIONS
|
|
403
|
-
* @fqn wix.devcenter.apps.permissions.v1.AppPermissionsService.ListAppPermissions
|
|
404
|
-
*/
|
|
405
|
-
export declare function listAppPermissions(appId: string, options?: ListAppPermissionsOptions): Promise<NonNullablePaths<ListAppPermissionsResponse, {
|
|
406
|
-
[P in AppPermissionNonNullablePaths]: `appPermissions.${number}.${P}`;
|
|
407
|
-
}[AppPermissionNonNullablePaths]>>;
|
|
408
|
-
export interface ListAppPermissionsOptions {
|
|
368
|
+
interface AppPermissionDeletedEnvelope {
|
|
369
|
+
metadata: EventMetadata;
|
|
370
|
+
}
|
|
371
|
+
interface ListAppPermissionsOptions {
|
|
409
372
|
/**
|
|
410
373
|
* Whether to retrieve the most recent permissions information. This decreases performance but ensures that the retrieved information is up-to-date, even immediately after an update.
|
|
411
374
|
*
|
|
@@ -415,31 +378,5 @@ export interface ListAppPermissionsOptions {
|
|
|
415
378
|
/** Paging configuration. */
|
|
416
379
|
paging?: CursorPaging;
|
|
417
380
|
}
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
* @param appId - [App ID](https://dev.wix.com/docs/build-apps/get-started/overview/glossary#app-id).
|
|
421
|
-
*
|
|
422
|
-
* You can find the app ID on the [Home page](https://manage.wix.com/app-selector?title=Select+an+App&primaryButtonText=Select+Site&actionUrl=https%3A%2F%2Fdev.wix.com%2Fapps%2F%7BappId%7D%home) in the app's dashboard.
|
|
423
|
-
* @public
|
|
424
|
-
* @documentationMaturity preview
|
|
425
|
-
* @requiredField appId
|
|
426
|
-
* @requiredField options
|
|
427
|
-
* @requiredField options.permissionId
|
|
428
|
-
* @permissionId DEV_CENTER.DELETE_APP_PERMISSION
|
|
429
|
-
* @permissionScope Write Dev Center App Permissions
|
|
430
|
-
* @permissionScopeId SCOPE.DEV_CENTER.WRITE_PERMISSIONS
|
|
431
|
-
* @applicableIdentity APP
|
|
432
|
-
* @fqn wix.devcenter.apps.permissions.v1.AppPermissionsService.DeleteAppPermission
|
|
433
|
-
*/
|
|
434
|
-
export declare function deleteAppPermission(appId: string, options: NonNullablePaths<DeleteAppPermissionOptions, `permissionId`>): Promise<void>;
|
|
435
|
-
export interface DeleteAppPermissionOptions {
|
|
436
|
-
/**
|
|
437
|
-
* Permission ID.
|
|
438
|
-
*
|
|
439
|
-
* To find the permission ID, navigate to the [Permissions page](https://dev.wix.com/app-selector?title=Select+an+App&primaryButtonText=Select+Site&actionUrl=https%3A%2F%2Fdev.wix.com%2Fapps%2F%7BappId%7D%2Fdev-center-permissions/add) in the app's dashboard and search for the [permission you want to configure](https://dev.wix.com/docs/build-apps/develop-your-app/access/authorization/configure-permissions-for-your-app#step-1--identify-required-permissions).
|
|
440
|
-
* @minLength 1
|
|
441
|
-
* @maxLength 164
|
|
442
|
-
*/
|
|
443
|
-
permissionId: string;
|
|
444
|
-
}
|
|
445
|
-
export {};
|
|
381
|
+
|
|
382
|
+
export { type AppPermission as A, type BaseEventMetadata as B, type CreateAppPermissionRequest as C, type DeleteAppPermissionRequest as D, type EntityCreatedEvent as E, type GetAppPermissionRequest as G, type IdentificationData as I, type ListAppPermissionsOptions as L, type MessageEnvelope as M, type OldPermissionChangedEvent as O, type PermissionActionDomainEventEntity as P, type RestoreInfo as R, type V1Permission as V, WebhookIdentityType as W, type ListAppPermissionsResponse as a, ActionType as b, Action as c, type CreateAppPermissionResponse as d, type GetAppPermissionResponse as e, type ListAppPermissionsRequest as f, type CursorPaging as g, type CursorPagingMetadata as h, type Cursors as i, type DeleteAppPermissionResponse as j, type DomainEvent as k, type DomainEventBodyOneOf as l, type EntityUpdatedEvent as m, type EntityDeletedEvent as n, type ActionEvent as o, type Empty as p, type Permission as q, type IdentificationDataIdOneOf as r, type EventMetadata as s, type AppPermissionCreatedEnvelope as t, type AppPermissionDeletedEnvelope as u };
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
|
|
2
|
-
export interface AppPermission {
|
|
1
|
+
interface AppPermission {
|
|
3
2
|
/**
|
|
4
3
|
* [App ID](https://dev.wix.com/docs/build-apps/get-started/overview/glossary#app-id).
|
|
5
4
|
*
|
|
@@ -24,7 +23,7 @@ export interface AppPermission {
|
|
|
24
23
|
*/
|
|
25
24
|
_updatedDate?: Date | null;
|
|
26
25
|
}
|
|
27
|
-
|
|
26
|
+
interface V1Permission {
|
|
28
27
|
/**
|
|
29
28
|
* Permission ID.
|
|
30
29
|
*
|
|
@@ -34,15 +33,15 @@ export interface V1Permission {
|
|
|
34
33
|
*/
|
|
35
34
|
permissionId?: string;
|
|
36
35
|
}
|
|
37
|
-
|
|
36
|
+
interface CreateAppPermissionRequest {
|
|
38
37
|
/** Permission to add to the specified app. */
|
|
39
38
|
appPermission: AppPermission;
|
|
40
39
|
}
|
|
41
|
-
|
|
40
|
+
interface CreateAppPermissionResponse {
|
|
42
41
|
/** Details of permission that was added to the app. */
|
|
43
42
|
appPermission?: AppPermission;
|
|
44
43
|
}
|
|
45
|
-
|
|
44
|
+
interface GetAppPermissionRequest {
|
|
46
45
|
/**
|
|
47
46
|
* [App ID](https://dev.wix.com/docs/build-apps/get-started/overview/glossary#app-id).
|
|
48
47
|
*
|
|
@@ -59,11 +58,11 @@ export interface GetAppPermissionRequest {
|
|
|
59
58
|
*/
|
|
60
59
|
permissionId?: string;
|
|
61
60
|
}
|
|
62
|
-
|
|
61
|
+
interface GetAppPermissionResponse {
|
|
63
62
|
/** Details of the retrieved app permission. */
|
|
64
63
|
appPermission?: AppPermission;
|
|
65
64
|
}
|
|
66
|
-
|
|
65
|
+
interface ListAppPermissionsRequest {
|
|
67
66
|
/**
|
|
68
67
|
* [App ID](https://dev.wix.com/docs/build-apps/get-started/overview/glossary#app-id).
|
|
69
68
|
*
|
|
@@ -80,7 +79,7 @@ export interface ListAppPermissionsRequest {
|
|
|
80
79
|
/** Paging configuration. */
|
|
81
80
|
paging?: CursorPaging;
|
|
82
81
|
}
|
|
83
|
-
|
|
82
|
+
interface CursorPaging {
|
|
84
83
|
/**
|
|
85
84
|
* Maximum number of items to return in the results.
|
|
86
85
|
* @max 100
|
|
@@ -95,13 +94,13 @@ export interface CursorPaging {
|
|
|
95
94
|
*/
|
|
96
95
|
cursor?: string | null;
|
|
97
96
|
}
|
|
98
|
-
|
|
97
|
+
interface ListAppPermissionsResponse {
|
|
99
98
|
/** List of permissions for the specified app. */
|
|
100
99
|
appPermissions?: AppPermission[];
|
|
101
100
|
/** Paging metadata. */
|
|
102
101
|
pagingMetadata?: CursorPagingMetadata;
|
|
103
102
|
}
|
|
104
|
-
|
|
103
|
+
interface CursorPagingMetadata {
|
|
105
104
|
/** Number of items returned in current page. */
|
|
106
105
|
count?: number | null;
|
|
107
106
|
/** Cursor strings that point to the next page, previous page, or both. */
|
|
@@ -114,7 +113,7 @@ export interface CursorPagingMetadata {
|
|
|
114
113
|
*/
|
|
115
114
|
hasNext?: boolean | null;
|
|
116
115
|
}
|
|
117
|
-
|
|
116
|
+
interface Cursors {
|
|
118
117
|
/**
|
|
119
118
|
* Cursor string pointing to the next page in the list of results.
|
|
120
119
|
* @maxLength 16000
|
|
@@ -126,7 +125,7 @@ export interface Cursors {
|
|
|
126
125
|
*/
|
|
127
126
|
prev?: string | null;
|
|
128
127
|
}
|
|
129
|
-
|
|
128
|
+
interface DeleteAppPermissionRequest {
|
|
130
129
|
/**
|
|
131
130
|
* [App ID](https://dev.wix.com/docs/build-apps/get-started/overview/glossary#app-id).
|
|
132
131
|
*
|
|
@@ -143,18 +142,18 @@ export interface DeleteAppPermissionRequest {
|
|
|
143
142
|
*/
|
|
144
143
|
permissionId: string;
|
|
145
144
|
}
|
|
146
|
-
|
|
145
|
+
interface DeleteAppPermissionResponse {
|
|
147
146
|
}
|
|
148
|
-
|
|
147
|
+
interface PermissionActionDomainEventEntity {
|
|
149
148
|
/** The permission that had an event */
|
|
150
149
|
appPermission?: AppPermission;
|
|
151
150
|
/** The action which happened */
|
|
152
151
|
actionType?: ActionType;
|
|
153
152
|
}
|
|
154
|
-
|
|
153
|
+
declare enum ActionType {
|
|
155
154
|
APP_PERMISSION_DELETED = "APP_PERMISSION_DELETED"
|
|
156
155
|
}
|
|
157
|
-
|
|
156
|
+
interface DomainEvent extends DomainEventBodyOneOf {
|
|
158
157
|
createdEvent?: EntityCreatedEvent;
|
|
159
158
|
updatedEvent?: EntityUpdatedEvent;
|
|
160
159
|
deletedEvent?: EntityDeletedEvent;
|
|
@@ -197,19 +196,19 @@ export interface DomainEvent extends DomainEventBodyOneOf {
|
|
|
197
196
|
entityEventSequence?: string | null;
|
|
198
197
|
}
|
|
199
198
|
/** @oneof */
|
|
200
|
-
|
|
199
|
+
interface DomainEventBodyOneOf {
|
|
201
200
|
createdEvent?: EntityCreatedEvent;
|
|
202
201
|
updatedEvent?: EntityUpdatedEvent;
|
|
203
202
|
deletedEvent?: EntityDeletedEvent;
|
|
204
203
|
actionEvent?: ActionEvent;
|
|
205
204
|
}
|
|
206
|
-
|
|
205
|
+
interface EntityCreatedEvent {
|
|
207
206
|
entity?: string;
|
|
208
207
|
}
|
|
209
|
-
|
|
208
|
+
interface RestoreInfo {
|
|
210
209
|
deletedDate?: Date | null;
|
|
211
210
|
}
|
|
212
|
-
|
|
211
|
+
interface EntityUpdatedEvent {
|
|
213
212
|
/**
|
|
214
213
|
* Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.
|
|
215
214
|
* This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.
|
|
@@ -217,30 +216,30 @@ export interface EntityUpdatedEvent {
|
|
|
217
216
|
*/
|
|
218
217
|
currentEntity?: string;
|
|
219
218
|
}
|
|
220
|
-
|
|
219
|
+
interface EntityDeletedEvent {
|
|
221
220
|
/** Entity that was deleted */
|
|
222
221
|
deletedEntity?: string | null;
|
|
223
222
|
}
|
|
224
|
-
|
|
223
|
+
interface ActionEvent {
|
|
225
224
|
body?: string;
|
|
226
225
|
}
|
|
227
|
-
|
|
226
|
+
interface Empty {
|
|
228
227
|
}
|
|
229
|
-
|
|
228
|
+
interface OldPermissionChangedEvent {
|
|
230
229
|
/** @format GUID */
|
|
231
230
|
appId?: string;
|
|
232
231
|
permission?: Permission;
|
|
233
232
|
action?: Action;
|
|
234
233
|
}
|
|
235
|
-
|
|
234
|
+
interface Permission {
|
|
236
235
|
permissionId?: string;
|
|
237
236
|
}
|
|
238
|
-
|
|
237
|
+
declare enum Action {
|
|
239
238
|
CREATED = "CREATED",
|
|
240
239
|
UPDATED = "UPDATED",
|
|
241
240
|
DELETED = "DELETED"
|
|
242
241
|
}
|
|
243
|
-
|
|
242
|
+
interface MessageEnvelope {
|
|
244
243
|
/**
|
|
245
244
|
* App instance ID.
|
|
246
245
|
* @format GUID
|
|
@@ -256,7 +255,7 @@ export interface MessageEnvelope {
|
|
|
256
255
|
/** Stringify payload. */
|
|
257
256
|
data?: string;
|
|
258
257
|
}
|
|
259
|
-
|
|
258
|
+
interface IdentificationData extends IdentificationDataIdOneOf {
|
|
260
259
|
/**
|
|
261
260
|
* ID of a site visitor that has not logged in to the site.
|
|
262
261
|
* @format GUID
|
|
@@ -281,7 +280,7 @@ export interface IdentificationData extends IdentificationDataIdOneOf {
|
|
|
281
280
|
identityType?: WebhookIdentityType;
|
|
282
281
|
}
|
|
283
282
|
/** @oneof */
|
|
284
|
-
|
|
283
|
+
interface IdentificationDataIdOneOf {
|
|
285
284
|
/**
|
|
286
285
|
* ID of a site visitor that has not logged in to the site.
|
|
287
286
|
* @format GUID
|
|
@@ -303,14 +302,14 @@ export interface IdentificationDataIdOneOf {
|
|
|
303
302
|
*/
|
|
304
303
|
appId?: string;
|
|
305
304
|
}
|
|
306
|
-
|
|
305
|
+
declare enum WebhookIdentityType {
|
|
307
306
|
UNKNOWN = "UNKNOWN",
|
|
308
307
|
ANONYMOUS_VISITOR = "ANONYMOUS_VISITOR",
|
|
309
308
|
MEMBER = "MEMBER",
|
|
310
309
|
WIX_USER = "WIX_USER",
|
|
311
310
|
APP = "APP"
|
|
312
311
|
}
|
|
313
|
-
|
|
312
|
+
interface BaseEventMetadata {
|
|
314
313
|
/**
|
|
315
314
|
* App instance ID.
|
|
316
315
|
* @format GUID
|
|
@@ -324,7 +323,7 @@ export interface BaseEventMetadata {
|
|
|
324
323
|
/** The identification type and identity data. */
|
|
325
324
|
identity?: IdentificationData;
|
|
326
325
|
}
|
|
327
|
-
|
|
326
|
+
interface EventMetadata extends BaseEventMetadata {
|
|
328
327
|
/**
|
|
329
328
|
* Unique event ID.
|
|
330
329
|
* Allows clients to ignore duplicate webhooks.
|
|
@@ -362,50 +361,14 @@ export interface EventMetadata extends BaseEventMetadata {
|
|
|
362
361
|
*/
|
|
363
362
|
entityEventSequence?: string | null;
|
|
364
363
|
}
|
|
365
|
-
|
|
364
|
+
interface AppPermissionCreatedEnvelope {
|
|
366
365
|
entity: AppPermission;
|
|
367
366
|
metadata: EventMetadata;
|
|
368
367
|
}
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
* @documentationMaturity preview
|
|
374
|
-
*/
|
|
375
|
-
export declare function onAppPermissionCreated(handler: (event: AppPermissionCreatedEnvelope) => void | Promise<void>): void;
|
|
376
|
-
type AppPermissionNonNullablePaths = `appId` | `permission.permissionId`;
|
|
377
|
-
/**
|
|
378
|
-
* Adds a permission to the specified app.
|
|
379
|
-
* @param appPermission - Permission to add to the specified app.
|
|
380
|
-
* @public
|
|
381
|
-
* @documentationMaturity preview
|
|
382
|
-
* @requiredField appPermission
|
|
383
|
-
* @requiredField appPermission.appId
|
|
384
|
-
* @requiredField appPermission.permission
|
|
385
|
-
* @requiredField appPermission.permission.permissionId
|
|
386
|
-
* @permissionId DEV_CENTER.CREATE_APP_PERMISSION
|
|
387
|
-
* @permissionScope Write Dev Center App Permissions
|
|
388
|
-
* @permissionScopeId SCOPE.DEV_CENTER.WRITE_PERMISSIONS
|
|
389
|
-
* @applicableIdentity APP
|
|
390
|
-
* @returns Details of permission that was added to the app.
|
|
391
|
-
* @fqn wix.devcenter.apps.permissions.v1.AppPermissionsService.CreateAppPermission
|
|
392
|
-
*/
|
|
393
|
-
export declare function createAppPermission(appPermission: NonNullablePaths<AppPermission, `appId` | `permission` | `permission.permissionId`>): Promise<NonNullablePaths<AppPermission, AppPermissionNonNullablePaths>>;
|
|
394
|
-
/**
|
|
395
|
-
* Lists all permissions for the specified app.
|
|
396
|
-
* @param appId - [App ID](https://dev.wix.com/docs/build-apps/get-started/overview/glossary#app-id).
|
|
397
|
-
*
|
|
398
|
-
* You can find the app ID on the [Home page](https://manage.wix.com/app-selector?title=Select+an+App&primaryButtonText=Select+Site&actionUrl=https%3A%2F%2Fdev.wix.com%2Fapps%2F%7BappId%7D%home) in the app's dashboard.
|
|
399
|
-
* @public
|
|
400
|
-
* @documentationMaturity preview
|
|
401
|
-
* @requiredField appId
|
|
402
|
-
* @permissionId DEV_CENTER.READ_APP_PERMISSIONS
|
|
403
|
-
* @fqn wix.devcenter.apps.permissions.v1.AppPermissionsService.ListAppPermissions
|
|
404
|
-
*/
|
|
405
|
-
export declare function listAppPermissions(appId: string, options?: ListAppPermissionsOptions): Promise<NonNullablePaths<ListAppPermissionsResponse, {
|
|
406
|
-
[P in AppPermissionNonNullablePaths]: `appPermissions.${number}.${P}`;
|
|
407
|
-
}[AppPermissionNonNullablePaths]>>;
|
|
408
|
-
export interface ListAppPermissionsOptions {
|
|
368
|
+
interface AppPermissionDeletedEnvelope {
|
|
369
|
+
metadata: EventMetadata;
|
|
370
|
+
}
|
|
371
|
+
interface ListAppPermissionsOptions {
|
|
409
372
|
/**
|
|
410
373
|
* Whether to retrieve the most recent permissions information. This decreases performance but ensures that the retrieved information is up-to-date, even immediately after an update.
|
|
411
374
|
*
|
|
@@ -415,31 +378,5 @@ export interface ListAppPermissionsOptions {
|
|
|
415
378
|
/** Paging configuration. */
|
|
416
379
|
paging?: CursorPaging;
|
|
417
380
|
}
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
* @param appId - [App ID](https://dev.wix.com/docs/build-apps/get-started/overview/glossary#app-id).
|
|
421
|
-
*
|
|
422
|
-
* You can find the app ID on the [Home page](https://manage.wix.com/app-selector?title=Select+an+App&primaryButtonText=Select+Site&actionUrl=https%3A%2F%2Fdev.wix.com%2Fapps%2F%7BappId%7D%home) in the app's dashboard.
|
|
423
|
-
* @public
|
|
424
|
-
* @documentationMaturity preview
|
|
425
|
-
* @requiredField appId
|
|
426
|
-
* @requiredField options
|
|
427
|
-
* @requiredField options.permissionId
|
|
428
|
-
* @permissionId DEV_CENTER.DELETE_APP_PERMISSION
|
|
429
|
-
* @permissionScope Write Dev Center App Permissions
|
|
430
|
-
* @permissionScopeId SCOPE.DEV_CENTER.WRITE_PERMISSIONS
|
|
431
|
-
* @applicableIdentity APP
|
|
432
|
-
* @fqn wix.devcenter.apps.permissions.v1.AppPermissionsService.DeleteAppPermission
|
|
433
|
-
*/
|
|
434
|
-
export declare function deleteAppPermission(appId: string, options: NonNullablePaths<DeleteAppPermissionOptions, `permissionId`>): Promise<void>;
|
|
435
|
-
export interface DeleteAppPermissionOptions {
|
|
436
|
-
/**
|
|
437
|
-
* Permission ID.
|
|
438
|
-
*
|
|
439
|
-
* To find the permission ID, navigate to the [Permissions page](https://dev.wix.com/app-selector?title=Select+an+App&primaryButtonText=Select+Site&actionUrl=https%3A%2F%2Fdev.wix.com%2Fapps%2F%7BappId%7D%2Fdev-center-permissions/add) in the app's dashboard and search for the [permission you want to configure](https://dev.wix.com/docs/build-apps/develop-your-app/access/authorization/configure-permissions-for-your-app#step-1--identify-required-permissions).
|
|
440
|
-
* @minLength 1
|
|
441
|
-
* @maxLength 164
|
|
442
|
-
*/
|
|
443
|
-
permissionId: string;
|
|
444
|
-
}
|
|
445
|
-
export {};
|
|
381
|
+
|
|
382
|
+
export { type AppPermission as A, type BaseEventMetadata as B, type CreateAppPermissionRequest as C, type DeleteAppPermissionRequest as D, type EntityCreatedEvent as E, type GetAppPermissionRequest as G, type IdentificationData as I, type ListAppPermissionsOptions as L, type MessageEnvelope as M, type OldPermissionChangedEvent as O, type PermissionActionDomainEventEntity as P, type RestoreInfo as R, type V1Permission as V, WebhookIdentityType as W, type ListAppPermissionsResponse as a, ActionType as b, Action as c, type CreateAppPermissionResponse as d, type GetAppPermissionResponse as e, type ListAppPermissionsRequest as f, type CursorPaging as g, type CursorPagingMetadata as h, type Cursors as i, type DeleteAppPermissionResponse as j, type DomainEvent as k, type DomainEventBodyOneOf as l, type EntityUpdatedEvent as m, type EntityDeletedEvent as n, type ActionEvent as o, type Empty as p, type Permission as q, type IdentificationDataIdOneOf as r, type EventMetadata as s, type AppPermissionCreatedEnvelope as t, type AppPermissionDeletedEnvelope as u };
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import { HttpClient, MaybeContext, BuildRESTFunction } from '@wix/sdk-types';
|
|
2
|
+
import { A as AppPermission, L as ListAppPermissionsOptions, a as ListAppPermissionsResponse } from './devcenter-apps-v1-app-permission-app-permissions.universal-ROYtr-wC.mjs';
|
|
3
|
+
export { c as Action, o as ActionEvent, b as ActionType, t as AppPermissionCreatedEnvelope, u as AppPermissionDeletedEnvelope, B as BaseEventMetadata, C as CreateAppPermissionRequest, d as CreateAppPermissionResponse, g as CursorPaging, h as CursorPagingMetadata, i as Cursors, D as DeleteAppPermissionRequest, j as DeleteAppPermissionResponse, k as DomainEvent, l as DomainEventBodyOneOf, p as Empty, E as EntityCreatedEvent, n as EntityDeletedEvent, m as EntityUpdatedEvent, s as EventMetadata, G as GetAppPermissionRequest, e as GetAppPermissionResponse, I as IdentificationData, r as IdentificationDataIdOneOf, f as ListAppPermissionsRequest, M as MessageEnvelope, O as OldPermissionChangedEvent, q as Permission, P as PermissionActionDomainEventEntity, R as RestoreInfo, V as V1Permission, W as WebhookIdentityType } from './devcenter-apps-v1-app-permission-app-permissions.universal-ROYtr-wC.mjs';
|
|
4
|
+
import { createEventModule } from '@wix/sdk-runtime/event-definition-modules';
|
|
5
|
+
|
|
6
|
+
declare function createAppPermission$1(httpClient: HttpClient): CreateAppPermissionSignature;
|
|
7
|
+
interface CreateAppPermissionSignature {
|
|
8
|
+
/**
|
|
9
|
+
* Adds a permission to the specified app.
|
|
10
|
+
* @param - Permission to add to the specified app.
|
|
11
|
+
* @returns Details of permission that was added to the app.
|
|
12
|
+
*/
|
|
13
|
+
(appPermission: AppPermission): Promise<AppPermission>;
|
|
14
|
+
}
|
|
15
|
+
declare function listAppPermissions$1(httpClient: HttpClient): ListAppPermissionsSignature;
|
|
16
|
+
interface ListAppPermissionsSignature {
|
|
17
|
+
/**
|
|
18
|
+
* Lists all permissions for the specified app.
|
|
19
|
+
* @param - [App ID](https://dev.wix.com/docs/build-apps/get-started/overview/glossary#app-id).
|
|
20
|
+
*
|
|
21
|
+
* You can find the app ID on the [Home page](https://manage.wix.com/app-selector?title=Select+an+App&primaryButtonText=Select+Site&actionUrl=https%3A%2F%2Fdev.wix.com%2Fapps%2F%7BappId%7D%home) in the app's dashboard.
|
|
22
|
+
*/
|
|
23
|
+
(appId: string, options?: ListAppPermissionsOptions | undefined): Promise<ListAppPermissionsResponse>;
|
|
24
|
+
}
|
|
25
|
+
declare function deleteAppPermission$1(httpClient: HttpClient): DeleteAppPermissionSignature;
|
|
26
|
+
interface DeleteAppPermissionSignature {
|
|
27
|
+
/**
|
|
28
|
+
* Deletes a permission from the specified app.
|
|
29
|
+
* @param - [App ID](https://dev.wix.com/docs/build-apps/get-started/overview/glossary#app-id).
|
|
30
|
+
*
|
|
31
|
+
* You can find the app ID on the [Home page](https://manage.wix.com/app-selector?title=Select+an+App&primaryButtonText=Select+Site&actionUrl=https%3A%2F%2Fdev.wix.com%2Fapps%2F%7BappId%7D%home) in the app's dashboard.
|
|
32
|
+
* @param - Permission ID.
|
|
33
|
+
*
|
|
34
|
+
* To find the permission ID, navigate to the [Permissions page](https://dev.wix.com/app-selector?title=Select+an+App&primaryButtonText=Select+Site&actionUrl=https%3A%2F%2Fdev.wix.com%2Fapps%2F%7BappId%7D%2Fdev-center-permissions/add) in the app's dashboard and search for the [permission you want to configure](https://dev.wix.com/docs/build-apps/develop-your-app/access/authorization/configure-permissions-for-your-app#step-1--identify-required-permissions).
|
|
35
|
+
*/
|
|
36
|
+
(appId: string, permissionId: string): Promise<void>;
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
declare const createAppPermission: MaybeContext<BuildRESTFunction<typeof createAppPermission$1> & typeof createAppPermission$1>;
|
|
40
|
+
declare const listAppPermissions: MaybeContext<BuildRESTFunction<typeof listAppPermissions$1> & typeof listAppPermissions$1>;
|
|
41
|
+
declare const deleteAppPermission: MaybeContext<BuildRESTFunction<typeof deleteAppPermission$1> & typeof deleteAppPermission$1>;
|
|
42
|
+
/** */
|
|
43
|
+
declare const onAppPermissionCreated: ReturnType<typeof createEventModule<typeof publicOnAppPermissionCreated>>;
|
|
44
|
+
/** */
|
|
45
|
+
declare const onAppPermissionDeleted: ReturnType<typeof createEventModule<typeof publicOnAppPermissionDeleted>>;
|
|
46
|
+
|
|
47
|
+
export { AppPermission, ListAppPermissionsOptions, ListAppPermissionsResponse, createAppPermission, deleteAppPermission, listAppPermissions, onAppPermissionCreated, onAppPermissionDeleted };
|