@dynamic-labs-wallet/core 0.0.117 → 0.0.119
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/index.cjs.js +14 -8
- package/index.esm.js +14 -8
- package/package.json +1 -1
- package/src/api/api.d.ts +12 -6
- package/src/api/api.d.ts.map +1 -1
- package/src/eventStream/utils.d.ts +2 -1
- package/src/eventStream/utils.d.ts.map +1 -1
package/index.cjs.js
CHANGED
|
@@ -455,7 +455,7 @@ var SuccessEventType = /*#__PURE__*/ function(SuccessEventType) {
|
|
|
455
455
|
* @param apiClient The axios instance to use for API calls
|
|
456
456
|
* @param options The configuration options
|
|
457
457
|
* @returns A promise that resolves with the event data or rejects on timeout
|
|
458
|
-
*/ const createEventStreamPromise = ({ apiClient, endpoint, body, successEventType, timeoutMs = 30000, timeoutMessage, onError, onCeremonyComplete })=>{
|
|
458
|
+
*/ const createEventStreamPromise = ({ apiClient, dynamicRequestId, endpoint, body, successEventType, timeoutMs = 30000, timeoutMessage, onError, onCeremonyComplete })=>{
|
|
459
459
|
// Create a promise that will resolve when the success event is received
|
|
460
460
|
const eventPromise = new Promise((resolve, reject)=>{
|
|
461
461
|
apiClient.post(endpoint, body, {
|
|
@@ -464,7 +464,7 @@ var SuccessEventType = /*#__PURE__*/ function(SuccessEventType) {
|
|
|
464
464
|
Accept: 'text/event-stream',
|
|
465
465
|
'Cache-Control': 'no-cache',
|
|
466
466
|
Connection: 'keep-alive',
|
|
467
|
-
[DynamicRequestIdHeader]:
|
|
467
|
+
[DynamicRequestIdHeader]: dynamicRequestId
|
|
468
468
|
},
|
|
469
469
|
adapter: 'fetch'
|
|
470
470
|
}).then(createSuccessErrorEventStreamHandler({
|
|
@@ -623,9 +623,10 @@ class DynamicApiClient extends BaseClient {
|
|
|
623
623
|
}
|
|
624
624
|
});
|
|
625
625
|
}
|
|
626
|
-
async createWalletAccount({ chainName, clientKeygenIds, thresholdSignatureScheme, onError, onCeremonyComplete }) {
|
|
626
|
+
async createWalletAccount({ chainName, clientKeygenIds, dynamicRequestId, thresholdSignatureScheme, onError, onCeremonyComplete }) {
|
|
627
627
|
return createEventStreamPromise({
|
|
628
628
|
apiClient: this.apiClient,
|
|
629
|
+
dynamicRequestId,
|
|
629
630
|
endpoint: `/api/v0/sdk/${this.environmentId}/waas/create`,
|
|
630
631
|
body: {
|
|
631
632
|
chain: chainName,
|
|
@@ -638,9 +639,10 @@ class DynamicApiClient extends BaseClient {
|
|
|
638
639
|
onCeremonyComplete
|
|
639
640
|
});
|
|
640
641
|
}
|
|
641
|
-
async signMessage({ walletId, message, onError, isFormatted }) {
|
|
642
|
+
async signMessage({ dynamicRequestId, walletId, message, onError, isFormatted }) {
|
|
642
643
|
return createEventStreamPromise({
|
|
643
644
|
apiClient: this.apiClient,
|
|
645
|
+
dynamicRequestId,
|
|
644
646
|
endpoint: `/api/v0/sdk/${this.environmentId}/waas/${walletId}/signMessage`,
|
|
645
647
|
body: {
|
|
646
648
|
message,
|
|
@@ -651,9 +653,10 @@ class DynamicApiClient extends BaseClient {
|
|
|
651
653
|
onError
|
|
652
654
|
});
|
|
653
655
|
}
|
|
654
|
-
async refreshWalletAccountShares({ walletId, onError }) {
|
|
656
|
+
async refreshWalletAccountShares({ dynamicRequestId, walletId, onError }) {
|
|
655
657
|
return createEventStreamPromise({
|
|
656
658
|
apiClient: this.apiClient,
|
|
659
|
+
dynamicRequestId,
|
|
657
660
|
endpoint: `/api/v0/sdk/${this.environmentId}/waas/${walletId}/refresh`,
|
|
658
661
|
body: undefined,
|
|
659
662
|
successEventType: SuccessEventType.RoomCreated,
|
|
@@ -661,9 +664,10 @@ class DynamicApiClient extends BaseClient {
|
|
|
661
664
|
onError
|
|
662
665
|
});
|
|
663
666
|
}
|
|
664
|
-
async reshare({ walletId, clientKeygenIds, oldThresholdSignatureScheme, newThresholdSignatureScheme, onError }) {
|
|
667
|
+
async reshare({ walletId, dynamicRequestId, clientKeygenIds, oldThresholdSignatureScheme, newThresholdSignatureScheme, onError }) {
|
|
665
668
|
return createEventStreamPromise({
|
|
666
669
|
apiClient: this.apiClient,
|
|
670
|
+
dynamicRequestId,
|
|
667
671
|
endpoint: `/api/v0/sdk/${this.environmentId}/waas/${walletId}/reshare`,
|
|
668
672
|
body: {
|
|
669
673
|
clientKeygenIds,
|
|
@@ -675,9 +679,10 @@ class DynamicApiClient extends BaseClient {
|
|
|
675
679
|
onError
|
|
676
680
|
});
|
|
677
681
|
}
|
|
678
|
-
async exportKey({ walletId, exportId, onError }) {
|
|
682
|
+
async exportKey({ dynamicRequestId, walletId, exportId, onError }) {
|
|
679
683
|
return createEventStreamPromise({
|
|
680
684
|
apiClient: this.apiClient,
|
|
685
|
+
dynamicRequestId,
|
|
681
686
|
endpoint: `/api/v0/sdk/${this.environmentId}/waas/${walletId}/privateKey/export`,
|
|
682
687
|
body: {
|
|
683
688
|
exportId
|
|
@@ -740,9 +745,10 @@ class DynamicApiClient extends BaseClient {
|
|
|
740
745
|
return data.accessToken;
|
|
741
746
|
}
|
|
742
747
|
// TODO: return array instead considering cases where server has multiple parties
|
|
743
|
-
async importPrivateKey({ chainName, clientKeygenIds, thresholdSignatureScheme, onError, onCeremonyComplete }) {
|
|
748
|
+
async importPrivateKey({ chainName, dynamicRequestId, clientKeygenIds, thresholdSignatureScheme, onError, onCeremonyComplete }) {
|
|
744
749
|
return createEventStreamPromise({
|
|
745
750
|
apiClient: this.apiClient,
|
|
751
|
+
dynamicRequestId,
|
|
746
752
|
endpoint: `/api/v0/sdk/${this.environmentId}/waas/privateKey/import`,
|
|
747
753
|
body: {
|
|
748
754
|
chain: chainName,
|
package/index.esm.js
CHANGED
|
@@ -453,7 +453,7 @@ var SuccessEventType = /*#__PURE__*/ function(SuccessEventType) {
|
|
|
453
453
|
* @param apiClient The axios instance to use for API calls
|
|
454
454
|
* @param options The configuration options
|
|
455
455
|
* @returns A promise that resolves with the event data or rejects on timeout
|
|
456
|
-
*/ const createEventStreamPromise = ({ apiClient, endpoint, body, successEventType, timeoutMs = 30000, timeoutMessage, onError, onCeremonyComplete })=>{
|
|
456
|
+
*/ const createEventStreamPromise = ({ apiClient, dynamicRequestId, endpoint, body, successEventType, timeoutMs = 30000, timeoutMessage, onError, onCeremonyComplete })=>{
|
|
457
457
|
// Create a promise that will resolve when the success event is received
|
|
458
458
|
const eventPromise = new Promise((resolve, reject)=>{
|
|
459
459
|
apiClient.post(endpoint, body, {
|
|
@@ -462,7 +462,7 @@ var SuccessEventType = /*#__PURE__*/ function(SuccessEventType) {
|
|
|
462
462
|
Accept: 'text/event-stream',
|
|
463
463
|
'Cache-Control': 'no-cache',
|
|
464
464
|
Connection: 'keep-alive',
|
|
465
|
-
[DynamicRequestIdHeader]:
|
|
465
|
+
[DynamicRequestIdHeader]: dynamicRequestId
|
|
466
466
|
},
|
|
467
467
|
adapter: 'fetch'
|
|
468
468
|
}).then(createSuccessErrorEventStreamHandler({
|
|
@@ -621,9 +621,10 @@ class DynamicApiClient extends BaseClient {
|
|
|
621
621
|
}
|
|
622
622
|
});
|
|
623
623
|
}
|
|
624
|
-
async createWalletAccount({ chainName, clientKeygenIds, thresholdSignatureScheme, onError, onCeremonyComplete }) {
|
|
624
|
+
async createWalletAccount({ chainName, clientKeygenIds, dynamicRequestId, thresholdSignatureScheme, onError, onCeremonyComplete }) {
|
|
625
625
|
return createEventStreamPromise({
|
|
626
626
|
apiClient: this.apiClient,
|
|
627
|
+
dynamicRequestId,
|
|
627
628
|
endpoint: `/api/v0/sdk/${this.environmentId}/waas/create`,
|
|
628
629
|
body: {
|
|
629
630
|
chain: chainName,
|
|
@@ -636,9 +637,10 @@ class DynamicApiClient extends BaseClient {
|
|
|
636
637
|
onCeremonyComplete
|
|
637
638
|
});
|
|
638
639
|
}
|
|
639
|
-
async signMessage({ walletId, message, onError, isFormatted }) {
|
|
640
|
+
async signMessage({ dynamicRequestId, walletId, message, onError, isFormatted }) {
|
|
640
641
|
return createEventStreamPromise({
|
|
641
642
|
apiClient: this.apiClient,
|
|
643
|
+
dynamicRequestId,
|
|
642
644
|
endpoint: `/api/v0/sdk/${this.environmentId}/waas/${walletId}/signMessage`,
|
|
643
645
|
body: {
|
|
644
646
|
message,
|
|
@@ -649,9 +651,10 @@ class DynamicApiClient extends BaseClient {
|
|
|
649
651
|
onError
|
|
650
652
|
});
|
|
651
653
|
}
|
|
652
|
-
async refreshWalletAccountShares({ walletId, onError }) {
|
|
654
|
+
async refreshWalletAccountShares({ dynamicRequestId, walletId, onError }) {
|
|
653
655
|
return createEventStreamPromise({
|
|
654
656
|
apiClient: this.apiClient,
|
|
657
|
+
dynamicRequestId,
|
|
655
658
|
endpoint: `/api/v0/sdk/${this.environmentId}/waas/${walletId}/refresh`,
|
|
656
659
|
body: undefined,
|
|
657
660
|
successEventType: SuccessEventType.RoomCreated,
|
|
@@ -659,9 +662,10 @@ class DynamicApiClient extends BaseClient {
|
|
|
659
662
|
onError
|
|
660
663
|
});
|
|
661
664
|
}
|
|
662
|
-
async reshare({ walletId, clientKeygenIds, oldThresholdSignatureScheme, newThresholdSignatureScheme, onError }) {
|
|
665
|
+
async reshare({ walletId, dynamicRequestId, clientKeygenIds, oldThresholdSignatureScheme, newThresholdSignatureScheme, onError }) {
|
|
663
666
|
return createEventStreamPromise({
|
|
664
667
|
apiClient: this.apiClient,
|
|
668
|
+
dynamicRequestId,
|
|
665
669
|
endpoint: `/api/v0/sdk/${this.environmentId}/waas/${walletId}/reshare`,
|
|
666
670
|
body: {
|
|
667
671
|
clientKeygenIds,
|
|
@@ -673,9 +677,10 @@ class DynamicApiClient extends BaseClient {
|
|
|
673
677
|
onError
|
|
674
678
|
});
|
|
675
679
|
}
|
|
676
|
-
async exportKey({ walletId, exportId, onError }) {
|
|
680
|
+
async exportKey({ dynamicRequestId, walletId, exportId, onError }) {
|
|
677
681
|
return createEventStreamPromise({
|
|
678
682
|
apiClient: this.apiClient,
|
|
683
|
+
dynamicRequestId,
|
|
679
684
|
endpoint: `/api/v0/sdk/${this.environmentId}/waas/${walletId}/privateKey/export`,
|
|
680
685
|
body: {
|
|
681
686
|
exportId
|
|
@@ -738,9 +743,10 @@ class DynamicApiClient extends BaseClient {
|
|
|
738
743
|
return data.accessToken;
|
|
739
744
|
}
|
|
740
745
|
// TODO: return array instead considering cases where server has multiple parties
|
|
741
|
-
async importPrivateKey({ chainName, clientKeygenIds, thresholdSignatureScheme, onError, onCeremonyComplete }) {
|
|
746
|
+
async importPrivateKey({ chainName, dynamicRequestId, clientKeygenIds, thresholdSignatureScheme, onError, onCeremonyComplete }) {
|
|
742
747
|
return createEventStreamPromise({
|
|
743
748
|
apiClient: this.apiClient,
|
|
749
|
+
dynamicRequestId,
|
|
744
750
|
endpoint: `/api/v0/sdk/${this.environmentId}/waas/privateKey/import`,
|
|
745
751
|
body: {
|
|
746
752
|
chain: chainName,
|
package/package.json
CHANGED
package/src/api/api.d.ts
CHANGED
|
@@ -11,34 +11,39 @@ export declare class DynamicApiClient extends BaseClient {
|
|
|
11
11
|
authenticateApiToken({ environmentId }: {
|
|
12
12
|
environmentId: string;
|
|
13
13
|
}): Promise<import("axios").AxiosResponse<any, any>>;
|
|
14
|
-
createWalletAccount({ chainName, clientKeygenIds, thresholdSignatureScheme, onError, onCeremonyComplete, }: {
|
|
14
|
+
createWalletAccount({ chainName, clientKeygenIds, dynamicRequestId, thresholdSignatureScheme, onError, onCeremonyComplete, }: {
|
|
15
15
|
chainName: string;
|
|
16
|
+
dynamicRequestId?: string;
|
|
16
17
|
clientKeygenIds: string[];
|
|
17
18
|
thresholdSignatureScheme: ThresholdSignatureScheme;
|
|
18
19
|
onError?: (error: Error) => void;
|
|
19
20
|
onCeremonyComplete?: (accountAddress: string, walletId: string) => void;
|
|
20
21
|
}): Promise<KeygenCompleteResponse>;
|
|
21
|
-
signMessage({ walletId, message, onError, isFormatted, }: {
|
|
22
|
+
signMessage({ dynamicRequestId, walletId, message, onError, isFormatted, }: {
|
|
23
|
+
dynamicRequestId?: string;
|
|
22
24
|
walletId: string;
|
|
23
25
|
message: string;
|
|
24
26
|
onError?: (error: Error) => void;
|
|
25
27
|
isFormatted?: boolean;
|
|
26
28
|
}): Promise<OpenRoomResponse>;
|
|
27
|
-
refreshWalletAccountShares({ walletId, onError, }: {
|
|
29
|
+
refreshWalletAccountShares({ dynamicRequestId, walletId, onError, }: {
|
|
30
|
+
dynamicRequestId?: string;
|
|
28
31
|
walletId: string;
|
|
29
32
|
onError?: (error: Error) => void;
|
|
30
33
|
}): Promise<{
|
|
31
34
|
roomId: string;
|
|
32
35
|
serverKeygenIds: string[];
|
|
33
36
|
}>;
|
|
34
|
-
reshare({ walletId, clientKeygenIds, oldThresholdSignatureScheme, newThresholdSignatureScheme, onError, }: {
|
|
37
|
+
reshare({ walletId, dynamicRequestId, clientKeygenIds, oldThresholdSignatureScheme, newThresholdSignatureScheme, onError, }: {
|
|
38
|
+
dynamicRequestId?: string;
|
|
35
39
|
walletId: string;
|
|
36
40
|
clientKeygenIds: string[];
|
|
37
41
|
oldThresholdSignatureScheme: ThresholdSignatureScheme;
|
|
38
42
|
newThresholdSignatureScheme: ThresholdSignatureScheme;
|
|
39
43
|
onError?: (error: Error) => void;
|
|
40
44
|
}): Promise<ReshareResponse>;
|
|
41
|
-
exportKey({ walletId, exportId, onError, }: {
|
|
45
|
+
exportKey({ dynamicRequestId, walletId, exportId, onError, }: {
|
|
46
|
+
dynamicRequestId?: string;
|
|
42
47
|
walletId: string;
|
|
43
48
|
exportId: string;
|
|
44
49
|
onError?: (error: Error) => void;
|
|
@@ -65,7 +70,8 @@ export declare class DynamicApiClient extends BaseClient {
|
|
|
65
70
|
getAccessToken({ oauthAccountId }: {
|
|
66
71
|
oauthAccountId: string;
|
|
67
72
|
}): Promise<any>;
|
|
68
|
-
importPrivateKey({ chainName, clientKeygenIds, thresholdSignatureScheme, onError, onCeremonyComplete, }: {
|
|
73
|
+
importPrivateKey({ chainName, dynamicRequestId, clientKeygenIds, thresholdSignatureScheme, onError, onCeremonyComplete, }: {
|
|
74
|
+
dynamicRequestId?: string;
|
|
69
75
|
chainName: string;
|
|
70
76
|
clientKeygenIds: string[];
|
|
71
77
|
thresholdSignatureScheme: ThresholdSignatureScheme;
|
package/src/api/api.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"api.d.ts","sourceRoot":"","sources":["../../src/api/api.ts"],"names":[],"mappings":"AACA,OAAO,EACL,cAAc,EAGf,MAAM,cAAc,CAAC;AAEtB,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,kBAAkB,CAAC;AACjE,OAAO,EAEL,KAAK,sBAAsB,EAC3B,KAAK,gBAAgB,EACrB,KAAK,eAAe,EACrB,MAAM,UAAU,CAAC;AAClB,OAAO,EAAE,UAAU,EAAE,MAAM,UAAU,CAAC;AAEtC,qBAAa,gBAAiB,SAAQ,UAAU;gBAClC,EACV,aAAa,EACb,SAAS,EACT,UAAU,GACX,EAAE;QACD,aAAa,EAAE,MAAM,CAAC;QACtB,SAAS,EAAE,MAAM,CAAC;QAClB,UAAU,CAAC,EAAE,MAAM,CAAC;KACrB;IAIK,oBAAoB,CAAC,EAAE,aAAa,EAAE,EAAE;QAAE,aAAa,EAAE,MAAM,CAAA;KAAE;IAYjE,mBAAmB,CAAC,EACxB,SAAS,EACT,eAAe,EACf,wBAAwB,EACxB,OAAO,EACP,kBAAkB,GACnB,EAAE;QACD,SAAS,EAAE,MAAM,CAAC;QAClB,eAAe,EAAE,MAAM,EAAE,CAAC;QAC1B,wBAAwB,EAAE,wBAAwB,CAAC;QACnD,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE,KAAK,KAAK,IAAI,CAAC;QACjC,kBAAkB,CAAC,EAAE,CAAC,cAAc,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,KAAK,IAAI,CAAC;KACzE;
|
|
1
|
+
{"version":3,"file":"api.d.ts","sourceRoot":"","sources":["../../src/api/api.ts"],"names":[],"mappings":"AACA,OAAO,EACL,cAAc,EAGf,MAAM,c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R,QAAQ,GACT,EAAE;QACD,QAAQ,EAAE,MAAM,CAAC;QACjB,QAAQ,EAAE,cAAc,CAAC;KAC1B;IAgBK,8BAA8B,CAAC,EACnC,QAAQ,EACR,WAAW,EACX,eAAe,GAChB,EAAE;QACD,QAAQ,EAAE,MAAM,CAAC;QACjB,WAAW,CAAC,EAAE,MAAM,EAAE,CAAC;QACvB,eAAe,CAAC,EAAE,MAAM,CAAC;KAC1B;IAeK,cAAc,CAAC,EAAE,cAAc,EAAE,EAAE;QAAE,cAAc,EAAE,MAAM,CAAA;KAAE;IAa7D,gBAAgB,CAAC,EACrB,SAAS,EACT,gBAAgB,EAChB,eAAe,EACf,wBAAwB,EACxB,OAAO,EACP,kBAAkB,GACnB,EAAE;QACD,gBAAgB,CAAC,EAAE,MAAM,CAAC;QAC1B,SAAS,EAAE,MAAM,CAAC;QAClB,eAAe,EAAE,MAAM,EAAE,CAAC;QAC1B,wBAAwB,EAAE,wBAAwB,CAAC;QACnD,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE,KAAK,KAAK,IAAI,CAAC;QACjC,kBAAkB,CAAC,EAAE,CAAC,cAAc,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,KAAK,IAAI,CAAC;KACzE;IAkBK,OAAO,IAAI,OAAO,CAAC,GAAG,CAAC;IA2BvB,WAAW,IAAI,OAAO,CAAC,GAAG,CAAC;CA0BlC"}
|
|
@@ -9,8 +9,9 @@ import { SuccessEventType } from '../types';
|
|
|
9
9
|
* @param options The configuration options
|
|
10
10
|
* @returns A promise that resolves with the event data or rejects on timeout
|
|
11
11
|
*/
|
|
12
|
-
export declare const createEventStreamPromise: <T>({ apiClient, endpoint, body, successEventType, timeoutMs, timeoutMessage, onError, onCeremonyComplete, }: {
|
|
12
|
+
export declare const createEventStreamPromise: <T>({ apiClient, dynamicRequestId, endpoint, body, successEventType, timeoutMs, timeoutMessage, onError, onCeremonyComplete, }: {
|
|
13
13
|
apiClient: AxiosInstance;
|
|
14
|
+
dynamicRequestId?: string;
|
|
14
15
|
endpoint: string;
|
|
15
16
|
body: Record<string, unknown> | undefined;
|
|
16
17
|
successEventType: SuccessEventType;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../src/eventStream/utils.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,aAAa,EAAE,MAAM,OAAO,CAAC;AAC3C,OAAO,EAAE,gBAAgB,EAAE,MAAM,UAAU,CAAC;
|
|
1
|
+
{"version":3,"file":"utils.d.ts","sourceRoot":"","sources":["../../src/eventStream/utils.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,aAAa,EAAE,MAAM,OAAO,CAAC;AAC3C,OAAO,EAAE,gBAAgB,EAAE,MAAM,UAAU,CAAC;AAE5C;;;;;;;;GAQG;AACH,eAAO,MAAM,wBAAwB,GAAI,CAAC,8HAUvC;IACD,SAAS,EAAE,aAAa,CAAC;IACzB,gBAAgB,CAAC,EAAE,MAAM,CAAC;IAC1B,QAAQ,EAAE,MAAM,CAAC;IACjB,IAAI,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,SAAS,CAAC;IAC1C,gBAAgB,EAAE,gBAAgB,CAAC;IACnC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,cAAc,EAAE,MAAM,CAAC;IACvB,OAAO,CAAC,EAAE,CAAC,KAAK,EAAE,KAAK,KAAK,IAAI,CAAC;IACjC,kBAAkB,CAAC,EAAE,CAAC,cAAc,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,KAAK,IAAI,CAAC;CACzE,KAAG,OAAO,CAAC,CAAC,CAiCZ,CAAC;AAEF;;;;;;;;;;;GAWG;AACH,eAAO,MAAM,oCAAoC,GAAI,CAAC,uEAMnD;IACD,OAAO,EAAE,CAAC,IAAI,EAAE,CAAC,KAAK,IAAI,CAAC;IAC3B,MAAM,EAAE,CAAC,KAAK,EAAE,KAAK,KAAK,IAAI,CAAC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