@privy-io/api-types 0.10.0 → 0.11.0

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.
Files changed (103) hide show
  1. package/CHANGELOG.md +8 -0
  2. package/client.d.mts +18 -24
  3. package/client.d.mts.map +1 -1
  4. package/client.d.ts +18 -24
  5. package/client.d.ts.map +1 -1
  6. package/client.js +6 -12
  7. package/client.js.map +1 -1
  8. package/client.mjs +6 -12
  9. package/client.mjs.map +1 -1
  10. package/package.json +1 -1
  11. package/resources/client-auth.d.mts +496 -514
  12. package/resources/client-auth.d.mts.map +1 -1
  13. package/resources/client-auth.d.ts +496 -514
  14. package/resources/client-auth.d.ts.map +1 -1
  15. package/resources/client-auth.js.map +1 -1
  16. package/resources/client-auth.mjs.map +1 -1
  17. package/resources/embedded-wallets.d.mts +9 -9
  18. package/resources/embedded-wallets.d.mts.map +1 -1
  19. package/resources/embedded-wallets.d.ts +9 -9
  20. package/resources/embedded-wallets.d.ts.map +1 -1
  21. package/resources/fiat.d.mts +110 -0
  22. package/resources/fiat.d.mts.map +1 -0
  23. package/resources/fiat.d.ts +110 -0
  24. package/resources/fiat.d.ts.map +1 -0
  25. package/resources/fiat.js +9 -0
  26. package/resources/fiat.js.map +1 -0
  27. package/resources/fiat.mjs +5 -0
  28. package/resources/fiat.mjs.map +1 -0
  29. package/resources/funding.d.mts +46 -46
  30. package/resources/funding.d.mts.map +1 -1
  31. package/resources/funding.d.ts +46 -46
  32. package/resources/funding.d.ts.map +1 -1
  33. package/resources/index.d.mts +9 -8
  34. package/resources/index.d.mts.map +1 -1
  35. package/resources/index.d.ts +9 -8
  36. package/resources/index.d.ts.map +1 -1
  37. package/resources/index.js +3 -1
  38. package/resources/index.js.map +1 -1
  39. package/resources/index.mjs +1 -0
  40. package/resources/index.mjs.map +1 -1
  41. package/resources/key-quorums.d.mts +1 -132
  42. package/resources/key-quorums.d.mts.map +1 -1
  43. package/resources/key-quorums.d.ts +1 -132
  44. package/resources/key-quorums.d.ts.map +1 -1
  45. package/resources/key-quorums.js +0 -92
  46. package/resources/key-quorums.js.map +1 -1
  47. package/resources/key-quorums.mjs +0 -92
  48. package/resources/key-quorums.mjs.map +1 -1
  49. package/resources/policies.d.mts +1 -311
  50. package/resources/policies.d.mts.map +1 -1
  51. package/resources/policies.d.ts +1 -311
  52. package/resources/policies.d.ts.map +1 -1
  53. package/resources/policies.js +0 -229
  54. package/resources/policies.js.map +1 -1
  55. package/resources/policies.mjs +0 -229
  56. package/resources/policies.mjs.map +1 -1
  57. package/resources/transactions.d.mts +28 -44
  58. package/resources/transactions.d.mts.map +1 -1
  59. package/resources/transactions.d.ts +28 -44
  60. package/resources/transactions.d.ts.map +1 -1
  61. package/resources/transactions.js +0 -17
  62. package/resources/transactions.js.map +1 -1
  63. package/resources/transactions.mjs +0 -17
  64. package/resources/transactions.mjs.map +1 -1
  65. package/resources/users.d.mts +1 -345
  66. package/resources/users.d.mts.map +1 -1
  67. package/resources/users.d.ts +1 -345
  68. package/resources/users.d.ts.map +1 -1
  69. package/resources/users.js +0 -272
  70. package/resources/users.js.map +1 -1
  71. package/resources/users.mjs +0 -272
  72. package/resources/users.mjs.map +1 -1
  73. package/resources/wallets/index.d.mts +1 -1
  74. package/resources/wallets/index.d.mts.map +1 -1
  75. package/resources/wallets/index.d.ts +1 -1
  76. package/resources/wallets/index.d.ts.map +1 -1
  77. package/resources/wallets/index.js.map +1 -1
  78. package/resources/wallets/index.mjs.map +1 -1
  79. package/resources/wallets/wallets.d.mts +130 -315
  80. package/resources/wallets/wallets.d.mts.map +1 -1
  81. package/resources/wallets/wallets.d.ts +130 -315
  82. package/resources/wallets/wallets.d.ts.map +1 -1
  83. package/resources/wallets/wallets.js +41 -102
  84. package/resources/wallets/wallets.js.map +1 -1
  85. package/resources/wallets/wallets.mjs +41 -102
  86. package/resources/wallets/wallets.mjs.map +1 -1
  87. package/src/client.ts +106 -152
  88. package/src/resources/client-auth.ts +743 -787
  89. package/src/resources/embedded-wallets.ts +14 -14
  90. package/src/resources/fiat.ts +177 -0
  91. package/src/resources/funding.ts +65 -65
  92. package/src/resources/index.ts +86 -106
  93. package/src/resources/key-quorums.ts +1 -203
  94. package/src/resources/policies.ts +1 -493
  95. package/src/resources/transactions.ts +35 -55
  96. package/src/resources/users.ts +1 -479
  97. package/src/resources/wallets/index.ts +4 -9
  98. package/src/resources/wallets/wallets.ts +182 -423
  99. package/src/version.ts +1 -1
  100. package/version.d.mts +1 -1
  101. package/version.d.ts +1 -1
  102. package/version.js +1 -1
  103. package/version.mjs +1 -1
