@privy-io/api-types 0.7.0 → 0.8.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 (169) hide show
  1. package/CHANGELOG.md +43 -0
  2. package/client.d.mts +37 -28
  3. package/client.d.mts.map +1 -1
  4. package/client.d.ts +37 -28
  5. package/client.d.ts.map +1 -1
  6. package/client.js +9 -0
  7. package/client.js.map +1 -1
  8. package/client.mjs +9 -0
  9. package/client.mjs.map +1 -1
  10. package/package.json +1 -1
  11. package/resources/accounts.d.mts +79 -106
  12. package/resources/accounts.d.mts.map +1 -1
  13. package/resources/accounts.d.ts +79 -106
  14. package/resources/accounts.d.ts.map +1 -1
  15. package/resources/accounts.js.map +1 -1
  16. package/resources/accounts.mjs.map +1 -1
  17. package/resources/aggregations.d.mts +18 -392
  18. package/resources/aggregations.d.mts.map +1 -1
  19. package/resources/aggregations.d.ts +18 -392
  20. package/resources/aggregations.d.ts.map +1 -1
  21. package/resources/aggregations.js.map +1 -1
  22. package/resources/aggregations.mjs.map +1 -1
  23. package/resources/apps.d.mts +139 -70
  24. package/resources/apps.d.mts.map +1 -1
  25. package/resources/apps.d.ts +139 -70
  26. package/resources/apps.d.ts.map +1 -1
  27. package/resources/apps.js.map +1 -1
  28. package/resources/apps.mjs.map +1 -1
  29. package/resources/client-auth.d.mts +796 -427
  30. package/resources/client-auth.d.mts.map +1 -1
  31. package/resources/client-auth.d.ts +796 -427
  32. package/resources/client-auth.d.ts.map +1 -1
  33. package/resources/client-auth.js.map +1 -1
  34. package/resources/client-auth.mjs.map +1 -1
  35. package/resources/cross-app.d.mts +14 -13
  36. package/resources/cross-app.d.mts.map +1 -1
  37. package/resources/cross-app.d.ts +14 -13
  38. package/resources/cross-app.d.ts.map +1 -1
  39. package/resources/embedded-wallets.d.mts +165 -81
  40. package/resources/embedded-wallets.d.mts.map +1 -1
  41. package/resources/embedded-wallets.d.ts +165 -81
  42. package/resources/embedded-wallets.d.ts.map +1 -1
  43. package/resources/embedded-wallets.js.map +1 -1
  44. package/resources/embedded-wallets.mjs.map +1 -1
  45. package/resources/funding.d.mts +150 -64
  46. package/resources/funding.d.mts.map +1 -1
  47. package/resources/funding.d.ts +150 -64
  48. package/resources/funding.d.ts.map +1 -1
  49. package/resources/funding.js.map +1 -1
  50. package/resources/funding.mjs.map +1 -1
  51. package/resources/index.d.mts +17 -14
  52. package/resources/index.d.mts.map +1 -1
  53. package/resources/index.d.ts +17 -14
  54. package/resources/index.d.ts.map +1 -1
  55. package/resources/index.js +7 -1
  56. package/resources/index.js.map +1 -1
  57. package/resources/index.mjs +3 -0
  58. package/resources/index.mjs.map +1 -1
  59. package/resources/intents.d.mts +224 -1757
  60. package/resources/intents.d.mts.map +1 -1
  61. package/resources/intents.d.ts +224 -1757
  62. package/resources/intents.d.ts.map +1 -1
  63. package/resources/intents.js.map +1 -1
  64. package/resources/intents.mjs.map +1 -1
  65. package/resources/key-quorums.d.mts +74 -26
  66. package/resources/key-quorums.d.mts.map +1 -1
  67. package/resources/key-quorums.d.ts +74 -26
  68. package/resources/key-quorums.d.ts.map +1 -1
  69. package/resources/key-quorums.js +8 -8
  70. package/resources/key-quorums.js.map +1 -1
  71. package/resources/key-quorums.mjs +8 -8
  72. package/resources/key-quorums.mjs.map +1 -1
  73. package/resources/policies.d.mts +335 -926
  74. package/resources/policies.d.mts.map +1 -1
  75. package/resources/policies.d.ts +335 -926
  76. package/resources/policies.d.ts.map +1 -1
  77. package/resources/policies.js +48 -41
  78. package/resources/policies.js.map +1 -1
  79. package/resources/policies.mjs +48 -41
  80. package/resources/policies.mjs.map +1 -1
  81. package/resources/shared.d.mts +59 -0
  82. package/resources/shared.d.mts.map +1 -0
  83. package/resources/shared.d.ts +59 -0
  84. package/resources/shared.d.ts.map +1 -0
  85. package/resources/shared.js +9 -0
  86. package/resources/shared.js.map +1 -0
  87. package/resources/shared.mjs +5 -0
  88. package/resources/shared.mjs.map +1 -0
  89. package/resources/swaps.d.mts +108 -0
  90. package/resources/swaps.d.mts.map +1 -0
  91. package/resources/swaps.d.ts +108 -0
  92. package/resources/swaps.d.ts.map +1 -0
  93. package/resources/swaps.js +9 -0
  94. package/resources/swaps.js.map +1 -0
  95. package/resources/swaps.mjs +5 -0
  96. package/resources/swaps.mjs.map +1 -0
  97. package/resources/transactions.d.mts +155 -93
  98. package/resources/transactions.d.mts.map +1 -1
  99. package/resources/transactions.d.ts +155 -93
  100. package/resources/transactions.d.ts.map +1 -1
  101. package/resources/users.d.mts +61 -94
  102. package/resources/users.d.mts.map +1 -1
  103. package/resources/users.d.ts +61 -94
  104. package/resources/users.d.ts.map +1 -1
  105. package/resources/users.js.map +1 -1
  106. package/resources/users.mjs.map +1 -1
  107. package/resources/wallet-actions.d.mts +187 -0
  108. package/resources/wallet-actions.d.mts.map +1 -0
  109. package/resources/wallet-actions.d.ts +187 -0
  110. package/resources/wallet-actions.d.ts.map +1 -0
  111. package/resources/wallet-actions.js +9 -0
  112. package/resources/wallet-actions.js.map +1 -0
  113. package/resources/wallet-actions.mjs +5 -0
  114. package/resources/wallet-actions.mjs.map +1 -0
  115. package/resources/wallets/index.d.mts +1 -1
  116. package/resources/wallets/index.d.mts.map +1 -1
  117. package/resources/wallets/index.d.ts +1 -1
  118. package/resources/wallets/index.d.ts.map +1 -1
  119. package/resources/wallets/index.js.map +1 -1
  120. package/resources/wallets/index.mjs.map +1 -1
  121. package/resources/wallets/transactions.d.mts +1 -0
  122. package/resources/wallets/transactions.d.mts.map +1 -1
  123. package/resources/wallets/transactions.d.ts +1 -0
  124. package/resources/wallets/transactions.d.ts.map +1 -1
  125. package/resources/wallets/wallets.d.mts +2377 -971
  126. package/resources/wallets/wallets.d.mts.map +1 -1
  127. package/resources/wallets/wallets.d.ts +2377 -971
  128. package/resources/wallets/wallets.d.ts.map +1 -1
  129. package/resources/wallets/wallets.js +18 -6
  130. package/resources/wallets/wallets.js.map +1 -1
  131. package/resources/wallets/wallets.mjs +18 -6
  132. package/resources/wallets/wallets.mjs.map +1 -1
  133. package/resources/webhooks.d.mts +438 -33
  134. package/resources/webhooks.d.mts.map +1 -1
  135. package/resources/webhooks.d.ts +438 -33
  136. package/resources/webhooks.d.ts.map +1 -1
  137. package/resources/webhooks.js.map +1 -1
  138. package/resources/webhooks.mjs.map +1 -1
  139. package/resources/yield.d.mts +25 -1
  140. package/resources/yield.d.mts.map +1 -1
  141. package/resources/yield.d.ts +25 -1
  142. package/resources/yield.d.ts.map +1 -1
  143. package/src/client.ts +721 -72
  144. package/src/resources/accounts.ts +93 -120
  145. package/src/resources/aggregations.ts +18 -702
  146. package/src/resources/apps.ts +187 -110
  147. package/src/resources/client-auth.ts +1358 -893
  148. package/src/resources/cross-app.ts +19 -15
  149. package/src/resources/embedded-wallets.ts +219 -123
  150. package/src/resources/funding.ts +263 -173
  151. package/src/resources/index.ts +368 -47
  152. package/src/resources/intents.ts +370 -3100
  153. package/src/resources/key-quorums.ts +100 -32
  154. package/src/resources/policies.ts +583 -1558
  155. package/src/resources/shared.ts +79 -0
  156. package/src/resources/swaps.ts +136 -0
  157. package/src/resources/transactions.ts +185 -91
  158. package/src/resources/users.ts +79 -132
  159. package/src/resources/wallet-actions.ts +251 -0
  160. package/src/resources/wallets/index.ts +144 -16
  161. package/src/resources/wallets/transactions.ts +2 -0
  162. package/src/resources/wallets/wallets.ts +2893 -1023
  163. package/src/resources/webhooks.ts +547 -47
  164. package/src/resources/yield.ts +29 -0
  165. package/src/version.ts +1 -1
  166. package/version.d.mts +1 -1
  167. package/version.d.ts +1 -1
  168. package/version.js +1 -1
  169. package/version.mjs +1 -1
@@ -1,21 +1,25 @@
1
1
  // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
2
 
3
3
  import { APIResource } from '../core/resource';
4
+ import * as EmbeddedWalletsAPI from './embedded-wallets';
4
5
  import * as UsersAPI from './users';
5
6
 
6
7
  export class ClientAuth extends APIResource {}
7
8
 
8
9
  /**
9
- * The request body for authenticating with a custom JWT
10
+ * The request body for authenticating with a custom JWT.
10
11
  */
11
12
  export interface CustomJwtAuthenticateRequestBody {
12
13
  token?: string;
13
14
 
14
- mode?: 'no-signup' | 'login-or-sign-up';
15
+ /**
16
+ * Whether to allow sign-up during authentication.
17
+ */
18
+ mode?: AuthenticateModeOption;
15
19
  }
16
20
 
17
21
  /**
18
- * The request body for linking a custom JWT account
22
+ * The request body for linking a custom JWT account.
19
23
  */
20
24
  export interface CustomJwtLinkRequestBody {
21
25
  token?: string;
@@ -33,7 +37,10 @@ export interface FarcasterAuthenticateRequestBody {
33
37
 
34
38
  signature: string;
35
39
 
36
- mode?: 'no-signup' | 'login-or-sign-up';
40
+ /**
41
+ * Whether to allow sign-up during authentication.
42
+ */
43
+ mode?: AuthenticateModeOption;
37
44
  }
38
45
 
39
46
  /**
@@ -106,65 +113,25 @@ export interface FarcasterLinkRequestBody {
106
113
  */
107
114
  export interface FarcasterSignerInitRequestBody {
108
115
  ed25519_public_key: string;
116
+
117
+ deadline?: string;
109
118
  }
110
119
 
111
120
  /**
112
121
  * The response body from initiating a Farcaster signer connection.
113
122
  */
114
123
  export type FarcasterSignerInitResponseBody =
115
- | FarcasterSignerInitResponseBody.UnionMember0
116
- | FarcasterSignerInitResponseBody.UnionMember1
117
- | FarcasterSignerInitResponseBody.UnionMember2;
118
-
119
- export namespace FarcasterSignerInitResponseBody {
120
- export interface UnionMember0 {
121
- public_key: string;
122
-
123
- signer_approval_url: string;
124
-
125
- status: 'pending_approval';
126
- }
127
-
128
- export interface UnionMember1 {
129
- public_key: string;
130
-
131
- status: 'approved';
132
- }
133
-
134
- export interface UnionMember2 {
135
- public_key: string;
136
-
137
- status: 'revoked';
138
- }
139
- }
124
+ | FarcasterSignerInitPendingApproval
125
+ | FarcasterSignerApproved
126
+ | FarcasterSignerRevoked;
140
127
 
141
128
  /**
142
129
  * The response body from checking the status of a Farcaster signer connection.
143
130
  */
144
131
  export type FarcasterSignerStatusResponseBody =
145
- | FarcasterSignerStatusResponseBody.UnionMember0
146
- | FarcasterSignerStatusResponseBody.UnionMember1
147
- | FarcasterSignerStatusResponseBody.UnionMember2;
148
-
149
- export namespace FarcasterSignerStatusResponseBody {
150
- export interface UnionMember0 {
151
- public_key: string;
152
-
153
- status: 'pending_approval';
154
- }
155
-
156
- export interface UnionMember1 {
157
- public_key: string;
158
-
159
- status: 'approved';
160
- }
161
-
162
- export interface UnionMember2 {
163
- public_key: string;
164
-
165
- status: 'revoked';
166
- }
167
- }
132
+ | FarcasterSignerStatusPendingApproval
133
+ | FarcasterSignerApproved
134
+ | FarcasterSignerRevoked;
168
135
 
169
136
  /**
170
137
  * The request body for unlinking a Farcaster account.
@@ -183,14 +150,12 @@ export interface FarcasterV2AuthenticateRequestBody {
183
150
 
184
151
  signature: string;
185
152
 
186
- mode?: 'no-signup' | 'login-or-sign-up';
153
+ /**
154
+ * Whether to allow sign-up during authentication.
155
+ */
156
+ mode?: AuthenticateModeOption;
187
157
  }
