@privy-io/api-types 0.13.0 → 0.15.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 (256) hide show
  1. package/CHANGELOG.md +49 -0
  2. package/api-promise.d.mts +1 -0
  3. package/api-promise.d.mts.map +1 -1
  4. package/api-promise.d.ts +1 -0
  5. package/api-promise.d.ts.map +1 -1
  6. package/api-promise.mjs +1 -0
  7. package/api-promise.mjs.map +1 -1
  8. package/client.d.mts +25 -19
  9. package/client.d.mts.map +1 -1
  10. package/client.d.ts +25 -19
  11. package/client.d.ts.map +1 -1
  12. package/client.js +8 -2
  13. package/client.js.map +1 -1
  14. package/client.mjs +8 -2
  15. package/client.mjs.map +1 -1
  16. package/core/api-promise.d.mts.map +1 -1
  17. package/core/api-promise.d.ts.map +1 -1
  18. package/core/api-promise.mjs.map +1 -1
  19. package/core/error.mjs.map +1 -1
  20. package/core/pagination.d.mts.map +1 -1
  21. package/core/pagination.d.ts.map +1 -1
  22. package/core/pagination.mjs.map +1 -1
  23. package/core/resource.d.mts.map +1 -1
  24. package/core/resource.d.ts.map +1 -1
  25. package/core/uploads.d.mts.map +1 -1
  26. package/core/uploads.d.ts.map +1 -1
  27. package/core/uploads.mjs.map +1 -1
  28. package/error.d.mts +1 -0
  29. package/error.d.mts.map +1 -1
  30. package/error.d.ts +1 -0
  31. package/error.d.ts.map +1 -1
  32. package/error.mjs +1 -0
  33. package/error.mjs.map +1 -1
  34. package/index.d.mts.map +1 -1
  35. package/index.d.ts.map +1 -1
  36. package/index.mjs.map +1 -1
  37. package/internal/detect-platform.mjs.map +1 -1
  38. package/internal/headers.mjs.map +1 -1
  39. package/internal/parse.d.mts.map +1 -1
  40. package/internal/parse.d.ts.map +1 -1
  41. package/internal/parse.mjs.map +1 -1
  42. package/internal/qs/formats.d.mts.map +1 -1
  43. package/internal/qs/formats.d.ts.map +1 -1
  44. package/internal/qs/index.d.mts +2 -2
  45. package/internal/qs/index.d.mts.map +1 -1
  46. package/internal/qs/index.d.ts +2 -2
  47. package/internal/qs/index.d.ts.map +1 -1
  48. package/internal/qs/index.mjs.map +1 -1
  49. package/internal/qs/stringify.d.mts.map +1 -1
  50. package/internal/qs/stringify.d.ts.map +1 -1
  51. package/internal/qs/stringify.mjs.map +1 -1
  52. package/internal/qs/utils.d.mts.map +1 -1
  53. package/internal/qs/utils.d.ts.map +1 -1
  54. package/internal/qs/utils.mjs.map +1 -1
  55. package/internal/request-options.d.mts.map +1 -1
  56. package/internal/request-options.d.ts.map +1 -1
  57. package/internal/shims.d.mts +6 -0
  58. package/internal/shims.d.mts.map +1 -1
  59. package/internal/shims.d.ts +6 -0
  60. package/internal/shims.d.ts.map +1 -1
  61. package/internal/to-file.d.mts.map +1 -1
  62. package/internal/to-file.d.ts.map +1 -1
  63. package/internal/to-file.mjs.map +1 -1
  64. package/internal/types.d.mts +4 -4
  65. package/internal/types.d.mts.map +1 -1
  66. package/internal/types.d.ts +4 -4
  67. package/internal/types.d.ts.map +1 -1
  68. package/internal/uploads.d.mts.map +1 -1
  69. package/internal/uploads.d.ts.map +1 -1
  70. package/internal/uploads.mjs.map +1 -1
  71. package/internal/utils/base64.mjs.map +1 -1
  72. package/internal/utils/log.d.mts.map +1 -1
  73. package/internal/utils/log.d.ts.map +1 -1
  74. package/internal/utils/log.mjs.map +1 -1
  75. package/internal/utils/path.mjs.map +1 -1
  76. package/internal/utils/query.mjs.map +1 -1
  77. package/internal/utils/values.mjs.map +1 -1
  78. package/internal/utils.d.mts.map +1 -1
  79. package/internal/utils.d.ts.map +1 -1
  80. package/internal/utils.mjs.map +1 -1
  81. package/package.json +1 -1
  82. package/pagination.d.mts +1 -0
  83. package/pagination.d.mts.map +1 -1
  84. package/pagination.d.ts +1 -0
  85. package/pagination.d.ts.map +1 -1
  86. package/pagination.mjs +1 -0
  87. package/pagination.mjs.map +1 -1
  88. package/resource.d.mts +1 -0
  89. package/resource.d.mts.map +1 -1
  90. package/resource.d.ts +1 -0
  91. package/resource.d.ts.map +1 -1
  92. package/resource.mjs +1 -0
  93. package/resource.mjs.map +1 -1
  94. package/resources/accounts.d.mts.map +1 -1
  95. package/resources/accounts.d.ts.map +1 -1
  96. package/resources/accounts.mjs.map +1 -1
  97. package/resources/aggregations.d.mts.map +1 -1
  98. package/resources/aggregations.d.ts.map +1 -1
  99. package/resources/aggregations.mjs.map +1 -1
  100. package/resources/analytics.d.mts +1 -1
  101. package/resources/analytics.d.mts.map +1 -1
  102. package/resources/analytics.d.ts +1 -1
  103. package/resources/analytics.d.ts.map +1 -1
  104. package/resources/analytics.mjs.map +1 -1
  105. package/resources/apps.d.mts +1 -17
  106. package/resources/apps.d.mts.map +1 -1
  107. package/resources/apps.d.ts +1 -17
  108. package/resources/apps.d.ts.map +1 -1
  109. package/resources/apps.mjs.map +1 -1
  110. package/resources/client-auth.d.mts +156 -213
  111. package/resources/client-auth.d.mts.map +1 -1
  112. package/resources/client-auth.d.ts +156 -213
  113. package/resources/client-auth.d.ts.map +1 -1
  114. package/resources/client-auth.js.map +1 -1
  115. package/resources/client-auth.mjs.map +1 -1
  116. package/resources/cross-app.d.mts.map +1 -1
  117. package/resources/cross-app.d.ts.map +1 -1
  118. package/resources/cross-app.mjs.map +1 -1
  119. package/resources/embedded-wallets.d.mts.map +1 -1
  120. package/resources/embedded-wallets.d.ts.map +1 -1
  121. package/resources/embedded-wallets.mjs.map +1 -1
  122. package/resources/fiat.d.mts.map +1 -1
  123. package/resources/fiat.d.ts.map +1 -1
  124. package/resources/fiat.mjs.map +1 -1
  125. package/resources/funding.d.mts.map +1 -1
  126. package/resources/funding.d.ts.map +1 -1
  127. package/resources/funding.mjs.map +1 -1
  128. package/resources/index.d.mts +11 -9
  129. package/resources/index.d.mts.map +1 -1
  130. package/resources/index.d.ts +11 -9
  131. package/resources/index.d.ts.map +1 -1
  132. package/resources/index.js +5 -1
  133. package/resources/index.js.map +1 -1
  134. package/resources/index.mjs +2 -0
  135. package/resources/index.mjs.map +1 -1
  136. package/resources/intents.d.mts +63 -2
  137. package/resources/intents.d.mts.map +1 -1
  138. package/resources/intents.d.ts +63 -2
  139. package/resources/intents.d.ts.map +1 -1
  140. package/resources/intents.mjs.map +1 -1
  141. package/resources/key-quorums.d.mts.map +1 -1
  142. package/resources/key-quorums.d.ts.map +1 -1
  143. package/resources/key-quorums.mjs.map +1 -1
  144. package/resources/kraken-embed.d.mts +653 -1
  145. package/resources/kraken-embed.d.mts.map +1 -1
  146. package/resources/kraken-embed.d.ts +653 -1
  147. package/resources/kraken-embed.d.ts.map +1 -1
  148. package/resources/kraken-embed.mjs.map +1 -1
  149. package/resources/oauth.d.mts +77 -0
  150. package/resources/oauth.d.mts.map +1 -0
  151. package/resources/oauth.d.ts +77 -0
  152. package/resources/oauth.d.ts.map +1 -0
  153. package/resources/oauth.js +9 -0
  154. package/resources/oauth.js.map +1 -0
  155. package/resources/oauth.mjs +5 -0
  156. package/resources/oauth.mjs.map +1 -0
  157. package/resources/onramps.d.mts +456 -0
  158. package/resources/onramps.d.mts.map +1 -0
  159. package/resources/onramps.d.ts +456 -0
  160. package/resources/onramps.d.ts.map +1 -0
  161. package/resources/onramps.js +9 -0
  162. package/resources/onramps.js.map +1 -0
  163. package/resources/onramps.mjs +5 -0
  164. package/resources/onramps.mjs.map +1 -0
  165. package/resources/organizations.d.mts.map +1 -1
  166. package/resources/organizations.d.ts.map +1 -1
  167. package/resources/organizations.mjs.map +1 -1
  168. package/resources/policies.d.mts +29 -3
  169. package/resources/policies.d.mts.map +1 -1
  170. package/resources/policies.d.ts +29 -3
  171. package/resources/policies.d.ts.map +1 -1
  172. package/resources/policies.mjs.map +1 -1
  173. package/resources/shared.d.mts +26 -1
  174. package/resources/shared.d.mts.map +1 -1
  175. package/resources/shared.d.ts +26 -1
  176. package/resources/shared.d.ts.map +1 -1
  177. package/resources/shared.mjs.map +1 -1
  178. package/resources/swaps.d.mts +43 -5
  179. package/resources/swaps.d.mts.map +1 -1
  180. package/resources/swaps.d.ts +43 -5
  181. package/resources/swaps.d.ts.map +1 -1
  182. package/resources/swaps.mjs.map +1 -1
  183. package/resources/transactions.d.mts.map +1 -1
  184. package/resources/transactions.d.ts.map +1 -1
  185. package/resources/transactions.mjs.map +1 -1
  186. package/resources/users.d.mts +3 -0
  187. package/resources/users.d.mts.map +1 -1
  188. package/resources/users.d.ts +3 -0
  189. package/resources/users.d.ts.map +1 -1
  190. package/resources/users.mjs.map +1 -1
  191. package/resources/wallet-actions.d.mts +86 -1
  192. package/resources/wallet-actions.d.mts.map +1 -1
  193. package/resources/wallet-actions.d.ts +86 -1
  194. package/resources/wallet-actions.d.ts.map +1 -1
  195. package/resources/wallet-actions.js.map +1 -1
  196. package/resources/wallet-actions.mjs.map +1 -1
  197. package/resources/wallets/balance.d.mts.map +1 -1
  198. package/resources/wallets/balance.d.ts.map +1 -1
  199. package/resources/wallets/balance.mjs.map +1 -1
  200. package/resources/wallets/index.d.mts +1 -1
  201. package/resources/wallets/index.d.mts.map +1 -1
  202. package/resources/wallets/index.d.ts +1 -1
  203. package/resources/wallets/index.d.ts.map +1 -1
  204. package/resources/wallets/index.js.map +1 -1
  205. package/resources/wallets/index.mjs.map +1 -1
  206. package/resources/wallets/transactions.d.mts.map +1 -1
  207. package/resources/wallets/transactions.d.ts.map +1 -1
  208. package/resources/wallets/transactions.mjs.map +1 -1
  209. package/resources/wallets/wallets.d.mts +153 -4
  210. package/resources/wallets/wallets.d.mts.map +1 -1
  211. package/resources/wallets/wallets.d.ts +153 -4
  212. package/resources/wallets/wallets.d.ts.map +1 -1
  213. package/resources/wallets/wallets.js.map +1 -1
  214. package/resources/wallets/wallets.mjs.map +1 -1
  215. package/resources/wallets.d.mts.map +1 -1
  216. package/resources/wallets.d.ts.map +1 -1
  217. package/resources/wallets.mjs.map +1 -1
  218. package/resources/webhooks.d.mts +116 -2
  219. package/resources/webhooks.d.mts.map +1 -1
  220. package/resources/webhooks.d.ts +116 -2
  221. package/resources/webhooks.d.ts.map +1 -1
  222. package/resources/webhooks.mjs.map +1 -1
  223. package/resources/yield.d.mts.map +1 -1
  224. package/resources/yield.d.ts.map +1 -1
  225. package/resources/yield.mjs.map +1 -1
  226. package/resources.d.mts.map +1 -1
  227. package/resources.d.ts.map +1 -1
  228. package/resources.mjs.map +1 -1
  229. package/src/client.ts +313 -61
  230. package/src/resources/analytics.ts +1 -1
  231. package/src/resources/apps.ts +0 -24
  232. package/src/resources/client-auth.ts +193 -304
  233. package/src/resources/index.ts +148 -25
  234. package/src/resources/intents.ts +84 -1
  235. package/src/resources/kraken-embed.ts +1661 -0
  236. package/src/resources/oauth.ts +96 -0
  237. package/src/resources/onramps.ts +637 -0
  238. package/src/resources/policies.ts +40 -0
  239. package/src/resources/shared.ts +37 -0
  240. package/src/resources/swaps.ts +51 -5
  241. package/src/resources/users.ts +3 -0
  242. package/src/resources/wallet-actions.ts +104 -0
  243. package/src/resources/wallets/index.ts +9 -0
  244. package/src/resources/wallets/wallets.ts +191 -3
  245. package/src/resources/webhooks.ts +142 -0
  246. package/src/version.ts +1 -1
  247. package/uploads.d.mts +1 -0
  248. package/uploads.d.mts.map +1 -1
  249. package/uploads.d.ts +1 -0
  250. package/uploads.d.ts.map +1 -1
  251. package/uploads.mjs +1 -0
  252. package/uploads.mjs.map +1 -1
  253. package/version.d.mts +1 -1
  254. package/version.d.ts +1 -1
  255. package/version.js +1 -1
  256. package/version.mjs +1 -1