@@ -6,18 +6,6 @@ import * as WalletsAPI from './wallets/wallets';
6
6
 
7
7
  export class EmbeddedWallets extends APIResource {}
8
8
 
9
- /**
10
- * The configuration object for smart wallets.
11
- */
12
- export type SmartWalletConfiguration = SmartWalletConfigurationDisabled | SmartWalletConfigurationEnabled;
13
-
14
- /**
15
- * The input configuration object for smart wallets.
16
- */
17
- export type SmartWalletConfigurationInput =
18
- | SmartWalletConfigurationDisabled
19
- | SmartWalletConfigurationInputEnabled;
20
-
21
9
  /**
22
10
  * The Alchemy paymaster context for a smart wallet network configuration.
23
11
  */
@@ -136,6 +124,11 @@ export type RecoveryType =
136
124
  | 'google_drive_recovery_secret'
137
125
  | 'icloud_recovery_secret';
138
126
 
127
+ /**
128
+ * The configuration object for smart wallets.
129
+ */
130
+ export type SmartWalletConfiguration = SmartWalletConfigurationDisabled | SmartWalletConfigurationEnabled;
131
+
139
132
  /**
140
133
  * A disabled smart wallet configuration.
141
134
  */
@@ -159,6 +152,13 @@ export interface SmartWalletConfigurationEnabled {
159
152
  smart_wallet_version?: string;
160
153
  }
161
154
 
155
+ /**
156
+ * The input configuration object for smart wallets.
157
+ */
158
+ export type SmartWalletConfigurationInput =
159
+ | SmartWalletConfigurationDisabled
160
+ | SmartWalletConfigurationInputEnabled;
161
+
162
162
  /**
163
163
  * An enabled smart wallet configuration input.
164
164
  */