188
158
 
189
- /**
190
- * The request body for initiating a Farcaster V2 connection.
191
- */
192
- export type FarcasterV2InitRequestBody = unknown;
193
-
194
159
  /**
195
160
  * The response body for initiating a Farcaster V2 connection.
196
161
  */
@@ -227,96 +192,28 @@ export interface MfaPasskeyInitRequestBody {
227
192
  * The response body for initializing a passkey MFA flow.
228
193
  */
229
194
  export interface MfaPasskeyInitResponseBody {
230
- options: MfaPasskeyInitResponseBody.Options;
195
+ /**
196
+ * WebAuthn authentication options as defined by the Web Authentication
197
+ * specification.
198
+ */
199
+ options: PasskeyAuthenticatorVerifyOptions;
231
200
 
232
201
  relying_party?: string;
233
202
  }
234
203
 
235
- export namespace MfaPasskeyInitResponseBody {
236
- export interface Options {
237
- challenge: string;
238
-
239
- allow_credentials?: Array<Options.AllowCredential>;
240
-
241
- extensions?: Options.Extensions;
242
-
243
- rp_id?: string;
244
-
245
- timeout?: number;
246
-
247
- user_verification?: string;
248
- }
249
-
250
- export namespace Options {
251
- export interface AllowCredential {
252
- id: string;
253
-
254
- type: string;
255
-
256
- transports?: Array<string>;
257
- }
258
-
259
- export interface Extensions {
260
- app_id?: string;
261
-
262
- cred_props?: boolean;
263
-
264
- hmac_create_secret?: boolean;
265
- }
266
- }
267
- }
268
-
269
204
  /**
270
205
  * The request body for verifying a passkey MFA flow.
271
206
  */
272
207
  export interface MfaPasskeyVerifyRequestBody {
273
- authenticator_response: MfaPasskeyVerifyRequestBody.AuthenticatorResponse;
208
+ /**
209
+ * WebAuthn authentication response as defined by the Web Authentication
210
+ * specification.
211
+ */
212
+ authenticator_response: PasskeyAuthenticatorVerifyResponse;
274
213
 
275
214
  relying_party?: string;
276
215
  }
277
216
 
278
- export namespace MfaPasskeyVerifyRequestBody {
279
- export interface AuthenticatorResponse {
280
- id: string;
281
-
282
- client_extension_results: AuthenticatorResponse.ClientExtensionResults;
283
-
284
- raw_id: string;
285
-
286
- response: AuthenticatorResponse.Response;
287
-
288
- type: 'public-key';
289
-
290
- authenticator_attachment?: string;
291
- }
292
-
293
- export namespace AuthenticatorResponse {
294
- export interface ClientExtensionResults {
295
- app_id?: boolean;
296
-
297
- cred_props?: ClientExtensionResults.CredProps;
298
-
299
- hmac_create_secret?: boolean;
300
- }
301
-
302
- export namespace ClientExtensionResults {
303
- export interface CredProps {
304
- rk?: boolean;
305
- }
306
- }
307
-
308
- export interface Response {
309
- authenticator_data: string;
310
-
311
- client_data_json: string;
312
-
313
- signature: string;
314
-
315
- user_handle?: string;
316
- }
317
- }
318
- }
319
-
320
217
  /**
321
218
  * The request body for enrolling a SMS MFA code.
322
219
  */
@@ -329,19 +226,7 @@ export interface MfaSMSEnrollRequestBody {
329
226
  /**
330
227
  * The request body for initiating a SMS MFA flow.
331
228
  */
332
- export type MfaSMSInitRequestBody = MfaSMSInitRequestBody.Action | MfaSMSInitRequestBody.UnionMember1;
333
-
334
- export namespace MfaSMSInitRequestBody {
335
- export interface Action {
336
- action: 'verify';
337
- }
338
-
339
- export interface UnionMember1 {
340
- action: 'enroll';
341
-
342
- phoneNumber: string;
343
- }
344
- }
229
+ export type MfaSMSInitRequestBody = MfaSMSInitVerifyInput | MfaSMSInitEnrollInput;
345
230
 
346
231
  /**
347
232
  * The request body for verifying a SMS MFA code.
@@ -381,11 +266,17 @@ export interface OAuthAuthenticateRequestBody {
381
266
 
382
267
  state_code: string;
383
268
 
384
- code_type?: 'raw';
269
+ /**
270
+ * The type of OAuth authorization code.
271
+ */
272
+ code_type?: OAuthCodeType;
385
273
 
386
274
  code_verifier?: string;
387
275
 
388
- mode?: 'no-signup' | 'login-or-sign-up';
276
+ /**
277
+ * Whether to allow sign-up during authentication.
278
+ */
279
+ mode?: AuthenticateModeOption;
389
280
  }
390
281
 
391
282
  /**
@@ -400,7 +291,7 @@ export interface OAuthAuthorizationCodeRequestBody {
400
291
  }
401
292
 
402
293
  /**
403
- * The request body for initiating an OAuth account.
294
+ * The request body for initiating an OAuth ceremony.
404
295
  */
405
296
  export interface OAuthInitRequestBody {
406
297
  /**
@@ -432,7 +323,10 @@ export interface OAuthLinkRequestBody {
432
323
 
433
324
  state_code: string;
434
325
 
435
- code_type?: 'raw';
326
+ /**
327
+ * The type of OAuth authorization code.
328
+ */
329
+ code_type?: OAuthCodeType;
436
330
 
437
331
  code_verifier?: string;
438
332
  }
@@ -480,400 +374,6 @@ export interface OptionalRefreshTokenInput {
480
374
  refresh_token?: string;
481
375
  }
482
376
 
483
- /**
484
- * The request body for authenticating a passkey.
485
- */
486
- export interface PasskeyAuthenticateRequestBody {
487
- authenticator_response: PasskeyAuthenticateRequestBody.AuthenticatorResponse;
488
-
489
- challenge: string;
490
-
491
- relying_party?: string;
492
- }
493
-
494
- export namespace PasskeyAuthenticateRequestBody {
495
- export interface AuthenticatorResponse {
496
- id: string;
497
-
498
- client_extension_results: AuthenticatorResponse.ClientExtensionResults;
499
-
500
- raw_id: string;
501
-
502
- response: AuthenticatorResponse.Response;
503
-
504
- type: 'public-key';
505
-
506
- authenticator_attachment?: string;
507
- }
508
-
509
- export namespace AuthenticatorResponse {
510
- export interface ClientExtensionResults {
511
- app_id?: boolean;
512
-
513
- cred_props?: ClientExtensionResults.CredProps;
514
-
515
- hmac_create_secret?: boolean;
516
- }
517
-
518
- export namespace ClientExtensionResults {
519
- export interface CredProps {
520
- rk?: boolean;
521
- }
522
- }
523
-
524
- export interface Response {
525
- authenticator_data: string;
526
-
527
- client_data_json: string;
528
-
529
- signature: string;
530
-
531
- user_handle?: string;
532
- }
533
- }
534
- }
535
-
536
- /**
537
- * The response body for initiating a passkey authenticate ceremony.
538
- */
539
- export interface PasskeyInitAuthenticateResponseBody {
540
- options: PasskeyInitAuthenticateResponseBody.Options;
541
-
542
- relying_party?: string;
543
- }
544
-
545
- export namespace PasskeyInitAuthenticateResponseBody {
546
- export interface Options {
547
- challenge: string;
548
-
549
- allow_credentials?: Array<Options.AllowCredential>;
550
-
551
- extensions?: Options.Extensions;
552
-
553
- rp_id?: string;
554
-
555
- timeout?: number;
556
-
557
- user_verification?: string;
558
- }
559
-
560
- export namespace Options {
561
- export interface AllowCredential {
562
- id: string;
563
-
564
- type: string;
565
-
566
- transports?: Array<string>;
567
- }
568
-
569
- export interface Extensions {
570
- app_id?: string;
571
-
572
- cred_props?: boolean;
573
-
574
- hmac_create_secret?: boolean;
575
- }
576
- }
577
- }
578
-
579
- /**
580
- * The response body for initiating a passkey link ceremony.
581
- */
582
- export interface PasskeyInitLinkResponseBody {
583
- options: PasskeyInitLinkResponseBody.Options;
584
-
585
- relying_party?: string;
586
- }
587
-
588
- export namespace PasskeyInitLinkResponseBody {
589
- export interface Options {
590
- challenge: string;
591
-
592
- pub_key_cred_params: Array<Options.PubKeyCredParam>;
593
-
594
- rp: Options.Rp;
595
-
596
- user: Options.User;
597
-
598
- attestation?: string;
599
-
600
- authenticator_selection?: Options.AuthenticatorSelection;
601
-
602
- exclude_credentials?: Array<Options.ExcludeCredential>;
603
-
604
- extensions?: Options.Extensions;
605
-
606
- timeout?: number;
607
- }
608
-
609
- export namespace Options {
610
- export interface PubKeyCredParam {
611
- alg: number;
612
-
613
- type: 'public-key';
614
- }
615
-
616
- export interface Rp {
617
- name: string;
618
-
619
- id?: string;
620
- }
621
-
622
- export interface User {
623
- id: string;
624
-
625
- display_name: string;
626
-
627
- name: string;
628
- }
629
-
630
- export interface AuthenticatorSelection {
631
- authenticator_attachment?: string;
632
-
633
- require_resident_key?: boolean;
634
-
635
- resident_key?: string;
636
-
637
- user_verification?: string;
638
- }
639
-
640
- export interface ExcludeCredential {
641
- id: string;
642
-
643
- type: string;
644
-
645
- transports?: Array<string>;
646
- }
647
-
648
- export interface Extensions {
649
- app_id?: string;
650
-
651
- cred_props?: Extensions.CredProps;
652
-
653
- hmac_create_secret?: boolean;
654
- }
655
-
656
- export namespace Extensions {
657
- export interface CredProps {
658
- rk?: boolean;
659
- }
660
- }
661
- }
662
- }
663
-
664
- /**
665
- * The response body for initiating a passkey register ceremony.
666
- */
667
- export interface PasskeyInitRegisterResponseBody {
668
- options: PasskeyInitRegisterResponseBody.Options;
669
-
670
- relying_party?: string;
671
- }
672
-
673
- export namespace PasskeyInitRegisterResponseBody {
674
- export interface Options {
675
- challenge: string;
676
-
677
- pub_key_cred_params: Array<Options.PubKeyCredParam>;
678
-
679
- rp: Options.Rp;
680
-
681
- user: Options.User;
682
-
683
- attestation?: string;
684
-
685
- authenticator_selection?: Options.AuthenticatorSelection;
686
-
687
- exclude_credentials?: Array<Options.ExcludeCredential>;
688
-
689
- extensions?: Options.Extensions;
690
-
691
- timeout?: number;
692
- }
693
-
694
- export namespace Options {
695
- export interface PubKeyCredParam {
696
- alg: number;
697
-
698
- type: 'public-key';
699
- }
700
-
701
- export interface Rp {
702
- name: string;
703
-
704
- id?: string;
705
- }
706
-
707
- export interface User {
708
- id: string;
709
-
710
- display_name: string;
711
-
712
- name: string;
713
- }
714
-
715
- export interface AuthenticatorSelection {
716
- authenticator_attachment?: string;
717
-
718
- require_resident_key?: boolean;
719
-
720
- resident_key?: string;
721
-
722
- user_verification?: string;
723
- }
724
-
725
- export interface ExcludeCredential {
726
- id: string;
727
-
728
- type: string;
729
-
730
- transports?: Array<string>;
731
- }
732
-
733
- export interface Extensions {
734
- app_id?: string;
735
-
736
- cred_props?: Extensions.CredProps;
737
-
738
- hmac_create_secret?: boolean;
739
- }
740
-
741
- export namespace Extensions {
742
- export interface CredProps {
743
- rk?: boolean;
744
- }
745
- }
746
- }
747
- }
748
-
749
- /**
750
- * The request body for initiating a passkey ceremony.
751
- */
752
- export interface PasskeyInitRequestBody {
753
- token?: string;
754
-
755
- relying_party?: string;
756
- }
757
-
758
- /**
759
- * The request body for linking a passkey.
760
- */
761
- export interface PasskeyLinkRequestBody {
762
- authenticator_response: PasskeyLinkRequestBody.AuthenticatorResponse;
763
-
764
- relying_party?: string;
765
- }
766
-
767
- export namespace PasskeyLinkRequestBody {
768
- export interface AuthenticatorResponse {
769
- id: string;
770
-
771
- client_extension_results: AuthenticatorResponse.ClientExtensionResults;
772
-
773
- raw_id: string;
774
-
775
- response: AuthenticatorResponse.Response;
776
-
777
- type: 'public-key';
778
-
779
- authenticator_attachment?: string;
780
- }
781
-
782
- export namespace AuthenticatorResponse {
783
- export interface ClientExtensionResults {
784
- app_id?: boolean;
785
-
786
- cred_props?: ClientExtensionResults.CredProps;
787
-
788
- hmac_create_secret?: boolean;
789
- }
790
-
791
- export namespace ClientExtensionResults {
792
- export interface CredProps {
793
- rk?: boolean;
794
- }
795
- }
796
-
797
- export interface Response {
798
- attestation_object: string;
799
-
800
- client_data_json: string;
801
-
802
- authenticator_data?: string;
803
-
804
- public_key?: string;
805
-
806
- public_key_algorithm?: number;
807
-
808
- transports?: Array<unknown>;
809
- }
810
- }
811
- }
812
-
813
- /**
814
- * The request body for registering a passkey.
815
- */
816
- export interface PasskeyRegisterRequestBody {
817
- authenticator_response: PasskeyRegisterRequestBody.AuthenticatorResponse;
818
-
819
- relying_party?: string;
820
- }
821
-
822
- export namespace PasskeyRegisterRequestBody {
823
- export interface AuthenticatorResponse {
824
- id: string;
825
-
826
- client_extension_results: AuthenticatorResponse.ClientExtensionResults;
827
-
828
- raw_id: string;
829
-
830
- response: AuthenticatorResponse.Response;
831
-
832
- type: 'public-key';
833
-
834
- authenticator_attachment?: string;
835
- }
836
-
837
- export namespace AuthenticatorResponse {
838
- export interface ClientExtensionResults {
839
- app_id?: boolean;
840
-
841
- cred_props?: ClientExtensionResults.CredProps;
842
-
843
- hmac_create_secret?: boolean;
844
- }
845
-
846
- export namespace ClientExtensionResults {
847
- export interface CredProps {
848
- rk?: boolean;
849
- }
850
- }
851
-
852
- export interface Response {
853
- attestation_object: string;
854
-
855
- client_data_json: string;
856
-
857
- authenticator_data?: string;
858
-
859
- public_key?: string;
860
-
861
- public_key_algorithm?: number;
862
-
863
- transports?: Array<unknown>;
864
- }
865
- }
866
- }
867
-
868
- /**
869
- * The request body for unlinking a passkey.
870
- */
871
- export interface PasskeyUnlinkRequestBody {
872
- credential_id: string;
873
-
874
- remove_as_mfa?: boolean;
875
- }
876
-
877
377
  /**
878
378
  * The request body for authenticating a passwordless account.
879
379
  */
@@ -882,7 +382,10 @@ export interface PasswordlessAuthenticateRequestBody {
882
382
 
883
383
  email: string;
884
384
 
885
- mode?: 'no-signup' | 'login-or-sign-up';
385
+ /**
386
+ * Whether to allow sign-up during authentication.
387
+ */
388
+ mode?: AuthenticateModeOption;
886
389
  }
887
390
 
888
391
  /**
@@ -911,7 +414,10 @@ export interface PasswordlessSMSAuthenticateRequestBody {
911
414
 
912
415
  phoneNumber: string;
913
416
 
914
- mode?: 'no-signup' | 'login-or-sign-up';
417
+ /**
418
+ * Whether to allow sign-up during authentication.
419
+ */
420
+ mode?: AuthenticateModeOption;
915
421
  }