@@ -10,7 +10,7 @@ export class Analytics extends APIResource {}
10
10
  export interface AnalyticsEventInput {
11
11
  event_name: string;
12
12
 
13
- client_id?: string;
13
+ client_id?: string | null;
14
14
 
15
15
  payload?: { [key: string]: unknown };
16
16
  }
@@ -377,28 +377,6 @@ export interface GasSpendResponseBody {
377
377
  value: string;
378
378
  }
379
379
 
380
- /**
381
- * Gas sponsorship configuration for an app.
382
- */
383
- export interface GasSponsorshipConfiguration {
384
- configured_networks: Array<Caip2>;
385
-
386
- require_app_secret: boolean;
387
-
388
- sponsorship_enabled: boolean;
389
- }
390
-
391
- /**
392
- * Input for configuring gas sponsorship settings for an app.
393
- */
394
- export interface GasSponsorshipConfigurationInput {
395
- configured_networks?: Array<Caip2>;
396
-
397
- require_app_secret?: boolean;
398
-
399
- sponsorship_enabled?: boolean;
400
- }
401
-
402
380
  /**
403
381
  * Allowlist invite input for a phone number.
404
382
  */
@@ -490,8 +468,6 @@ export declare namespace Apps {
490
468
  type GasSpendCurrency as GasSpendCurrency,
491
469
  type GasSpendRequestBody as GasSpendRequestBody,
492
470
  type GasSpendResponseBody as GasSpendResponseBody,
493
- type GasSponsorshipConfiguration as GasSponsorshipConfiguration,
494
- type GasSponsorshipConfigurationInput as GasSponsorshipConfigurationInput,
495
471
  type PhoneInviteInput as PhoneInviteInput,
496
472
  type TelegramAuthConfigSchema as TelegramAuthConfigSchema,
497
473
  type TestAccount as TestAccount,
@@ -2,7 +2,6 @@
2
2
 
3
3
  import { APIResource } from '../core/resource';
4
4
  import * as EmbeddedWalletsAPI from './embedded-wallets';
5
- import * as FiatAPI from './fiat';
6
5
  import * as UsersAPI from './users';
7
6
 
8
7
  export class ClientAuth extends APIResource {}
@@ -91,6 +90,9 @@ export interface BridgeBrlFiatVirtualAccountDepositInstructions {
91
90
  payment_rails: Array<'pix'>;
92
91
  }
93
92
 
93
+ /**
94
+ * Supported destination stablecoin assets for fiat-to-crypto transfers.
95
+ */
94
96
  export type BridgeDestinationAsset = 'usdb' | 'usdc' | 'usdt' | 'dai' | 'pyusd' | 'eurc';
95
97
 
96
98
  /**
@@ -112,31 +114,6 @@ export interface BridgeEurFiatVirtualAccountDepositInstructions {
112
114
  payment_rails: Array<'sepa'>;
113
115
  }
114
116
 
115
- /**
116
- * The response for getting a native onramp provider customer.
117
- */
118
- export interface BridgeFiatCustomerResponse {
119
- has_accepted_terms: boolean;
120
-
121
- provider: 'bridge';
122
-
123
- /**
124
- * Status of the KYC verification process.
125
- */
126
- status: FiatAPI.OnrampKYCStatus;
127
-
128
- kyc_url?: string;
129
-
130
- rejection_reasons?: Array<BridgeFiatRejectionReason>;
131
- }
132
-
133
- /**
134
- * A rejection reason for a customer KYC verification.
135
- */
136
- export interface BridgeFiatRejectionReason {
137
- reason: string;
138
- }
139
-
140
117
  /**
141
118
  * The deposit instructions for a virtual account.
142
119
  */
@@ -147,9 +124,15 @@ export type BridgeFiatVirtualAccountDepositInstructions =
147
124
  | BridgeBrlFiatVirtualAccountDepositInstructions
148
125
  | BridgeGbpFiatVirtualAccountDepositInstructions;
149
126
 
127
+ /**
128
+ * The destination chain, asset, and address for a virtual account transfer.
129
+ */
150
130
  export interface BridgeFiatVirtualAccountDestination {
151
131
  address: string;
152
132
 
133
+ /**
134
+ * Supported destination stablecoin assets for fiat-to-crypto transfers.
135
+ */
153
136
  asset: BridgeDestinationAsset;
154
137
 
155
138
  chain: string;
@@ -159,10 +142,16 @@ export interface BridgeFiatVirtualAccountDestination {
159
142
  * The request input for creating virtual account.
160
143
  */
161
144
  export interface BridgeFiatVirtualAccountRequest {
145
+ /**
146
+ * The destination chain, asset, and address for a virtual account transfer.
147
+ */
162
148
  destination: BridgeFiatVirtualAccountDestination;
163
149
 
164
150
  provider: 'bridge';
165
151
 
152
+ /**
153
+ * The source fiat currency configuration for a virtual account.
154
+ */
166
155
  source: BridgeFiatVirtualAccountSource;
167
156
  }
168
157
 
@@ -175,6 +164,9 @@ export interface BridgeFiatVirtualAccountResponse {
175
164
  */
176
165
  deposit_instructions: BridgeFiatVirtualAccountDepositInstructions;
177
166
 
167
+ /**
168
+ * The destination chain, asset, and address for a virtual account transfer.
169
+ */
178
170
  destination: BridgeFiatVirtualAccountDestination;
179
171
 
180
172
  provider: 'bridge';
@@ -182,7 +174,13 @@ export interface BridgeFiatVirtualAccountResponse {
182
174
  status: string;
183
175
  }
184
176
 
177
+ /**
178
+ * The source fiat currency configuration for a virtual account.
179
+ */
185
180
  export interface BridgeFiatVirtualAccountSource {
181
+ /**
182
+ * Supported source fiat currencies for virtual account deposits.
183
+ */
186
184
  asset: BridgeSourceAsset;
187
185
  }
188
186
 
@@ -227,32 +225,20 @@ export interface BridgeMxnFiatVirtualAccountDepositInstructions {
227
225
  */
228
226
  export type BridgeOnrampProvider = 'bridge' | 'bridge-sandbox';
229
227
 
230
- /**
231
- * The response for getting a native onramp provider customer.
232
- */
233
- export interface BridgeSandboxFiatCustomerResponse {
234
- has_accepted_terms: boolean;
235
-
236
- provider: 'bridge-sandbox';
237
-
238
- /**
239
- * Status of the KYC verification process.
240
- */
241
- status: FiatAPI.OnrampKYCStatus;
242
-
243
- kyc_url?: string;
244
-
245
- rejection_reasons?: Array<BridgeFiatRejectionReason>;
246
- }
247
-
248
228
  /**
249
229
  * The request input for creating virtual account.
250
230
  */
251
231
  export interface BridgeSandboxFiatVirtualAccountRequest {
232
+ /**
233
+ * The destination chain, asset, and address for a virtual account transfer.
234
+ */
252
235
  destination: BridgeFiatVirtualAccountDestination;
253
236
 
254
237
  provider: 'bridge-sandbox';
255
238
 
239
+ /**
240
+ * The source fiat currency configuration for a virtual account.
241
+ */
256
242
  source: BridgeFiatVirtualAccountSource;
257
243
  }
258
244
 
@@ -265,6 +251,9 @@ export interface BridgeSandboxFiatVirtualAccountResponse {
265
251
  */
266
252
  deposit_instructions: BridgeFiatVirtualAccountDepositInstructions;
267
253
 
254
+ /**
255
+ * The destination chain, asset, and address for a virtual account transfer.
256
+ */
268
257
  destination: BridgeFiatVirtualAccountDestination;
269
258
 
270
259
  provider: 'bridge-sandbox';
@@ -272,6 +261,9 @@ export interface BridgeSandboxFiatVirtualAccountResponse {
272
261
  status: string;
273
262
  }
274
263
 
264
+ /**
265
+ * Supported source fiat currencies for virtual account deposits.
266
+ */
275
267
  export type BridgeSourceAsset = 'usd' | 'eur' | 'mxn' | 'brl' | 'gbp';
276
268
 
277
269
  /**
@@ -295,31 +287,6 @@ export interface BridgeUsdFiatVirtualAccountDepositInstructions {
295
287
  payment_rails: Array<'ach_push' | 'wire'>;
296
288
  }
297
289
 
298
- /**
299
- * A CAIP-2 chain identifier in namespace:reference format (e.g. "eip155:1" for
300
- * Ethereum mainnet, "solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp" for Solana mainnet).
301
- */
302
- export type Caip2ChainID = string;
303
-
304
- /**
305
- * The request input for creating (or updating) a native onramp provider customer.
306
- */
307
- export interface CreateOrUpdateFiatCustomerRequestInput {
308
- has_accepted_terms: boolean;
309
-
310
- /**
311
- * Valid set of onramp providers
312
- */
313
- provider: OnrampProvider;
314
-
315
- kyc_redirect_url?: string;
316
- }
317
-
318
- /**
319
- * Cryptocurrency symbol. Uppercase alphanumeric, 2-10 characters.
320
- */
321
- export type CryptoCurrencyCode = string;
322
-
323
290
  /**
324
291
  * The request body for authenticating with a custom JWT.
325
292
  */
@@ -345,6 +312,37 @@ export interface CustomJwtLinkRequestBody {
345
312
  */
346
313
  export type CustomOAuthProviderID = `custom:${string}`;
347
314
 
315
+ /**
316
+ * The action to take on the device authorization request.
317
+ */
318
+ export type DeviceVerifyAction = 'approve' | 'deny';
319
+
320
+ /**
321
+ * Request body for approving or denying a device authorization request. The user
322
+ * must be authenticated and belong to the target app.
323
+ */
324
+ export interface DeviceVerifyRequestBody {
325
+ /**
326
+ * The action to take on the device authorization request.
327
+ */
328
+ action: DeviceVerifyAction;
329
+
330
+ /**
331
+ * The user code displayed on the CLI device.
332
+ */
333
+ user_code: string;
334
+ }
335
+
336
+ /**
337
+ * Response indicating the device authorization action was processed.
338
+ */
339
+ export interface DeviceVerifyResponse {
340
+ /**
341
+ * Whether the action was processed successfully.
342
+ */
343
+ success: boolean;
344
+ }
345
+
348
346
  /**
349
347
  * The ID of an external OAuth provider.
350
348
  */
@@ -669,114 +667,6 @@ export interface FarcasterV2InitResponseBody {
669
667
  nonce: string;
670
668
  }
671
669
 
672
- /**
673
- * A positive decimal amount as a string (e.g. "100", "50.25", "0.001").
674
- */
675
- export type FiatAmount = string;
676
-
677
- /**
678
- * ISO 4217 fiat currency code. Three uppercase ASCII letters.
679
- */
680
- export type FiatCurrencyCode = string;
681
-
682
- /**
683
- * The response for getting a native onramp provider customer.
684
- */
685
- export type FiatCustomerResponse = BridgeFiatCustomerResponse | BridgeSandboxFiatCustomerResponse;
686
-
687
- /**
688
- * Destination cryptocurrency details for a fiat onramp quote request.
689
- */
690
- export interface FiatOnrampDestination {
691
- address: string;
692
-
693
- /**
694
- * Cryptocurrency symbol. Uppercase alphanumeric, 2-10 characters.
695
- */
696
- asset: CryptoCurrencyCode;
697
-
698
- /**
699
- * A CAIP-2 chain identifier in namespace:reference format (e.g. "eip155:1" for
700
- * Ethereum mainnet, "solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp" for Solana mainnet).
701
- */
702
- chain: Caip2ChainID;
703
- }
704
-
705
- /**
706
- * Whether to use the sandbox or production environment for fiat onramp.
707
- */
708
- export type FiatOnrampEnvironment = 'sandbox' | 'production';
709
-
710
- /**
711
- * The fiat onramp provider to use.
712
- */
713
- export type FiatOnrampProvider =
714
- | 'meld'
715
- | 'meld-sandbox'
716
- | 'moonpay'
717
- | 'moonpay-sandbox'
718
- | 'coinbase'
719
- | 'coinbase-sandbox';
720
-
721
- /**
722
- * An error from a specific fiat onramp provider when fetching quotes.
723
- */
724
- export interface FiatOnrampProviderError {
725
- error: string;
726
-
727
- /**
728
- * The fiat onramp provider to use.
729
- */
730
- provider: FiatOnrampProvider;
731
- }
732
-
733
- /**
734
- * A single fiat onramp quote from a provider.
735
- */
736
- export interface FiatOnrampQuote {
737
- payment_method: string;
738
-
739
- /**
740
- * The fiat onramp provider to use.
741
- */
742
- provider: FiatOnrampProvider;
743
-
744
- destination_currency_code?: string | null;
745
-
746
- source_amount?: number | null;
747
-
748
- source_currency_code?: string | null;
749
-
750
- sub_provider?: string | null;
751
- }
752
-
753
- /**
754
- * Source currency details for a fiat onramp quote request.
755
- */
756
- export interface FiatOnrampSource {
757
- /**
758
- * A positive decimal amount as a string (e.g. "100", "50.25", "0.001").
759
- */
760
- amount: FiatAmount;
761
-
762
- /**
763
- * ISO 4217 fiat currency code. Three uppercase ASCII letters.
764
- */
765
- asset: FiatCurrencyCode;
766
- }
767
-
768
- /**
769
- * Normalized fiat onramp transaction status.
770
- */
771
- export type FiatOnrampTransactionStatus =
772
- | 'pending'
773
- | 'processing'
774
- | 'completed'
775
- | 'failed'
776
- | 'cancelled'
777
- | 'refunded'
778
- | 'unknown';
779
-
780
670
  /**
781
671
  * The request input for creating virtual account.
782
672
  */
@@ -791,110 +681,6 @@ export type FiatVirtualAccountResponse =
791
681
  | BridgeFiatVirtualAccountResponse
792
682
  | BridgeSandboxFiatVirtualAccountResponse;
793
683
 
794
- /**
795
- * The request input for getting a native onramp provider customer.
796
- */
797
- export interface GetFiatCustomerRequestInput {
798
- /**
799
- * Valid set of onramp providers
800
- */
801
- provider: OnrampProvider;
802
-
803
- kyc_redirect_url?: string;
804
- }
805
-
806
- /**
807
- * The request input for getting fiat onramp quotes.
808
- */
809
- export interface GetFiatOnrampQuotesInput {
810
- /**
811
- * Destination cryptocurrency details for a fiat onramp quote request.
812
- */
813
- destination: FiatOnrampDestination;
814
-
815
- /**
816
- * Whether to use the sandbox or production environment for fiat onramp.
817
- */
818
- environment: FiatOnrampEnvironment;
819
-
820
- /**
821
- * Source currency details for a fiat onramp quote request.
822
- */
823
- source: FiatOnrampSource;
824
- }
825
-
826
- /**
827
- * The response containing fiat onramp quotes.
828
- */
829
- export interface GetFiatOnrampQuotesResponse {
830
- quotes: Array<FiatOnrampQuote>;
831
-
832
- provider_errors?: Array<FiatOnrampProviderError>;
833
- }
834
-
835
- /**
836
- * The request input for checking a fiat onramp session status.
837
- */
838
- export interface GetFiatOnrampTransactionStatusInput {
839
- /**
840
- * The fiat onramp provider to use.
841
- */
842
- provider: FiatOnrampProvider;
843
-
844
- session_id: string;
845
- }
846
-
847
- /**
848
- * The response containing the fiat onramp session status.
849
- */
850
- export interface GetFiatOnrampTransactionStatusResponse {
851
- raw_status: string;
852
-
853
- session_id: string;
854
-
855
- /**
856
- * Normalized fiat onramp transaction status.
857
- */
858
- status: FiatOnrampTransactionStatus;
859
-
860
- transaction_id?: string;
861
- }
862
-
863
- /**
864
- * The request input for getting a fiat onramp provider session URL.
865
- */
866
- export interface GetFiatOnrampURLInput {
867
- /**
868
- * Destination cryptocurrency details for a fiat onramp quote request.
869
- */
870
- destination: FiatOnrampDestination;
871
-
872
- payment_method: string;
873
-
874
- /**
875
- * The fiat onramp provider to use.
876
- */
877
- provider: FiatOnrampProvider;
878
-
879
- /**
880
- * Source currency details for a fiat onramp quote request.
881
- */
882
- source: FiatOnrampSource;
883
-
884
- redirect_url?: string;
885
-
886
- sub_provider?: string;
887
- }
888
-
889
- /**
890
- * The response containing a fiat onramp provider session URL.
891
- */
892
- export interface GetFiatOnrampURLResponse {
893
- session_id: string;
894
-
895
- url: string;
896
- }
897
-
898
684
  /**
899
685
  * The request body for authenticating a guest.
900
686
  */
@@ -1104,6 +890,122 @@ export interface OAuthLinkResponseBody extends UsersAPI.User {
1104
890
  */
1105
891
  export type OAuthProviderID = ExternalOAuthProviderID | PrivyOAuthProviderID | CustomOAuthProviderID;
1106
892
 
893
+ /**
894
+ * Request body for the authorization_code grant type.
895
+ */
896
+ export interface OAuthTokenAuthorizationCodeRequestBody {
897
+ /**
898
+ * The authorization code received from the authorization endpoint.
899
+ */
900
+ code: string;
901
+
902
+ grant_type: 'authorization_code';
903
+
904
+ /**
905
+ * The client ID. Alternative to Basic auth header.
906
+ */
907
+ client_id?: string;
908
+
909
+ /**
910
+ * The client secret. Alternative to Basic auth header.
911
+ */
912
+ client_secret?: string;
913
+
914
+ /**
915
+ * The redirect URI used in the authorization request.
916
+ */
917
+ redirect_uri?: string;
918
+ }
919
+
920
+ /**
921
+ * Error response returned while the device authorization is still pending (RFC
922
+ * 8628 Section 3.5).
923
+ */
924
+ export interface OAuthTokenDeviceCodePendingError {
925
+ /**
926
+ * The error code indicating why the token request failed.
927
+ */
928
+ error: 'authorization_pending' | 'slow_down' | 'access_denied' | 'expired_token';
929
+
930
+ /**
931
+ * Human-readable description of the error.
932
+ */
933
+ error_description?: string;
934
+
935
+ /**
936
+ * The minimum polling interval in seconds.
937
+ */
938
+ interval?: number;
939
+ }
940
+
941
+ /**
942
+ * Request body for the urn:ietf:params:oauth:grant-type:device_code grant type
943
+ * (RFC 8628). Used by CLI clients to poll for authorization.
944
+ */
945
+ export interface OAuthTokenDeviceCodeRequestBody {
946
+ /**
947
+ * The device code received from the device authorization endpoint.
948
+ */
949
+ device_code: string;
950
+
951
+ grant_type: 'urn:ietf:params:oauth:grant-type:device_code';
952
+ }
953
+
954
+ /**
955
+ * The OAuth grant type for the token request.
956
+ */
957
+ export type OAuthTokenGrantType =
958
+ | 'authorization_code'
959
+ | 'urn:ietf:params:oauth:grant-type:device_code'
960
+ | 'refresh_token';
961
+
962
+ /**
963
+ * Request body for the refresh_token grant type. Rotates the refresh token and
964
+ * issues a new access token.
965
+ */
966
+ export interface OAuthTokenRefreshTokenRequestBody {
967
+ grant_type: 'refresh_token';
968
+
969
+ /**
970
+ * The refresh token to exchange for a new access token.
971
+ */
972
+ refresh_token: string;
973
+ }
974
+
975
+ /**
976
+ * Request body for the OAuth token endpoint, discriminated by grant_type.
977
+ */
978
+ export type OAuthTokenRequestBody =
979
+ | OAuthTokenAuthorizationCodeRequestBody
980
+ | OAuthTokenDeviceCodeRequestBody
981
+ | OAuthTokenRefreshTokenRequestBody;
982
+
983
+ /**
984
+ * Successful token response per RFC 6749 Section 5.1.
985
+ */
986
+ export interface OAuthTokenSuccessResponse {
987
+ /**
988
+ * The issued access token.
989
+ */
990
+ access_token: string;
991
+
992
+ /**
993
+ * The type of token issued.
994
+ */
995
+ token_type: 'Bearer';
996
+
997
+ /**
998
+ * The lifetime in seconds of the access token.
999
+ */
1000
+ expires_in?: number;
1001
+
1002
+ /**
1003
+ * A refresh token for obtaining new access tokens. Issued for device_code and
1004
+ * refresh_token grants.
1005
+ */
1006
+ refresh_token?: string;
1007
+ }
1008
+
1107
1009
  /**
1108
1010
  * The request body for transferring an OAuth account.
1109
1011
  */
@@ -2074,8 +1976,6 @@ export declare namespace ClientAuth {
2074
1976
  type BridgeBrlFiatVirtualAccountDepositInstructions as BridgeBrlFiatVirtualAccountDepositInstructions,
2075
1977
  type BridgeDestinationAsset as BridgeDestinationAsset,
2076
1978
  type BridgeEurFiatVirtualAccountDepositInstructions as BridgeEurFiatVirtualAccountDepositInstructions,
2077
- type BridgeFiatCustomerResponse as BridgeFiatCustomerResponse,
2078
- type BridgeFiatRejectionReason as BridgeFiatRejectionReason,
2079
1979
  type BridgeFiatVirtualAccountDepositInstructions as BridgeFiatVirtualAccountDepositInstructions,
2080
1980
  type BridgeFiatVirtualAccountDestination as BridgeFiatVirtualAccountDestination,
2081
1981
  type BridgeFiatVirtualAccountRequest as BridgeFiatVirtualAccountRequest,
@@ -2084,17 +1984,16 @@ export declare namespace ClientAuth {
2084
1984
  type BridgeGbpFiatVirtualAccountDepositInstructions as BridgeGbpFiatVirtualAccountDepositInstructions,
2085
1985
  type BridgeMxnFiatVirtualAccountDepositInstructions as BridgeMxnFiatVirtualAccountDepositInstructions,
2086
1986
  type BridgeOnrampProvider as BridgeOnrampProvider,
2087
- type BridgeSandboxFiatCustomerResponse as BridgeSandboxFiatCustomerResponse,
2088
1987
  type BridgeSandboxFiatVirtualAccountRequest as BridgeSandboxFiatVirtualAccountRequest,
2089
1988
  type BridgeSandboxFiatVirtualAccountResponse as BridgeSandboxFiatVirtualAccountResponse,
2090
1989
  type BridgeSourceAsset as BridgeSourceAsset,
2091
1990
  type BridgeUsdFiatVirtualAccountDepositInstructions as BridgeUsdFiatVirtualAccountDepositInstructions,
2092
- type Caip2ChainID as Caip2ChainID,
2093
- type CreateOrUpdateFiatCustomerRequestInput as CreateOrUpdateFiatCustomerRequestInput,
2094
- type CryptoCurrencyCode as CryptoCurrencyCode,
2095
1991
  type CustomJwtAuthenticateRequestBody as CustomJwtAuthenticateRequestBody,
2096
1992
  type CustomJwtLinkRequestBody as CustomJwtLinkRequestBody,
2097
1993
  type CustomOAuthProviderID as CustomOAuthProviderID,
1994
+ type DeviceVerifyAction as DeviceVerifyAction,
1995
+ type DeviceVerifyRequestBody as DeviceVerifyRequestBody,
1996
+ type DeviceVerifyResponse as DeviceVerifyResponse,
2098
1997
  type ExternalOAuthProviderID as ExternalOAuthProviderID,
2099
1998
  type FarcasterAuthenticateInput as FarcasterAuthenticateInput,
2100
1999
  type FarcasterAuthenticateRequestBody as FarcasterAuthenticateRequestBody,
@@ -2123,25 +2022,8 @@ export declare namespace ClientAuth {
2123
2022
  type FarcasterV2InitRequestBody as FarcasterV2InitRequestBody,
2124
2023
  type FarcasterV2InitResponse as FarcasterV2InitResponse,
2125
2024
  type FarcasterV2InitResponseBody as FarcasterV2InitResponseBody,
2126
- type FiatAmount as FiatAmount,
2127
- type FiatCurrencyCode as FiatCurrencyCode,
2128
- type FiatCustomerResponse as FiatCustomerResponse,
2129
- type FiatOnrampDestination as FiatOnrampDestination,
2130
- type FiatOnrampEnvironment as FiatOnrampEnvironment,
2131
- type FiatOnrampProvider as FiatOnrampProvider,
2132
- type FiatOnrampProviderError as FiatOnrampProviderError,
2133
- type FiatOnrampQuote as FiatOnrampQuote,
2134
- type FiatOnrampSource as FiatOnrampSource,
2135
- type FiatOnrampTransactionStatus as FiatOnrampTransactionStatus,
2136
2025
  type FiatVirtualAccountRequest as FiatVirtualAccountRequest,
2137
2026
  type FiatVirtualAccountResponse as FiatVirtualAccountResponse,
2138
- type GetFiatCustomerRequestInput as GetFiatCustomerRequestInput,
2139
- type GetFiatOnrampQuotesInput as GetFiatOnrampQuotesInput,
2140
- type GetFiatOnrampQuotesResponse as GetFiatOnrampQuotesResponse,
2141
- type GetFiatOnrampTransactionStatusInput as GetFiatOnrampTransactionStatusInput,
2142
- type GetFiatOnrampTransactionStatusResponse as GetFiatOnrampTransactionStatusResponse,
2143
- type GetFiatOnrampURLInput as GetFiatOnrampURLInput,
2144
- type GetFiatOnrampURLResponse as GetFiatOnrampURLResponse,
2145
2027
  type GuestAuthenticateRequestBody as GuestAuthenticateRequestBody,
2146
2028
  type LinkJwtInput as LinkJwtInput,
2147
2029
  type MfaPasskeyEnrollmentRequestBody as MfaPasskeyEnrollmentRequestBody,
@@ -2164,6 +2046,13 @@ export declare namespace ClientAuth {
2164
2046
  type OAuthLinkRequestBody as OAuthLinkRequestBody,
2165
2047
  type OAuthLinkResponseBody as OAuthLinkResponseBody,
2166
2048
  type OAuthProviderID as OAuthProviderID,
2049
+ type OAuthTokenAuthorizationCodeRequestBody as OAuthTokenAuthorizationCodeRequestBody,
2050
+ type OAuthTokenDeviceCodePendingError as OAuthTokenDeviceCodePendingError,
2051
+ type OAuthTokenDeviceCodeRequestBody as OAuthTokenDeviceCodeRequestBody,
2052
+ type OAuthTokenGrantType as OAuthTokenGrantType,
2053
+ type OAuthTokenRefreshTokenRequestBody as OAuthTokenRefreshTokenRequestBody,
2054
+ type OAuthTokenRequestBody as OAuthTokenRequestBody,
2055
+ type OAuthTokenSuccessResponse as OAuthTokenSuccessResponse,
2167
2056
  type OAuthTransferRequestBody as OAuthTransferRequestBody,
2168
2057
  type OAuthTransferUserInfo as OAuthTransferUserInfo,
2169
2058
  type OAuthTransferUserInfoMeta as OAuthTransferUserInfoMeta,