@@ -273,8 +273,6 @@ export interface WalletCreationInput {
273
273
 
274
274
  export declare namespace EmbeddedWallets {
275
275
  export {
276
- type SmartWalletConfiguration as SmartWalletConfiguration,
277
- type SmartWalletConfigurationInput as SmartWalletConfigurationInput,
278
276
  type AlchemyPaymasterContext as AlchemyPaymasterContext,
279
277
  type EmbeddedWalletCreationInput as EmbeddedWalletCreationInput,
280
278
  type ICloudClientType as ICloudClientType,
@@ -287,8 +285,10 @@ export declare namespace EmbeddedWallets {
287
285
  type RecoveryKeyMaterialInput as RecoveryKeyMaterialInput,
288
286
  type RecoveryKeyMaterialResponse as RecoveryKeyMaterialResponse,
289
287
  type RecoveryType as RecoveryType,
288
+ type SmartWalletConfiguration as SmartWalletConfiguration,
290
289
  type SmartWalletConfigurationDisabled as SmartWalletConfigurationDisabled,
291
290
  type SmartWalletConfigurationEnabled as SmartWalletConfigurationEnabled,
291
+ type SmartWalletConfigurationInput as SmartWalletConfigurationInput,
292
292
  type SmartWalletConfigurationInputEnabled as SmartWalletConfigurationInputEnabled,
293
293
  type SmartWalletNetworkConfiguration as SmartWalletNetworkConfiguration,
294
294
  type SmartWalletNetworkConfigurationInput as SmartWalletNetworkConfigurationInput,
@@ -0,0 +1,177 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ import { APIResource } from '../core/resource';
4
+
5
+ export class Fiat extends APIResource {}
6
+
7
+ /**
8
+ * Supported fiat currencies.
9
+ */
10
+ export type FiatCurrency = 'usd' | 'eur';
11
+
12
+ /**
13
+ * Supported fiat payment rails.
14
+ */
15
+ export type FiatPaymentRail = 'sepa' | 'ach_push' | 'wire';
16
+
17
+ /**
18
+ * Deposit instructions for an offramp transfer.
19
+ */
20
+ export interface OfframpDepositInstructions {
21
+ amount: string;
22
+
23
+ /**
24
+ * Supported blockchain chains for onramp and offramp.
25
+ */
26
+ chain: OnrampChain;
27
+
28
+ /**
29
+ * Supported crypto assets for onramp and offramp.
30
+ */
31
+ currency: OnrampAsset;
32
+
33
+ from_address: string;
34
+
35
+ to_address: string;
36
+ }
37
+
38
+ /**
39
+ * Response for an offramp transfer initiation.
40
+ */
41
+ export interface OfframpResponse {
42
+ id: string;
43
+
44
+ /**
45
+ * Deposit instructions for an offramp transfer.
46
+ */
47
+ deposit_instructions: OfframpDepositInstructions;
48
+
49
+ /**
50
+ * Status of an onramp or offramp transfer.
51
+ */
52
+ status: OnrampTransferStatus;
53
+ }
54
+
55
+ /**
56
+ * Supported crypto assets for onramp and offramp.
57
+ */
58
+ export type OnrampAsset = 'usdc';
59
+
60
+ /**
61
+ * Supported blockchain chains for onramp and offramp.
62
+ */
63
+ export type OnrampChain = 'ethereum' | 'base' | 'arbitrum' | 'polygon' | 'optimism';
64
+
65
+ /**
66
+ * Bank deposit instructions for an onramp transfer.
67
+ */
68
+ export interface OnrampDepositInstructions {
69
+ amount: string;
70
+
71
+ /**
72
+ * Supported fiat currencies.
73
+ */
74
+ currency: FiatCurrency;
75
+
76
+ /**
77
+ * Supported fiat payment rails.
78
+ */
79
+ payment_rail: FiatPaymentRail;
80
+
81
+ account_holder_name?: string;
82
+
83
+ bank_account_number?: string;
84
+
85
+ bank_address?: string;
86
+
87
+ bank_beneficiary_address?: string;
88
+
89
+ bank_beneficiary_name?: string;
90
+
91
+ bank_name?: string;
92
+
93
+ bank_routing_number?: string;
94
+
95
+ bic?: string;
96
+
97
+ deposit_message?: string;
98
+
99
+ iban?: string;
100
+ }
101
+
102
+ /**
103
+ * Response for an onramp KYC verification.
104
+ */
105
+ export interface OnrampKYCResponse {
106
+ /**
107
+ * Status of the KYC verification process.
108
+ */
109
+ status: OnrampKYCStatus;
110
+
111
+ user_id: string;
112
+
113
+ provider_user_id?: string;
114
+ }
115
+
116
+ /**
117
+ * Status of the KYC verification process.
118
+ */
119
+ export type OnrampKYCStatus =
120
+ | 'not_found'
121
+ | 'active'
122
+ | 'awaiting_questionnaire'
123
+ | 'awaiting_ubo'
124
+ | 'incomplete'
125
+ | 'not_started'
126
+ | 'offboarded'
127
+ | 'paused'
128
+ | 'rejected'
129
+ | 'under_review';
130
+
131
+ /**
132
+ * Response for an onramp transfer initiation.
133
+ */
134
+ export interface OnrampResponse {
135
+ id: string;
136
+
137
+ /**
138
+ * Bank deposit instructions for an onramp transfer.
139
+ */
140
+ deposit_instructions: OnrampDepositInstructions;
141
+
142
+ /**
143
+ * Status of an onramp or offramp transfer.
144
+ */
145
+ status: OnrampTransferStatus;
146
+ }
147
+
148
+ /**
149
+ * Status of an onramp or offramp transfer.
150
+ */
151
+ export type OnrampTransferStatus =
152
+ | 'awaiting_funds'
153
+ | 'in_review'
154
+ | 'funds_received'
155
+ | 'payment_submitted'
156
+ | 'payment_processed'
157
+ | 'canceled'
158
+ | 'error'
159
+ | 'undeliverable'
160
+ | 'returned'
161
+ | 'refunded';
162
+
163
+ export declare namespace Fiat {
164
+ export {
165
+ type FiatCurrency as FiatCurrency,
166
+ type FiatPaymentRail as FiatPaymentRail,
167
+ type OfframpDepositInstructions as OfframpDepositInstructions,
168
+ type OfframpResponse as OfframpResponse,
169
+ type OnrampAsset as OnrampAsset,
170
+ type OnrampChain as OnrampChain,
171
+ type OnrampDepositInstructions as OnrampDepositInstructions,
172
+ type OnrampKYCResponse as OnrampKYCResponse,
173
+ type OnrampKYCStatus as OnrampKYCStatus,
174
+ type OnrampResponse as OnrampResponse,
175
+ type OnrampTransferStatus as OnrampTransferStatus,
176
+ };
177
+ }
@@ -5,66 +5,6 @@ import * as FundingAPI from './funding';
5
5
 
6
6
  export class Funding extends APIResource {}
7
7
 
8
- /**
9
- * The input for initializing a Coinbase on-ramp session.
10
- */
11
- export type CoinbaseOnRampInitInput = CoinbaseOnRampInitEthereumInput | CoinbaseOnRampInitSolanaInput;
12
-
13
- /**
14
- * The response from initializing a Coinbase on-ramp session.
15
- */
16
- export interface CoinbaseOnRampInitResponse {
17
- app_id: string;
18
-
19
- channel_id: string;
20
-
21
- partner_user_id: string;
22
-
23
- session_token: string;
24
- }
25
-
26
- /**
27
- * The response for getting the status of a Coinbase on-ramp session.
28
- */
29
- export interface CoinbaseOnRampStatusResponse {
30
- /**
31
- * Status of a Coinbase on-ramp session.
32
- */
33
- status: CoinbaseOnRampStatus;
34
- }
35
-
36
- /**
37
- * The input for signing a Moonpay on-ramp.
38
- */
39
- export type MoonpayOnRampSignInput =
40
- | MoonpayOnRampSignInput.MoonpayFiatOnRampEthereumInput
41
- | MoonpayOnRampSignInput.MoonpayFiatOnRampSolanaInput;
42
-
43
- export namespace MoonpayOnRampSignInput {
44
- /**
45
- * Sandbox configuration for a Moonpay on-ramp.
46
- */
47
- export interface MoonpayFiatOnRampEthereumInput
48
- extends FundingAPI.MoonpayOnRampSandboxConfig,
49
- FundingAPI.MoonpayFiatOnRampEthereumInput {}
50
-
51
- /**
52
- * Sandbox configuration for a Moonpay on-ramp.
53
- */
54
- export interface MoonpayFiatOnRampSolanaInput
55
- extends FundingAPI.MoonpayOnRampSandboxConfig,
56
- FundingAPI.MoonpayFiatOnRampSolanaInput {}
57
- }
58
-
59
- /**
60
- * The response from signing a Moonpay on-ramp.
61
- */
62
- export interface MoonpayOnRampSignResponse {
63
- externalTransactionId: string;
64
-
65
- signedUrl: string;
66
- }
67
-
68
8
  /**
69
9
  * A blockchain supported by Coinbase on-ramp.
70
10
  */
@@ -103,6 +43,24 @@ export interface CoinbaseOnRampInitEthereumInput {
103
43
  assets?: Array<CoinbaseEthereumAsset>;
104
44
  }
105
45
 
46
+ /**
47
+ * The input for initializing a Coinbase on-ramp session.
48
+ */
49
+ export type CoinbaseOnRampInitInput = CoinbaseOnRampInitEthereumInput | CoinbaseOnRampInitSolanaInput;
50
+
51
+ /**
52
+ * The response from initializing a Coinbase on-ramp session.
53
+ */
54
+ export interface CoinbaseOnRampInitResponse {
55
+ app_id: string;
56
+
57
+ channel_id: string;
58
+
59
+ partner_user_id: string;
60
+
61
+ session_token: string;
62
+ }
63
+
106
64
  /**
107
65
  * Input for initializing a Coinbase on-ramp session for Solana.
108
66
  */
@@ -126,6 +84,16 @@ export interface CoinbaseOnRampSolanaAddress {
126
84
  */
127
85
  export type CoinbaseOnRampStatus = 'pending' | 'success' | 'failure';
128
86
 
87
+ /**
88
+ * The response for getting the status of a Coinbase on-ramp session.
89
+ */
90
+ export interface CoinbaseOnRampStatusResponse {
91
+ /**
92
+ * Status of a Coinbase on-ramp session.
93
+ */
94
+ status: CoinbaseOnRampStatus;
95
+ }
96
+
129
97
  /**
130
98
  * A Solana asset supported by Coinbase on-ramp.
131
99
  */
@@ -253,6 +221,38 @@ export interface MoonpayOnRampSandboxConfig {
253
221
  useSandbox?: boolean;
254
222
  }
255
223
 
224
+ /**
225
+ * The input for signing a Moonpay on-ramp.
226
+ */
227
+ export type MoonpayOnRampSignInput =
228
+ | MoonpayOnRampSignInput.MoonpayFiatOnRampEthereumInput
229
+ | MoonpayOnRampSignInput.MoonpayFiatOnRampSolanaInput;
230
+
231
+ export namespace MoonpayOnRampSignInput {
232
+ /**
233
+ * Sandbox configuration for a Moonpay on-ramp.
234
+ */
235
+ export interface MoonpayFiatOnRampEthereumInput
236
+ extends FundingAPI.MoonpayOnRampSandboxConfig,
237
+ FundingAPI.MoonpayFiatOnRampEthereumInput {}
238
+
239
+ /**
240
+ * Sandbox configuration for a Moonpay on-ramp.
241
+ */
242
+ export interface MoonpayFiatOnRampSolanaInput
243
+ extends FundingAPI.MoonpayOnRampSandboxConfig,
244
+ FundingAPI.MoonpayFiatOnRampSolanaInput {}
245
+ }
246
+
247
+ /**
248
+ * The response from signing a Moonpay on-ramp.
249
+ */
250
+ export interface MoonpayOnRampSignResponse {
251
+ externalTransactionId: string;
252
+
253
+ signedUrl: string;
254
+ }
255
+
256
256
  /**
257
257
  * A payment method supported by Moonpay on-ramp.
258
258
  */
@@ -291,18 +291,16 @@ export type MoonpayUiTheme = 'light' | 'dark';
291
291
 
292
292
  export declare namespace Funding {
293
293
  export {
294
- type CoinbaseOnRampInitInput as CoinbaseOnRampInitInput,
295
- type CoinbaseOnRampInitResponse as CoinbaseOnRampInitResponse,
296
- type CoinbaseOnRampStatusResponse as CoinbaseOnRampStatusResponse,
297
- type MoonpayOnRampSignInput as MoonpayOnRampSignInput,
298
- type MoonpayOnRampSignResponse as MoonpayOnRampSignResponse,
299
294
  type CoinbaseBlockchain as CoinbaseBlockchain,
300
295
  type CoinbaseEthereumAsset as CoinbaseEthereumAsset,
301
296
  type CoinbaseOnRampEthereumAddress as CoinbaseOnRampEthereumAddress,
302
297
  type CoinbaseOnRampInitEthereumInput as CoinbaseOnRampInitEthereumInput,
298
+ type CoinbaseOnRampInitInput as CoinbaseOnRampInitInput,
299
+ type CoinbaseOnRampInitResponse as CoinbaseOnRampInitResponse,
303
300
  type CoinbaseOnRampInitSolanaInput as CoinbaseOnRampInitSolanaInput,
304
301
  type CoinbaseOnRampSolanaAddress as CoinbaseOnRampSolanaAddress,
305
302
  type CoinbaseOnRampStatus as CoinbaseOnRampStatus,
303
+ type CoinbaseOnRampStatusResponse as CoinbaseOnRampStatusResponse,
306
304
  type CoinbaseSolanaAsset as CoinbaseSolanaAsset,
307
305
  type MoonpayCurrencyCode as MoonpayCurrencyCode,
308
306
  type MoonpayFiatOnRampEthereumConfig as MoonpayFiatOnRampEthereumConfig,
@@ -310,6 +308,8 @@ export declare namespace Funding {
310
308
  type MoonpayFiatOnRampSolanaConfig as MoonpayFiatOnRampSolanaConfig,
311
309
  type MoonpayFiatOnRampSolanaInput as MoonpayFiatOnRampSolanaInput,
312
310
  type MoonpayOnRampSandboxConfig as MoonpayOnRampSandboxConfig,
311
+ type MoonpayOnRampSignInput as MoonpayOnRampSignInput,
312
+ type MoonpayOnRampSignResponse as MoonpayOnRampSignResponse,
313
313
  type MoonpayPaymentMethod as MoonpayPaymentMethod,
314
314
  type MoonpaySolanaCurrencyCode as MoonpaySolanaCurrencyCode,
315
315
  type MoonpayUiConfig as MoonpayUiConfig,