@magic-sdk/types 11.2.0-5fe3cb7-2 → 11.2.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.
package/CHANGELOG.md ADDED
@@ -0,0 +1,508 @@
1
+ # v11.2.0 (Thu Feb 09 2023)
2
+
3
+ #### 🚀 Enhancement
4
+
5
+ - move connect methods to wallet module under magic-sdk [#446](https://github.com/magiclabs/magic-js/pull/446) ([@hcote](https://github.com/hcote))
6
+
7
+ #### 🐛 Bug Fix
8
+
9
+ - update RequestUserInfoScope ([@hcote](https://github.com/hcote))
10
+ - move connect methods to wallet module under magic-sdk ([@hcote](https://github.com/hcote))
11
+
12
+ #### Authors: 1
13
+
14
+ - Hunter Cote ([@hcote](https://github.com/hcote))
15
+
16
+ ---
17
+
18
+ # v11.1.0 (Fri Jan 06 2023)
19
+
20
+ #### 🚀 Enhancement
21
+
22
+ - Bare React Native / Expo React Native Package Split [#412](https://github.com/magiclabs/magic-js/pull/412) ([@Ariflo](https://github.com/Ariflo))
23
+
24
+ #### 🐛 Bug Fix
25
+
26
+ - Updates @magic-sdk/types SDK ([@Ariflo](https://github.com/Ariflo))
27
+
28
+ #### Authors: 1
29
+
30
+ - Arian Flores ([@Ariflo](https://github.com/Ariflo))
31
+
32
+ ---
33
+
34
+ # v11.0.0 (Thu Jan 05 2023)
35
+
36
+ #### 💥 Breaking Change
37
+
38
+ - Update Commons/Provider/Types Packages + Workflow [#427](https://github.com/magiclabs/magic-js/pull/427) ([@Ariflo](https://github.com/Ariflo))
39
+
40
+ #### 🐛 Bug Fix
41
+
42
+ - Update ReadMe to Triggger CI ([@Ariflo](https://github.com/Ariflo))
43
+
44
+ #### Authors: 1
45
+
46
+ - Arian Flores ([@Ariflo](https://github.com/Ariflo))
47
+
48
+ ---
49
+
50
+ # v10.0.0 (Tue Dec 20 2022)
51
+
52
+ #### 🐛 Bug Fix
53
+
54
+ - Mushfichowdhury sc 61149 implement event emitting in magic sdk [#390](https://github.com/magiclabs/magic-js/pull/390) ([@mushfichowdhury-magic](https://github.com/mushfichowdhury-magic))
55
+ - Merge branch 'master' into mushfichowdhury-sc-61149-implement-event-emitting-in-magic-sdk-based ([@mushfichowdhury-magic](https://github.com/mushfichowdhury-magic))
56
+ - adding in types ([@mushfichowdhury-magic](https://github.com/mushfichowdhury-magic))
57
+ - v1 of bidirectional rpc event support ([@mushfichowdhury-magic](https://github.com/mushfichowdhury-magic))
58
+
59
+ #### Authors: 1
60
+
61
+ - Mushfi Chowdhury ([@mushfichowdhury-magic](https://github.com/mushfichowdhury-magic))
62
+
63
+ ---
64
+
65
+ # v9.0.0 (Wed Sep 28 2022)
66
+
67
+ #### 💥 Breaking Change
68
+
69
+ - drop legacy testnet support [#364](https://github.com/magiclabs/magic-js/pull/364) ([@harryEth](https://github.com/harryEth))
70
+
71
+ #### Authors: 1
72
+
73
+ - [@harryEth](https://github.com/harryEth)
74
+
75
+ ---
76
+
77
+ # v8.1.0 (Tue Sep 27 2022)
78
+
79
+ #### 🚀 Enhancement
80
+
81
+ - Harryxue sc 61854 m2 magic sdk support goerli testnet and release [#362](https://github.com/magiclabs/magic-js/pull/362) ([@harryEth](https://github.com/harryEth))
82
+
83
+ #### Authors: 1
84
+
85
+ - [@harryEth](https://github.com/harryEth)
86
+
87
+ ---
88
+
89
+ # v8.0.0 (Fri Aug 05 2022)
90
+
91
+ #### 💥 Breaking Change
92
+
93
+ - Revert "Revert "Enable bundle Id in Expo"" [#338](https://github.com/magiclabs/magic-js/pull/338) ([@Ethella](https://github.com/Ethella))
94
+ - Enable bundle Id in Expo [#335](https://github.com/magiclabs/magic-js/pull/335) ([@Ethella](https://github.com/Ethella))
95
+
96
+ #### 🐛 Bug Fix
97
+
98
+ - Merge branch 'master' into early-access ([@bcleary06](https://github.com/bcleary06))
99
+ - Update Readme and manual version bump for releases [#339](https://github.com/magiclabs/magic-js/pull/339) ([@Ethella](https://github.com/Ethella))
100
+ - Revert "Enable bundle Id in Expo" [#337](https://github.com/magiclabs/magic-js/pull/337) ([@Ethella](https://github.com/Ethella))
101
+
102
+ #### Authors: 2
103
+
104
+ - Brian Cleary ([@bcleary06](https://github.com/bcleary06))
105
+ - Jerry Liu ([@Ethella](https://github.com/Ethella))
106
+
107
+ ---
108
+
109
+ # v7.1.1 (Wed Apr 20 2022)
110
+
111
+ #### 🐛 Bug Fix
112
+
113
+ - [Chore]: added `loginWithEmailOTP` method [#302](https://github.com/magiclabs/magic-js/pull/302) ([@adenekan41](https://github.com/adenekan41))
114
+
115
+ #### Authors: 1
116
+
117
+ - Adenekan Wonderful ([@adenekan41](https://github.com/adenekan41))
118
+
119
+ ---
120
+
121
+ # v7.1.0 (Mon Mar 07 2022)
122
+
123
+ #### 🐛 Bug Fix
124
+
125
+ - Update READMEs with outdated context/hyperlinks ([@smithki](https://github.com/smithki))
126
+
127
+ #### 🏠 Internal
128
+
129
+ - Internal documentation updates (`BUILD_SYSTEM.md`) [#283](https://github.com/magiclabs/magic-js/pull/283) ([@smithki](https://github.com/smithki))
130
+
131
+ #### Authors: 1
132
+
133
+ - Ian K Smith ([@smithki](https://github.com/smithki))
134
+
135
+ ---
136
+
137
+ # v7.0.0 (Tue Jan 25 2022)
138
+
139
+ #### 💥 Breaking Change
140
+
141
+ - Switch from `microbundle` to `esbuild` [#220](https://github.com/magiclabs/magic-js/pull/220) ([@smithki](https://github.com/smithki))
142
+
143
+ #### 🐛 Bug Fix
144
+
145
+ - Merge with master ([@smithki](https://github.com/smithki))
146
+ - Merge branch 'master' into feat/faster-builds ([@smithki](https://github.com/smithki))
147
+ - Remove comments from README files ([@smithki](https://github.com/smithki))
148
+ - Fix build errors related to isolatedModules ([@smithki](https://github.com/smithki))
149
+ - Replace microbundle with ESBuild ([@smithki](https://github.com/smithki))
150
+
151
+ #### Authors: 1
152
+
153
+ - Ian K Smith ([@smithki](https://github.com/smithki))
154
+
155
+ ---
156
+
157
+ # v6.0.0 (Tue Dec 14 2021)
158
+
159
+ #### 💥 Breaking Change
160
+
161
+ - Deprecate test API key [#252](https://github.com/magiclabs/magic-js/pull/252) (harry [@harryEth](https://github.com/harryEth))
162
+
163
+ #### Authors: 2
164
+
165
+ - [@harryEth](https://github.com/harryEth)
166
+ - harry (harry)
167
+
168
+ ---
169
+
170
+ # v5.2.0 (Fri Oct 22 2021)
171
+
172
+ #### 🚀 Enhancement
173
+
174
+ - Add `UserModule#settings` endpoint [#231](https://github.com/magiclabs/magic-js/pull/231) ([@smithki](https://github.com/smithki))
175
+
176
+ #### Authors: 1
177
+
178
+ - Ian K Smith ([@smithki](https://github.com/smithki))
179
+
180
+ ---
181
+
182
+ # v5.1.4 (Thu Oct 21 2021)
183
+
184
+ #### 🐛 Bug Fix
185
+
186
+ - Revert to `.js` extension for ES module builds targeting webpack/CRA [#232](https://github.com/magiclabs/magic-js/pull/232) ([@smithki](https://github.com/smithki))
187
+
188
+ #### Authors: 1
189
+
190
+ - Ian K Smith ([@smithki](https://github.com/smithki))
191
+
192
+ ---
193
+
194
+ # v5.1.3 (Wed Oct 20 2021)
195
+
196
+ #### ⚠️ Pushed to `master`
197
+
198
+ - Fix dist files glob in package.json ([@smithki](https://github.com/smithki))
199
+ - Merge branch 'master' of github.com:magiclabs/magic-js ([@smithki](https://github.com/smithki))
200
+ - Force re-publish ([@smithki](https://github.com/smithki))
201
+
202
+ #### Authors: 1
203
+
204
+ - Ian K Smith ([@smithki](https://github.com/smithki))
205
+
206
+ ---
207
+
208
+ # v5.1.2 (Wed Oct 20 2021)
209
+
210
+ #### 🐛 Bug Fix
211
+
212
+ - Use '.mjs' extension for ESM build files [#230](https://github.com/magiclabs/magic-js/pull/230) ([@smithki](https://github.com/smithki))
213
+
214
+ #### Authors: 1
215
+
216
+ - Ian K Smith ([@smithki](https://github.com/smithki))
217
+
218
+ ---
219
+
220
+ # v5.1.1 (Tue Oct 19 2021)
221
+
222
+ #### 🐛 Bug Fix
223
+
224
+ - add typing for metadata phone number [#225](https://github.com/magiclabs/magic-js/pull/225) ([@dgerrellsMagic](https://github.com/dgerrellsMagic))
225
+
226
+ #### Authors: 1
227
+
228
+ - [@dgerrellsMagic](https://github.com/dgerrellsMagic)
229
+
230
+ ---
231
+
232
+ # v5.1.0 (Fri Oct 01 2021)
233
+
234
+ #### 🚀 Enhancement
235
+
236
+ - Enable SMS login [#223](https://github.com/magiclabs/magic-js/pull/223) ([@dgerrellsMagic](https://github.com/dgerrellsMagic))
237
+
238
+ #### Authors: 1
239
+
240
+ - [@dgerrellsMagic](https://github.com/dgerrellsMagic)
241
+
242
+ ---
243
+
244
+ # v5.0.3 (Thu Sep 23 2021)
245
+
246
+ #### 🐛 Bug Fix
247
+
248
+ - Port `@magic-ext/oauth`, `@magic-ext/react-native-oauth`, `@magic-ext/webauthn` extensions to Magic SDK monorepo [#218](https://github.com/magiclabs/magic-js/pull/218) ([@smithki](https://github.com/smithki))
249
+ - Add `@magic-sdk/pnp` package for out-of-the-box login page UIs [#217](https://github.com/magiclabs/magic-js/pull/217) ([@smithki](https://github.com/smithki))
250
+
251
+ #### Authors: 1
252
+
253
+ - Ian K Smith ([@smithki](https://github.com/smithki))
254
+
255
+ ---
256
+
257
+ # v5.0.2 (Fri Sep 17 2021)
258
+
259
+ #### 🐛 Bug Fix
260
+
261
+ - Fix CJS-dependent entry-points using the 'exports' field in package.json [#214](https://github.com/magiclabs/magic-js/pull/214) ([@smithki](https://github.com/smithki))
262
+
263
+ #### Authors: 1
264
+
265
+ - Ian K Smith ([@smithki](https://github.com/smithki))
266
+
267
+ ---
268
+
269
+ # v5.0.1 (Tue Sep 14 2021)
270
+
271
+ #### 🐛 Bug Fix
272
+
273
+ - Import regeneratorRuntime in Magic JS (non-CDN version) [#210](https://github.com/magiclabs/magic-js/pull/210) ([@smithki](https://github.com/smithki))
274
+
275
+ #### Authors: 1
276
+
277
+ - Ian K Smith ([@smithki](https://github.com/smithki))
278
+
279
+ ---
280
+
281
+ # v5.0.0 (Tue Sep 14 2021)
282
+
283
+ #### 💥 Breaking Change
284
+
285
+ - v6.0.0 [#208](https://github.com/magiclabs/magic-js/pull/208) ([@smithki](https://github.com/smithki))
286
+
287
+ #### Authors: 1
288
+
289
+ - Ian K Smith ([@smithki](https://github.com/smithki))
290
+
291
+ ---
292
+
293
+ # v4.0.0 (Tue Aug 31 2021)
294
+
295
+ #### 💥 Breaking Change
296
+
297
+ - Custom session duration [#199](https://github.com/magiclabs/magic-js/pull/199) ([@dgerrellsMagic](https://github.com/dgerrellsMagic))
298
+
299
+ #### Authors: 1
300
+
301
+ - [@dgerrellsMagic](https://github.com/dgerrellsMagic)
302
+
303
+ ---
304
+
305
+ # v3.2.2 (Mon Aug 16 2021)
306
+
307
+ #### 🐛 Bug Fix
308
+
309
+ - Migrate unit tests to Jest [#194](https://github.com/magiclabs/magic-js/pull/194) ([@smithki](https://github.com/smithki))
310
+
311
+ #### Authors: 1
312
+
313
+ - Ian K Smith ([@smithki](https://github.com/smithki))
314
+
315
+ ---
316
+
317
+ # v3.2.1 (Mon Aug 09 2021)
318
+
319
+ #### 🐛 Bug Fix
320
+
321
+ - register access control rpc error code [#193](https://github.com/magiclabs/magic-js/pull/193) ([@Dizigen](https://github.com/Dizigen))
322
+
323
+ #### Authors: 1
324
+
325
+ - David He ([@Dizigen](https://github.com/Dizigen))
326
+
327
+ ---
328
+
329
+ # v3.2.0 (Wed Jul 28 2021)
330
+
331
+ #### 🚀 Enhancement
332
+
333
+ - Add explicit JSDelivr entry-point for `magic-sdk` [#191](https://github.com/magiclabs/magic-js/pull/191) ([@smithki](https://github.com/smithki))
334
+
335
+ #### Authors: 1
336
+
337
+ - Ian K Smith ([@smithki](https://github.com/smithki))
338
+
339
+ ---
340
+
341
+ # v3.1.1 (Fri Mar 19 2021)
342
+
343
+ #### 🐛 Bug Fix
344
+
345
+ - register "inactive recipient" rpc error code [#170](https://github.com/magiclabs/magic-js/pull/170) ([@Dizigen](https://github.com/Dizigen))
346
+
347
+ #### Authors: 1
348
+
349
+ - David He ([@Dizigen](https://github.com/Dizigen))
350
+
351
+ ---
352
+
353
+ # v3.1.0 (Mon Mar 15 2021)
354
+
355
+ #### 🚀 Enhancement
356
+
357
+ - Add testing framework [#168](https://github.com/magiclabs/magic-js/pull/168) (harry [@smithki](https://github.com/smithki) [@harryEth](https://github.com/harryEth))
358
+
359
+ #### Authors: 3
360
+
361
+ - [@harryEth](https://github.com/harryEth)
362
+ - harry (harry)
363
+ - Ian K Smith ([@smithki](https://github.com/smithki))
364
+
365
+ ---
366
+
367
+ # v3.0.1 (Tue Dec 01 2020)
368
+
369
+ #### 🐛 Bug Fix
370
+
371
+ - Add 'importHelpers: true' to base tsconfig.json [#152](https://github.com/magiclabs/magic-js/pull/152) ([@smithki](https://github.com/smithki))
372
+
373
+ #### 📝 Documentation
374
+
375
+ - Fix incorrect TypeScript project references and update READMEs with changelog links [#151](https://github.com/magiclabs/magic-js/pull/151) ([@smithki](https://github.com/smithki))
376
+
377
+ #### Authors: 1
378
+
379
+ - Ian K Smith ([@smithki](https://github.com/smithki))
380
+
381
+ ---
382
+
383
+ # v3.0.0 (Tue Nov 17 2020)
384
+
385
+ #### 🐛 Bug Fix
386
+
387
+ - Update CHANGELOGs and CONTRIBUTING guide [#146](https://github.com/magiclabs/magic-js/pull/146) ([@smithki](https://github.com/smithki))
388
+
389
+ #### 🏠 Internal
390
+
391
+ - Simplify scripts [#147](https://github.com/magiclabs/magic-js/pull/147) ([@smithki](https://github.com/smithki))
392
+
393
+ #### Authors: 1
394
+
395
+ - Ian K Smith ([@smithki](https://github.com/smithki))
396
+
397
+ ---
398
+
399
+ ## `2.0.1` - 10/21/2020
400
+
401
+ #### Changed
402
+
403
+ - Removed the following public methods and functions
404
+ - `BaseExtension.utils.encodeQueryParameters`
405
+ - `BaseExtension.utils.decodeQueryParameters`
406
+
407
+ ## `1.6.0` - 09/24/2020
408
+
409
+ #### Added
410
+
411
+ - Adds a Magic SDK extensions runtime compatibility check, ensuring you're version of Magic SDK is designed for the extensions you have in use.
412
+
413
+ ## `1.5.0` - 09/15/2020
414
+
415
+ #### Added
416
+
417
+ - New, optional `redirectURI` parameter for the `loginWithMagicLink` method
418
+ - New `loginWithCredential` method for completing a magic link login with redirect: `await magic.auth.loginWithCredential()`
419
+
420
+ ## `1.4.8` - 08/20/2020
421
+
422
+ #### Added
423
+
424
+ - Updated dependencies
425
+
426
+ ## `1.4.7` - 08/20/2020
427
+
428
+ #### Added
429
+
430
+ - Updated dependencies
431
+
432
+ ## `1.4.6` - 08/20/2020
433
+
434
+ #### Added
435
+
436
+ - New RPC error code for the `loginWithMagicLink` method: `-10005`
437
+
438
+ ## `1.4.5` - 07/22/2020
439
+
440
+ #### Added
441
+
442
+ - Export `PromiEvent` type and `isPromiEvent` utility from SDK entry-points (`magic-sdk` and `@magic-sdk/react-native`).
443
+
444
+ ## `1.4.1` through `1.4.4` - 07/13/2020
445
+
446
+ #### Fixed
447
+
448
+ - Bug preventing NPM tarball from containing `/dist` files.
449
+
450
+ ## `1.4.0` - 07/13/2020
451
+
452
+ #### Changed
453
+
454
+ - Updated build system to use TypeScript project references instead of Microbundle.
455
+ - Pass `targetOrigin` parameter to `postMessage` calls.
456
+
457
+ ## `1.3.1` - 07/08/2020
458
+
459
+ #### Fixed
460
+
461
+ - Bug affecting `localforage` type imports causing compilation failure in TypeScript.
462
+
463
+ ## `1.3.0` - 07/08/2020
464
+
465
+ #### Added
466
+
467
+ - WebAuthn support.
468
+
469
+ ## `1.1.0` - 06/23/2020
470
+
471
+ #### Added
472
+
473
+ - Add `SDKWarningCode.DeprecationNotice`.
474
+
475
+ ## `1.0.3` - 06/23/2020
476
+
477
+ #### Changed
478
+
479
+ - Update dependencies.
480
+
481
+ ## `1.0.2` - 06/12/2020
482
+
483
+ #### Changed
484
+
485
+ - Update dependencies.
486
+ - Circle CI tag in readme is broken after namechange from MagicHQ to MagicLabs
487
+
488
+ ## `1.0.1` - 06/11/2020
489
+
490
+ #### Changed
491
+
492
+ - Update `package.json` description.
493
+
494
+ ## `1.0.0` - 06/02/2020
495
+
496
+ This is the first release our changelog records. Future updates will be logged in the following format:
497
+
498
+ #### Fixed
499
+
500
+ - Bug fixes and patches will be described here.
501
+
502
+ #### Changed
503
+
504
+ - Changes (breaking or otherwise) to current APIs will be described here.
505
+
506
+ #### Added
507
+
508
+ - New features or APIs will be described here.
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../src/index.ts", "../../src/core/exception-types.ts", "../../src/core/json-rpc-types.ts", "../../src/core/message-types.ts", "../../src/modules/rpc-provider-types.ts"],
4
- "sourcesContent": ["// Only re-export types that are intended for the public API from this file.\n// Deprecate test API key in v7.0.0\n\nexport * from './core/exception-types';\nexport * from './core/i18n';\nexport * from './core/json-rpc-types';\nexport * from './core/message-types';\nexport * from './core/query-types';\n\nexport * from './modules/auth-types';\nexport * from './modules/rpc-provider-types';\nexport * from './modules/user-types';\nexport * from './modules/intermediary-types';\n", "export enum SDKErrorCode {\n MissingApiKey = 'MISSING_API_KEY',\n ModalNotReady = 'MODAL_NOT_READY',\n MalformedResponse = 'MALFORMED_RESPONSE',\n InvalidArgument = 'INVALID_ARGUMENT',\n ExtensionNotInitialized = 'EXTENSION_NOT_INITIALIZED',\n IncompatibleExtensions = 'INCOMPATIBLE_EXTENSIONS',\n}\n\nexport enum SDKWarningCode {\n SyncWeb3Method = 'SYNC_WEB3_METHOD',\n DuplicateIframe = 'DUPLICATE_IFRAME',\n ReactNativeEndpointConfiguration = 'REACT_NATIVE_ENDPOINT_CONFIGURATION',\n DeprecationNotice = 'DEPRECATION_NOTICE',\n}\n\nexport enum RPCErrorCode {\n // Standard JSON RPC 2.0 Error Codes\n ParseError = -32700,\n InvalidRequest = -32600,\n MethodNotFound = -32601,\n InvalidParams = -32602,\n InternalError = -32603,\n\n // Custom RPC Error Codes\n MagicLinkFailedVerification = -10000,\n MagicLinkExpired = -10001,\n MagicLinkRateLimited = -10002,\n MagicLinkInvalidRedirectURL = -10006,\n UserAlreadyLoggedIn = -10003,\n UpdateEmailFailed = -10004,\n UserRequestEditEmail = -10005,\n InactiveRecipient = -10010,\n AccessDeniedToUser = -10011,\n}\n\nexport type ErrorCode = SDKErrorCode | RPCErrorCode;\nexport type WarningCode = SDKWarningCode;\n", "import { RPCErrorCode } from './exception-types';\n\n// --- Request interfaces\n\nexport interface JsonRpcRequestPayload<TParams = any> {\n jsonrpc: string;\n id: string | number | null;\n method: string;\n params?: TParams;\n}\n\nexport interface JsonRpcRequestCallback {\n /** Callback executed upon JSON RPC response. */\n (err: JsonRpcError | null, result?: JsonRpcResponsePayload | null): void;\n}\n\nexport interface JsonRpcBatchRequestCallback {\n /** Callback executed upon JSON RPC response. */\n (err: JsonRpcError | null, result?: (JsonRpcResponsePayload | null)[] | null): void;\n}\n\n// --- Response interfaces\n\nexport interface JsonRpcError {\n message: string;\n code: RPCErrorCode;\n}\n\nexport interface JsonRpcResponsePayload<ResultType = any> {\n jsonrpc: string;\n id: string | number | null;\n result?: ResultType | null;\n error?: JsonRpcError | null;\n}\n\nexport interface UserInfo {\n email?: string;\n}\n\nexport interface WalletInfo {\n walletType: 'magic' | 'metamask' | 'coinbase_wallet' | 'wallet_connect';\n}\n\nexport interface RequestUserInfoScope {\n email?: 'required' | 'optional';\n}\n\n// --- Payload methods\n\n/**\n * Enum of JSON RPC methods for interacting with the Magic SDK authentication\n * relayer.\n */\nexport enum MagicPayloadMethod {\n LoginWithSms = 'magic_auth_login_with_sms',\n LoginWithEmailOTP = 'magic_auth_login_with_email_otp',\n LoginWithMagicLink = 'magic_auth_login_with_magic_link',\n LoginWithCredential = 'magic_auth_login_with_credential',\n GetIdToken = 'magic_auth_get_id_token',\n GenerateIdToken = 'magic_auth_generate_id_token',\n GetMetadata = 'magic_auth_get_metadata',\n IsLoggedIn = 'magic_auth_is_logged_in',\n Logout = 'magic_auth_logout',\n UpdateEmail = 'magic_auth_update_email',\n UserSettings = 'magic_auth_settings',\n UserSettingsTestMode = 'magic_auth_settings_testing_mode',\n LoginWithSmsTestMode = 'magic_auth_login_with_sms_testing_mode',\n LoginWithEmailOTPTestMode = 'magic_auth_login_with_email_otp_testing_mode',\n LoginWithMagicLinkTestMode = 'magic_login_with_magic_link_testing_mode',\n LoginWithCredentialTestMode = 'magic_auth_login_with_credential_testing_mode',\n GetIdTokenTestMode = 'magic_auth_get_id_token_testing_mode',\n GenerateIdTokenTestMode = 'magic_auth_generate_id_token_testing_mode',\n GetMetadataTestMode = 'magic_auth_get_metadata_testing_mode',\n IsLoggedInTestMode = 'magic_auth_is_logged_in_testing_mode',\n LogoutTestMode = 'magic_auth_logout_testing_mode',\n UpdateEmailTestMode = 'magic_auth_update_email_testing_mode',\n IntermediaryEvent = 'magic_intermediary_event',\n RequestAccounts = 'eth_requestAccounts',\n GetInfo = 'mc_get_wallet_info',\n ShowUI = 'mc_wallet',\n RequestUserInfoWithUI = 'mc_request_user_info',\n Disconnect = 'mc_disconnect',\n}\n", "import { JsonRpcResponsePayload, JsonRpcError, JsonRpcRequestPayload } from './json-rpc-types';\n\nexport enum MagicIncomingWindowMessage {\n MAGIC_HANDLE_RESPONSE = 'MAGIC_HANDLE_RESPONSE',\n MAGIC_OVERLAY_READY = 'MAGIC_OVERLAY_READY',\n MAGIC_SHOW_OVERLAY = 'MAGIC_SHOW_OVERLAY',\n MAGIC_HIDE_OVERLAY = 'MAGIC_HIDE_OVERLAY',\n MAGIC_HANDLE_EVENT = 'MAGIC_HANDLE_EVENT',\n}\n\nexport enum MagicOutgoingWindowMessage {\n MAGIC_HANDLE_REQUEST = 'MAGIC_HANDLE_REQUEST',\n}\n\n/** The shape of responding window message datas from the Magic iframe context. */\nexport interface MagicMessageRequest {\n msgType: string;\n payload: JsonRpcRequestPayload | JsonRpcRequestPayload[];\n rt?: string;\n jwt?: string;\n}\n\n/** The shape of responding window message datas from the Magic iframe context. */\nexport interface MagicMessageResponse<ResultType = any> {\n msgType: string;\n response: Partial<JsonRpcError> & Partial<JsonRpcResponsePayload<ResultType>>;\n rt?: string;\n}\n\n/** The expected message event returned by the Magic iframe context. */\nexport interface MagicMessageEvent extends Partial<MessageEvent> {\n data: MagicMessageResponse;\n}\n", "export type EthNetworkName = 'mainnet' | 'goerli';\n\nexport enum EthChainType {\n Harmony = 'HARMONY',\n}\n\nexport interface CustomNodeConfiguration {\n rpcUrl: string;\n chainId?: number;\n chainType?: EthChainType;\n}\n\nexport type EthNetworkConfiguration = EthNetworkName | CustomNodeConfiguration;\n"],
5
- "mappings": "yaAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,kBAAAE,EAAA,+BAAAC,EAAA,+BAAAC,EAAA,uBAAAC,EAAA,iBAAAC,EAAA,iBAAAC,EAAA,mBAAAC,IAAA,eAAAC,EAAAT,GCAO,IAAKU,OACVA,EAAA,cAAgB,kBAChBA,EAAA,cAAgB,kBAChBA,EAAA,kBAAoB,qBACpBA,EAAA,gBAAkB,mBAClBA,EAAA,wBAA0B,4BAC1BA,EAAA,uBAAyB,0BANfA,OAAA,IASAC,OACVA,EAAA,eAAiB,mBACjBA,EAAA,gBAAkB,mBAClBA,EAAA,iCAAmC,sCACnCA,EAAA,kBAAoB,qBAJVA,OAAA,IAOAC,OAEVA,IAAA,WAAa,QAAb,aACAA,IAAA,eAAiB,QAAjB,iBACAA,IAAA,eAAiB,QAAjB,iBACAA,IAAA,cAAgB,QAAhB,gBACAA,IAAA,cAAgB,QAAhB,gBAGAA,IAAA,4BAA8B,MAA9B,8BACAA,IAAA,iBAAmB,QAAnB,mBACAA,IAAA,qBAAuB,QAAvB,uBACAA,IAAA,4BAA8B,QAA9B,8BACAA,IAAA,oBAAsB,QAAtB,sBACAA,IAAA,kBAAoB,QAApB,oBACAA,IAAA,qBAAuB,QAAvB,uBACAA,IAAA,kBAAoB,QAApB,oBACAA,IAAA,mBAAqB,QAArB,qBAjBUA,OAAA,ICqCL,IAAKC,OACVA,EAAA,aAAe,4BACfA,EAAA,kBAAoB,kCACpBA,EAAA,mBAAqB,mCACrBA,EAAA,oBAAsB,mCACtBA,EAAA,WAAa,0BACbA,EAAA,gBAAkB,+BAClBA,EAAA,YAAc,0BACdA,EAAA,WAAa,0BACbA,EAAA,OAAS,oBACTA,EAAA,YAAc,0BACdA,EAAA,aAAe,sBACfA,EAAA,qBAAuB,mCACvBA,EAAA,qBAAuB,yCACvBA,EAAA,0BAA4B,+CAC5BA,EAAA,2BAA6B,2CAC7BA,EAAA,4BAA8B,gDAC9BA,EAAA,mBAAqB,uCACrBA,EAAA,wBAA0B,4CAC1BA,EAAA,oBAAsB,uCACtBA,EAAA,mBAAqB,uCACrBA,EAAA,eAAiB,iCACjBA,EAAA,oBAAsB,uCACtBA,EAAA,kBAAoB,2BACpBA,EAAA,gBAAkB,sBAClBA,EAAA,QAAU,qBACVA,EAAA,OAAS,YACTA,EAAA,sBAAwB,uBACxBA,EAAA,WAAa,gBA5BHA,OAAA,ICnDL,IAAKC,OACVA,EAAA,sBAAwB,wBACxBA,EAAA,oBAAsB,sBACtBA,EAAA,mBAAqB,qBACrBA,EAAA,mBAAqB,qBACrBA,EAAA,mBAAqB,qBALXA,OAAA,IAQAC,OACVA,EAAA,qBAAuB,uBADbA,OAAA,ICRL,IAAKC,OACVA,EAAA,QAAU,UADAA,OAAA",
4
+ "sourcesContent": ["// Only re-export types that are intended for the public API from this file.\n// Deprecate test API key in v7.0.0\n\nexport * from './core/exception-types';\nexport * from './core/i18n';\nexport * from './core/json-rpc-types';\nexport * from './core/message-types';\nexport * from './core/query-types';\n\nexport * from './modules/auth-types';\nexport * from './modules/rpc-provider-types';\nexport * from './modules/user-types';\nexport * from './modules/intermediary-types';\n", "export enum SDKErrorCode {\n MissingApiKey = 'MISSING_API_KEY',\n ModalNotReady = 'MODAL_NOT_READY',\n MalformedResponse = 'MALFORMED_RESPONSE',\n InvalidArgument = 'INVALID_ARGUMENT',\n ExtensionNotInitialized = 'EXTENSION_NOT_INITIALIZED',\n IncompatibleExtensions = 'INCOMPATIBLE_EXTENSIONS',\n}\n\nexport enum SDKWarningCode {\n SyncWeb3Method = 'SYNC_WEB3_METHOD',\n DuplicateIframe = 'DUPLICATE_IFRAME',\n ReactNativeEndpointConfiguration = 'REACT_NATIVE_ENDPOINT_CONFIGURATION',\n DeprecationNotice = 'DEPRECATION_NOTICE',\n}\n\nexport enum RPCErrorCode {\n // Standard JSON RPC 2.0 Error Codes\n ParseError = -32700,\n InvalidRequest = -32600,\n MethodNotFound = -32601,\n InvalidParams = -32602,\n InternalError = -32603,\n\n // Custom RPC Error Codes\n MagicLinkFailedVerification = -10000,\n MagicLinkExpired = -10001,\n MagicLinkRateLimited = -10002,\n MagicLinkInvalidRedirectURL = -10006,\n UserAlreadyLoggedIn = -10003,\n UpdateEmailFailed = -10004,\n UserRequestEditEmail = -10005,\n InactiveRecipient = -10010,\n AccessDeniedToUser = -10011,\n}\n\nexport type ErrorCode = SDKErrorCode | RPCErrorCode;\nexport type WarningCode = SDKWarningCode;\n", "import { RPCErrorCode } from './exception-types';\n\n// --- Request interfaces\n\nexport interface JsonRpcRequestPayload<TParams = any> {\n jsonrpc: string;\n id: string | number | null;\n method: string;\n params?: TParams;\n}\n\nexport interface JsonRpcRequestCallback {\n /** Callback executed upon JSON RPC response. */\n (err: JsonRpcError | null, result?: JsonRpcResponsePayload | null): void;\n}\n\nexport interface JsonRpcBatchRequestCallback {\n /** Callback executed upon JSON RPC response. */\n (err: JsonRpcError | null, result?: (JsonRpcResponsePayload | null)[] | null): void;\n}\n\n// --- Response interfaces\n\nexport interface JsonRpcError {\n message: string;\n code: RPCErrorCode;\n}\n\nexport interface JsonRpcResponsePayload<ResultType = any> {\n jsonrpc: string;\n id: string | number | null;\n result?: ResultType | null;\n error?: JsonRpcError | null;\n}\n\nexport interface UserInfo {\n email?: string;\n}\n\nexport interface WalletInfo {\n walletType: 'magic' | 'metamask' | 'coinbase_wallet' | 'wallet_connect';\n}\n\nexport interface RequestUserInfoScope {\n scope?: {\n email?: 'required' | 'optional';\n };\n}\n\n// --- Payload methods\n\n/**\n * Enum of JSON RPC methods for interacting with the Magic SDK authentication\n * relayer.\n */\nexport enum MagicPayloadMethod {\n LoginWithSms = 'magic_auth_login_with_sms',\n LoginWithEmailOTP = 'magic_auth_login_with_email_otp',\n LoginWithMagicLink = 'magic_auth_login_with_magic_link',\n LoginWithCredential = 'magic_auth_login_with_credential',\n GetIdToken = 'magic_auth_get_id_token',\n GenerateIdToken = 'magic_auth_generate_id_token',\n GetMetadata = 'magic_auth_get_metadata',\n IsLoggedIn = 'magic_auth_is_logged_in',\n Logout = 'magic_auth_logout',\n UpdateEmail = 'magic_auth_update_email',\n UserSettings = 'magic_auth_settings',\n UserSettingsTestMode = 'magic_auth_settings_testing_mode',\n LoginWithSmsTestMode = 'magic_auth_login_with_sms_testing_mode',\n LoginWithEmailOTPTestMode = 'magic_auth_login_with_email_otp_testing_mode',\n LoginWithMagicLinkTestMode = 'magic_login_with_magic_link_testing_mode',\n LoginWithCredentialTestMode = 'magic_auth_login_with_credential_testing_mode',\n GetIdTokenTestMode = 'magic_auth_get_id_token_testing_mode',\n GenerateIdTokenTestMode = 'magic_auth_generate_id_token_testing_mode',\n GetMetadataTestMode = 'magic_auth_get_metadata_testing_mode',\n IsLoggedInTestMode = 'magic_auth_is_logged_in_testing_mode',\n LogoutTestMode = 'magic_auth_logout_testing_mode',\n UpdateEmailTestMode = 'magic_auth_update_email_testing_mode',\n IntermediaryEvent = 'magic_intermediary_event',\n RequestAccounts = 'eth_requestAccounts',\n GetInfo = 'mc_get_wallet_info',\n ShowUI = 'mc_wallet',\n RequestUserInfoWithUI = 'mc_request_user_info',\n Disconnect = 'mc_disconnect',\n}\n", "import { JsonRpcResponsePayload, JsonRpcError, JsonRpcRequestPayload } from './json-rpc-types';\n\nexport enum MagicIncomingWindowMessage {\n MAGIC_HANDLE_RESPONSE = 'MAGIC_HANDLE_RESPONSE',\n MAGIC_OVERLAY_READY = 'MAGIC_OVERLAY_READY',\n MAGIC_SHOW_OVERLAY = 'MAGIC_SHOW_OVERLAY',\n MAGIC_HIDE_OVERLAY = 'MAGIC_HIDE_OVERLAY',\n MAGIC_HANDLE_EVENT = 'MAGIC_HANDLE_EVENT',\n}\n\nexport enum MagicOutgoingWindowMessage {\n MAGIC_HANDLE_REQUEST = 'MAGIC_HANDLE_REQUEST',\n}\n\n/** The shape of responding window message datas from the Magic iframe context. */\nexport interface MagicMessageRequest {\n msgType: string;\n payload: JsonRpcRequestPayload | JsonRpcRequestPayload[];\n rt?: string;\n jwt?: string;\n}\n\n/** The shape of responding window message datas from the Magic iframe context. */\nexport interface MagicMessageResponse<ResultType = any> {\n msgType: string;\n response: Partial<JsonRpcError> & Partial<JsonRpcResponsePayload<ResultType>>;\n rt?: string;\n}\n\n/** The expected message event returned by the Magic iframe context. */\nexport interface MagicMessageEvent extends Partial<MessageEvent> {\n data: MagicMessageResponse;\n}\n", "export type EthNetworkName = 'mainnet' | 'goerli';\n\nexport enum EthChainType {\n Harmony = 'HARMONY',\n}\n\nexport interface CustomNodeConfiguration {\n rpcUrl: string;\n chainId?: number;\n chainType?: EthChainType;\n}\n\nexport type EthNetworkConfiguration = EthNetworkName | CustomNodeConfiguration;\n"],
5
+ "mappings": "yaAAA,IAAAA,EAAA,GAAAC,EAAAD,EAAA,kBAAAE,EAAA,+BAAAC,EAAA,+BAAAC,EAAA,uBAAAC,EAAA,iBAAAC,EAAA,iBAAAC,EAAA,mBAAAC,IAAA,eAAAC,EAAAT,GCAO,IAAKU,OACVA,EAAA,cAAgB,kBAChBA,EAAA,cAAgB,kBAChBA,EAAA,kBAAoB,qBACpBA,EAAA,gBAAkB,mBAClBA,EAAA,wBAA0B,4BAC1BA,EAAA,uBAAyB,0BANfA,OAAA,IASAC,OACVA,EAAA,eAAiB,mBACjBA,EAAA,gBAAkB,mBAClBA,EAAA,iCAAmC,sCACnCA,EAAA,kBAAoB,qBAJVA,OAAA,IAOAC,OAEVA,IAAA,WAAa,QAAb,aACAA,IAAA,eAAiB,QAAjB,iBACAA,IAAA,eAAiB,QAAjB,iBACAA,IAAA,cAAgB,QAAhB,gBACAA,IAAA,cAAgB,QAAhB,gBAGAA,IAAA,4BAA8B,MAA9B,8BACAA,IAAA,iBAAmB,QAAnB,mBACAA,IAAA,qBAAuB,QAAvB,uBACAA,IAAA,4BAA8B,QAA9B,8BACAA,IAAA,oBAAsB,QAAtB,sBACAA,IAAA,kBAAoB,QAApB,oBACAA,IAAA,qBAAuB,QAAvB,uBACAA,IAAA,kBAAoB,QAApB,oBACAA,IAAA,mBAAqB,QAArB,qBAjBUA,OAAA,ICuCL,IAAKC,OACVA,EAAA,aAAe,4BACfA,EAAA,kBAAoB,kCACpBA,EAAA,mBAAqB,mCACrBA,EAAA,oBAAsB,mCACtBA,EAAA,WAAa,0BACbA,EAAA,gBAAkB,+BAClBA,EAAA,YAAc,0BACdA,EAAA,WAAa,0BACbA,EAAA,OAAS,oBACTA,EAAA,YAAc,0BACdA,EAAA,aAAe,sBACfA,EAAA,qBAAuB,mCACvBA,EAAA,qBAAuB,yCACvBA,EAAA,0BAA4B,+CAC5BA,EAAA,2BAA6B,2CAC7BA,EAAA,4BAA8B,gDAC9BA,EAAA,mBAAqB,uCACrBA,EAAA,wBAA0B,4CAC1BA,EAAA,oBAAsB,uCACtBA,EAAA,mBAAqB,uCACrBA,EAAA,eAAiB,iCACjBA,EAAA,oBAAsB,uCACtBA,EAAA,kBAAoB,2BACpBA,EAAA,gBAAkB,sBAClBA,EAAA,QAAU,qBACVA,EAAA,OAAS,YACTA,EAAA,sBAAwB,uBACxBA,EAAA,WAAa,gBA5BHA,OAAA,ICrDL,IAAKC,OACVA,EAAA,sBAAwB,wBACxBA,EAAA,oBAAsB,sBACtBA,EAAA,mBAAqB,qBACrBA,EAAA,mBAAqB,qBACrBA,EAAA,mBAAqB,qBALXA,OAAA,IAQAC,OACVA,EAAA,qBAAuB,uBADbA,OAAA,ICRL,IAAKC,OACVA,EAAA,QAAU,UADAA,OAAA",
6
6
  "names": ["src_exports", "__export", "EthChainType", "MagicIncomingWindowMessage", "MagicOutgoingWindowMessage", "MagicPayloadMethod", "RPCErrorCode", "SDKErrorCode", "SDKWarningCode", "__toCommonJS", "SDKErrorCode", "SDKWarningCode", "RPCErrorCode", "MagicPayloadMethod", "MagicIncomingWindowMessage", "MagicOutgoingWindowMessage", "EthChainType"]
7
7
  }
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../src/core/exception-types.ts", "../../src/core/json-rpc-types.ts", "../../src/core/message-types.ts", "../../src/modules/rpc-provider-types.ts"],
4
- "sourcesContent": ["export enum SDKErrorCode {\n MissingApiKey = 'MISSING_API_KEY',\n ModalNotReady = 'MODAL_NOT_READY',\n MalformedResponse = 'MALFORMED_RESPONSE',\n InvalidArgument = 'INVALID_ARGUMENT',\n ExtensionNotInitialized = 'EXTENSION_NOT_INITIALIZED',\n IncompatibleExtensions = 'INCOMPATIBLE_EXTENSIONS',\n}\n\nexport enum SDKWarningCode {\n SyncWeb3Method = 'SYNC_WEB3_METHOD',\n DuplicateIframe = 'DUPLICATE_IFRAME',\n ReactNativeEndpointConfiguration = 'REACT_NATIVE_ENDPOINT_CONFIGURATION',\n DeprecationNotice = 'DEPRECATION_NOTICE',\n}\n\nexport enum RPCErrorCode {\n // Standard JSON RPC 2.0 Error Codes\n ParseError = -32700,\n InvalidRequest = -32600,\n MethodNotFound = -32601,\n InvalidParams = -32602,\n InternalError = -32603,\n\n // Custom RPC Error Codes\n MagicLinkFailedVerification = -10000,\n MagicLinkExpired = -10001,\n MagicLinkRateLimited = -10002,\n MagicLinkInvalidRedirectURL = -10006,\n UserAlreadyLoggedIn = -10003,\n UpdateEmailFailed = -10004,\n UserRequestEditEmail = -10005,\n InactiveRecipient = -10010,\n AccessDeniedToUser = -10011,\n}\n\nexport type ErrorCode = SDKErrorCode | RPCErrorCode;\nexport type WarningCode = SDKWarningCode;\n", "import { RPCErrorCode } from './exception-types';\n\n// --- Request interfaces\n\nexport interface JsonRpcRequestPayload<TParams = any> {\n jsonrpc: string;\n id: string | number | null;\n method: string;\n params?: TParams;\n}\n\nexport interface JsonRpcRequestCallback {\n /** Callback executed upon JSON RPC response. */\n (err: JsonRpcError | null, result?: JsonRpcResponsePayload | null): void;\n}\n\nexport interface JsonRpcBatchRequestCallback {\n /** Callback executed upon JSON RPC response. */\n (err: JsonRpcError | null, result?: (JsonRpcResponsePayload | null)[] | null): void;\n}\n\n// --- Response interfaces\n\nexport interface JsonRpcError {\n message: string;\n code: RPCErrorCode;\n}\n\nexport interface JsonRpcResponsePayload<ResultType = any> {\n jsonrpc: string;\n id: string | number | null;\n result?: ResultType | null;\n error?: JsonRpcError | null;\n}\n\nexport interface UserInfo {\n email?: string;\n}\n\nexport interface WalletInfo {\n walletType: 'magic' | 'metamask' | 'coinbase_wallet' | 'wallet_connect';\n}\n\nexport interface RequestUserInfoScope {\n email?: 'required' | 'optional';\n}\n\n// --- Payload methods\n\n/**\n * Enum of JSON RPC methods for interacting with the Magic SDK authentication\n * relayer.\n */\nexport enum MagicPayloadMethod {\n LoginWithSms = 'magic_auth_login_with_sms',\n LoginWithEmailOTP = 'magic_auth_login_with_email_otp',\n LoginWithMagicLink = 'magic_auth_login_with_magic_link',\n LoginWithCredential = 'magic_auth_login_with_credential',\n GetIdToken = 'magic_auth_get_id_token',\n GenerateIdToken = 'magic_auth_generate_id_token',\n GetMetadata = 'magic_auth_get_metadata',\n IsLoggedIn = 'magic_auth_is_logged_in',\n Logout = 'magic_auth_logout',\n UpdateEmail = 'magic_auth_update_email',\n UserSettings = 'magic_auth_settings',\n UserSettingsTestMode = 'magic_auth_settings_testing_mode',\n LoginWithSmsTestMode = 'magic_auth_login_with_sms_testing_mode',\n LoginWithEmailOTPTestMode = 'magic_auth_login_with_email_otp_testing_mode',\n LoginWithMagicLinkTestMode = 'magic_login_with_magic_link_testing_mode',\n LoginWithCredentialTestMode = 'magic_auth_login_with_credential_testing_mode',\n GetIdTokenTestMode = 'magic_auth_get_id_token_testing_mode',\n GenerateIdTokenTestMode = 'magic_auth_generate_id_token_testing_mode',\n GetMetadataTestMode = 'magic_auth_get_metadata_testing_mode',\n IsLoggedInTestMode = 'magic_auth_is_logged_in_testing_mode',\n LogoutTestMode = 'magic_auth_logout_testing_mode',\n UpdateEmailTestMode = 'magic_auth_update_email_testing_mode',\n IntermediaryEvent = 'magic_intermediary_event',\n RequestAccounts = 'eth_requestAccounts',\n GetInfo = 'mc_get_wallet_info',\n ShowUI = 'mc_wallet',\n RequestUserInfoWithUI = 'mc_request_user_info',\n Disconnect = 'mc_disconnect',\n}\n", "import { JsonRpcResponsePayload, JsonRpcError, JsonRpcRequestPayload } from './json-rpc-types';\n\nexport enum MagicIncomingWindowMessage {\n MAGIC_HANDLE_RESPONSE = 'MAGIC_HANDLE_RESPONSE',\n MAGIC_OVERLAY_READY = 'MAGIC_OVERLAY_READY',\n MAGIC_SHOW_OVERLAY = 'MAGIC_SHOW_OVERLAY',\n MAGIC_HIDE_OVERLAY = 'MAGIC_HIDE_OVERLAY',\n MAGIC_HANDLE_EVENT = 'MAGIC_HANDLE_EVENT',\n}\n\nexport enum MagicOutgoingWindowMessage {\n MAGIC_HANDLE_REQUEST = 'MAGIC_HANDLE_REQUEST',\n}\n\n/** The shape of responding window message datas from the Magic iframe context. */\nexport interface MagicMessageRequest {\n msgType: string;\n payload: JsonRpcRequestPayload | JsonRpcRequestPayload[];\n rt?: string;\n jwt?: string;\n}\n\n/** The shape of responding window message datas from the Magic iframe context. */\nexport interface MagicMessageResponse<ResultType = any> {\n msgType: string;\n response: Partial<JsonRpcError> & Partial<JsonRpcResponsePayload<ResultType>>;\n rt?: string;\n}\n\n/** The expected message event returned by the Magic iframe context. */\nexport interface MagicMessageEvent extends Partial<MessageEvent> {\n data: MagicMessageResponse;\n}\n", "export type EthNetworkName = 'mainnet' | 'goerli';\n\nexport enum EthChainType {\n Harmony = 'HARMONY',\n}\n\nexport interface CustomNodeConfiguration {\n rpcUrl: string;\n chainId?: number;\n chainType?: EthChainType;\n}\n\nexport type EthNetworkConfiguration = EthNetworkName | CustomNodeConfiguration;\n"],
5
- "mappings": "AAAO,IAAKA,OACVA,EAAA,cAAgB,kBAChBA,EAAA,cAAgB,kBAChBA,EAAA,kBAAoB,qBACpBA,EAAA,gBAAkB,mBAClBA,EAAA,wBAA0B,4BAC1BA,EAAA,uBAAyB,0BANfA,OAAA,IASAC,OACVA,EAAA,eAAiB,mBACjBA,EAAA,gBAAkB,mBAClBA,EAAA,iCAAmC,sCACnCA,EAAA,kBAAoB,qBAJVA,OAAA,IAOAC,OAEVA,IAAA,WAAa,QAAb,aACAA,IAAA,eAAiB,QAAjB,iBACAA,IAAA,eAAiB,QAAjB,iBACAA,IAAA,cAAgB,QAAhB,gBACAA,IAAA,cAAgB,QAAhB,gBAGAA,IAAA,4BAA8B,MAA9B,8BACAA,IAAA,iBAAmB,QAAnB,mBACAA,IAAA,qBAAuB,QAAvB,uBACAA,IAAA,4BAA8B,QAA9B,8BACAA,IAAA,oBAAsB,QAAtB,sBACAA,IAAA,kBAAoB,QAApB,oBACAA,IAAA,qBAAuB,QAAvB,uBACAA,IAAA,kBAAoB,QAApB,oBACAA,IAAA,mBAAqB,QAArB,qBAjBUA,OAAA,ICqCL,IAAKC,OACVA,EAAA,aAAe,4BACfA,EAAA,kBAAoB,kCACpBA,EAAA,mBAAqB,mCACrBA,EAAA,oBAAsB,mCACtBA,EAAA,WAAa,0BACbA,EAAA,gBAAkB,+BAClBA,EAAA,YAAc,0BACdA,EAAA,WAAa,0BACbA,EAAA,OAAS,oBACTA,EAAA,YAAc,0BACdA,EAAA,aAAe,sBACfA,EAAA,qBAAuB,mCACvBA,EAAA,qBAAuB,yCACvBA,EAAA,0BAA4B,+CAC5BA,EAAA,2BAA6B,2CAC7BA,EAAA,4BAA8B,gDAC9BA,EAAA,mBAAqB,uCACrBA,EAAA,wBAA0B,4CAC1BA,EAAA,oBAAsB,uCACtBA,EAAA,mBAAqB,uCACrBA,EAAA,eAAiB,iCACjBA,EAAA,oBAAsB,uCACtBA,EAAA,kBAAoB,2BACpBA,EAAA,gBAAkB,sBAClBA,EAAA,QAAU,qBACVA,EAAA,OAAS,YACTA,EAAA,sBAAwB,uBACxBA,EAAA,WAAa,gBA5BHA,OAAA,ICnDL,IAAKC,OACVA,EAAA,sBAAwB,wBACxBA,EAAA,oBAAsB,sBACtBA,EAAA,mBAAqB,qBACrBA,EAAA,mBAAqB,qBACrBA,EAAA,mBAAqB,qBALXA,OAAA,IAQAC,OACVA,EAAA,qBAAuB,uBADbA,OAAA,ICRL,IAAKC,OACVA,EAAA,QAAU,UADAA,OAAA",
4
+ "sourcesContent": ["export enum SDKErrorCode {\n MissingApiKey = 'MISSING_API_KEY',\n ModalNotReady = 'MODAL_NOT_READY',\n MalformedResponse = 'MALFORMED_RESPONSE',\n InvalidArgument = 'INVALID_ARGUMENT',\n ExtensionNotInitialized = 'EXTENSION_NOT_INITIALIZED',\n IncompatibleExtensions = 'INCOMPATIBLE_EXTENSIONS',\n}\n\nexport enum SDKWarningCode {\n SyncWeb3Method = 'SYNC_WEB3_METHOD',\n DuplicateIframe = 'DUPLICATE_IFRAME',\n ReactNativeEndpointConfiguration = 'REACT_NATIVE_ENDPOINT_CONFIGURATION',\n DeprecationNotice = 'DEPRECATION_NOTICE',\n}\n\nexport enum RPCErrorCode {\n // Standard JSON RPC 2.0 Error Codes\n ParseError = -32700,\n InvalidRequest = -32600,\n MethodNotFound = -32601,\n InvalidParams = -32602,\n InternalError = -32603,\n\n // Custom RPC Error Codes\n MagicLinkFailedVerification = -10000,\n MagicLinkExpired = -10001,\n MagicLinkRateLimited = -10002,\n MagicLinkInvalidRedirectURL = -10006,\n UserAlreadyLoggedIn = -10003,\n UpdateEmailFailed = -10004,\n UserRequestEditEmail = -10005,\n InactiveRecipient = -10010,\n AccessDeniedToUser = -10011,\n}\n\nexport type ErrorCode = SDKErrorCode | RPCErrorCode;\nexport type WarningCode = SDKWarningCode;\n", "import { RPCErrorCode } from './exception-types';\n\n// --- Request interfaces\n\nexport interface JsonRpcRequestPayload<TParams = any> {\n jsonrpc: string;\n id: string | number | null;\n method: string;\n params?: TParams;\n}\n\nexport interface JsonRpcRequestCallback {\n /** Callback executed upon JSON RPC response. */\n (err: JsonRpcError | null, result?: JsonRpcResponsePayload | null): void;\n}\n\nexport interface JsonRpcBatchRequestCallback {\n /** Callback executed upon JSON RPC response. */\n (err: JsonRpcError | null, result?: (JsonRpcResponsePayload | null)[] | null): void;\n}\n\n// --- Response interfaces\n\nexport interface JsonRpcError {\n message: string;\n code: RPCErrorCode;\n}\n\nexport interface JsonRpcResponsePayload<ResultType = any> {\n jsonrpc: string;\n id: string | number | null;\n result?: ResultType | null;\n error?: JsonRpcError | null;\n}\n\nexport interface UserInfo {\n email?: string;\n}\n\nexport interface WalletInfo {\n walletType: 'magic' | 'metamask' | 'coinbase_wallet' | 'wallet_connect';\n}\n\nexport interface RequestUserInfoScope {\n scope?: {\n email?: 'required' | 'optional';\n };\n}\n\n// --- Payload methods\n\n/**\n * Enum of JSON RPC methods for interacting with the Magic SDK authentication\n * relayer.\n */\nexport enum MagicPayloadMethod {\n LoginWithSms = 'magic_auth_login_with_sms',\n LoginWithEmailOTP = 'magic_auth_login_with_email_otp',\n LoginWithMagicLink = 'magic_auth_login_with_magic_link',\n LoginWithCredential = 'magic_auth_login_with_credential',\n GetIdToken = 'magic_auth_get_id_token',\n GenerateIdToken = 'magic_auth_generate_id_token',\n GetMetadata = 'magic_auth_get_metadata',\n IsLoggedIn = 'magic_auth_is_logged_in',\n Logout = 'magic_auth_logout',\n UpdateEmail = 'magic_auth_update_email',\n UserSettings = 'magic_auth_settings',\n UserSettingsTestMode = 'magic_auth_settings_testing_mode',\n LoginWithSmsTestMode = 'magic_auth_login_with_sms_testing_mode',\n LoginWithEmailOTPTestMode = 'magic_auth_login_with_email_otp_testing_mode',\n LoginWithMagicLinkTestMode = 'magic_login_with_magic_link_testing_mode',\n LoginWithCredentialTestMode = 'magic_auth_login_with_credential_testing_mode',\n GetIdTokenTestMode = 'magic_auth_get_id_token_testing_mode',\n GenerateIdTokenTestMode = 'magic_auth_generate_id_token_testing_mode',\n GetMetadataTestMode = 'magic_auth_get_metadata_testing_mode',\n IsLoggedInTestMode = 'magic_auth_is_logged_in_testing_mode',\n LogoutTestMode = 'magic_auth_logout_testing_mode',\n UpdateEmailTestMode = 'magic_auth_update_email_testing_mode',\n IntermediaryEvent = 'magic_intermediary_event',\n RequestAccounts = 'eth_requestAccounts',\n GetInfo = 'mc_get_wallet_info',\n ShowUI = 'mc_wallet',\n RequestUserInfoWithUI = 'mc_request_user_info',\n Disconnect = 'mc_disconnect',\n}\n", "import { JsonRpcResponsePayload, JsonRpcError, JsonRpcRequestPayload } from './json-rpc-types';\n\nexport enum MagicIncomingWindowMessage {\n MAGIC_HANDLE_RESPONSE = 'MAGIC_HANDLE_RESPONSE',\n MAGIC_OVERLAY_READY = 'MAGIC_OVERLAY_READY',\n MAGIC_SHOW_OVERLAY = 'MAGIC_SHOW_OVERLAY',\n MAGIC_HIDE_OVERLAY = 'MAGIC_HIDE_OVERLAY',\n MAGIC_HANDLE_EVENT = 'MAGIC_HANDLE_EVENT',\n}\n\nexport enum MagicOutgoingWindowMessage {\n MAGIC_HANDLE_REQUEST = 'MAGIC_HANDLE_REQUEST',\n}\n\n/** The shape of responding window message datas from the Magic iframe context. */\nexport interface MagicMessageRequest {\n msgType: string;\n payload: JsonRpcRequestPayload | JsonRpcRequestPayload[];\n rt?: string;\n jwt?: string;\n}\n\n/** The shape of responding window message datas from the Magic iframe context. */\nexport interface MagicMessageResponse<ResultType = any> {\n msgType: string;\n response: Partial<JsonRpcError> & Partial<JsonRpcResponsePayload<ResultType>>;\n rt?: string;\n}\n\n/** The expected message event returned by the Magic iframe context. */\nexport interface MagicMessageEvent extends Partial<MessageEvent> {\n data: MagicMessageResponse;\n}\n", "export type EthNetworkName = 'mainnet' | 'goerli';\n\nexport enum EthChainType {\n Harmony = 'HARMONY',\n}\n\nexport interface CustomNodeConfiguration {\n rpcUrl: string;\n chainId?: number;\n chainType?: EthChainType;\n}\n\nexport type EthNetworkConfiguration = EthNetworkName | CustomNodeConfiguration;\n"],
5
+ "mappings": "AAAO,IAAKA,OACVA,EAAA,cAAgB,kBAChBA,EAAA,cAAgB,kBAChBA,EAAA,kBAAoB,qBACpBA,EAAA,gBAAkB,mBAClBA,EAAA,wBAA0B,4BAC1BA,EAAA,uBAAyB,0BANfA,OAAA,IASAC,OACVA,EAAA,eAAiB,mBACjBA,EAAA,gBAAkB,mBAClBA,EAAA,iCAAmC,sCACnCA,EAAA,kBAAoB,qBAJVA,OAAA,IAOAC,OAEVA,IAAA,WAAa,QAAb,aACAA,IAAA,eAAiB,QAAjB,iBACAA,IAAA,eAAiB,QAAjB,iBACAA,IAAA,cAAgB,QAAhB,gBACAA,IAAA,cAAgB,QAAhB,gBAGAA,IAAA,4BAA8B,MAA9B,8BACAA,IAAA,iBAAmB,QAAnB,mBACAA,IAAA,qBAAuB,QAAvB,uBACAA,IAAA,4BAA8B,QAA9B,8BACAA,IAAA,oBAAsB,QAAtB,sBACAA,IAAA,kBAAoB,QAApB,oBACAA,IAAA,qBAAuB,QAAvB,uBACAA,IAAA,kBAAoB,QAApB,oBACAA,IAAA,mBAAqB,QAArB,qBAjBUA,OAAA,ICuCL,IAAKC,OACVA,EAAA,aAAe,4BACfA,EAAA,kBAAoB,kCACpBA,EAAA,mBAAqB,mCACrBA,EAAA,oBAAsB,mCACtBA,EAAA,WAAa,0BACbA,EAAA,gBAAkB,+BAClBA,EAAA,YAAc,0BACdA,EAAA,WAAa,0BACbA,EAAA,OAAS,oBACTA,EAAA,YAAc,0BACdA,EAAA,aAAe,sBACfA,EAAA,qBAAuB,mCACvBA,EAAA,qBAAuB,yCACvBA,EAAA,0BAA4B,+CAC5BA,EAAA,2BAA6B,2CAC7BA,EAAA,4BAA8B,gDAC9BA,EAAA,mBAAqB,uCACrBA,EAAA,wBAA0B,4CAC1BA,EAAA,oBAAsB,uCACtBA,EAAA,mBAAqB,uCACrBA,EAAA,eAAiB,iCACjBA,EAAA,oBAAsB,uCACtBA,EAAA,kBAAoB,2BACpBA,EAAA,gBAAkB,sBAClBA,EAAA,QAAU,qBACVA,EAAA,OAAS,YACTA,EAAA,sBAAwB,uBACxBA,EAAA,WAAa,gBA5BHA,OAAA,ICrDL,IAAKC,OACVA,EAAA,sBAAwB,wBACxBA,EAAA,oBAAsB,sBACtBA,EAAA,mBAAqB,qBACrBA,EAAA,mBAAqB,qBACrBA,EAAA,mBAAqB,qBALXA,OAAA,IAQAC,OACVA,EAAA,qBAAuB,uBADbA,OAAA,ICRL,IAAKC,OACVA,EAAA,QAAU,UADAA,OAAA",
6
6
  "names": ["SDKErrorCode", "SDKWarningCode", "RPCErrorCode", "MagicPayloadMethod", "MagicIncomingWindowMessage", "MagicOutgoingWindowMessage", "EthChainType"]
7
7
  }
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "version": 3,
3
3
  "sources": ["../../src/core/exception-types.ts", "../../src/core/json-rpc-types.ts", "../../src/core/message-types.ts", "../../src/modules/rpc-provider-types.ts"],
4
- "sourcesContent": ["export enum SDKErrorCode {\n MissingApiKey = 'MISSING_API_KEY',\n ModalNotReady = 'MODAL_NOT_READY',\n MalformedResponse = 'MALFORMED_RESPONSE',\n InvalidArgument = 'INVALID_ARGUMENT',\n ExtensionNotInitialized = 'EXTENSION_NOT_INITIALIZED',\n IncompatibleExtensions = 'INCOMPATIBLE_EXTENSIONS',\n}\n\nexport enum SDKWarningCode {\n SyncWeb3Method = 'SYNC_WEB3_METHOD',\n DuplicateIframe = 'DUPLICATE_IFRAME',\n ReactNativeEndpointConfiguration = 'REACT_NATIVE_ENDPOINT_CONFIGURATION',\n DeprecationNotice = 'DEPRECATION_NOTICE',\n}\n\nexport enum RPCErrorCode {\n // Standard JSON RPC 2.0 Error Codes\n ParseError = -32700,\n InvalidRequest = -32600,\n MethodNotFound = -32601,\n InvalidParams = -32602,\n InternalError = -32603,\n\n // Custom RPC Error Codes\n MagicLinkFailedVerification = -10000,\n MagicLinkExpired = -10001,\n MagicLinkRateLimited = -10002,\n MagicLinkInvalidRedirectURL = -10006,\n UserAlreadyLoggedIn = -10003,\n UpdateEmailFailed = -10004,\n UserRequestEditEmail = -10005,\n InactiveRecipient = -10010,\n AccessDeniedToUser = -10011,\n}\n\nexport type ErrorCode = SDKErrorCode | RPCErrorCode;\nexport type WarningCode = SDKWarningCode;\n", "import { RPCErrorCode } from './exception-types';\n\n// --- Request interfaces\n\nexport interface JsonRpcRequestPayload<TParams = any> {\n jsonrpc: string;\n id: string | number | null;\n method: string;\n params?: TParams;\n}\n\nexport interface JsonRpcRequestCallback {\n /** Callback executed upon JSON RPC response. */\n (err: JsonRpcError | null, result?: JsonRpcResponsePayload | null): void;\n}\n\nexport interface JsonRpcBatchRequestCallback {\n /** Callback executed upon JSON RPC response. */\n (err: JsonRpcError | null, result?: (JsonRpcResponsePayload | null)[] | null): void;\n}\n\n// --- Response interfaces\n\nexport interface JsonRpcError {\n message: string;\n code: RPCErrorCode;\n}\n\nexport interface JsonRpcResponsePayload<ResultType = any> {\n jsonrpc: string;\n id: string | number | null;\n result?: ResultType | null;\n error?: JsonRpcError | null;\n}\n\nexport interface UserInfo {\n email?: string;\n}\n\nexport interface WalletInfo {\n walletType: 'magic' | 'metamask' | 'coinbase_wallet' | 'wallet_connect';\n}\n\nexport interface RequestUserInfoScope {\n email?: 'required' | 'optional';\n}\n\n// --- Payload methods\n\n/**\n * Enum of JSON RPC methods for interacting with the Magic SDK authentication\n * relayer.\n */\nexport enum MagicPayloadMethod {\n LoginWithSms = 'magic_auth_login_with_sms',\n LoginWithEmailOTP = 'magic_auth_login_with_email_otp',\n LoginWithMagicLink = 'magic_auth_login_with_magic_link',\n LoginWithCredential = 'magic_auth_login_with_credential',\n GetIdToken = 'magic_auth_get_id_token',\n GenerateIdToken = 'magic_auth_generate_id_token',\n GetMetadata = 'magic_auth_get_metadata',\n IsLoggedIn = 'magic_auth_is_logged_in',\n Logout = 'magic_auth_logout',\n UpdateEmail = 'magic_auth_update_email',\n UserSettings = 'magic_auth_settings',\n UserSettingsTestMode = 'magic_auth_settings_testing_mode',\n LoginWithSmsTestMode = 'magic_auth_login_with_sms_testing_mode',\n LoginWithEmailOTPTestMode = 'magic_auth_login_with_email_otp_testing_mode',\n LoginWithMagicLinkTestMode = 'magic_login_with_magic_link_testing_mode',\n LoginWithCredentialTestMode = 'magic_auth_login_with_credential_testing_mode',\n GetIdTokenTestMode = 'magic_auth_get_id_token_testing_mode',\n GenerateIdTokenTestMode = 'magic_auth_generate_id_token_testing_mode',\n GetMetadataTestMode = 'magic_auth_get_metadata_testing_mode',\n IsLoggedInTestMode = 'magic_auth_is_logged_in_testing_mode',\n LogoutTestMode = 'magic_auth_logout_testing_mode',\n UpdateEmailTestMode = 'magic_auth_update_email_testing_mode',\n IntermediaryEvent = 'magic_intermediary_event',\n RequestAccounts = 'eth_requestAccounts',\n GetInfo = 'mc_get_wallet_info',\n ShowUI = 'mc_wallet',\n RequestUserInfoWithUI = 'mc_request_user_info',\n Disconnect = 'mc_disconnect',\n}\n", "import { JsonRpcResponsePayload, JsonRpcError, JsonRpcRequestPayload } from './json-rpc-types';\n\nexport enum MagicIncomingWindowMessage {\n MAGIC_HANDLE_RESPONSE = 'MAGIC_HANDLE_RESPONSE',\n MAGIC_OVERLAY_READY = 'MAGIC_OVERLAY_READY',\n MAGIC_SHOW_OVERLAY = 'MAGIC_SHOW_OVERLAY',\n MAGIC_HIDE_OVERLAY = 'MAGIC_HIDE_OVERLAY',\n MAGIC_HANDLE_EVENT = 'MAGIC_HANDLE_EVENT',\n}\n\nexport enum MagicOutgoingWindowMessage {\n MAGIC_HANDLE_REQUEST = 'MAGIC_HANDLE_REQUEST',\n}\n\n/** The shape of responding window message datas from the Magic iframe context. */\nexport interface MagicMessageRequest {\n msgType: string;\n payload: JsonRpcRequestPayload | JsonRpcRequestPayload[];\n rt?: string;\n jwt?: string;\n}\n\n/** The shape of responding window message datas from the Magic iframe context. */\nexport interface MagicMessageResponse<ResultType = any> {\n msgType: string;\n response: Partial<JsonRpcError> & Partial<JsonRpcResponsePayload<ResultType>>;\n rt?: string;\n}\n\n/** The expected message event returned by the Magic iframe context. */\nexport interface MagicMessageEvent extends Partial<MessageEvent> {\n data: MagicMessageResponse;\n}\n", "export type EthNetworkName = 'mainnet' | 'goerli';\n\nexport enum EthChainType {\n Harmony = 'HARMONY',\n}\n\nexport interface CustomNodeConfiguration {\n rpcUrl: string;\n chainId?: number;\n chainType?: EthChainType;\n}\n\nexport type EthNetworkConfiguration = EthNetworkName | CustomNodeConfiguration;\n"],
5
- "mappings": "AAAO,IAAKA,OACVA,EAAA,cAAgB,kBAChBA,EAAA,cAAgB,kBAChBA,EAAA,kBAAoB,qBACpBA,EAAA,gBAAkB,mBAClBA,EAAA,wBAA0B,4BAC1BA,EAAA,uBAAyB,0BANfA,OAAA,IASAC,OACVA,EAAA,eAAiB,mBACjBA,EAAA,gBAAkB,mBAClBA,EAAA,iCAAmC,sCACnCA,EAAA,kBAAoB,qBAJVA,OAAA,IAOAC,OAEVA,IAAA,WAAa,QAAb,aACAA,IAAA,eAAiB,QAAjB,iBACAA,IAAA,eAAiB,QAAjB,iBACAA,IAAA,cAAgB,QAAhB,gBACAA,IAAA,cAAgB,QAAhB,gBAGAA,IAAA,4BAA8B,MAA9B,8BACAA,IAAA,iBAAmB,QAAnB,mBACAA,IAAA,qBAAuB,QAAvB,uBACAA,IAAA,4BAA8B,QAA9B,8BACAA,IAAA,oBAAsB,QAAtB,sBACAA,IAAA,kBAAoB,QAApB,oBACAA,IAAA,qBAAuB,QAAvB,uBACAA,IAAA,kBAAoB,QAApB,oBACAA,IAAA,mBAAqB,QAArB,qBAjBUA,OAAA,ICqCL,IAAKC,OACVA,EAAA,aAAe,4BACfA,EAAA,kBAAoB,kCACpBA,EAAA,mBAAqB,mCACrBA,EAAA,oBAAsB,mCACtBA,EAAA,WAAa,0BACbA,EAAA,gBAAkB,+BAClBA,EAAA,YAAc,0BACdA,EAAA,WAAa,0BACbA,EAAA,OAAS,oBACTA,EAAA,YAAc,0BACdA,EAAA,aAAe,sBACfA,EAAA,qBAAuB,mCACvBA,EAAA,qBAAuB,yCACvBA,EAAA,0BAA4B,+CAC5BA,EAAA,2BAA6B,2CAC7BA,EAAA,4BAA8B,gDAC9BA,EAAA,mBAAqB,uCACrBA,EAAA,wBAA0B,4CAC1BA,EAAA,oBAAsB,uCACtBA,EAAA,mBAAqB,uCACrBA,EAAA,eAAiB,iCACjBA,EAAA,oBAAsB,uCACtBA,EAAA,kBAAoB,2BACpBA,EAAA,gBAAkB,sBAClBA,EAAA,QAAU,qBACVA,EAAA,OAAS,YACTA,EAAA,sBAAwB,uBACxBA,EAAA,WAAa,gBA5BHA,OAAA,ICnDL,IAAKC,OACVA,EAAA,sBAAwB,wBACxBA,EAAA,oBAAsB,sBACtBA,EAAA,mBAAqB,qBACrBA,EAAA,mBAAqB,qBACrBA,EAAA,mBAAqB,qBALXA,OAAA,IAQAC,OACVA,EAAA,qBAAuB,uBADbA,OAAA,ICRL,IAAKC,OACVA,EAAA,QAAU,UADAA,OAAA",
4
+ "sourcesContent": ["export enum SDKErrorCode {\n MissingApiKey = 'MISSING_API_KEY',\n ModalNotReady = 'MODAL_NOT_READY',\n MalformedResponse = 'MALFORMED_RESPONSE',\n InvalidArgument = 'INVALID_ARGUMENT',\n ExtensionNotInitialized = 'EXTENSION_NOT_INITIALIZED',\n IncompatibleExtensions = 'INCOMPATIBLE_EXTENSIONS',\n}\n\nexport enum SDKWarningCode {\n SyncWeb3Method = 'SYNC_WEB3_METHOD',\n DuplicateIframe = 'DUPLICATE_IFRAME',\n ReactNativeEndpointConfiguration = 'REACT_NATIVE_ENDPOINT_CONFIGURATION',\n DeprecationNotice = 'DEPRECATION_NOTICE',\n}\n\nexport enum RPCErrorCode {\n // Standard JSON RPC 2.0 Error Codes\n ParseError = -32700,\n InvalidRequest = -32600,\n MethodNotFound = -32601,\n InvalidParams = -32602,\n InternalError = -32603,\n\n // Custom RPC Error Codes\n MagicLinkFailedVerification = -10000,\n MagicLinkExpired = -10001,\n MagicLinkRateLimited = -10002,\n MagicLinkInvalidRedirectURL = -10006,\n UserAlreadyLoggedIn = -10003,\n UpdateEmailFailed = -10004,\n UserRequestEditEmail = -10005,\n InactiveRecipient = -10010,\n AccessDeniedToUser = -10011,\n}\n\nexport type ErrorCode = SDKErrorCode | RPCErrorCode;\nexport type WarningCode = SDKWarningCode;\n", "import { RPCErrorCode } from './exception-types';\n\n// --- Request interfaces\n\nexport interface JsonRpcRequestPayload<TParams = any> {\n jsonrpc: string;\n id: string | number | null;\n method: string;\n params?: TParams;\n}\n\nexport interface JsonRpcRequestCallback {\n /** Callback executed upon JSON RPC response. */\n (err: JsonRpcError | null, result?: JsonRpcResponsePayload | null): void;\n}\n\nexport interface JsonRpcBatchRequestCallback {\n /** Callback executed upon JSON RPC response. */\n (err: JsonRpcError | null, result?: (JsonRpcResponsePayload | null)[] | null): void;\n}\n\n// --- Response interfaces\n\nexport interface JsonRpcError {\n message: string;\n code: RPCErrorCode;\n}\n\nexport interface JsonRpcResponsePayload<ResultType = any> {\n jsonrpc: string;\n id: string | number | null;\n result?: ResultType | null;\n error?: JsonRpcError | null;\n}\n\nexport interface UserInfo {\n email?: string;\n}\n\nexport interface WalletInfo {\n walletType: 'magic' | 'metamask' | 'coinbase_wallet' | 'wallet_connect';\n}\n\nexport interface RequestUserInfoScope {\n scope?: {\n email?: 'required' | 'optional';\n };\n}\n\n// --- Payload methods\n\n/**\n * Enum of JSON RPC methods for interacting with the Magic SDK authentication\n * relayer.\n */\nexport enum MagicPayloadMethod {\n LoginWithSms = 'magic_auth_login_with_sms',\n LoginWithEmailOTP = 'magic_auth_login_with_email_otp',\n LoginWithMagicLink = 'magic_auth_login_with_magic_link',\n LoginWithCredential = 'magic_auth_login_with_credential',\n GetIdToken = 'magic_auth_get_id_token',\n GenerateIdToken = 'magic_auth_generate_id_token',\n GetMetadata = 'magic_auth_get_metadata',\n IsLoggedIn = 'magic_auth_is_logged_in',\n Logout = 'magic_auth_logout',\n UpdateEmail = 'magic_auth_update_email',\n UserSettings = 'magic_auth_settings',\n UserSettingsTestMode = 'magic_auth_settings_testing_mode',\n LoginWithSmsTestMode = 'magic_auth_login_with_sms_testing_mode',\n LoginWithEmailOTPTestMode = 'magic_auth_login_with_email_otp_testing_mode',\n LoginWithMagicLinkTestMode = 'magic_login_with_magic_link_testing_mode',\n LoginWithCredentialTestMode = 'magic_auth_login_with_credential_testing_mode',\n GetIdTokenTestMode = 'magic_auth_get_id_token_testing_mode',\n GenerateIdTokenTestMode = 'magic_auth_generate_id_token_testing_mode',\n GetMetadataTestMode = 'magic_auth_get_metadata_testing_mode',\n IsLoggedInTestMode = 'magic_auth_is_logged_in_testing_mode',\n LogoutTestMode = 'magic_auth_logout_testing_mode',\n UpdateEmailTestMode = 'magic_auth_update_email_testing_mode',\n IntermediaryEvent = 'magic_intermediary_event',\n RequestAccounts = 'eth_requestAccounts',\n GetInfo = 'mc_get_wallet_info',\n ShowUI = 'mc_wallet',\n RequestUserInfoWithUI = 'mc_request_user_info',\n Disconnect = 'mc_disconnect',\n}\n", "import { JsonRpcResponsePayload, JsonRpcError, JsonRpcRequestPayload } from './json-rpc-types';\n\nexport enum MagicIncomingWindowMessage {\n MAGIC_HANDLE_RESPONSE = 'MAGIC_HANDLE_RESPONSE',\n MAGIC_OVERLAY_READY = 'MAGIC_OVERLAY_READY',\n MAGIC_SHOW_OVERLAY = 'MAGIC_SHOW_OVERLAY',\n MAGIC_HIDE_OVERLAY = 'MAGIC_HIDE_OVERLAY',\n MAGIC_HANDLE_EVENT = 'MAGIC_HANDLE_EVENT',\n}\n\nexport enum MagicOutgoingWindowMessage {\n MAGIC_HANDLE_REQUEST = 'MAGIC_HANDLE_REQUEST',\n}\n\n/** The shape of responding window message datas from the Magic iframe context. */\nexport interface MagicMessageRequest {\n msgType: string;\n payload: JsonRpcRequestPayload | JsonRpcRequestPayload[];\n rt?: string;\n jwt?: string;\n}\n\n/** The shape of responding window message datas from the Magic iframe context. */\nexport interface MagicMessageResponse<ResultType = any> {\n msgType: string;\n response: Partial<JsonRpcError> & Partial<JsonRpcResponsePayload<ResultType>>;\n rt?: string;\n}\n\n/** The expected message event returned by the Magic iframe context. */\nexport interface MagicMessageEvent extends Partial<MessageEvent> {\n data: MagicMessageResponse;\n}\n", "export type EthNetworkName = 'mainnet' | 'goerli';\n\nexport enum EthChainType {\n Harmony = 'HARMONY',\n}\n\nexport interface CustomNodeConfiguration {\n rpcUrl: string;\n chainId?: number;\n chainType?: EthChainType;\n}\n\nexport type EthNetworkConfiguration = EthNetworkName | CustomNodeConfiguration;\n"],
5
+ "mappings": "AAAO,IAAKA,OACVA,EAAA,cAAgB,kBAChBA,EAAA,cAAgB,kBAChBA,EAAA,kBAAoB,qBACpBA,EAAA,gBAAkB,mBAClBA,EAAA,wBAA0B,4BAC1BA,EAAA,uBAAyB,0BANfA,OAAA,IASAC,OACVA,EAAA,eAAiB,mBACjBA,EAAA,gBAAkB,mBAClBA,EAAA,iCAAmC,sCACnCA,EAAA,kBAAoB,qBAJVA,OAAA,IAOAC,OAEVA,IAAA,WAAa,QAAb,aACAA,IAAA,eAAiB,QAAjB,iBACAA,IAAA,eAAiB,QAAjB,iBACAA,IAAA,cAAgB,QAAhB,gBACAA,IAAA,cAAgB,QAAhB,gBAGAA,IAAA,4BAA8B,MAA9B,8BACAA,IAAA,iBAAmB,QAAnB,mBACAA,IAAA,qBAAuB,QAAvB,uBACAA,IAAA,4BAA8B,QAA9B,8BACAA,IAAA,oBAAsB,QAAtB,sBACAA,IAAA,kBAAoB,QAApB,oBACAA,IAAA,qBAAuB,QAAvB,uBACAA,IAAA,kBAAoB,QAApB,oBACAA,IAAA,mBAAqB,QAArB,qBAjBUA,OAAA,ICuCL,IAAKC,OACVA,EAAA,aAAe,4BACfA,EAAA,kBAAoB,kCACpBA,EAAA,mBAAqB,mCACrBA,EAAA,oBAAsB,mCACtBA,EAAA,WAAa,0BACbA,EAAA,gBAAkB,+BAClBA,EAAA,YAAc,0BACdA,EAAA,WAAa,0BACbA,EAAA,OAAS,oBACTA,EAAA,YAAc,0BACdA,EAAA,aAAe,sBACfA,EAAA,qBAAuB,mCACvBA,EAAA,qBAAuB,yCACvBA,EAAA,0BAA4B,+CAC5BA,EAAA,2BAA6B,2CAC7BA,EAAA,4BAA8B,gDAC9BA,EAAA,mBAAqB,uCACrBA,EAAA,wBAA0B,4CAC1BA,EAAA,oBAAsB,uCACtBA,EAAA,mBAAqB,uCACrBA,EAAA,eAAiB,iCACjBA,EAAA,oBAAsB,uCACtBA,EAAA,kBAAoB,2BACpBA,EAAA,gBAAkB,sBAClBA,EAAA,QAAU,qBACVA,EAAA,OAAS,YACTA,EAAA,sBAAwB,uBACxBA,EAAA,WAAa,gBA5BHA,OAAA,ICrDL,IAAKC,OACVA,EAAA,sBAAwB,wBACxBA,EAAA,oBAAsB,sBACtBA,EAAA,mBAAqB,qBACrBA,EAAA,mBAAqB,qBACrBA,EAAA,mBAAqB,qBALXA,OAAA,IAQAC,OACVA,EAAA,qBAAuB,uBADbA,OAAA,ICRL,IAAKC,OACVA,EAAA,QAAU,UADAA,OAAA",
6
6
  "names": ["SDKErrorCode", "SDKWarningCode", "RPCErrorCode", "MagicPayloadMethod", "MagicIncomingWindowMessage", "MagicOutgoingWindowMessage", "EthChainType"]
7
7
  }
@@ -30,7 +30,9 @@ export interface WalletInfo {
30
30
  walletType: 'magic' | 'metamask' | 'coinbase_wallet' | 'wallet_connect';
31
31
  }
32
32
  export interface RequestUserInfoScope {
33
- email?: 'required' | 'optional';
33
+ scope?: {
34
+ email?: 'required' | 'optional';
35
+ };
34
36
  }
35
37
  /**
36
38
  * Enum of JSON RPC methods for interacting with the Magic SDK authentication
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@magic-sdk/types",
3
- "version": "11.2.0-5fe3cb7-2",
3
+ "version": "11.2.0",
4
4
  "description": "Core typings for Magic SDK packages.",
5
5
  "author": "Magic Labs <team@magic.link> (https://magic.link/)",
6
6
  "license": "MIT",
@@ -20,5 +20,5 @@
20
20
  "import": "./dist/es/index.mjs",
21
21
  "require": "./dist/cjs/index.js"
22
22
  },
23
- "gitHead": "1ef062ea699d48d5e9a9375a93b7c147632b05ca"
23
+ "gitHead": "1c4c72cf1354c6177c3764144bd121a051a2f0c1"
24
24
  }