916
422
 
917
423
  /**
@@ -980,7 +486,10 @@ export interface SiweAuthenticateRequestBody {
980
486
 
981
487
  connectorType?: string | null;
982
488
 
983
- mode?: 'no-signup' | 'login-or-sign-up';
489
+ /**
490
+ * Whether to allow sign-up during authentication.
491
+ */
492
+ mode?: AuthenticateModeOption;
984
493
 
985
494
  walletClientType?: string | null;
986
495
  }
@@ -1026,7 +535,10 @@ export interface SiweLinkSmartWalletRequestBody {
1026
535
 
1027
536
  signature: string;
1028
537
 
1029
- smart_wallet_type: 'safe' | 'kernel' | 'light_account' | 'biconomy' | 'coinbase_smart_wallet' | 'thirdweb';
538
+ /**
539
+ * The supported smart wallet providers.
540
+ */
541
+ smart_wallet_type: EmbeddedWalletsAPI.SmartWalletType;
1030
542
 
1031
543
  smart_wallet_version?: string;
1032
544
  }
@@ -1050,7 +562,10 @@ export interface SiwsAuthenticateRequestBody {
1050
562
 
1051
563
  message_type?: 'transaction' | 'plain';
1052
564
 
1053
- mode?: 'no-signup' | 'login-or-sign-up';
565
+ /**
566
+ * Whether to allow sign-up during authentication.
567
+ */
568
+ mode?: AuthenticateModeOption;
1054
569
 
1055
570
  walletClientType?: string | null;
1056
571
  }
@@ -1089,7 +604,7 @@ export interface SiwsLinkRequestBody {
1089
604
  }
1090
605
 
1091
606
  /**
1092
- * The request body for unlinking a Siws ceremony.
607
+ * The request body for unlinking a SIWS ceremony.
1093
608
  */
1094
609
  export interface SiwsUnlinkRequestBody {
1095
610
  address: string;
@@ -1101,47 +616,22 @@ export interface SiwsUnlinkRequestBody {
1101
616
  export interface TelegramAuthenticateRequestBody {
1102
617
  captcha_token?: string;
1103
618
 
1104
- mode?: 'no-signup' | 'login-or-sign-up';
619
+ /**
620
+ * Whether to allow sign-up during authentication.
621
+ */
622
+ mode?: AuthenticateModeOption;
1105
623
 
1106
- telegram_auth_result?: TelegramAuthenticateRequestBody.TelegramAuthResult;
624
+ /**
625
+ * Auth result object returned by Telegram when a user authenticates using the
626
+ * login widget.
627
+ */
628
+ telegram_auth_result?: TelegramAuthResult;
1107
629
 
1108
- telegram_web_app_data?: TelegramAuthenticateRequestBody.TelegramWebAppData;
1109
- }
1110
-
1111
- export namespace TelegramAuthenticateRequestBody {
1112
- export interface TelegramAuthResult {
1113
- id: number | null;
1114
-
1115
- auth_date: number | null;
1116
-
1117
- first_name: string;
1118
-
1119
- hash: string;
1120
-
1121
- last_name?: string;
1122
-
1123
- photo_url?: string;
1124
-
1125
- username?: string;
1126
- }
1127
-
1128
- export interface TelegramWebAppData {
1129
- auth_date: number | null;
1130
-
1131
- hash: string;
1132
-
1133
- user: string;
1134
-
1135
- chat_instance?: string;
1136
-
1137
- chat_type?: string;
1138
-
1139
- query_id?: string;
1140
-
1141
- signature?: string;
1142
-
1143
- start_param?: string;
1144
- }
630
+ /**
631
+ * Auth result object returned by Telegram when a user authenticates using a mini
632
+ * app.
633
+ */
634
+ telegram_web_app_data?: TelegramWebAppData;
1145
635
  }
1146
636
 
1147
637
  /**
@@ -1150,47 +640,22 @@ export namespace TelegramAuthenticateRequestBody {
1150
640
  export interface TelegramLinkRequestBody {
1151
641
  captcha_token?: string;
1152
642
 
1153
- mode?: 'no-signup' | 'login-or-sign-up';
1154
-
1155
- telegram_auth_result?: TelegramLinkRequestBody.TelegramAuthResult;
1156
-
1157
- telegram_web_app_data?: TelegramLinkRequestBody.TelegramWebAppData;
1158
- }
1159
-
1160
- export namespace TelegramLinkRequestBody {
1161
- export interface TelegramAuthResult {
1162
- id: number | null;
1163
-
1164
- auth_date: number | null;
1165
-
1166
- first_name: string;
1167
-
1168
- hash: string;
1169
-
1170
- last_name?: string;
1171
-
1172
- photo_url?: string;
1173
-
1174
- username?: string;
1175
- }
1176
-
1177
- export interface TelegramWebAppData {
1178
- auth_date: number | null;
1179
-
1180
- hash: string;
1181
-
1182
- user: string;
1183
-
1184
- chat_instance?: string;
1185
-
1186
- chat_type?: string;
1187
-
1188
- query_id?: string;
643
+ /**
644
+ * Whether to allow sign-up during authentication.
645
+ */
646
+ mode?: AuthenticateModeOption;
1189
647
 
1190
- signature?: string;
648
+ /**
649
+ * Auth result object returned by Telegram when a user authenticates using the
650
+ * login widget.
651
+ */
652
+ telegram_auth_result?: TelegramAuthResult;
1191
653
 
1192
- start_param?: string;
1193
- }
654
+ /**
655
+ * Auth result object returned by Telegram when a user authenticates using a mini
656
+ * app.
657
+ */
658
+ telegram_web_app_data?: TelegramWebAppData;
1194
659
  }
1195
660
 
1196
661
  /**
@@ -1243,465 +708,1404 @@ export type BridgeOnrampProvider = 'bridge' | 'bridge-sandbox';
1243
708
  export type OnrampProvider = 'bridge' | 'bridge-sandbox';
1244
709
 
1245
710
  /**
1246
- * The request input for getting a native onramp provider customer.
711
+ * Whether to allow sign-up during authentication.
1247
712
  */
