@privy-io/node 0.9.0 → 0.10.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/CHANGELOG.md +44 -0
- package/client.d.mts +13 -7
- package/client.d.mts.map +1 -1
- package/client.d.ts +13 -7
- package/client.d.ts.map +1 -1
- package/client.js +15 -2
- package/client.js.map +1 -1
- package/client.mjs +15 -2
- package/client.mjs.map +1 -1
- package/index.d.mts +1 -1
- package/index.d.mts.map +1 -1
- package/index.d.ts +1 -1
- package/index.d.ts.map +1 -1
- package/internal/tslib.js +17 -17
- package/internal/utils/query.d.mts +2 -0
- package/internal/utils/query.d.mts.map +1 -0
- package/internal/utils/query.d.ts +2 -0
- package/internal/utils/query.d.ts.map +1 -0
- package/internal/utils/query.js +10 -0
- package/internal/utils/query.js.map +1 -0
- package/internal/utils/query.mjs +6 -0
- package/internal/utils/query.mjs.map +1 -0
- package/internal/utils.d.mts +1 -0
- package/internal/utils.d.ts +1 -0
- package/internal/utils.js +1 -0
- package/internal/utils.js.map +1 -1
- package/internal/utils.mjs +1 -0
- package/package.json +1 -1
- package/public-api/services/ethereum.d.mts +4 -1
- package/public-api/services/ethereum.d.mts.map +1 -1
- package/public-api/services/ethereum.d.ts +4 -1
- package/public-api/services/ethereum.d.ts.map +1 -1
- package/public-api/services/ethereum.js +8 -0
- package/public-api/services/ethereum.js.map +1 -1
- package/public-api/services/ethereum.mjs +8 -0
- package/public-api/services/ethereum.mjs.map +1 -1
- package/public-api/services/webhooks.d.mts +3 -1
- package/public-api/services/webhooks.d.mts.map +1 -1
- package/public-api/services/webhooks.d.ts +3 -1
- package/public-api/services/webhooks.d.ts.map +1 -1
- package/public-api/services/webhooks.js +1 -0
- package/public-api/services/webhooks.js.map +1 -1
- package/public-api/services/webhooks.mjs +1 -0
- package/public-api/services/webhooks.mjs.map +1 -1
- package/resources/accounts.d.mts +85 -0
- package/resources/accounts.d.mts.map +1 -0
- package/resources/accounts.d.ts +85 -0
- package/resources/accounts.d.ts.map +1 -0
- package/resources/accounts.js +9 -0
- package/resources/accounts.js.map +1 -0
- package/resources/accounts.mjs +5 -0
- package/resources/accounts.mjs.map +1 -0
- package/resources/client-auth.d.mts +15 -1
- package/resources/client-auth.d.mts.map +1 -1
- package/resources/client-auth.d.ts +15 -1
- package/resources/client-auth.d.ts.map +1 -1
- package/resources/index.d.mts +5 -3
- package/resources/index.d.mts.map +1 -1
- package/resources/index.d.ts +5 -3
- package/resources/index.d.ts.map +1 -1
- package/resources/index.js +5 -1
- package/resources/index.js.map +1 -1
- package/resources/index.mjs +2 -0
- package/resources/index.mjs.map +1 -1
- package/resources/intents.d.mts +104 -0
- package/resources/intents.d.mts.map +1 -0
- package/resources/intents.d.ts +104 -0
- package/resources/intents.d.ts.map +1 -0
- package/resources/intents.js +9 -0
- package/resources/intents.js.map +1 -0
- package/resources/intents.mjs +5 -0
- package/resources/intents.mjs.map +1 -0
- package/resources/key-quorums.d.mts +14 -0
- package/resources/key-quorums.d.mts.map +1 -1
- package/resources/key-quorums.d.ts +14 -0
- package/resources/key-quorums.d.ts.map +1 -1
- package/resources/policies.d.mts +8 -8
- package/resources/policies.d.ts +8 -8
- package/resources/wallets/wallets.d.mts +11 -4
- package/resources/wallets/wallets.d.mts.map +1 -1
- package/resources/wallets/wallets.d.ts +11 -4
- package/resources/wallets/wallets.d.ts.map +1 -1
- package/resources/wallets/wallets.js.map +1 -1
- package/resources/wallets/wallets.mjs.map +1 -1
- package/resources/webhooks.d.mts +38 -1
- package/resources/webhooks.d.mts.map +1 -1
- package/resources/webhooks.d.ts +38 -1
- package/resources/webhooks.d.ts.map +1 -1
- package/resources/yield.d.mts +48 -1
- package/resources/yield.d.mts.map +1 -1
- package/resources/yield.d.ts +48 -1
- package/resources/yield.d.ts.map +1 -1
- package/src/client.ts +56 -4
- package/src/index.ts +1 -1
- package/src/internal/utils/query.ts +7 -0
- package/src/internal/utils.ts +1 -0
- package/src/public-api/services/ethereum.ts +16 -0
- package/src/public-api/services/webhooks.ts +49 -2
- package/src/resources/accounts.ts +106 -0
- package/src/resources/client-auth.ts +22 -0
- package/src/resources/index.ts +17 -0
- package/src/resources/intents.ts +138 -0
- package/src/resources/key-quorums.ts +17 -0
- package/src/resources/policies.ts +8 -8
- package/src/resources/wallets/wallets.ts +13 -5
- package/src/resources/webhooks.ts +60 -0
- package/src/resources/yield.ts +59 -0
- package/src/version.ts +1 -1
- package/version.d.mts +1 -1
- package/version.d.mts.map +1 -1
- package/version.d.ts +1 -1
- package/version.d.ts.map +1 -1
- package/version.js +1 -1
- package/version.js.map +1 -1
- package/version.mjs +1 -1
- package/version.mjs.map +1 -1
package/resources/yield.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"yield.d.ts","sourceRoot":"","sources":["../src/resources/yield.ts"],"names":[],"mappings":"OAEO,EAAE,WAAW,EAAE;AAEtB,qBAAa,KAAM,SAAQ,WAAW;CAAG;AAEzC;;GAEG;AACH,MAAM,MAAM,qBAAqB,GAAG,QAAQ,GAAG,MAAM,CAAC;AAEtD;;GAEG;AACH,MAAM,MAAM,sBAAsB,GAAG,SAAS,GAAG,UAAU,CAAC;AAE5D;;GAEG;AACH,MAAM,MAAM,wBAAwB,GAAG,SAAS,GAAG,WAAW,GAAG,QAAQ,CAAC;AAE1E;;GAEG;AACH,MAAM,WAAW,yBAAyB;IACxC;;;OAGG;IACH,YAAY,EAAE,MAAM,CAAC;IAErB;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED;;GAEG;AACH,MAAM,WAAW,0BAA0B;IACzC;;;OAGG;IACH,YAAY,EAAE,MAAM,CAAC;IAErB;;OAEG;IACH,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED;;GAEG;AACH,MAAM,WAAW,0BAA0B;IACzC;;OAEG;IACH,EAAE,EAAE,MAAM,CAAC;IAEX;;OAEG;IACH,uBAAuB,EAAE,MAAM,GAAG,IAAI,CAAC;IAEvC;;;OA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,MAAM,WAAW,0BAA0B;IACzC;;OAEG;IACH,EAAE,EAAE,MAAM,CAAC;IAEX;;OAEG;IACH,KAAK,EAAE,eAAe,CAAC;IAEvB;;OAEG;IACH,OAAO,EAAE,KAAK,CAAC,wBAAwB,CAAC,CAAC;CAC1C;AAED,MAAM,CAAC,OAAO,WAAW,KAAK,CAAC;IAC7B,OAAO,EACL,KAAK,eAAe,IAAI,eAAe,EACvC,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,sBAAsB,IAAI,sBAAsB,EACrD,KAAK,wBAAwB,IAAI,wBAAwB,EACzD,KAAK,yBAAyB,IAAI,yBAAyB,EAC3D,KAAK,0BAA0B,IAAI,0BAA0B,EAC7D,KAAK,0BAA0B,IAAI,0BAA0B,EAC7D,KAAK,yBAAyB,IAAI,yBAAyB,EAC3D,KAAK,yBAAyB,IAAI,yBAAyB,EAC3D,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,4BAA4B,IAAI,4BAA4B,EACjE,KAAK,2BAA2B,IAAI,2BAA2B,EAC/D,KAAK,qBAAqB,IAAI,qBAAqB,EACnD,KAAK,6BAA6B,IAAI,6BAA6B,EACnE,KAAK,uBAAuB,IAAI,uBAAuB,EACvD,KAAK,wBAAwB,IAAI,wBAAwB,EACzD,KAAK,0BAA0B,IAAI,0BAA0B,GAC9D,CAAC;CACH"}
|
package/src/client.ts
CHANGED
|
@@ -11,7 +11,7 @@ import type { APIResponseProps } from './internal/parse';
|
|
|
11
11
|
import { getPlatformHeaders } from './internal/detect-platform';
|
|
12
12
|
import * as Shims from './internal/shims';
|
|
13
13
|
import * as Opts from './internal/request-options';
|
|
14
|
-
import
|
|
14
|
+
import { stringifyQuery } from './internal/utils/query';
|
|
15
15
|
import { VERSION } from './version';
|
|
16
16
|
import * as Errors from './core/error';
|
|
17
17
|
import * as Pagination from './core/pagination';
|
|
@@ -19,6 +19,14 @@ import { AbstractPage, type CursorParams, CursorResponse } from './core/paginati
|
|
|
19
19
|
import * as Uploads from './core/uploads';
|
|
20
20
|
import * as API from './resources/index';
|
|
21
21
|
import { APIPromise } from './core/api-promise';
|
|
22
|
+
import {
|
|
23
|
+
AccountResponse,
|
|
24
|
+
AccountWallet,
|
|
25
|
+
AccountWalletConfigurationItem,
|
|
26
|
+
Accounts,
|
|
27
|
+
AccountsListResponse,
|
|
28
|
+
CreateAccountInput,
|
|
29
|
+
} from './resources/accounts';
|
|
22
30
|
import {
|
|
23
31
|
Aggregation,
|
|
24
32
|
AggregationGroupBy,
|
|
@@ -35,6 +43,7 @@ import {
|
|
|
35
43
|
BridgeDestinationAsset,
|
|
36
44
|
BridgeEurFiatVirtualAccountDepositInstructions,
|
|
37
45
|
BridgeFiatCustomerResponse,
|
|
46
|
+
BridgeFiatRejectionReason,
|
|
38
47
|
BridgeFiatVirtualAccountDepositInstructions,
|
|
39
48
|
BridgeFiatVirtualAccountDestination,
|
|
40
49
|
BridgeFiatVirtualAccountRequest,
|
|
@@ -42,6 +51,7 @@ import {
|
|
|
42
51
|
BridgeFiatVirtualAccountSource,
|
|
43
52
|
BridgeGbpFiatVirtualAccountDepositInstructions,
|
|
44
53
|
BridgeMxnFiatVirtualAccountDepositInstructions,
|
|
54
|
+
BridgeOnrampProvider,
|
|
45
55
|
BridgeSandboxFiatCustomerResponse,
|
|
46
56
|
BridgeSandboxFiatVirtualAccountRequest,
|
|
47
57
|
BridgeSandboxFiatVirtualAccountResponse,
|
|
@@ -59,6 +69,7 @@ import {
|
|
|
59
69
|
OnrampProvider,
|
|
60
70
|
PrivyOAuthProviderID,
|
|
61
71
|
} from './resources/client-auth';
|
|
72
|
+
import { IntentAuthorizationKeyQuorumMember, IntentAuthorizationMember, Intents } from './resources/intents';
|
|
62
73
|
import {
|
|
63
74
|
KeyQuorum,
|
|
64
75
|
KeyQuorumCreateParams,
|
|
@@ -208,12 +219,17 @@ import {
|
|
|
208
219
|
WalletRecoveredWebhookPayload,
|
|
209
220
|
WalletRecoverySetupWebhookPayload,
|
|
210
221
|
Webhooks,
|
|
222
|
+
YieldDepositConfirmedWebhookPayload,
|
|
223
|
+
YieldWithdrawConfirmedWebhookPayload,
|
|
211
224
|
} from './resources/webhooks';
|
|
212
225
|
import {
|
|
213
226
|
EthereumVaultDetailsInput,
|
|
214
227
|
EthereumVaultDetailsResponse,
|
|
215
228
|
EthereumVaultPosition,
|
|
216
229
|
EthereumVaultResponse,
|
|
230
|
+
EthereumYieldClaimInput,
|
|
231
|
+
EthereumYieldClaimResponse,
|
|
232
|
+
EthereumYieldClaimReward,
|
|
217
233
|
EthereumYieldDepositInput,
|
|
218
234
|
EthereumYieldPositionResponse,
|
|
219
235
|
EthereumYieldPositionsInput,
|
|
@@ -223,6 +239,7 @@ import {
|
|
|
223
239
|
EthereumYieldSweepStatus,
|
|
224
240
|
EthereumYieldSweepType,
|
|
225
241
|
EthereumYieldWithdrawInput,
|
|
242
|
+
EvmCaip2ChainID,
|
|
226
243
|
Yield,
|
|
227
244
|
} from './resources/yield';
|
|
228
245
|
import {
|
|
@@ -532,8 +549,8 @@ export class PrivyAPI {
|
|
|
532
549
|
return buildHeaders([{ Authorization }]);
|
|
533
550
|
}
|
|
534
551
|
|
|
535
|
-
protected stringifyQuery(query: Record<string, unknown>): string {
|
|
536
|
-
return
|
|
552
|
+
protected stringifyQuery(query: object | Record<string, unknown>): string {
|
|
553
|
+
return stringifyQuery(query);
|
|
537
554
|
}
|
|
538
555
|
|
|
539
556
|
private getUserAgent(): string {
|
|
@@ -570,7 +587,7 @@ export class PrivyAPI {
|
|
|
570
587
|
}
|
|
571
588
|
|
|
572
589
|
if (typeof query === 'object' && query && !Array.isArray(query)) {
|
|
573
|
-
url.search = this.stringifyQuery(query
|
|
590
|
+
url.search = this.stringifyQuery(query);
|
|
574
591
|
}
|
|
575
592
|
|
|
576
593
|
return url.toString();
|
|
@@ -1028,6 +1045,14 @@ export class PrivyAPI {
|
|
|
1028
1045
|
(Symbol.iterator in body && 'next' in body && typeof body.next === 'function'))
|
|
1029
1046
|
) {
|
|
1030
1047
|
return { bodyHeaders: undefined, body: Shims.ReadableStreamFrom(body as AsyncIterable<Uint8Array>) };
|
|
1048
|
+
} else if (
|
|
1049
|
+
typeof body === 'object' &&
|
|
1050
|
+
headers.values.get('content-type') === 'application/x-www-form-urlencoded'
|
|
1051
|
+
) {
|
|
1052
|
+
return {
|
|
1053
|
+
bodyHeaders: { 'content-type': 'application/x-www-form-urlencoded' },
|
|
1054
|
+
body: this.stringifyQuery(body),
|
|
1055
|
+
};
|
|
1031
1056
|
} else {
|
|
1032
1057
|
return this.#encoder({ body, headers });
|
|
1033
1058
|
}
|
|
@@ -1062,7 +1087,9 @@ export class PrivyAPI {
|
|
|
1062
1087
|
apps: API.Apps = new API.Apps(this);
|
|
1063
1088
|
aggregations: API.Aggregations = new API.Aggregations(this);
|
|
1064
1089
|
webhooks: API.Webhooks = new API.Webhooks(this);
|
|
1090
|
+
accounts: API.Accounts = new API.Accounts(this);
|
|
1065
1091
|
yield: API.Yield = new API.Yield(this);
|
|
1092
|
+
intents: API.Intents = new API.Intents(this);
|
|
1066
1093
|
}
|
|
1067
1094
|
|
|
1068
1095
|
PrivyAPI.Wallets = Wallets;
|
|
@@ -1075,7 +1102,9 @@ PrivyAPI.Analytics = Analytics;
|
|
|
1075
1102
|
PrivyAPI.Apps = Apps;
|
|
1076
1103
|
PrivyAPI.Aggregations = Aggregations;
|
|
1077
1104
|
PrivyAPI.Webhooks = Webhooks;
|
|
1105
|
+
PrivyAPI.Accounts = Accounts;
|
|
1078
1106
|
PrivyAPI.Yield = Yield;
|
|
1107
|
+
PrivyAPI.Intents = Intents;
|
|
1079
1108
|
|
|
1080
1109
|
export declare namespace PrivyAPI {
|
|
1081
1110
|
export type RequestOptions = Opts.RequestOptions;
|
|
@@ -1268,9 +1297,11 @@ export declare namespace PrivyAPI {
|
|
|
1268
1297
|
type PrivyOAuthProviderID as PrivyOAuthProviderID,
|
|
1269
1298
|
type CustomOAuthProviderID as CustomOAuthProviderID,
|
|
1270
1299
|
type OAuthProviderID as OAuthProviderID,
|
|
1300
|
+
type BridgeOnrampProvider as BridgeOnrampProvider,
|
|
1271
1301
|
type OnrampProvider as OnrampProvider,
|
|
1272
1302
|
type GetFiatCustomerRequestInput as GetFiatCustomerRequestInput,
|
|
1273
1303
|
type CreateOrUpdateFiatCustomerRequestInput as CreateOrUpdateFiatCustomerRequestInput,
|
|
1304
|
+
type BridgeFiatRejectionReason as BridgeFiatRejectionReason,
|
|
1274
1305
|
type BridgeFiatCustomerResponse as BridgeFiatCustomerResponse,
|
|
1275
1306
|
type BridgeSandboxFiatCustomerResponse as BridgeSandboxFiatCustomerResponse,
|
|
1276
1307
|
type FiatCustomerResponse as FiatCustomerResponse,
|
|
@@ -1337,10 +1368,22 @@ export declare namespace PrivyAPI {
|
|
|
1337
1368
|
type KrakenEmbedUserVerifiedWebhookPayload as KrakenEmbedUserVerifiedWebhookPayload,
|
|
1338
1369
|
type KrakenEmbedUserDisabledWebhookPayload as KrakenEmbedUserDisabledWebhookPayload,
|
|
1339
1370
|
type KrakenEmbedUserClosedWebhookPayload as KrakenEmbedUserClosedWebhookPayload,
|
|
1371
|
+
type YieldDepositConfirmedWebhookPayload as YieldDepositConfirmedWebhookPayload,
|
|
1372
|
+
type YieldWithdrawConfirmedWebhookPayload as YieldWithdrawConfirmedWebhookPayload,
|
|
1373
|
+
};
|
|
1374
|
+
|
|
1375
|
+
export {
|
|
1376
|
+
Accounts as Accounts,
|
|
1377
|
+
type AccountWallet as AccountWallet,
|
|
1378
|
+
type AccountResponse as AccountResponse,
|
|
1379
|
+
type AccountWalletConfigurationItem as AccountWalletConfigurationItem,
|
|
1380
|
+
type CreateAccountInput as CreateAccountInput,
|
|
1381
|
+
type AccountsListResponse as AccountsListResponse,
|
|
1340
1382
|
};
|
|
1341
1383
|
|
|
1342
1384
|
export {
|
|
1343
1385
|
Yield as Yield,
|
|
1386
|
+
type EvmCaip2ChainID as EvmCaip2ChainID,
|
|
1344
1387
|
type EthereumYieldProvider as EthereumYieldProvider,
|
|
1345
1388
|
type EthereumYieldSweepType as EthereumYieldSweepType,
|
|
1346
1389
|
type EthereumYieldSweepStatus as EthereumYieldSweepStatus,
|
|
@@ -1354,5 +1397,14 @@ export declare namespace PrivyAPI {
|
|
|
1354
1397
|
type EthereumYieldPositionsInput as EthereumYieldPositionsInput,
|
|
1355
1398
|
type EthereumVaultPosition as EthereumVaultPosition,
|
|
1356
1399
|
type EthereumYieldPositionResponse as EthereumYieldPositionResponse,
|
|
1400
|
+
type EthereumYieldClaimInput as EthereumYieldClaimInput,
|
|
1401
|
+
type EthereumYieldClaimReward as EthereumYieldClaimReward,
|
|
1402
|
+
type EthereumYieldClaimResponse as EthereumYieldClaimResponse,
|
|
1403
|
+
};
|
|
1404
|
+
|
|
1405
|
+
export {
|
|
1406
|
+
Intents as Intents,
|
|
1407
|
+
type IntentAuthorizationKeyQuorumMember as IntentAuthorizationKeyQuorumMember,
|
|
1408
|
+
type IntentAuthorizationMember as IntentAuthorizationMember,
|
|
1357
1409
|
};
|
|
1358
1410
|
}
|
package/src/index.ts
CHANGED
|
@@ -19,7 +19,7 @@ export {
|
|
|
19
19
|
type VerifyIdentityTokenInput,
|
|
20
20
|
} from './lib/auth';
|
|
21
21
|
|
|
22
|
-
export { type User, type LinkedAccountEmbeddedWallet } from './resources/users';
|
|
22
|
+
export { type User, type LinkedAccountEmbeddedWallet, type LinkedAccount } from './resources/users';
|
|
23
23
|
export { type Wallet } from './resources/wallets';
|
|
24
24
|
export { type Policy } from './resources/policies';
|
|
25
25
|
export { type KeyQuorum } from './resources/key-quorums';
|
package/src/internal/utils.ts
CHANGED
|
@@ -5,6 +5,7 @@ import {
|
|
|
5
5
|
EthereumSign7702AuthorizationRpcResponse,
|
|
6
6
|
EthereumSignTransactionRpcResponse,
|
|
7
7
|
EthereumSignTypedDataRpcResponse,
|
|
8
|
+
EthereumSignUserOperationRpcResponse,
|
|
8
9
|
WalletRpcParams,
|
|
9
10
|
} from '../../resources';
|
|
10
11
|
import { ReplaceParams, PrivyWalletsService } from './wallets';
|
|
@@ -94,6 +95,19 @@ export class PrivyEthereumService {
|
|
|
94
95
|
return response.data;
|
|
95
96
|
}
|
|
96
97
|
|
|
98
|
+
public async signUserOperation(
|
|
99
|
+
walletId: string,
|
|
100
|
+
input: PrivyEthereumService.SignUserOperationInput,
|
|
101
|
+
): Promise<EthereumSignUserOperationRpcResponse.Data> {
|
|
102
|
+
const response = await this.privyWalletsService.rpc(walletId, {
|
|
103
|
+
...input,
|
|
104
|
+
method: 'eth_signUserOperation',
|
|
105
|
+
chain_type: 'ethereum',
|
|
106
|
+
});
|
|
107
|
+
|
|
108
|
+
return response.data;
|
|
109
|
+
}
|
|
110
|
+
|
|
97
111
|
public async sendTransaction(
|
|
98
112
|
walletId: string,
|
|
99
113
|
input: PrivyEthereumService.SendTransactionInput,
|
|
@@ -129,6 +143,8 @@ export namespace PrivyEthereumService {
|
|
|
129
143
|
export type SignTransactionInput = PrivyWalletsRpcInput<WalletRpcParams.EthereumSignTransactionRpcInput>;
|
|
130
144
|
/** The input type for the {@link PrivyEthereumService.signTypedData} method. */
|
|
131
145
|
export type SignTypedDataInput = PrivyWalletsRpcInput<WalletRpcParams.EthereumSignTypedDataRpcInput>;
|
|
146
|
+
/** The input type for the {@link PrivyEthereumService.signUserOperation} method. */
|
|
147
|
+
export type SignUserOperationInput = PrivyWalletsRpcInput<WalletRpcParams.EthereumSignUserOperationRpcInput>;
|
|
132
148
|
/** The input type for the {@link PrivyEthereumService.sendTransaction} method. */
|
|
133
149
|
export type SendTransactionInput = PrivyWalletsRpcInput<WalletRpcParams.EthereumSendTransactionRpcInput>;
|
|
134
150
|
}
|
|
@@ -1,5 +1,51 @@
|
|
|
1
1
|
import { Webhook } from 'svix';
|
|
2
2
|
import { PrivyAPIError } from '../../core/error';
|
|
3
|
+
import type {
|
|
4
|
+
UserCreatedWebhookPayload,
|
|
5
|
+
UserAuthenticatedWebhookPayload,
|
|
6
|
+
UserLinkedAccountWebhookPayload,
|
|
7
|
+
UserUnlinkedAccountWebhookPayload,
|
|
8
|
+
UserUpdatedAccountWebhookPayload,
|
|
9
|
+
UserTransferredAccountWebhookPayload,
|
|
10
|
+
UserWalletCreatedWebhookPayload,
|
|
11
|
+
TransactionBroadcastedWebhookPayload,
|
|
12
|
+
TransactionConfirmedWebhookPayload,
|
|
13
|
+
TransactionExecutionRevertedWebhookPayload,
|
|
14
|
+
TransactionStillPendingWebhookPayload,
|
|
15
|
+
TransactionFailedWebhookPayload,
|
|
16
|
+
TransactionReplacedWebhookPayload,
|
|
17
|
+
TransactionProviderErrorWebhookPayload,
|
|
18
|
+
FundsDepositedWebhookPayload,
|
|
19
|
+
FundsWithdrawnWebhookPayload,
|
|
20
|
+
PrivateKeyExportWebhookPayload,
|
|
21
|
+
WalletRecoverySetupWebhookPayload,
|
|
22
|
+
WalletRecoveredWebhookPayload,
|
|
23
|
+
MfaEnabledWebhookPayload,
|
|
24
|
+
MfaDisabledWebhookPayload,
|
|
25
|
+
} from '../../resources/webhooks';
|
|
26
|
+
|
|
27
|
+
export type WebhookEvent =
|
|
28
|
+
| UserCreatedWebhookPayload
|
|
29
|
+
| UserAuthenticatedWebhookPayload
|
|
30
|
+
| UserLinkedAccountWebhookPayload
|
|
31
|
+
| UserUnlinkedAccountWebhookPayload
|
|
32
|
+
| UserUpdatedAccountWebhookPayload
|
|
33
|
+
| UserTransferredAccountWebhookPayload
|
|
34
|
+
| UserWalletCreatedWebhookPayload
|
|
35
|
+
| TransactionBroadcastedWebhookPayload
|
|
36
|
+
| TransactionConfirmedWebhookPayload
|
|
37
|
+
| TransactionExecutionRevertedWebhookPayload
|
|
38
|
+
| TransactionStillPendingWebhookPayload
|
|
39
|
+
| TransactionFailedWebhookPayload
|
|
40
|
+
| TransactionReplacedWebhookPayload
|
|
41
|
+
| TransactionProviderErrorWebhookPayload
|
|
42
|
+
| FundsDepositedWebhookPayload
|
|
43
|
+
| FundsWithdrawnWebhookPayload
|
|
44
|
+
| PrivateKeyExportWebhookPayload
|
|
45
|
+
| WalletRecoverySetupWebhookPayload
|
|
46
|
+
| WalletRecoveredWebhookPayload
|
|
47
|
+
| MfaEnabledWebhookPayload
|
|
48
|
+
| MfaDisabledWebhookPayload;
|
|
3
49
|
|
|
4
50
|
export class PrivyWebhooksService {
|
|
5
51
|
private webhookSigningSecret: string | undefined;
|
|
@@ -17,7 +63,7 @@ export class PrivyWebhooksService {
|
|
|
17
63
|
* @param input.signing_secret The webhook secret to use for verifying the webhook request.
|
|
18
64
|
* @returns verified payload if the webhook signature is valid otherwise throws.
|
|
19
65
|
*/
|
|
20
|
-
async verify({ payload, svix, signing_secret }: PrivyWebhooksService.VerifyInput): Promise<
|
|
66
|
+
async verify({ payload, svix, signing_secret }: PrivyWebhooksService.VerifyInput): Promise<WebhookEvent> {
|
|
21
67
|
const signingSecret = signing_secret ?? this.webhookSigningSecret;
|
|
22
68
|
if (!signingSecret) {
|
|
23
69
|
throw new InvalidWebhookError('Webhook signing secret is required');
|
|
@@ -31,7 +77,8 @@ export class PrivyWebhooksService {
|
|
|
31
77
|
'svix-timestamp': svix.timestamp,
|
|
32
78
|
'svix-signature': svix.signature,
|
|
33
79
|
};
|
|
34
|
-
|
|
80
|
+
// Casting is safe here because `verify` succeeds meaning the API sent this event.
|
|
81
|
+
return webhook.verify(stringPayload, svixHeaders) as WebhookEvent;
|
|
35
82
|
} catch (error) {
|
|
36
83
|
if (error instanceof Error) {
|
|
37
84
|
throw new InvalidWebhookError(`Webhook verification failed: ${error.message}`);
|
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
import { APIResource } from '../core/resource';
|
|
4
|
+
import * as WalletsAPI from './wallets/wallets';
|
|
5
|
+
|
|
6
|
+
export class Accounts extends APIResource {}
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* A wallet belonging to a digital asset account.
|
|
10
|
+
*/
|
|
11
|
+
export interface AccountWallet {
|
|
12
|
+
/**
|
|
13
|
+
* The wallet ID.
|
|
14
|
+
*/
|
|
15
|
+
id: string;
|
|
16
|
+
|
|
17
|
+
/**
|
|
18
|
+
* The on-chain address of the wallet.
|
|
19
|
+
*/
|
|
20
|
+
address: string;
|
|
21
|
+
|
|
22
|
+
/**
|
|
23
|
+
* The wallet chain types that offer first class support.
|
|
24
|
+
*/
|
|
25
|
+
chain_type: WalletsAPI.FirstClassChainType;
|
|
26
|
+
|
|
27
|
+
/**
|
|
28
|
+
* Information about the custodian managing this wallet.
|
|
29
|
+
*/
|
|
30
|
+
custody?: WalletsAPI.WalletCustodian;
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
/**
|
|
34
|
+
* A digital asset account that groups wallets under a single entity.
|
|
35
|
+
*/
|
|
36
|
+
export interface AccountResponse {
|
|
37
|
+
/**
|
|
38
|
+
* The account ID.
|
|
39
|
+
*/
|
|
40
|
+
id: string;
|
|
41
|
+
|
|
42
|
+
/**
|
|
43
|
+
* An optional display name for the account.
|
|
44
|
+
*/
|
|
45
|
+
display_name: string | null;
|
|
46
|
+
|
|
47
|
+
/**
|
|
48
|
+
* The wallets belonging to this account.
|
|
49
|
+
*/
|
|
50
|
+
wallets: Array<AccountWallet>;
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
/**
|
|
54
|
+
* Configuration for a wallet to create within an account.
|
|
55
|
+
*/
|
|
56
|
+
export interface AccountWalletConfigurationItem {
|
|
57
|
+
/**
|
|
58
|
+
* The wallet chain types that offer first class support.
|
|
59
|
+
*/
|
|
60
|
+
chain_type: WalletsAPI.FirstClassChainType;
|
|
61
|
+
|
|
62
|
+
/**
|
|
63
|
+
* Information about the custodian managing this wallet.
|
|
64
|
+
*/
|
|
65
|
+
custody?: WalletsAPI.WalletCustodian;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
/**
|
|
69
|
+
* Input for creating a digital asset account.
|
|
70
|
+
*/
|
|
71
|
+
export interface CreateAccountInput {
|
|
72
|
+
/**
|
|
73
|
+
* Configuration for wallets to create.
|
|
74
|
+
*/
|
|
75
|
+
wallets_configuration: Array<AccountWalletConfigurationItem>;
|
|
76
|
+
|
|
77
|
+
/**
|
|
78
|
+
* An optional display name for the account.
|
|
79
|
+
*/
|
|
80
|
+
display_name?: string;
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
/**
|
|
84
|
+
* Paginated list of digital asset accounts.
|
|
85
|
+
*/
|
|
86
|
+
export interface AccountsListResponse {
|
|
87
|
+
/**
|
|
88
|
+
* The list of accounts.
|
|
89
|
+
*/
|
|
90
|
+
data: Array<AccountResponse>;
|
|
91
|
+
|
|
92
|
+
/**
|
|
93
|
+
* Cursor for fetching the next page of results, or null if no more results.
|
|
94
|
+
*/
|
|
95
|
+
next_cursor: string | null;
|
|
96
|
+
}
|
|
97
|
+
|
|
98
|
+
export declare namespace Accounts {
|
|
99
|
+
export {
|
|
100
|
+
type AccountWallet as AccountWallet,
|
|
101
|
+
type AccountResponse as AccountResponse,
|
|
102
|
+
type AccountWalletConfigurationItem as AccountWalletConfigurationItem,
|
|
103
|
+
type CreateAccountInput as CreateAccountInput,
|
|
104
|
+
type AccountsListResponse as AccountsListResponse,
|
|
105
|
+
};
|
|
106
|
+
}
|
|
@@ -36,6 +36,11 @@ export type CustomOAuthProviderID = `custom:${string}`;
|
|
|
36
36
|
*/
|
|
37
37
|
export type OAuthProviderID = ExternalOAuthProviderID | PrivyOAuthProviderID;
|
|
38
38
|
|
|
39
|
+
/**
|
|
40
|
+
* Bridge provider variant — production or sandbox.
|
|
41
|
+
*/
|
|
42
|
+
export type BridgeOnrampProvider = 'bridge' | 'bridge-sandbox';
|
|
43
|
+
|
|
39
44
|
/**
|
|
40
45
|
* Valid set of onramp providers
|
|
41
46
|
*/
|
|
@@ -49,6 +54,8 @@ export interface GetFiatCustomerRequestInput {
|
|
|
49
54
|
* Valid set of onramp providers
|
|
50
55
|
*/
|
|
51
56
|
provider: OnrampProvider;
|
|
57
|
+
|
|
58
|
+
kyc_redirect_url?: string;
|
|
52
59
|
}
|
|
53
60
|
|
|
54
61
|
/**
|
|
@@ -61,6 +68,15 @@ export interface CreateOrUpdateFiatCustomerRequestInput {
|
|
|
61
68
|
* Valid set of onramp providers
|
|
62
69
|
*/
|
|
63
70
|
provider: OnrampProvider;
|
|
71
|
+
|
|
72
|
+
kyc_redirect_url?: string;
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
/**
|
|
76
|
+
* A rejection reason for a customer KYC verification.
|
|
77
|
+
*/
|
|
78
|
+
export interface BridgeFiatRejectionReason {
|
|
79
|
+
reason: string;
|
|
64
80
|
}
|
|
65
81
|
|
|
66
82
|
/**
|
|
@@ -84,6 +100,8 @@ export interface BridgeFiatCustomerResponse {
|
|
|
84
100
|
| 'under_review';
|
|
85
101
|
|
|
86
102
|
kyc_url?: string;
|
|
103
|
+
|
|
104
|
+
rejection_reasons?: Array<BridgeFiatRejectionReason>;
|
|
87
105
|
}
|
|
88
106
|
|
|
89
107
|
/**
|
|
@@ -107,6 +125,8 @@ export interface BridgeSandboxFiatCustomerResponse {
|
|
|
107
125
|
| 'under_review';
|
|
108
126
|
|
|
109
127
|
kyc_url?: string;
|
|
128
|
+
|
|
129
|
+
rejection_reasons?: Array<BridgeFiatRejectionReason>;
|
|
110
130
|
}
|
|
111
131
|
|
|
112
132
|
/**
|
|
@@ -307,9 +327,11 @@ export declare namespace ClientAuth {
|
|
|
307
327
|
type PrivyOAuthProviderID as PrivyOAuthProviderID,
|
|
308
328
|
type CustomOAuthProviderID as CustomOAuthProviderID,
|
|
309
329
|
type OAuthProviderID as OAuthProviderID,
|
|
330
|
+
type BridgeOnrampProvider as BridgeOnrampProvider,
|
|
310
331
|
type OnrampProvider as OnrampProvider,
|
|
311
332
|
type GetFiatCustomerRequestInput as GetFiatCustomerRequestInput,
|
|
312
333
|
type CreateOrUpdateFiatCustomerRequestInput as CreateOrUpdateFiatCustomerRequestInput,
|
|
334
|
+
type BridgeFiatRejectionReason as BridgeFiatRejectionReason,
|
|
313
335
|
type BridgeFiatCustomerResponse as BridgeFiatCustomerResponse,
|
|
314
336
|
type BridgeSandboxFiatCustomerResponse as BridgeSandboxFiatCustomerResponse,
|
|
315
337
|
type FiatCustomerResponse as FiatCustomerResponse,
|
package/src/resources/index.ts
CHANGED
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
2
|
|
|
3
|
+
export {
|
|
4
|
+
Accounts,
|
|
5
|
+
type AccountWallet,
|
|
6
|
+
type AccountResponse,
|
|
7
|
+
type AccountWalletConfigurationItem,
|
|
8
|
+
type CreateAccountInput,
|
|
9
|
+
type AccountsListResponse,
|
|
10
|
+
} from './accounts';
|
|
3
11
|
export {
|
|
4
12
|
Aggregations,
|
|
5
13
|
type AggregationMethod,
|
|
@@ -17,9 +25,11 @@ export {
|
|
|
17
25
|
type PrivyOAuthProviderID,
|
|
18
26
|
type CustomOAuthProviderID,
|
|
19
27
|
type OAuthProviderID,
|
|
28
|
+
type BridgeOnrampProvider,
|
|
20
29
|
type OnrampProvider,
|
|
21
30
|
type GetFiatCustomerRequestInput,
|
|
22
31
|
type CreateOrUpdateFiatCustomerRequestInput,
|
|
32
|
+
type BridgeFiatRejectionReason,
|
|
23
33
|
type BridgeFiatCustomerResponse,
|
|
24
34
|
type BridgeSandboxFiatCustomerResponse,
|
|
25
35
|
type FiatCustomerResponse,
|
|
@@ -40,6 +50,7 @@ export {
|
|
|
40
50
|
type BridgeSandboxFiatVirtualAccountResponse,
|
|
41
51
|
type FiatVirtualAccountResponse,
|
|
42
52
|
} from './client-auth';
|
|
53
|
+
export { Intents, type IntentAuthorizationKeyQuorumMember, type IntentAuthorizationMember } from './intents';
|
|
43
54
|
export {
|
|
44
55
|
KeyQuorums,
|
|
45
56
|
type KeyQuorum,
|
|
@@ -245,9 +256,12 @@ export {
|
|
|
245
256
|
type KrakenEmbedUserVerifiedWebhookPayload,
|
|
246
257
|
type KrakenEmbedUserDisabledWebhookPayload,
|
|
247
258
|
type KrakenEmbedUserClosedWebhookPayload,
|
|
259
|
+
type YieldDepositConfirmedWebhookPayload,
|
|
260
|
+
type YieldWithdrawConfirmedWebhookPayload,
|
|
248
261
|
} from './webhooks';
|
|
249
262
|
export {
|
|
250
263
|
Yield,
|
|
264
|
+
type EvmCaip2ChainID,
|
|
251
265
|
type EthereumYieldProvider,
|
|
252
266
|
type EthereumYieldSweepType,
|
|
253
267
|
type EthereumYieldSweepStatus,
|
|
@@ -261,4 +275,7 @@ export {
|
|
|
261
275
|
type EthereumYieldPositionsInput,
|
|
262
276
|
type EthereumVaultPosition,
|
|
263
277
|
type EthereumYieldPositionResponse,
|
|
278
|
+
type EthereumYieldClaimInput,
|
|
279
|
+
type EthereumYieldClaimReward,
|
|
280
|
+
type EthereumYieldClaimResponse,
|
|
264
281
|
} from './yield';
|
|
@@ -0,0 +1,138 @@
|
|
|
1
|
+
// File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
|
|
2
|
+
|
|
3
|
+
import { APIResource } from '../core/resource';
|
|
4
|
+
import * as IntentsAPI from './intents';
|
|
5
|
+
|
|
6
|
+
export class Intents extends APIResource {}
|
|
7
|
+
|
|
8
|
+
/**
|
|
9
|
+
* A leaf member (user or key) of a nested key quorum in an intent authorization.
|
|
10
|
+
*/
|
|
11
|
+
export type IntentAuthorizationKeyQuorumMember =
|
|
12
|
+
| IntentAuthorizationKeyQuorumMember.UserMember
|
|
13
|
+
| IntentAuthorizationKeyQuorumMember.KeyMember;
|
|
14
|
+
|
|
15
|
+
export namespace IntentAuthorizationKeyQuorumMember {
|
|
16
|
+
export interface UserMember {
|
|
17
|
+
/**
|
|
18
|
+
* Whether this member has signed the intent
|
|
19
|
+
*/
|
|
20
|
+
has_signed: boolean;
|
|
21
|
+
|
|
22
|
+
type: 'user';
|
|
23
|
+
|
|
24
|
+
/**
|
|
25
|
+
* User ID of the key quorum member
|
|
26
|
+
*/
|
|
27
|
+
user_id: string;
|
|
28
|
+
|
|
29
|
+
/**
|
|
30
|
+
* Display name for the user (email, etc)
|
|
31
|
+
*/
|
|
32
|
+
display_name?: string;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
export interface KeyMember {
|
|
36
|
+
/**
|
|
37
|
+
* Whether this key has signed the intent
|
|
38
|
+
*/
|
|
39
|
+
has_signed: boolean;
|
|
40
|
+
|
|
41
|
+
/**
|
|
42
|
+
* Public key of the key quorum member
|
|
43
|
+
*/
|
|
44
|
+
public_key: string;
|
|
45
|
+
|
|
46
|
+
type: 'key';
|
|
47
|
+
|
|
48
|
+
/**
|
|
49
|
+
* Display name for the key (if any)
|
|
50
|
+
*/
|
|
51
|
+
display_name?: string;
|
|
52
|
+
}
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
/**
|
|
56
|
+
* A member of an intent authorization quorum. Can be a user, key, or nested key
|
|
57
|
+
* quorum.
|
|
58
|
+
*/
|
|
59
|
+
export type IntentAuthorizationMember =
|
|
60
|
+
| IntentAuthorizationMember.UserMember
|
|
61
|
+
| IntentAuthorizationMember.KeyMember
|
|
62
|
+
| IntentAuthorizationMember.KeyQuorumMember;
|
|
63
|
+
|
|
64
|
+
export namespace IntentAuthorizationMember {
|
|
65
|
+
export interface UserMember {
|
|
66
|
+
/**
|
|
67
|
+
* Whether this member has signed the intent
|
|
68
|
+
*/
|
|
69
|
+
has_signed: boolean;
|
|
70
|
+
|
|
71
|
+
type: 'user';
|
|
72
|
+
|
|
73
|
+
/**
|
|
74
|
+
* User ID of the key quorum member
|
|
75
|
+
*/
|
|
76
|
+
user_id: string;
|
|
77
|
+
|
|
78
|
+
/**
|
|
79
|
+
* Display name for the user (email, etc)
|
|
80
|
+
*/
|
|
81
|
+
display_name?: string;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
export interface KeyMember {
|
|
85
|
+
/**
|
|
86
|
+
* Whether this key has signed the intent
|
|
87
|
+
*/
|
|
88
|
+
has_signed: boolean;
|
|
89
|
+
|
|
90
|
+
/**
|
|
91
|
+
* Public key of the key quorum member
|
|
92
|
+
*/
|
|
93
|
+
public_key: string;
|
|
94
|
+
|
|
95
|
+
type: 'key';
|
|
96
|
+
|
|
97
|
+
/**
|
|
98
|
+
* Display name for the key (if any)
|
|
99
|
+
*/
|
|
100
|
+
display_name?: string;
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
export interface KeyQuorumMember {
|
|
104
|
+
/**
|
|
105
|
+
* Whether this child key quorum has fulfilled its threshold
|
|
106
|
+
*/
|
|
107
|
+
has_signed: boolean;
|
|
108
|
+
|
|
109
|
+
/**
|
|
110
|
+
* ID of the child key quorum member
|
|
111
|
+
*/
|
|
112
|
+
key_quorum_id: string;
|
|
113
|
+
|
|
114
|
+
/**
|
|
115
|
+
* Members of this child quorum
|
|
116
|
+
*/
|
|
117
|
+
members: Array<IntentsAPI.IntentAuthorizationKeyQuorumMember>;
|
|
118
|
+
|
|
119
|
+
/**
|
|
120
|
+
* Number of signatures required from this child quorum
|
|
121
|
+
*/
|
|
122
|
+
threshold: number;
|
|
123
|
+
|
|
124
|
+
type: 'key_quorum';
|
|
125
|
+
|
|
126
|
+
/**
|
|
127
|
+
* Display name for the child key quorum (if any)
|
|
128
|
+
*/
|
|
129
|
+
display_name?: string;
|
|
130
|
+
}
|
|
131
|
+
}
|
|
132
|
+
|
|
133
|
+
export declare namespace Intents {
|
|
134
|
+
export {
|
|
135
|
+
type IntentAuthorizationKeyQuorumMember as IntentAuthorizationKeyQuorumMember,
|
|
136
|
+
type IntentAuthorizationMember as IntentAuthorizationMember,
|
|
137
|
+
};
|
|
138
|
+
}
|