@boxyhq/saml-jackson 1.37.0 → 1.37.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/dist/controller/api.d.ts +521 -474
- package/dist/controller/api.js +521 -474
- package/dist/controller/api.js.map +1 -1
- package/dist/controller/oauth.d.ts +88 -87
- package/dist/controller/oauth.js +146 -101
- package/dist/controller/oauth.js.map +1 -1
- package/dist/controller/setup-link.d.ts +343 -234
- package/dist/controller/setup-link.js +343 -234
- package/dist/controller/setup-link.js.map +1 -1
- package/dist/directory-sync/scim/DirectoryConfig.d.ts +265 -224
- package/dist/directory-sync/scim/DirectoryConfig.js +265 -224
- package/dist/directory-sync/scim/DirectoryConfig.js.map +1 -1
- package/dist/directory-sync/scim/Groups.d.ts +82 -87
- package/dist/directory-sync/scim/Groups.js +82 -87
- package/dist/directory-sync/scim/Groups.js.map +1 -1
- package/dist/directory-sync/scim/Users.d.ts +63 -49
- package/dist/directory-sync/scim/Users.js +63 -49
- package/dist/directory-sync/scim/Users.js.map +1 -1
- package/dist/directory-sync/scim/WebhookEventsLogger.d.ts +52 -61
- package/dist/directory-sync/scim/WebhookEventsLogger.js +52 -61
- package/dist/directory-sync/scim/WebhookEventsLogger.js.map +1 -1
- package/dist/ee/identity-federation/app.d.ts +292 -212
- package/dist/ee/identity-federation/app.js +292 -212
- package/dist/ee/identity-federation/app.js.map +1 -1
- package/dist/ee/identity-federation/idp-login.js +1 -1
- package/dist/ee/identity-federation/idp-login.js.map +1 -1
- package/dist/sso-traces/index.d.ts +67 -66
- package/dist/sso-traces/index.js +67 -66
- package/dist/sso-traces/index.js.map +1 -1
- package/dist/sso-traces/types.d.ts +1 -0
- package/package.json +7 -7
@@ -14,31 +14,6 @@ const error_1 = require("../../controller/error");
|
|
14
14
|
const Base_1 = require("./Base");
|
15
15
|
const utils_1 = require("../../db/utils");
|
16
16
|
const utils_2 = require("./utils");
|
17
|
-
/**
|
18
|
-
* @swagger
|
19
|
-
* definitions:
|
20
|
-
* User:
|
21
|
-
* type: object
|
22
|
-
* properties:
|
23
|
-
* id:
|
24
|
-
* type: string
|
25
|
-
* description: User ID
|
26
|
-
* first_name:
|
27
|
-
* type: string
|
28
|
-
* description: First name
|
29
|
-
* last_name:
|
30
|
-
* type: string
|
31
|
-
* description: Last name
|
32
|
-
* email:
|
33
|
-
* type: string
|
34
|
-
* description: Email address
|
35
|
-
* active:
|
36
|
-
* type: boolean
|
37
|
-
* description: Indicates whether the user is active or not
|
38
|
-
* raw:
|
39
|
-
* type: object
|
40
|
-
* description: Raw user attributes from the Identity Provider
|
41
|
-
*/
|
42
17
|
class Users extends Base_1.Base {
|
43
18
|
constructor({ db }) {
|
44
19
|
super({ db });
|
@@ -63,28 +38,69 @@ class Users extends Base_1.Base {
|
|
63
38
|
});
|
64
39
|
}
|
65
40
|
/**
|
66
|
-
* @
|
41
|
+
* @openapi
|
42
|
+
* components:
|
43
|
+
* schemas:
|
44
|
+
* User:
|
45
|
+
* type: object
|
46
|
+
* properties:
|
47
|
+
* id:
|
48
|
+
* type: string
|
49
|
+
* description: User ID
|
50
|
+
* first_name:
|
51
|
+
* type: string
|
52
|
+
* description: First name
|
53
|
+
* last_name:
|
54
|
+
* type: string
|
55
|
+
* description: Last name
|
56
|
+
* email:
|
57
|
+
* type: string
|
58
|
+
* description: Email address
|
59
|
+
* active:
|
60
|
+
* type: boolean
|
61
|
+
* description: Indicates whether the user is active or not
|
62
|
+
* raw:
|
63
|
+
* type: object
|
64
|
+
* properties: {}
|
65
|
+
* description: Raw user attributes from the Identity Provider
|
66
|
+
*
|
67
|
+
*/
|
68
|
+
/**
|
69
|
+
* @openapi
|
67
70
|
* /api/v1/dsync/users/{userId}:
|
68
71
|
* get:
|
72
|
+
* tags:
|
73
|
+
* - Directory Sync
|
69
74
|
* summary: Get user by id from a directory
|
70
75
|
* parameters:
|
71
|
-
* -
|
72
|
-
*
|
73
|
-
*
|
76
|
+
* - name: tenant
|
77
|
+
* in: query
|
78
|
+
* description: Tenant (Optional if directoryId is provided)
|
79
|
+
* schema:
|
80
|
+
* type: string
|
81
|
+
* - name: product
|
82
|
+
* in: query
|
83
|
+
* description: Product (Optional if directoryId is provided)
|
84
|
+
* schema:
|
85
|
+
* type: string
|
86
|
+
* - name: directoryId
|
87
|
+
* in: query
|
88
|
+
* description: Directory ID (Optional if tenant/product is provided)
|
89
|
+
* schema:
|
90
|
+
* type: string
|
74
91
|
* - name: userId
|
75
|
-
* description: User ID
|
76
92
|
* in: path
|
93
|
+
* description: User ID
|
77
94
|
* required: true
|
78
|
-
*
|
79
|
-
*
|
80
|
-
* - Directory Sync
|
81
|
-
* produces:
|
82
|
-
* - application/json
|
95
|
+
* schema:
|
96
|
+
* type: string
|
83
97
|
* responses:
|
84
98
|
* 200:
|
85
99
|
* description: Success
|
86
|
-
*
|
87
|
-
*
|
100
|
+
* content:
|
101
|
+
* application/json:
|
102
|
+
* schema:
|
103
|
+
* $ref: "#/components/schemas/User"
|
88
104
|
*/
|
89
105
|
get(id) {
|
90
106
|
return __awaiter(this, void 0, void 0, function* () {
|
@@ -147,21 +163,19 @@ class Users extends Base_1.Base {
|
|
147
163
|
});
|
148
164
|
}
|
149
165
|
/**
|
150
|
-
* @
|
166
|
+
* @openapi
|
151
167
|
* /api/v1/dsync/users:
|
152
168
|
* get:
|
153
|
-
* summary: Get users from a directory
|
154
|
-
* parameters:
|
155
|
-
* - $ref: '#/parameters/tenant'
|
156
|
-
* - $ref: '#/parameters/product'
|
157
|
-
* - $ref: '#/parameters/directoryId'
|
158
|
-
* - $ref: '#/parameters/pageOffset'
|
159
|
-
* - $ref: '#/parameters/pageLimit'
|
160
|
-
* - $ref: '#/parameters/pageToken'
|
161
169
|
* tags:
|
162
170
|
* - Directory Sync
|
163
|
-
*
|
164
|
-
*
|
171
|
+
* summary: Get users from a directory
|
172
|
+
* parameters:
|
173
|
+
* - $ref: '#/components/parameters/tenant'
|
174
|
+
* - $ref: '#/components/parameters/product'
|
175
|
+
* - $ref: '#/components/parameters/directoryId'
|
176
|
+
* - $ref: '#/components/parameters/pageOffset'
|
177
|
+
* - $ref: '#/components/parameters/pageLimit'
|
178
|
+
* - $ref: '#/components/parameters/pageToken'
|
165
179
|
* responses:
|
166
180
|
* 200:
|
167
181
|
* description: Success
|
@@ -173,7 +187,7 @@ class Users extends Base_1.Base {
|
|
173
187
|
* data:
|
174
188
|
* type: array
|
175
189
|
* items:
|
176
|
-
* $ref: '#/
|
190
|
+
* $ref: '#/components/schemas/User'
|
177
191
|
* pageToken:
|
178
192
|
* type: string
|
179
193
|
* description: token for pagination
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"Users.js","sourceRoot":"","sources":["../../../src/directory-sync/scim/Users.ts"],"names":[],"mappings":";;;;;;;;;;;;AACA,kDAAgE;AAChE,iCAA8B;AAC9B,0CAA8C;AAC9C,mCAAqC;AAErC
|
1
|
+
{"version":3,"file":"Users.js","sourceRoot":"","sources":["../../../src/directory-sync/scim/Users.ts"],"names":[],"mappings":";;;;;;;;;;;;AACA,kDAAgE;AAChE,iCAA8B;AAC9B,0CAA8C;AAC9C,mCAAqC;AAErC,MAAa,KAAM,SAAQ,WAAI;IAC7B,YAAY,EAAE,EAAE,EAAyB;QACvC,KAAK,CAAC,EAAE,EAAE,EAAE,CAAC,CAAC;IAChB,CAAC;IAED,oBAAoB;IACP,MAAM,CAAC,IAAoC;;YACtD,MAAM,EAAE,WAAW,EAAE,EAAE,EAAE,KAAK,EAAE,GAAG,IAAI,CAAC;YAExC,IAAI,CAAC;gBACH,MAAM,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC,GAAG,CAC3B,EAAE,EACF,IAAI,EACJ;oBACE,IAAI,EAAE,kBAAU,CAAC,mBAAmB;oBACpC,KAAK,EAAE,IAAA,oBAAY,EAAC,WAAW,EAAE,KAAK,CAAC;iBACxC,EACD;oBACE,IAAI,EAAE,kBAAU,CAAC,WAAW;oBAC5B,KAAK,EAAE,WAAW;iB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AAC;KAAA;CACF;AA/OD,sBA+OC"}
|
@@ -3,55 +3,6 @@ import { Base } from './Base';
|
|
3
3
|
type GetAllParams = PaginationParams & {
|
4
4
|
directoryId?: string;
|
5
5
|
};
|
6
|
-
/**
|
7
|
-
* @swagger
|
8
|
-
* definitions:
|
9
|
-
* Event:
|
10
|
-
* type: object
|
11
|
-
* example:
|
12
|
-
* {
|
13
|
-
* "id": "id1",
|
14
|
-
* "webhook_endpoint": "https://example.com/webhook",
|
15
|
-
* "created_at": "2024-03-05T17:06:26.074Z",
|
16
|
-
* "status_code": 200,
|
17
|
-
* "delivered": true,
|
18
|
-
* "payload": {
|
19
|
-
* "directory_id": "58b5cd9dfaa39d47eb8f5f88631f9a629a232016",
|
20
|
-
* "event": "user.created",
|
21
|
-
* "tenant": "boxyhq",
|
22
|
-
* "product": "jackson",
|
23
|
-
* "data": {
|
24
|
-
* "id": "038e767b-9bc6-4dbd-975e-fbc38a8e7d82",
|
25
|
-
* "first_name": "Deepak",
|
26
|
-
* "last_name": "Prabhakara",
|
27
|
-
* "email": "deepak@boxyhq.com",
|
28
|
-
* "active": true,
|
29
|
-
* "raw": {
|
30
|
-
* "schemas": ["urn:ietf:params:scim:schemas:core:2.0:User"],
|
31
|
-
* "userName": "deepak@boxyhq.com",
|
32
|
-
* "name": {
|
33
|
-
* "givenName": "Deepak",
|
34
|
-
* "familyName": "Prabhakara"
|
35
|
-
* },
|
36
|
-
* "emails": [
|
37
|
-
* {
|
38
|
-
* "primary": true,
|
39
|
-
* "value": "deepak@boxyhq.com",
|
40
|
-
* "type": "work"
|
41
|
-
* }
|
42
|
-
* ],
|
43
|
-
* "title": "CEO",
|
44
|
-
* "displayName": "Deepak Prabhakara",
|
45
|
-
* "locale": "en-US",
|
46
|
-
* "externalId": "00u1ldzzogFkXFmvT5d7",
|
47
|
-
* "groups": [],
|
48
|
-
* "active": true,
|
49
|
-
* "id": "038e767b-9bc6-4dbd-975e-fbc38a8e7d82"
|
50
|
-
* }
|
51
|
-
* }
|
52
|
-
* }
|
53
|
-
* }
|
54
|
-
*/
|
55
6
|
export declare class WebhookEventsLogger extends Base {
|
56
7
|
constructor({ db }: {
|
57
8
|
db: DatabaseStore;
|
@@ -59,21 +10,61 @@ export declare class WebhookEventsLogger extends Base {
|
|
59
10
|
log(directory: Directory, event: DirectorySyncEvent | DirectorySyncEvent[], status: number): Promise<WebhookEventLog>;
|
60
11
|
get(id: string): Promise<WebhookEventLog>;
|
61
12
|
/**
|
62
|
-
* @
|
13
|
+
* @openapi
|
14
|
+
* components:
|
15
|
+
* schemas:
|
16
|
+
* Event:
|
17
|
+
* type: object
|
18
|
+
* example:
|
19
|
+
* id: id1
|
20
|
+
* webhook_endpoint: https://example.com/webhook
|
21
|
+
* created_at: "2024-03-05T17:06:26.074Z"
|
22
|
+
* status_code: 200
|
23
|
+
* delivered: true
|
24
|
+
* payload:
|
25
|
+
* directory_id: 58b5cd9dfaa39d47eb8f5f88631f9a629a232016
|
26
|
+
* event: user.created
|
27
|
+
* tenant: boxyhq
|
28
|
+
* product: jackson
|
29
|
+
* data:
|
30
|
+
* id: 038e767b-9bc6-4dbd-975e-fbc38a8e7d82
|
31
|
+
* first_name: Deepak
|
32
|
+
* last_name: Prabhakara
|
33
|
+
* email: deepak@boxyhq.com
|
34
|
+
* active: true
|
35
|
+
* raw:
|
36
|
+
* schemas:
|
37
|
+
* - urn:ietf:params:scim:schemas:core:2.0:User
|
38
|
+
* userName: deepak@boxyhq.com
|
39
|
+
* name:
|
40
|
+
* givenName: Deepak
|
41
|
+
* familyName: Prabhakara
|
42
|
+
* emails:
|
43
|
+
* - primary: true
|
44
|
+
* value: deepak@boxyhq.com
|
45
|
+
* type: work
|
46
|
+
* title: CEO
|
47
|
+
* displayName: Deepak Prabhakara
|
48
|
+
* locale: en-US
|
49
|
+
* externalId: 00u1ldzzogFkXFmvT5d7
|
50
|
+
* groups: []
|
51
|
+
* active: true
|
52
|
+
*
|
53
|
+
*/
|
54
|
+
/**
|
55
|
+
* @openapi
|
63
56
|
* /api/v1/dsync/events:
|
64
57
|
* get:
|
65
|
-
* summary: Get event logs for a directory
|
66
|
-
* parameters:
|
67
|
-
* - $ref: '#/parameters/directoryId'
|
68
|
-
* - $ref: '#/parameters/tenant'
|
69
|
-
* - $ref: '#/parameters/product'
|
70
|
-
* - $ref: '#/parameters/pageOffset'
|
71
|
-
* - $ref: '#/parameters/pageLimit'
|
72
|
-
* - $ref: '#/parameters/pageToken'
|
73
58
|
* tags:
|
74
59
|
* - Directory Sync
|
75
|
-
*
|
76
|
-
*
|
60
|
+
* summary: Get event logs for a directory
|
61
|
+
* parameters:
|
62
|
+
* - $ref: '#/components/parameters/directoryId'
|
63
|
+
* - $ref: '#/components/parameters/tenant'
|
64
|
+
* - $ref: '#/components/parameters/product'
|
65
|
+
* - $ref: '#/components/parameters/pageOffset'
|
66
|
+
* - $ref: '#/components/parameters/pageLimit'
|
67
|
+
* - $ref: '#/components/parameters/pageToken'
|
77
68
|
* responses:
|
78
69
|
* 200:
|
79
70
|
* description: Success
|
@@ -85,7 +76,7 @@ export declare class WebhookEventsLogger extends Base {
|
|
85
76
|
* data:
|
86
77
|
* type: array
|
87
78
|
* items:
|
88
|
-
* $ref: '#/
|
79
|
+
* $ref: '#/components/schemas/Event'
|
89
80
|
* pageToken:
|
90
81
|
* type: string
|
91
82
|
* description: token for pagination
|
@@ -14,55 +14,6 @@ const crypto_1 = require("crypto");
|
|
14
14
|
const Base_1 = require("./Base");
|
15
15
|
const utils_1 = require("../utils");
|
16
16
|
const utils_2 = require("./utils");
|
17
|
-
/**
|
18
|
-
* @swagger
|
19
|
-
* definitions:
|
20
|
-
* Event:
|
21
|
-
* type: object
|
22
|
-
* example:
|
23
|
-
* {
|
24
|
-
* "id": "id1",
|
25
|
-
* "webhook_endpoint": "https://example.com/webhook",
|
26
|
-
* "created_at": "2024-03-05T17:06:26.074Z",
|
27
|
-
* "status_code": 200,
|
28
|
-
* "delivered": true,
|
29
|
-
* "payload": {
|
30
|
-
* "directory_id": "58b5cd9dfaa39d47eb8f5f88631f9a629a232016",
|
31
|
-
* "event": "user.created",
|
32
|
-
* "tenant": "boxyhq",
|
33
|
-
* "product": "jackson",
|
34
|
-
* "data": {
|
35
|
-
* "id": "038e767b-9bc6-4dbd-975e-fbc38a8e7d82",
|
36
|
-
* "first_name": "Deepak",
|
37
|
-
* "last_name": "Prabhakara",
|
38
|
-
* "email": "deepak@boxyhq.com",
|
39
|
-
* "active": true,
|
40
|
-
* "raw": {
|
41
|
-
* "schemas": ["urn:ietf:params:scim:schemas:core:2.0:User"],
|
42
|
-
* "userName": "deepak@boxyhq.com",
|
43
|
-
* "name": {
|
44
|
-
* "givenName": "Deepak",
|
45
|
-
* "familyName": "Prabhakara"
|
46
|
-
* },
|
47
|
-
* "emails": [
|
48
|
-
* {
|
49
|
-
* "primary": true,
|
50
|
-
* "value": "deepak@boxyhq.com",
|
51
|
-
* "type": "work"
|
52
|
-
* }
|
53
|
-
* ],
|
54
|
-
* "title": "CEO",
|
55
|
-
* "displayName": "Deepak Prabhakara",
|
56
|
-
* "locale": "en-US",
|
57
|
-
* "externalId": "00u1ldzzogFkXFmvT5d7",
|
58
|
-
* "groups": [],
|
59
|
-
* "active": true,
|
60
|
-
* "id": "038e767b-9bc6-4dbd-975e-fbc38a8e7d82"
|
61
|
-
* }
|
62
|
-
* }
|
63
|
-
* }
|
64
|
-
* }
|
65
|
-
*/
|
66
17
|
class WebhookEventsLogger extends Base_1.Base {
|
67
18
|
constructor({ db }) {
|
68
19
|
super({ db });
|
@@ -91,21 +42,61 @@ class WebhookEventsLogger extends Base_1.Base {
|
|
91
42
|
});
|
92
43
|
}
|
93
44
|
/**
|
94
|
-
* @
|
45
|
+
* @openapi
|
46
|
+
* components:
|
47
|
+
* schemas:
|
48
|
+
* Event:
|
49
|
+
* type: object
|
50
|
+
* example:
|
51
|
+
* id: id1
|
52
|
+
* webhook_endpoint: https://example.com/webhook
|
53
|
+
* created_at: "2024-03-05T17:06:26.074Z"
|
54
|
+
* status_code: 200
|
55
|
+
* delivered: true
|
56
|
+
* payload:
|
57
|
+
* directory_id: 58b5cd9dfaa39d47eb8f5f88631f9a629a232016
|
58
|
+
* event: user.created
|
59
|
+
* tenant: boxyhq
|
60
|
+
* product: jackson
|
61
|
+
* data:
|
62
|
+
* id: 038e767b-9bc6-4dbd-975e-fbc38a8e7d82
|
63
|
+
* first_name: Deepak
|
64
|
+
* last_name: Prabhakara
|
65
|
+
* email: deepak@boxyhq.com
|
66
|
+
* active: true
|
67
|
+
* raw:
|
68
|
+
* schemas:
|
69
|
+
* - urn:ietf:params:scim:schemas:core:2.0:User
|
70
|
+
* userName: deepak@boxyhq.com
|
71
|
+
* name:
|
72
|
+
* givenName: Deepak
|
73
|
+
* familyName: Prabhakara
|
74
|
+
* emails:
|
75
|
+
* - primary: true
|
76
|
+
* value: deepak@boxyhq.com
|
77
|
+
* type: work
|
78
|
+
* title: CEO
|
79
|
+
* displayName: Deepak Prabhakara
|
80
|
+
* locale: en-US
|
81
|
+
* externalId: 00u1ldzzogFkXFmvT5d7
|
82
|
+
* groups: []
|
83
|
+
* active: true
|
84
|
+
*
|
85
|
+
*/
|
86
|
+
/**
|
87
|
+
* @openapi
|
95
88
|
* /api/v1/dsync/events:
|
96
89
|
* get:
|
97
|
-
* summary: Get event logs for a directory
|
98
|
-
* parameters:
|
99
|
-
* - $ref: '#/parameters/directoryId'
|
100
|
-
* - $ref: '#/parameters/tenant'
|
101
|
-
* - $ref: '#/parameters/product'
|
102
|
-
* - $ref: '#/parameters/pageOffset'
|
103
|
-
* - $ref: '#/parameters/pageLimit'
|
104
|
-
* - $ref: '#/parameters/pageToken'
|
105
90
|
* tags:
|
106
91
|
* - Directory Sync
|
107
|
-
*
|
108
|
-
*
|
92
|
+
* summary: Get event logs for a directory
|
93
|
+
* parameters:
|
94
|
+
* - $ref: '#/components/parameters/directoryId'
|
95
|
+
* - $ref: '#/components/parameters/tenant'
|
96
|
+
* - $ref: '#/components/parameters/product'
|
97
|
+
* - $ref: '#/components/parameters/pageOffset'
|
98
|
+
* - $ref: '#/components/parameters/pageLimit'
|
99
|
+
* - $ref: '#/components/parameters/pageToken'
|
109
100
|
* responses:
|
110
101
|
* 200:
|
111
102
|
* description: Success
|
@@ -117,7 +108,7 @@ class WebhookEventsLogger extends Base_1.Base {
|
|
117
108
|
* data:
|
118
109
|
* type: array
|
119
110
|
* items:
|
120
|
-
* $ref: '#/
|
111
|
+
* $ref: '#/components/schemas/Event'
|
121
112
|
* pageToken:
|
122
113
|
* type: string
|
123
114
|
* description: token for pagination
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"WebhookEventsLogger.js","sourceRoot":"","sources":["../../../src/directory-sync/scim/WebhookEventsLogger.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,mCAAoC;AAUpC,iCAA8B;AAC9B,oCAA0C;AAC1C,mCAAqC;AAMrC
|
1
|
+
{"version":3,"file":"WebhookEventsLogger.js","sourceRoot":"","sources":["../../../src/directory-sync/scim/WebhookEventsLogger.ts"],"names":[],"mappings":";;;;;;;;;;;;AAAA,mCAAoC;AAUpC,iCAA8B;AAC9B,oCAA0C;AAC1C,mCAAqC;AAMrC,MAAa,mBAAoB,SAAQ,WAAI;IAC3C,YAAY,EAAE,EAAE,EAAyB;QACvC,KAAK,CAAC,EAAE,EAAE,EAAE,CAAC,CAAC;IAChB,CAAC;IAEY,GAAG,CAAC,SAAoB,EAAE,KAAgD,EAAE,MAAc;;YACrG,MAAM,EAAE,GAAG,IAAA,mBAAU,GAAE,CAAC;YAExB,MAAM,GAAG,GAAoB;gBAC3B,EAAE;gBACF,OAAO,EAAE,KAAK;gBACd,gBAAgB,EAAE,SAAS,CAAC,OAAO,CAAC,QAAQ;gBAC5C,UAAU,EAAE,IAAI,IAAI,EAAE;gBACtB,WAAW,EAAE,MAAM;gBACnB,SAAS,EAAE,MAAM,KAAK,GAAG;aAC1B,CAAC;YAEF,MAAM,IAAI,CAAC,UAAU,EAA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