1248
- export interface GetFiatCustomerRequestInput {
713
+ export type AuthenticateModeOption = 'no-signup' | 'login-or-sign-up';
714
+
715
+ /**
716
+ * The authentication mode settings for the ceremony.
717
+ */
718
+ export interface AuthenticateMode {
1249
719
  /**
1250
- * Valid set of onramp providers
720
+ * Whether to allow sign-up during authentication.
1251
721
  */
1252
- provider: OnrampProvider;
722
+ mode?: AuthenticateModeOption;
723
+ }
1253
724
 
1254
- kyc_redirect_url?: string;
725
+ /**
726
+ * The result of the WebAuthn credProps extension.
727
+ */
728
+ export interface PasskeyCredPropsResult {
729
+ rk?: boolean;
1255
730
  }
1256
731
 
1257
732
  /**
1258
- * The request input for creating (or updating) a native onramp provider customer.
733
+ * Client extension results returned by the WebAuthn authenticator.
1259
734
  */
1260
- export interface CreateOrUpdateFiatCustomerRequestInput {
1261
- has_accepted_terms: boolean;
735
+ export interface PasskeyClientExtensionResults {
736
+ app_id?: boolean;
1262
737
 
1263
738
  /**
1264
- * Valid set of onramp providers
739
+ * The result of the WebAuthn credProps extension.
1265
740
  */
1266
- provider: OnrampProvider;
741
+ cred_props?: PasskeyCredPropsResult;
1267
742
 
1268
- kyc_redirect_url?: string;
743
+ hmac_create_secret?: boolean;
1269
744
  }
1270
745
 
1271
746
  /**
1272
- * A rejection reason for a customer KYC verification.
747
+ * A WebAuthn credential descriptor identifying a specific public key credential.
1273
748
  */
1274
- export interface BridgeFiatRejectionReason {
1275
- reason: string;
749
+ export interface PasskeyCredentialDescriptor {
750
+ id: string;
751
+
752
+ type: string;
753
+
754
+ transports?: Array<string>;
1276
755
  }
1277
756
 
1278
757
  /**
1279
- * The response for getting a native onramp provider customer.
758
+ * Relying party information for a WebAuthn ceremony.
1280
759
  */
1281
- export interface BridgeFiatCustomerResponse {
1282
- has_accepted_terms: boolean;
760
+ export interface PasskeyRelyingParty {
761
+ name: string;
1283
762
 
1284
- provider: 'bridge';
763
+ id?: string;
764
+ }
1285
765
 
1286
- status:
1287
- | 'not_found'
1288
- | 'active'
1289
- | 'awaiting_questionnaire'
1290
- | 'awaiting_ubo'
1291
- | 'incomplete'
1292
- | 'not_started'
1293
- | 'offboarded'
1294
- | 'paused'
1295
- | 'rejected'
1296
- | 'under_review';
766
+ /**
767
+ * User entity for a WebAuthn registration ceremony.
768
+ */
769
+ export interface PasskeyUser {
770
+ id: string;
1297
771
 
1298
- kyc_url?: string;
772
+ display_name: string;
1299
773
 
1300
- rejection_reasons?: Array<BridgeFiatRejectionReason>;
774
+ name: string;
1301
775
  }
1302
776
 
1303
777
  /**
1304
- * The response for getting a native onramp provider customer.
778
+ * A public key credential parameter specifying the algorithm and credential type.
1305
779
  */
1306
- export interface BridgeSandboxFiatCustomerResponse {
1307
- has_accepted_terms: boolean;
780
+ export interface PasskeyPubKeyCredParam {
781
+ alg: number;
1308
782
 
1309
- provider: 'bridge-sandbox';
783
+ type: 'public-key';
784
+ }
1310
785
 
1311
- status:
1312
- | 'not_found'
1313
- | 'active'
1314
- | 'awaiting_questionnaire'
1315
- | 'awaiting_ubo'
1316
- | 'incomplete'
1317
- | 'not_started'
1318
- | 'offboarded'
1319
- | 'paused'
1320
- | 'rejected'
1321
- | 'under_review';
786
+ /**
787
+ * Authenticator selection criteria for a WebAuthn registration ceremony.
788
+ */
789
+ export interface PasskeyAuthenticatorSelection {
790
+ authenticator_attachment?: string;
1322
791
 
1323
- kyc_url?: string;
792
+ require_resident_key?: boolean;
1324
793
 
1325
- rejection_reasons?: Array<BridgeFiatRejectionReason>;
794
+ resident_key?: string;
795
+
796
+ user_verification?: string;
1326
797
  }
1327
798
 
1328
799
  /**
1329
- * The response for getting a native onramp provider customer.
800
+ * Extensions for a WebAuthn registration ceremony.
1330
801
  */
1331
- export type FiatCustomerResponse = BridgeFiatCustomerResponse | BridgeSandboxFiatCustomerResponse;
802
+ export interface PasskeyEnrollmentExtensions {
803
+ app_id?: string;
1332
804
 
1333
- /**
1334
- * ISO 4217 fiat currency code. Three uppercase ASCII letters.
1335
- */
1336
- export type FiatCurrencyCode = string;
805
+ /**
806
+ * The result of the WebAuthn credProps extension.
807
+ */
808
+ cred_props?: PasskeyCredPropsResult;
809
+
810
+ hmac_create_secret?: boolean;
811
+ }
1337
812
 
1338
813
  /**
1339
- * Cryptocurrency symbol. Uppercase alphanumeric, 2-10 characters.
814
+ * The authenticator attestation response from a WebAuthn registration ceremony.
1340
815
  */
1341
- export type CryptoCurrencyCode = string;
816
+ export interface PasskeyAttestationResponse {
817
+ attestation_object: string;
818
+
819
+ client_data_json: string;
820
+
821
+ authenticator_data?: string;
822
+
823
+ public_key?: string;
824
+
825
+ public_key_algorithm?: number;
826
+
827
+ transports?: Array<unknown>;
828
+ }
1342
829
 
1343
830
  /**
1344
- * A CAIP-2 chain identifier in namespace:reference format (e.g. "eip155:1" for
1345
- * Ethereum mainnet, "solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp" for Solana mainnet).
831
+ * WebAuthn registration options as defined by the Web Authentication
832
+ * specification.
1346
833
  */
1347
- export type Caip2ChainID = string;
834
+ export interface PasskeyAuthenticatorEnrollmentOptions {
835
+ challenge: string;
836
+
837
+ pub_key_cred_params: Array<PasskeyPubKeyCredParam>;
838
+
839
+ /**
840
+ * Relying party information for a WebAuthn ceremony.
841
+ */
842
+ rp: PasskeyRelyingParty;
843
+
844
+ /**
845
+ * User entity for a WebAuthn registration ceremony.
846
+ */
847
+ user: PasskeyUser;
848
+
849
+ attestation?: string;
850
+
851
+ /**
852
+ * Authenticator selection criteria for a WebAuthn registration ceremony.
853
+ */
854
+ authenticator_selection?: PasskeyAuthenticatorSelection;
855
+
856
+ exclude_credentials?: Array<PasskeyCredentialDescriptor>;
857
+
858
+ /**
859
+ * Extensions for a WebAuthn registration ceremony.
860
+ */
861
+ extensions?: PasskeyEnrollmentExtensions;
862
+
863
+ timeout?: number;
864
+ }
1348
865
 
1349
866
  /**
1350
- * A positive decimal amount as a string (e.g. "100", "50.25", "0.001").
867
+ * WebAuthn registration response as defined by the Web Authentication
868
+ * specification.
1351
869
  */
1352
- export type FiatAmount = string;
870
+ export interface PasskeyAuthenticatorEnrollmentResponse {
871
+ id: string;
872
+
873
+ /**
874
+ * Client extension results returned by the WebAuthn authenticator.
875
+ */
876
+ client_extension_results: PasskeyClientExtensionResults;
877
+
878
+ raw_id: string;
879
+
880
+ /**
881
+ * The authenticator attestation response from a WebAuthn registration ceremony.
882
+ */
883
+ response: PasskeyAttestationResponse;
884
+
885
+ type: 'public-key';
886
+
887
+ authenticator_attachment?: string;
888
+ }
1353
889
 
1354
890
  /**
1355
- * Source currency details for a fiat onramp quote request.
891
+ * Response for initiating a passkey link ceremony.
1356
892
  */
1357
- export interface FiatOnrampSource {
893
+ export interface ResponsePasskeyInitLink {
1358
894
  /**
1359
- * A positive decimal amount as a string (e.g. "100", "50.25", "0.001").
895
+ * WebAuthn registration options as defined by the Web Authentication
896
+ * specification.
1360
897
  */
1361
- amount: FiatAmount;
898
+ options: PasskeyAuthenticatorEnrollmentOptions;
1362
899
 
900
+ relying_party?: string;
901
+ }
902
+
903
+ /**
904
+ * Response for initiating a passkey registration ceremony.
905
+ */
906
+ export interface ResponsePasskeyInitRegister {
1363
907
  /**
1364
- * ISO 4217 fiat currency code. Three uppercase ASCII letters.
908
+ * WebAuthn registration options as defined by the Web Authentication
909
+ * specification.
1365
910
  */
1366
- asset: FiatCurrencyCode;
911
+ options: PasskeyAuthenticatorEnrollmentOptions;
912
+
913
+ relying_party?: string;
1367
914
  }
1368
915
 
1369
916
  /**
1370
- * Destination cryptocurrency details for a fiat onramp quote request.
917
+ * Input for linking a passkey credential.
1371
918
  */
1372
- export interface FiatOnrampDestination {
1373
- address: string;
1374
-
919
+ export interface PasskeyLinkInput {
1375
920
  /**
1376
- * Cryptocurrency symbol. Uppercase alphanumeric, 2-10 characters.
921
+ * WebAuthn registration response as defined by the Web Authentication
922
+ * specification.
1377
923
  */
1378
- asset: CryptoCurrencyCode;
924
+ authenticator_response: PasskeyAuthenticatorEnrollmentResponse;
925
+
926
+ relying_party?: string;
927
+ }
1379
928
 
929
+ /**
930
+ * Input for registering a passkey credential.
931
+ */
932
+ export interface PasskeyRegisterInput {
1380
933
  /**
1381
- * A CAIP-2 chain identifier in namespace:reference format (e.g. "eip155:1" for
1382
- * Ethereum mainnet, "solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp" for Solana mainnet).
934
+ * WebAuthn registration response as defined by the Web Authentication
935
+ * specification.
1383
936
  */
1384
- chain: Caip2ChainID;
937
+ authenticator_response: PasskeyAuthenticatorEnrollmentResponse;
938
+
939
+ relying_party?: string;
1385
940
  }
1386
941
 
1387
942
  /**
1388
- * Whether to use the sandbox or production environment for fiat onramp.
943
+ * Input for initiating a passkey ceremony.
1389
944
  */
1390
- export type FiatOnrampEnvironment = 'sandbox' | 'production';
945
+ export interface PasskeyInitInput {
946
+ token?: string;
947
+
948
+ relying_party?: string;
949
+ }
1391
950
 
1392
951
  /**
1393
- * The fiat onramp provider to use.
952
+ * Input for unlinking a passkey credential.
953
+ */
954
+ export interface UnlinkPasskeyInput {
955
+ credential_id: string;
956
+
957
+ remove_as_mfa?: boolean;
958
+ }
959
+
960
+ /**
961
+ * Extensions for a WebAuthn authentication ceremony.
1394
962
  */
1395
- export type FiatOnrampProvider = 'meld' | 'meld-sandbox';
963
+ export interface PasskeyVerifyExtensions {
964
+ app_id?: string;
965
+
966
+ cred_props?: boolean;
967
+
968
+ hmac_create_secret?: boolean;
969
+ }
1396
970
 
1397
971
  /**
1398
- * The request input for getting fiat onramp quotes.
972
+ * The authenticator assertion response from a WebAuthn authentication ceremony.
1399
973
  */
1400
- export interface GetFiatOnrampQuotesInput {
974
+ export interface PasskeyAssertionResponse {
975
+ authenticator_data: string;
976
+
977
+ client_data_json: string;
978
+
979
+ signature: string;
980
+
981
+ user_handle?: string;
982
+ }
983
+
984
+ /**
985
+ * WebAuthn authentication options as defined by the Web Authentication
986
+ * specification.
987
+ */
988
+ export interface PasskeyAuthenticatorVerifyOptions {
989
+ challenge: string;
990
+
991
+ allow_credentials?: Array<PasskeyCredentialDescriptor>;
992
+
1401
993
  /**
1402
- * Destination cryptocurrency details for a fiat onramp quote request.
994
+ * Extensions for a WebAuthn authentication ceremony.
1403
995
  */
1404
- destination: FiatOnrampDestination;
996
+ extensions?: PasskeyVerifyExtensions;
997
+
998
+ rp_id?: string;
999
+
1000
+ timeout?: number;
1001
+
1002
+ user_verification?: string;
1003
+ }
1004
+
1005
+ /**
1006
+ * WebAuthn authentication response as defined by the Web Authentication
1007
+ * specification.
1008
+ */
1009
+ export interface PasskeyAuthenticatorVerifyResponse {
1010
+ id: string;
1405
1011
 
1406
1012
  /**
1407
- * Whether to use the sandbox or production environment for fiat onramp.
1013
+ * Client extension results returned by the WebAuthn authenticator.
1408
1014
  */
1409
- environment: FiatOnrampEnvironment;
1015
+ client_extension_results: PasskeyClientExtensionResults;
1016
+
1017
+ raw_id: string;
1410
1018
 
1411
1019
  /**
1412
- * Source currency details for a fiat onramp quote request.
1020
+ * The authenticator assertion response from a WebAuthn authentication ceremony.
1413
1021
  */
1414
- source: FiatOnrampSource;
1022
+ response: PasskeyAssertionResponse;
1023
+
1024
+ type: 'public-key';
1025
+
1026
+ authenticator_attachment?: string;
1415
1027
  }
1416
1028
 
1417
1029
  /**
1418
- * A single fiat onramp quote from a provider.
1030
+ * Response for initiating a passkey authentication ceremony.
1419
1031
  */
1420
- export interface FiatOnrampQuote {
1421
- payment_method: string;
1032
+ export interface ResponsePasskeyInitAuthenticate {
1033
+ /**
1034
+ * WebAuthn authentication options as defined by the Web Authentication
1035
+ * specification.
1036
+ */
1037
+ options: PasskeyAuthenticatorVerifyOptions;
1422
1038
 
1039
+ relying_party?: string;
1040
+ }
1041
+
1042
+ /**
1043
+ * Input for authenticating with a passkey.
1044
+ */
1045
+ export interface PasskeyAuthenticateInput {
1423
1046
  /**
1424
- * The fiat onramp provider to use.
1047
+ * WebAuthn authentication response as defined by the Web Authentication
1048
+ * specification.
1425
1049
  */
1426
- provider: FiatOnrampProvider;
1050
+ authenticator_response: PasskeyAuthenticatorVerifyResponse;
1051
+
1052
+ challenge: string;
1053
+
1054
+ relying_party?: string;
1055
+ }
1056
+
1057
+ /**
1058
+ * The request body for transferring a passwordless account.
1059
+ */
1060
+ export interface PasswordlessTransferRequestBody {
1061
+ email: string;
1062
+
1063
+ nonce: string;
1064
+ }
1065
+
1066
+ /**
1067
+ * The request body for transferring a passwordless sms account.
1068
+ */
1069
+ export interface PasswordlessSMSTransferRequestBody {
1070
+ nonce: string;
1071
+
1072
+ phoneNumber: string;
1073
+ }
1074
+
1075
+ /**
1076
+ * Input for authenticating with a custom JWT.
1077
+ */
1078
+ export interface AuthenticateJwtInput {
1079
+ token?: string;
1080
+
1081
+ /**
1082
+ * Whether to allow sign-up during authentication.
1083
+ */
1084
+ mode?: AuthenticateModeOption;
1085
+ }
1086
+
1087
+ /**
1088
+ * Input for linking a custom JWT account.
1089
+ */
1090
+ export interface LinkJwtInput {
1091
+ token?: string;
1092
+ }
1093
+
1094
+ /**
1095
+ * The request input for getting a native onramp provider customer.
1096
+ */
1097
+ export interface GetFiatCustomerRequestInput {
1098
+ /**
1099
+ * Valid set of onramp providers
1100
+ */
1101
+ provider: OnrampProvider;
1102
+
1103
+ kyc_redirect_url?: string;
1104
+ }
1105
+
1106
+ /**
1107
+ * The request input for creating (or updating) a native onramp provider customer.
1108
+ */
1109
+ export interface CreateOrUpdateFiatCustomerRequestInput {
1110
+ has_accepted_terms: boolean;
1111
+
1112
+ /**
1113
+ * Valid set of onramp providers
1114
+ */
1115
+ provider: OnrampProvider;
1116
+
1117
+ kyc_redirect_url?: string;
1118
+ }
1119
+
1120
+ /**
1121
+ * A rejection reason for a customer KYC verification.
1122
+ */
1123
+ export interface BridgeFiatRejectionReason {
1124
+ reason: string;
1125
+ }
1126
+
1127
+ /**
1128
+ * The response for getting a native onramp provider customer.
1129
+ */
1130
+ export interface BridgeFiatCustomerResponse {
1131
+ has_accepted_terms: boolean;
1132
+
1133
+ provider: 'bridge';
1134
+
1135
+ /**
1136
+ * Status of the KYC verification process.
1137
+ */
1138
+ status:
1139
+ | 'not_found'
1140
+ | 'active'
1141
+ | 'awaiting_questionnaire'
1142
+ | 'awaiting_ubo'
1143
+ | 'incomplete'
1144
+ | 'not_started'
1145
+ | 'offboarded'
1146
+ | 'paused'
1147
+ | 'rejected'
1148
+ | 'under_review';
1149
+
1150
+ kyc_url?: string;
1151
+
1152
+ rejection_reasons?: Array<BridgeFiatRejectionReason>;
1153
+ }
1154
+
1155
+ /**
1156
+ * The response for getting a native onramp provider customer.
1157
+ */
1158
+ export interface BridgeSandboxFiatCustomerResponse {
1159
+ has_accepted_terms: boolean;
1160
+
1161
+ provider: 'bridge-sandbox';
1162
+
1163
+ /**
1164
+ * Status of the KYC verification process.
1165
+ */
1166
+ status:
1167
+ | 'not_found'
1168
+ | 'active'
1169
+ | 'awaiting_questionnaire'
1170
+ | 'awaiting_ubo'
1171
+ | 'incomplete'
1172
+ | 'not_started'
1173
+ | 'offboarded'
1174
+ | 'paused'
1175
+ | 'rejected'
1176
+ | 'under_review';
1177
+
1178
+ kyc_url?: string;
1179
+
1180
+ rejection_reasons?: Array<BridgeFiatRejectionReason>;
1181
+ }
1182
+
1183
+ /**
1184
+ * The response for getting a native onramp provider customer.
1185
+ */
1186
+ export type FiatCustomerResponse = BridgeFiatCustomerResponse | BridgeSandboxFiatCustomerResponse;
1187
+
1188
+ /**
1189
+ * ISO 4217 fiat currency code. Three uppercase ASCII letters.
1190
+ */
1191
+ export type FiatCurrencyCode = string;
1192
+
1193
+ /**
1194
+ * Cryptocurrency symbol. Uppercase alphanumeric, 2-10 characters.
1195
+ */
1196
+ export type CryptoCurrencyCode = string;
1197
+
1198
+ /**
1199
+ * A CAIP-2 chain identifier in namespace:reference format (e.g. "eip155:1" for
1200
+ * Ethereum mainnet, "solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp" for Solana mainnet).
1201
+ */
1202
+ export type Caip2ChainID = string;
1203
+
1204
+ /**
1205
+ * A positive decimal amount as a string (e.g. "100", "50.25", "0.001").
1206
+ */
1207
+ export type FiatAmount = string;
1208
+
1209
+ /**
1210
+ * Source currency details for a fiat onramp quote request.
1211
+ */
1212
+ export interface FiatOnrampSource {
1213
+ /**
1214
+ * A positive decimal amount as a string (e.g. "100", "50.25", "0.001").
1215
+ */
1216
+ amount: FiatAmount;
1217
+
1218
+ /**
1219
+ * ISO 4217 fiat currency code. Three uppercase ASCII letters.
1220
+ */
1221
+ asset: FiatCurrencyCode;
1222
+ }
1223
+
1224
+ /**
1225
+ * Destination cryptocurrency details for a fiat onramp quote request.
1226
+ */
1227
+ export interface FiatOnrampDestination {
1228
+ address: string;
1229
+
1230
+ /**
1231
+ * Cryptocurrency symbol. Uppercase alphanumeric, 2-10 characters.
1232
+ */
1233
+ asset: CryptoCurrencyCode;
1234
+
1235
+ /**
1236
+ * A CAIP-2 chain identifier in namespace:reference format (e.g. "eip155:1" for
1237
+ * Ethereum mainnet, "solana:5eykt4UsFv8P8NJdTREpY1vzqKqZKvdp" for Solana mainnet).
1238
+ */
1239
+ chain: Caip2ChainID;
1240
+ }
1241
+
1242
+ /**
1243
+ * Whether to use the sandbox or production environment for fiat onramp.
1244
+ */
1245
+ export type FiatOnrampEnvironment = 'sandbox' | 'production';
1246
+
1247
+ /**
1248
+ * The fiat onramp provider to use.
1249
+ */
1250
+ export type FiatOnrampProvider =
1251
+ | 'meld'
1252
+ | 'meld-sandbox'
1253
+ | 'moonpay'
1254
+ | 'moonpay-sandbox'
1255
+ | 'coinbase'
1256
+ | 'coinbase-sandbox';
1257
+
1258
+ /**
1259
+ * The request input for getting fiat onramp quotes.
1260
+ */
1261
+ export interface GetFiatOnrampQuotesInput {
1262
+ /**
1263
+ * Destination cryptocurrency details for a fiat onramp quote request.
1264
+ */
1265
+ destination: FiatOnrampDestination;
1266
+
1267
+ /**
1268
+ * Whether to use the sandbox or production environment for fiat onramp.
1269
+ */
1270
+ environment: FiatOnrampEnvironment;
1271
+
1272
+ /**
1273
+ * Source currency details for a fiat onramp quote request.
1274
+ */
1275
+ source: FiatOnrampSource;
1276
+ }
1277
+
1278
+ /**
1279
+ * A single fiat onramp quote from a provider.
1280
+ */
1281
+ export interface FiatOnrampQuote {
1282
+ payment_method: string;
1283
+
1284
+ /**
1285
+ * The fiat onramp provider to use.
1286
+ */
1287
+ provider: FiatOnrampProvider;
1288
+
1289
+ destination_currency_code?: string | null;
1290
+
1291
+ source_amount?: number | null;
1292
+
1293
+ source_currency_code?: string | null;
1294
+
1295
+ sub_provider?: string | null;
1296
+ }
1297
+
1298
+ /**
1299
+ * An error from a specific fiat onramp provider when fetching quotes.
1300
+ */
1301
+ export interface FiatOnrampProviderError {
1302
+ error: string;
1303
+
1304
+ /**
1305
+ * The fiat onramp provider to use.
1306
+ */
1307
+ provider: FiatOnrampProvider;
1308
+ }
1309
+
1310
+ /**
1311
+ * The response containing fiat onramp quotes.
1312
+ */
1313
+ export interface GetFiatOnrampQuotesResponse {
1314
+ quotes: Array<FiatOnrampQuote>;
1315
+
1316
+ provider_errors?: Array<FiatOnrampProviderError>;
1317
+ }
1318
+
1319
+ /**
1320
+ * The request input for getting a fiat onramp provider session URL.
1321
+ */
1322
+ export interface GetFiatOnrampURLInput {
1323
+ /**
1324
+ * Destination cryptocurrency details for a fiat onramp quote request.
1325
+ */
1326
+ destination: FiatOnrampDestination;
1327
+
1328
+ payment_method: string;
1329
+
1330
+ /**
1331
+ * The fiat onramp provider to use.
1332
+ */
1333
+ provider: FiatOnrampProvider;
1334
+
1335
+ /**
1336
+ * Source currency details for a fiat onramp quote request.
1337
+ */
1338
+ source: FiatOnrampSource;
1339
+
1340
+ redirect_url?: string;
1341
+
1342
+ sub_provider?: string;
1343
+ }
1344
+
1345
+ /**
1346
+ * The response containing a fiat onramp provider session URL.
1347
+ */
1348
+ export interface GetFiatOnrampURLResponse {
1349
+ session_id: string;
1350
+
1351
+ url: string;
1352
+ }
1353
+
1354
+ /**
1355
+ * Normalized fiat onramp transaction status.
1356
+ */
1357
+ export type FiatOnrampTransactionStatus =
1358
+ | 'pending'
1359
+ | 'processing'
1360
+ | 'completed'
1361
+ | 'failed'
1362
+ | 'cancelled'
1363
+ | 'refunded'
1364
+ | 'unknown';
1365
+
1366
+ /**
1367
+ * The request input for checking a fiat onramp session status.
1368
+ */
1369
+ export interface GetFiatOnrampTransactionStatusInput {
1370
+ /**
1371
+ * The fiat onramp provider to use.
1372
+ */
1373
+ provider: FiatOnrampProvider;
1374
+
1375
+ session_id: string;
1376
+ }
1377
+
1378
+ /**
1379
+ * The response containing the fiat onramp session status.
1380
+ */
1381
+ export interface GetFiatOnrampTransactionStatusResponse {
1382
+ raw_status: string;
1383
+
1384
+ session_id: string;
1385
+
1386
+ /**
1387
+ * Normalized fiat onramp transaction status.
1388
+ */
1389
+ status: FiatOnrampTransactionStatus;
1390
+
1391
+ transaction_id?: string;
1392
+ }
1393
+
1394
+ export type BridgeDestinationAsset = 'usdb' | 'usdc' | 'usdt' | 'dai' | 'pyusd' | 'eurc';
1395
+
1396
+ export type BridgeSourceAsset = 'usd' | 'eur' | 'mxn' | 'brl' | 'gbp';
1397
+
1398
+ export interface BridgeFiatVirtualAccountSource {
1399
+ asset: BridgeSourceAsset;
1400
+ }
1401
+
1402
+ export interface BridgeFiatVirtualAccountDestination {
1403
+ address: string;
1404
+
1405
+ asset: BridgeDestinationAsset;
1406
+
1407
+ chain: string;
1408
+ }
1409
+
1410
+ /**
1411
+ * The request input for creating virtual account.
1412
+ */
1413
+ export interface BridgeFiatVirtualAccountRequest {
1414
+ destination: BridgeFiatVirtualAccountDestination;
1415
+
1416
+ provider: 'bridge';
1417
+
1418
+ source: BridgeFiatVirtualAccountSource;
1419
+ }
1420
+
1421
+ /**
1422
+ * The request input for creating virtual account.
1423
+ */
1424
+ export interface BridgeSandboxFiatVirtualAccountRequest {
1425
+ destination: BridgeFiatVirtualAccountDestination;
1426
+
1427
+ provider: 'bridge-sandbox';
1428
+
1429
+ source: BridgeFiatVirtualAccountSource;
1430
+ }
1431
+
1432
+ /**
1433
+ * The request input for creating virtual account.
1434
+ */
1435
+ export type FiatVirtualAccountRequest =
1436
+ | BridgeFiatVirtualAccountRequest
1437
+ | BridgeSandboxFiatVirtualAccountRequest;
1438
+
1439
+ /**
1440
+ * The deposit instructions for a virtual account.
1441
+ */
1442
+ export interface BridgeUsdFiatVirtualAccountDepositInstructions {
1443
+ asset: 'usd';
1444
+
1445
+ bank_account_number: string;
1446
+
1447
+ bank_address: string;
1448
+
1449
+ bank_beneficiary_address: string;
1450
+
1451
+ bank_beneficiary_name: string;
1452
+
1453
+ bank_name: string;
1454
+
1455
+ bank_routing_number: string;
1456
+
1457
+ payment_rails: Array<'ach_push' | 'wire'>;
1458
+ }
1459
+
1460
+ /**
1461
+ * The deposit instructions for a virtual account.
1462
+ */
1463
+ export interface BridgeEurFiatVirtualAccountDepositInstructions {
1464
+ account_holder_name: string;
1465
+
1466
+ asset: 'eur';
1467
+
1468
+ bank_address: string;
1469
+
1470
+ bank_name: string;
1471
+
1472
+ bic: string;
1473
+
1474
+ iban: string;
1475
+
1476
+ payment_rails: Array<'sepa'>;
1477
+ }
1478
+
1479
+ /**
1480
+ * The deposit instructions for a virtual account.
1481
+ */
1482
+ export interface BridgeMxnFiatVirtualAccountDepositInstructions {
1483
+ account_holder_name: string;
1484
+
1485
+ asset: 'mxn';
1486
+
1487
+ bank_address: string;
1488
+
1489
+ bank_name: string;
1490
+
1491
+ clabe: string;
1492
+
1493
+ payment_rails: Array<'spei'>;
1494
+ }
1495
+
1496
+ /**
1497
+ * The deposit instructions for a virtual account.
1498
+ */
1499
+ export interface BridgeBrlFiatVirtualAccountDepositInstructions {
1500
+ account_holder_name: string;
1501
+
1502
+ asset: 'brl';
1503
+
1504
+ bank_address: string;
1505
+
1506
+ bank_name: string;
1507
+
1508
+ br_code: string;
1509
+
1510
+ payment_rails: Array<'pix'>;
1511
+ }
1512
+
1513
+ /**
1514
+ * The deposit instructions for a virtual account.
1515
+ */
1516
+ export interface BridgeGbpFiatVirtualAccountDepositInstructions {
1517
+ account_holder_name: string;
1518
+
1519
+ account_number: string;
1520
+
1521
+ asset: 'gbp';
1522
+
1523
+ bank_address: string;
1524
+
1525
+ bank_name: string;
1526
+
1527
+ payment_rails: Array<'faster_payments'>;
1528
+
1529
+ sort_code: string;
1530
+ }
1531
+
1532
+ /**
1533
+ * The deposit instructions for a virtual account.
1534
+ */
1535
+ export type BridgeFiatVirtualAccountDepositInstructions =
1536
+ | BridgeUsdFiatVirtualAccountDepositInstructions
1537
+ | BridgeEurFiatVirtualAccountDepositInstructions
1538
+ | BridgeMxnFiatVirtualAccountDepositInstructions
1539
+ | BridgeBrlFiatVirtualAccountDepositInstructions
1540
+ | BridgeGbpFiatVirtualAccountDepositInstructions;
1541
+
1542
+ /**
1543
+ * The response for creating virtual account.
1544
+ */
1545
+ export interface BridgeFiatVirtualAccountResponse {
1546
+ /**
1547
+ * The deposit instructions for a virtual account.
1548
+ */
1549
+ deposit_instructions: BridgeFiatVirtualAccountDepositInstructions;
1550
+
1551
+ destination: BridgeFiatVirtualAccountDestination;
1552
+
1553
+ provider: 'bridge';
1554
+
1555
+ status: string;
1556
+ }
1557
+
1558
+ /**
1559
+ * The response for creating virtual account.
1560
+ */
1561
+ export interface BridgeSandboxFiatVirtualAccountResponse {
1562
+ /**
1563
+ * The deposit instructions for a virtual account.
1564
+ */
1565
+ deposit_instructions: BridgeFiatVirtualAccountDepositInstructions;
1566
+
1567
+ destination: BridgeFiatVirtualAccountDestination;
1568
+
1569
+ provider: 'bridge-sandbox';
1570
+
1571
+ status: string;
1572
+ }
1573
+
1574
+ /**
1575
+ * The response for creating virtual account.
1576
+ */
1577
+ export type FiatVirtualAccountResponse =
1578
+ | BridgeFiatVirtualAccountResponse
1579
+ | BridgeSandboxFiatVirtualAccountResponse;
1580
+
1581
+ /**
1582
+ * The type of OAuth authorization code.
1583
+ */
1584
+ export type OAuthCodeType = 'raw';
1585
+
1586
+ /**
1587
+ * Metadata for an OAuth transfer user info.
1588
+ */
1589
+ export interface OAuthTransferUserInfoMeta {
1590
+ providerAppId?: string;
1591
+ }
1592
+
1593
+ /**
1594
+ * User info for an OAuth transfer.
1595
+ */
1596
+ export interface OAuthTransferUserInfo {
1597
+ subject: string;
1598
+
1599
+ email?: string | null;
1600
+
1601
+ embeddedWalletAddresses?: Array<string>;
1602
+
1603
+ /**
1604
+ * Metadata for an OAuth transfer user info.
1605
+ */
1606
+ meta?: OAuthTransferUserInfoMeta;
1607
+
1608
+ name?: string;
1609
+
1610
+ profilePictureUrl?: string;
1611
+
1612
+ smartWalletAddresses?: Array<string>;
1613
+
1614
+ username?: string;
1615
+
1616
+ vanityName?: string;
1617
+ }
1618
+
1619
+ /**
1620
+ * The request body for transferring an OAuth account.
1621
+ */
1622
+ export interface OAuthTransferRequestBody {
1623
+ nonce: string;
1624
+
1625
+ /**
1626
+ * User info for an OAuth transfer.
1627
+ */
1628
+ userInfo: OAuthTransferUserInfo;
1629
+ }
1630
+
1631
+ /**
1632
+ * Input for a SIWE signing ceremony.
1633
+ */
1634
+ export interface SiweInput {
1635
+ message: string;
1636
+
1637
+ signature: string;
1638
+
1639
+ chainId?: string | null;
1640
+
1641
+ connectorType?: string | null;
1642
+
1643
+ walletClientType?: string | null;
1644
+ }
1645
+
1646
+ /**
1647
+ * Input for a smart wallet SIWE signing ceremony.
1648
+ */
1649
+ export interface SmartWalletSiweInput {
1650
+ message: string;
1651
+
1652
+ signature: string;
1653
+
1654
+ /**
1655
+ * The supported smart wallet providers.
1656
+ */
1657
+ smart_wallet_type: EmbeddedWalletsAPI.SmartWalletType;
1658
+
1659
+ smart_wallet_version?: string;
1660
+ }
1661
+
1662
+ /**
1663
+ * Input for authenticating a SIWE ceremony.
1664
+ */
1665
+ export interface AuthenticateSiweInput {
1666
+ message: string;
1667
+
1668
+ signature: string;
1669
+
1670
+ chainId?: string | null;
1671
+
1672
+ connectorType?: string | null;
1673
+
1674
+ /**
1675
+ * Whether to allow sign-up during authentication.
1676
+ */
1677
+ mode?: AuthenticateModeOption;
1678
+
1679
+ walletClientType?: string | null;
1680
+ }
1681
+
1682
+ /**
1683
+ * Input containing a SIWE wallet address.
1684
+ */
1685
+ export interface SiweAddressInput {
1686
+ address: string;
1687
+ }
1688
+
1689
+ /**
1690
+ * Input for initiating a SIWE ceremony.
1691
+ */
1692
+ export interface SiweInitInput {
1693
+ token?: string;
1694
+
1695
+ address?: string;
1696
+ }
1697
+
1698
+ /**
1699
+ * A SIWE nonce response.
1700
+ */
1701
+ export interface SiweNonce {
1702
+ address: string;
1703
+
1704
+ expires_at: string;
1705
+
1706
+ nonce: string;
1707
+ }
1708
+
1709
+ /**
1710
+ * Input for transferring a SIWE account.
1711
+ */
1712
+ export interface TransferSiweInput {
1713
+ address: string;
1714
+
1715
+ nonce: string;
1716
+
1717
+ chainId?: string | null;
1718
+
1719
+ connectorType?: string | null;
1720
+
1721
+ walletClientType?: string | null;
1722
+ }
1723
+
1724
+ /**
1725
+ * Input for a SIWS signing ceremony.
1726
+ */
1727
+ export interface SiwsInput {
1728
+ message: string;
1729
+
1730
+ signature: string;
1731
+
1732
+ connectorType?: string | null;
1733
+
1734
+ message_type?: 'transaction' | 'plain';
1735
+
1736
+ walletClientType?: string | null;
1737
+ }
1738
+
1739
+ /**
1740
+ * Input for authenticating a SIWS ceremony.
1741
+ */
1742
+ export interface AuthenticateSiwsInput {
1743
+ message: string;
1744
+
1745
+ signature: string;
1746
+
1747
+ connectorType?: string | null;
1748
+
1749
+ message_type?: 'transaction' | 'plain';
1750
+
1751
+ /**
1752
+ * Whether to allow sign-up during authentication.
1753
+ */
1754
+ mode?: AuthenticateModeOption;
1755
+
1756
+ walletClientType?: string | null;
1757
+ }
1758
+
1759
+ /**
1760
+ * Input containing a SIWS wallet address.
1761
+ */
1762
+ export interface SiwsAddressInput {
1763
+ address: string;
1764
+ }
1765
+
1766
+ /**
1767
+ * Input for initiating a SIWS ceremony.
1768
+ */
1769
+ export interface SiwsInitInput {
1770
+ address: string;
1771
+
1772
+ token?: string;
1773
+ }
1774
+
1775
+ /**
1776
+ * A SIWS nonce response.
1777
+ */
1778
+ export interface SiwsNonce {
1779
+ address: string;
1780
+
1781
+ expires_at: string;
1782
+
1783
+ nonce: string;
1784
+ }
1785
+
1786
+ /**
1787
+ * Input for transferring a SIWS account.
1788
+ */
1789
+ export interface TransferSiwsInput {
1790
+ address: string;
1791
+
1792
+ nonce: string;
1793
+
1794
+ connectorType?: string | null;
1795
+
1796
+ walletClientType?: string | null;
1797
+ }
1798
+
1799
+ /**
1800
+ * Auth result object returned by Telegram when a user authenticates using the
1801
+ * login widget.
1802
+ */
1803
+ export interface TelegramAuthResult {
1804
+ id: number | null;
1427
1805
 
1428
- destination_currency_code?: string | null;
1806
+ auth_date: number | null;
1429
1807
 
1430
- source_amount?: number | null;
1808
+ first_name: string;
1431
1809
 
1432
- source_currency_code?: string | null;
1810
+ hash: string;
1433
1811
 
1434
- sub_provider?: string | null;
1812
+ last_name?: string;
1813
+
1814
+ photo_url?: string;
1815
+
1816
+ username?: string;
1435
1817
  }
1436
1818
 
1437
1819
  /**
1438
- * The response containing fiat onramp quotes.
1820
+ * Auth result object returned by Telegram when a user authenticates using a mini
1821
+ * app.
1439
1822
  */
1440
- export interface GetFiatOnrampQuotesResponse {
1441
- quotes: Array<FiatOnrampQuote>;
1823
+ export interface TelegramWebAppData {
1824
+ auth_date: number | null;
1825
+
1826
+ hash: string;
1827
+
1828
+ user: string;
1829
+
1830
+ chat_instance?: string;
1831
+
1832
+ chat_type?: string;
1833
+
1834
+ query_id?: string;
1835
+
1836
+ signature?: string;
1837
+
1838
+ start_param?: string;
1442
1839
  }
1443
1840
 
1444
1841
  /**
1445
- * The request input for getting a fiat onramp provider session URL.
1842
+ * Input for authenticating with Telegram.
1446
1843
  */
1447
- export interface GetFiatOnrampURLInput {
1844
+ export interface TelegramAuthenticateInput {
1845
+ captcha_token?: string;
1846
+
1448
1847
  /**
1449
- * Destination cryptocurrency details for a fiat onramp quote request.
1848
+ * Whether to allow sign-up during authentication.
1450
1849
  */
1451
- destination: FiatOnrampDestination;
1452
-
1453
- payment_method: string;
1850
+ mode?: AuthenticateModeOption;
1454
1851
 
1455
1852
  /**
1456
- * The fiat onramp provider to use.
1853
+ * Auth result object returned by Telegram when a user authenticates using the
1854
+ * login widget.
1457
1855
  */
1458
- provider: FiatOnrampProvider;
1856
+ telegram_auth_result?: TelegramAuthResult;
1459
1857
 
1460
1858
  /**
1461
- * Source currency details for a fiat onramp quote request.
1859
+ * Auth result object returned by Telegram when a user authenticates using a mini
1860
+ * app.
1462
1861
  */
1463
- source: FiatOnrampSource;
1464
-
1465
- redirect_url?: string;
1466
-
1467
- sub_provider?: string;
1862
+ telegram_web_app_data?: TelegramWebAppData;
1468
1863
  }
1469
1864
 
1470
1865
  /**
1471
- * The response containing a fiat onramp provider session URL.
1866
+ * Input for unlinking a Telegram account.
1472
1867
  */
1473
- export interface GetFiatOnrampURLResponse {
1474
- session_id: string;
1475
-
1476
- url: string;
1868
+ export interface TelegramUnlinkInput {
1869
+ telegram_user_id: string;
1477
1870
  }
1478
1871
 
1479
1872
  /**
1480
- * Normalized fiat onramp transaction status.
1873
+ * Input for transferring a Telegram account.
1481
1874
  */
1482
- export type FiatOnrampTransactionStatus =
1483
- | 'pending'
1484
- | 'processing'
1485
- | 'completed'
1486
- | 'failed'
1487
- | 'cancelled'
1488
- | 'refunded'
1489
- | 'unknown';
1875
+ export interface TransferTelegramInput {
1876
+ nonce: string;
1490
1877
 
1491
- /**
1492
- * The request input for checking a fiat onramp session status.
1493
- */
1494
- export interface GetFiatOnrampTransactionStatusInput {
1495
1878
  /**
1496
- * The fiat onramp provider to use.
1879
+ * Auth result object returned by Telegram when a user authenticates using the
1880
+ * login widget.
1497
1881
  */
1498
- provider: FiatOnrampProvider;
1882
+ telegram_auth_result?: TelegramAuthResult;
1499
1883
 
1500
- session_id: string;
1884
+ /**
1885
+ * Auth result object returned by Telegram when a user authenticates using a mini
1886
+ * app.
1887
+ */
1888
+ telegram_web_app_data?: TelegramWebAppData;
1501
1889
  }
1502
1890
 
1503
1891
  /**
1504
- * The response containing the fiat onramp session status.
1892
+ * Proxy for the Farcaster Connect init response as defined in FIP-11.
1505
1893
  */
1506
- export interface GetFiatOnrampTransactionStatusResponse {
1507
- raw_status: string;
1508
-
1509
- session_id: string;
1510
-
1511
- /**
1512
- * Normalized fiat onramp transaction status.
1513
- */
1514
- status: FiatOnrampTransactionStatus;
1894
+ export interface FarcasterConnectInitResponse {
1895
+ channel_token: string;
1515
1896
 
1516
- transaction_id?: string;
1897
+ connect_uri: string;
1517
1898
  }
1518
1899
 
1519
- export type BridgeDestinationAsset = 'usdb' | 'usdc' | 'usdt' | 'dai' | 'pyusd' | 'eurc';
1900
+ /**
1901
+ * Proxy for the Farcaster Connect completed status response as defined in FIP-11.
1902
+ */
1903
+ export interface FarcasterConnectStatusCompletedResponse {
1904
+ bio: string;
1520
1905
 
1521
- export type BridgeSourceAsset = 'usd' | 'eur' | 'mxn' | 'brl' | 'gbp';
1906
+ display_name: string;
1522
1907
 
1523
- export interface BridgeFiatVirtualAccountSource {
1524
- asset: BridgeSourceAsset;
1525
- }
1908
+ fid: number;
1526
1909
 
1527
- export interface BridgeFiatVirtualAccountDestination {
1528
- address: string;
1910
+ message: string;
1529
1911
 
1530
- asset: BridgeDestinationAsset;
1912
+ nonce: string;
1531
1913
 
1532
- chain: string;
1533
- }
1914
+ pfp_url: string;
1534
1915
 
1535
- /**
1536
- * The request input for creating virtual account.
1537
- */
1538
- export interface BridgeFiatVirtualAccountRequest {
1539
- destination: BridgeFiatVirtualAccountDestination;
1916
+ signature: string;
1540
1917
 
1541
- provider: 'bridge';
1918
+ state: 'completed';
1542
1919
 
1543
- source: BridgeFiatVirtualAccountSource;
1920
+ username: string;
1544
1921
  }
1545
1922
 
1546
1923
  /**
1547
- * The request input for creating virtual account.
1924
+ * Proxy for the Farcaster Connect pending status response as defined in FIP-11.
1548
1925
  */
1549
- export interface BridgeSandboxFiatVirtualAccountRequest {
1550
- destination: BridgeFiatVirtualAccountDestination;
1551
-
1552
- provider: 'bridge-sandbox';
1926
+ export interface FarcasterConnectStatusPendingResponse {
1927
+ nonce: string;
1553
1928
 
1554
- source: BridgeFiatVirtualAccountSource;
1929
+ state: 'pending';
1555
1930
  }
1556
1931
 
1557
1932
  /**
1558
- * The request input for creating virtual account.
1933
+ * Input for authenticating with Farcaster.
1559
1934
  */
1560
- export type FiatVirtualAccountRequest =
1561
- | BridgeFiatVirtualAccountRequest
1562
- | BridgeSandboxFiatVirtualAccountRequest;
1935
+ export interface FarcasterAuthenticateInput {
1936
+ channel_token: string;
1563
1937
 
1564
- /**
1565
- * The deposit instructions for a virtual account.
1566
- */
1567
- export interface BridgeUsdFiatVirtualAccountDepositInstructions {
1568
- asset: 'usd';
1938
+ fid: number;
1569
1939
 
1570
- bank_account_number: string;
1940
+ message: string;
1571
1941
 
1572
- bank_address: string;
1942
+ signature: string;
1573
1943
 
1574
- bank_beneficiary_address: string;
1944
+ /**
1945
+ * Whether to allow sign-up during authentication.
1946
+ */
1947
+ mode?: AuthenticateModeOption;
1948
+ }
1575
1949
 
1576
- bank_beneficiary_name: string;
1950
+ /**
1951
+ * Input for linking a Farcaster account.
1952
+ */
1953
+ export interface FarcasterLinkInput {
1954
+ channel_token: string;
1577
1955
 
1578
- bank_name: string;
1956
+ fid: number;
1579
1957
 
1580
- bank_routing_number: string;
1958
+ message: string;
1581
1959
 
1582
- payment_rails: Array<'ach_push' | 'wire'>;
1960
+ signature: string;
1583
1961
  }
1584
1962
 
1585
1963
  /**
1586
- * The deposit instructions for a virtual account.
1964
+ * Input for initiating a Farcaster connection.
1587
1965
  */
1588
- export interface BridgeEurFiatVirtualAccountDepositInstructions {
1589
- account_holder_name: string;
1590
-
1591
- asset: 'eur';
1592
-
1593
- bank_address: string;
1594
-
1595
- bank_name: string;
1966
+ export interface FarcasterInitInput {
1967
+ token?: string;
1596
1968
 
1597
- bic: string;
1969
+ redirect_url?: string;
1598
1970
 
1599
- iban: string;
1971
+ relying_party?: string;
1972
+ }
1600
1973
 
1601
- payment_rails: Array<'sepa'>;
1974
+ /**
1975
+ * Input for unlinking a Farcaster account.
1976
+ */
1977
+ export interface FarcasterUnlinkInput {
1978
+ fid: number;
1602
1979
  }
1603
1980
 
1604
1981
  /**
1605
- * The deposit instructions for a virtual account.
1982
+ * Input for transferring a Farcaster account.
1606
1983
  */
1607
- export interface BridgeMxnFiatVirtualAccountDepositInstructions {
1608
- account_holder_name: string;
1984
+ export interface TransferFarcasterInput {
1985
+ farcaster_embedded_address: string;
1609
1986
 
1610
- asset: 'mxn';
1987
+ farcaster_id: string;
1611
1988
 
1612
- bank_address: string;
1989
+ nonce: string;
1990
+ }
1613
1991
 
1614
- bank_name: string;
1992
+ /**
1993
+ * Input for initiating a Farcaster V2 connection.
1994
+ */
1995
+ export type FarcasterV2InitInput = unknown;
1615
1996
 
1616
- clabe: string;
1997
+ /**
1998
+ * Response for initiating a Farcaster V2 connection.
1999
+ */
2000
+ export interface FarcasterV2InitResponse {
2001
+ expires_at: string;
1617
2002
 
1618
- payment_rails: Array<'spei'>;
2003
+ nonce: string;
1619
2004
  }
1620
2005
 
1621
2006
  /**
1622
- * The deposit instructions for a virtual account.
2007
+ * Input for authenticating a Farcaster V2 account.
1623
2008
  */
1624
- export interface BridgeBrlFiatVirtualAccountDepositInstructions {
1625
- account_holder_name: string;
2009
+ export interface FarcasterV2AuthenticateInput {
2010
+ fid: number;
1626
2011
 
1627
- asset: 'brl';
2012
+ message: string;
1628
2013
 
1629
- bank_address: string;
2014
+ signature: string;
1630
2015
 
1631
- bank_name: string;
2016
+ /**
2017
+ * Whether to allow sign-up during authentication.
2018
+ */
2019
+ mode?: AuthenticateModeOption;
2020
+ }
1632
2021
 
1633
- br_code: string;
2022
+ /**
2023
+ * The request body for initiating a Farcaster V2 connection.
2024
+ */
2025
+ export type FarcasterV2InitRequestBody = unknown;
1634
2026
 
1635
- payment_rails: Array<'pix'>;
2027
+ /**
2028
+ * The response body for initiating a Farcaster V2 connection.
2029
+ */
2030
+ export interface FarcasterV2InitResponseBody {
2031
+ expires_at: string;
2032
+
2033
+ nonce: string;
1636
2034
  }
1637
2035
 
1638
2036
  /**
1639
- * The deposit instructions for a virtual account.
2037
+ * The request body for authenticating a Farcaster V2 account.
1640
2038
  */
1641
- export interface BridgeGbpFiatVirtualAccountDepositInstructions {
1642
- account_holder_name: string;
2039
+ export interface FarcasterV2AuthenticateRequestBody {
2040
+ fid: number;
1643
2041
 
1644
- account_number: string;
2042
+ message: string;
1645
2043
 
1646
- asset: 'gbp';
2044
+ signature: string;
1647
2045
 
1648
- bank_address: string;
2046
+ /**
2047
+ * Whether to allow sign-up during authentication.
2048
+ */
2049
+ mode?: AuthenticateModeOption;
2050
+ }
1649
2051
 
1650
- bank_name: string;
2052
+ /**
2053
+ * A Farcaster signer init response when the signer is pending approval.
2054
+ */
2055
+ export interface FarcasterSignerInitPendingApproval {
2056
+ public_key: string;
1651
2057
 
1652
- payment_rails: Array<'faster_payments'>;
2058
+ signer_approval_url: string;
1653
2059
 
1654
- sort_code: string;
2060
+ status: 'pending_approval';
1655
2061
  }
1656
2062
 
1657
2063
  /**
1658
- * The deposit instructions for a virtual account.
2064
+ * A Farcaster signer response when the signer has been approved.
1659
2065
  */
1660
- export type BridgeFiatVirtualAccountDepositInstructions =
1661
- | BridgeUsdFiatVirtualAccountDepositInstructions
1662
- | BridgeEurFiatVirtualAccountDepositInstructions
1663
- | BridgeMxnFiatVirtualAccountDepositInstructions
1664
- | BridgeBrlFiatVirtualAccountDepositInstructions
1665
- | BridgeGbpFiatVirtualAccountDepositInstructions;
2066
+ export interface FarcasterSignerApproved {
2067
+ fid: string;
2068
+
2069
+ public_key: string;
2070
+
2071
+ status: 'approved';
2072
+ }
1666
2073
 
1667
2074
  /**
1668
- * The response for creating virtual account.
2075
+ * A Farcaster signer response when the signer has been revoked.
1669
2076
  */
1670
- export interface BridgeFiatVirtualAccountResponse {
1671
- /**
1672
- * The deposit instructions for a virtual account.
1673
- */
1674
- deposit_instructions: BridgeFiatVirtualAccountDepositInstructions;
1675
-
1676
- destination: BridgeFiatVirtualAccountDestination;
2077
+ export interface FarcasterSignerRevoked {
2078
+ fid: string;
1677
2079
 
1678
- provider: 'bridge';
2080
+ public_key: string;
1679
2081
 
1680
- status: string;
2082
+ status: 'revoked';
1681
2083
  }
1682
2084
 
1683
2085
  /**
1684
- * The response for creating virtual account.
2086
+ * A Farcaster signer status response when the signer is pending approval.
1685
2087
  */
1686
- export interface BridgeSandboxFiatVirtualAccountResponse {
1687
- /**
1688
- * The deposit instructions for a virtual account.
1689
- */
1690
- deposit_instructions: BridgeFiatVirtualAccountDepositInstructions;
2088
+ export interface FarcasterSignerStatusPendingApproval {
2089
+ public_key: string;
1691
2090
 
1692
- destination: BridgeFiatVirtualAccountDestination;
1693
-
1694
- provider: 'bridge-sandbox';
2091
+ status: 'pending_approval';
2092
+ }
1695
2093
 
1696
- status: string;
2094
+ /**
2095
+ * Input for verifying SMS MFA.
2096
+ */
2097
+ export interface MfaSMSInitVerifyInput {
2098
+ action: 'verify';
1697
2099
  }
1698
2100
 
1699
2101
  /**
1700
- * The response for creating virtual account.
2102
+ * Input for enrolling SMS MFA.
1701
2103
  */
1702
- export type FiatVirtualAccountResponse =
1703
- | BridgeFiatVirtualAccountResponse
1704
- | BridgeSandboxFiatVirtualAccountResponse;
2104
+ export interface MfaSMSInitEnrollInput {
2105
+ action: 'enroll';
2106
+
2107
+ phoneNumber: string;
2108
+ }
1705
2109
 
1706
2110
  export declare namespace ClientAuth {
1707
2111
  export {
@@ -1718,7 +2122,6 @@ export declare namespace ClientAuth {
1718
2122
  type FarcasterSignerStatusResponseBody as FarcasterSignerStatusResponseBody,
1719
2123
  type FarcasterUnlinkRequestBody as FarcasterUnlinkRequestBody,
1720
2124
  type FarcasterV2AuthenticateRequestBody as FarcasterV2AuthenticateRequestBody,
1721
- type FarcasterV2InitRequestBody as FarcasterV2InitRequestBody,
1722
2125
  type FarcasterV2InitResponseBody as FarcasterV2InitResponseBody,
1723
2126
  type GuestAuthenticateRequestBody as GuestAuthenticateRequestBody,
1724
2127
  type MfaPasskeyEnrollmentRequestBody as MfaPasskeyEnrollmentRequestBody,
@@ -1741,14 +2144,6 @@ export declare namespace ClientAuth {
1741
2144
  type OAuthVerifyRequestBody as OAuthVerifyRequestBody,
1742
2145
  type OAuthVerifyResponseBody as OAuthVerifyResponseBody,
1743
2146
  type OptionalRefreshTokenInput as OptionalRefreshTokenInput,
1744
- type PasskeyAuthenticateRequestBody as PasskeyAuthenticateRequestBody,
1745
- type PasskeyInitAuthenticateResponseBody as PasskeyInitAuthenticateResponseBody,
1746
- type PasskeyInitLinkResponseBody as PasskeyInitLinkResponseBody,
1747
- type PasskeyInitRegisterResponseBody as PasskeyInitRegisterResponseBody,
1748
- type PasskeyInitRequestBody as PasskeyInitRequestBody,
1749
- type PasskeyLinkRequestBody as PasskeyLinkRequestBody,
1750
- type PasskeyRegisterRequestBody as PasskeyRegisterRequestBody,
1751
- type PasskeyUnlinkRequestBody as PasskeyUnlinkRequestBody,
1752
2147
  type PasswordlessAuthenticateRequestBody as PasswordlessAuthenticateRequestBody,
1753
2148
  type PasswordlessInitRequestBody as PasswordlessInitRequestBody,
1754
2149
  type PasswordlessLinkRequestBody as PasswordlessLinkRequestBody,
@@ -1779,6 +2174,35 @@ export declare namespace ClientAuth {
1779
2174
  type OAuthProviderID as OAuthProviderID,
1780
2175
  type BridgeOnrampProvider as BridgeOnrampProvider,
1781
2176
  type OnrampProvider as OnrampProvider,
2177
+ type AuthenticateModeOption as AuthenticateModeOption,
2178
+ type AuthenticateMode as AuthenticateMode,
2179
+ type PasskeyCredPropsResult as PasskeyCredPropsResult,
2180
+ type PasskeyClientExtensionResults as PasskeyClientExtensionResults,
2181
+ type PasskeyCredentialDescriptor as PasskeyCredentialDescriptor,
2182
+ type PasskeyRelyingParty as PasskeyRelyingParty,
2183
+ type PasskeyUser as PasskeyUser,
2184
+ type PasskeyPubKeyCredParam as PasskeyPubKeyCredParam,
2185
+ type PasskeyAuthenticatorSelection as PasskeyAuthenticatorSelection,
2186
+ type PasskeyEnrollmentExtensions as PasskeyEnrollmentExtensions,
2187
+ type PasskeyAttestationResponse as PasskeyAttestationResponse,
2188
+ type PasskeyAuthenticatorEnrollmentOptions as PasskeyAuthenticatorEnrollmentOptions,
2189
+ type PasskeyAuthenticatorEnrollmentResponse as PasskeyAuthenticatorEnrollmentResponse,
2190
+ type ResponsePasskeyInitLink as ResponsePasskeyInitLink,
2191
+ type ResponsePasskeyInitRegister as ResponsePasskeyInitRegister,
2192
+ type PasskeyLinkInput as PasskeyLinkInput,
2193
+ type PasskeyRegisterInput as PasskeyRegisterInput,
2194
+ type PasskeyInitInput as PasskeyInitInput,
2195
+ type UnlinkPasskeyInput as UnlinkPasskeyInput,
2196
+ type PasskeyVerifyExtensions as PasskeyVerifyExtensions,
2197
+ type PasskeyAssertionResponse as PasskeyAssertionResponse,
2198
+ type PasskeyAuthenticatorVerifyOptions as PasskeyAuthenticatorVerifyOptions,
2199
+ type PasskeyAuthenticatorVerifyResponse as PasskeyAuthenticatorVerifyResponse,
2200
+ type ResponsePasskeyInitAuthenticate as ResponsePasskeyInitAuthenticate,
2201
+ type PasskeyAuthenticateInput as PasskeyAuthenticateInput,
2202
+ type PasswordlessTransferRequestBody as PasswordlessTransferRequestBody,
2203
+ type PasswordlessSMSTransferRequestBody as PasswordlessSMSTransferRequestBody,
2204
+ type AuthenticateJwtInput as AuthenticateJwtInput,
2205
+ type LinkJwtInput as LinkJwtInput,
1782
2206
  type GetFiatCustomerRequestInput as GetFiatCustomerRequestInput,
1783
2207
  type CreateOrUpdateFiatCustomerRequestInput as CreateOrUpdateFiatCustomerRequestInput,
1784
2208
  type BridgeFiatRejectionReason as BridgeFiatRejectionReason,
@@ -1795,6 +2219,7 @@ export declare namespace ClientAuth {
1795
2219
  type FiatOnrampProvider as FiatOnrampProvider,
1796
2220
  type GetFiatOnrampQuotesInput as GetFiatOnrampQuotesInput,
1797
2221
  type FiatOnrampQuote as FiatOnrampQuote,
2222
+ type FiatOnrampProviderError as FiatOnrampProviderError,
1798
2223
  type GetFiatOnrampQuotesResponse as GetFiatOnrampQuotesResponse,
1799
2224
  type GetFiatOnrampURLInput as GetFiatOnrampURLInput,
1800
2225
  type GetFiatOnrampURLResponse as GetFiatOnrampURLResponse,
@@ -1817,5 +2242,45 @@ export declare namespace ClientAuth {
1817
2242
  type BridgeFiatVirtualAccountResponse as BridgeFiatVirtualAccountResponse,
1818
2243
  type BridgeSandboxFiatVirtualAccountResponse as BridgeSandboxFiatVirtualAccountResponse,
1819
2244
  type FiatVirtualAccountResponse as FiatVirtualAccountResponse,
2245
+ type OAuthCodeType as OAuthCodeType,
2246
+ type OAuthTransferUserInfoMeta as OAuthTransferUserInfoMeta,
2247
+ type OAuthTransferUserInfo as OAuthTransferUserInfo,
2248
+ type OAuthTransferRequestBody as OAuthTransferRequestBody,
2249
+ type SiweInput as SiweInput,
2250
+ type SmartWalletSiweInput as SmartWalletSiweInput,
2251
+ type AuthenticateSiweInput as AuthenticateSiweInput,
2252
+ type SiweAddressInput as SiweAddressInput,
2253
+ type SiweInitInput as SiweInitInput,
2254
+ type SiweNonce as SiweNonce,
2255
+ type TransferSiweInput as TransferSiweInput,
2256
+ type SiwsInput as SiwsInput,
2257
+ type AuthenticateSiwsInput as AuthenticateSiwsInput,
2258
+ type SiwsAddressInput as SiwsAddressInput,
2259
+ type SiwsInitInput as SiwsInitInput,
2260
+ type SiwsNonce as SiwsNonce,
2261
+ type TransferSiwsInput as TransferSiwsInput,
2262
+ type TelegramAuthResult as TelegramAuthResult,
2263
+ type TelegramWebAppData as TelegramWebAppData,
2264
+ type TelegramAuthenticateInput as TelegramAuthenticateInput,
2265
+ type TelegramUnlinkInput as TelegramUnlinkInput,
2266
+ type TransferTelegramInput as TransferTelegramInput,
2267
+ type FarcasterConnectInitResponse as FarcasterConnectInitResponse,
2268
+ type FarcasterConnectStatusCompletedResponse as FarcasterConnectStatusCompletedResponse,
2269
+ type FarcasterConnectStatusPendingResponse as FarcasterConnectStatusPendingResponse,
2270
+ type FarcasterAuthenticateInput as FarcasterAuthenticateInput,
2271
+ type FarcasterLinkInput as FarcasterLinkInput,
2272
+ type FarcasterInitInput as FarcasterInitInput,
2273
+ type FarcasterUnlinkInput as FarcasterUnlinkInput,
2274
+ type TransferFarcasterInput as TransferFarcasterInput,
2275
+ type FarcasterV2InitInput as FarcasterV2InitInput,
2276
+ type FarcasterV2InitResponse as FarcasterV2InitResponse,
2277
+ type FarcasterV2AuthenticateInput as FarcasterV2AuthenticateInput,
2278
+ type FarcasterV2InitRequestBody as FarcasterV2InitRequestBody,
2279
+ type FarcasterSignerInitPendingApproval as FarcasterSignerInitPendingApproval,
2280
+ type FarcasterSignerApproved as FarcasterSignerApproved,
2281
+ type FarcasterSignerRevoked as FarcasterSignerRevoked,
2282
+ type FarcasterSignerStatusPendingApproval as FarcasterSignerStatusPendingApproval,
2283
+ type MfaSMSInitVerifyInput as MfaSMSInitVerifyInput,
2284
+ type MfaSMSInitEnrollInput as MfaSMSInitEnrollInput,
1820
2285
  };
1821
2286
  }