@getpara/core-sdk 1.12.0 → 2.0.0-alpha.5
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/dist/cjs/ParaCore.js +936 -974
- package/dist/cjs/constants.js +7 -1
- package/dist/cjs/index.js +15 -9
- package/dist/cjs/types/coreApi.js +74 -0
- package/dist/cjs/types/events.js +1 -0
- package/dist/cjs/types/index.js +4 -2
- package/dist/cjs/types/{params.js → methods.js} +2 -2
- package/dist/cjs/utils/autobind.js +41 -0
- package/dist/cjs/utils/formatting.js +0 -12
- package/dist/cjs/utils/index.js +10 -0
- package/dist/cjs/utils/json.js +37 -0
- package/dist/cjs/utils/listeners.js +2 -11
- package/dist/cjs/utils/phone.js +61 -0
- package/dist/cjs/utils/types.js +29 -0
- package/dist/cjs/utils/url.js +34 -2
- package/dist/cjs/utils/wallet.js +30 -17
- package/dist/esm/ParaCore.js +952 -979
- package/dist/esm/constants.js +5 -1
- package/dist/esm/index.js +12 -9
- package/dist/esm/types/coreApi.js +52 -0
- package/dist/esm/types/events.js +1 -0
- package/dist/esm/types/index.js +2 -1
- package/dist/esm/utils/autobind.js +19 -0
- package/dist/esm/utils/formatting.js +0 -10
- package/dist/esm/utils/index.js +5 -0
- package/dist/esm/utils/json.js +15 -0
- package/dist/esm/utils/listeners.js +2 -11
- package/dist/esm/utils/phone.js +28 -0
- package/dist/esm/utils/types.js +7 -0
- package/dist/esm/utils/url.js +15 -2
- package/dist/esm/utils/wallet.js +27 -16
- package/dist/types/ParaCore.d.ts +100 -391
- package/dist/types/PlatformUtils.d.ts +3 -3
- package/dist/types/constants.d.ts +2 -0
- package/dist/types/external/userManagementClient.d.ts +1 -1
- package/dist/types/index.d.ts +5 -3
- package/dist/types/types/config.d.ts +4 -24
- package/dist/types/types/coreApi.d.ts +475 -0
- package/dist/types/types/events.d.ts +4 -1
- package/dist/types/types/index.d.ts +2 -1
- package/dist/types/types/methods.d.ts +148 -0
- package/dist/types/types/onRamps.d.ts +3 -3
- package/dist/types/types/wallet.d.ts +4 -4
- package/dist/types/utils/autobind.d.ts +1 -0
- package/dist/types/utils/formatting.d.ts +2 -4
- package/dist/types/utils/index.d.ts +5 -0
- package/dist/types/utils/json.d.ts +1 -0
- package/dist/types/utils/onRamps.d.ts +3 -3
- package/dist/types/utils/phone.d.ts +7 -0
- package/dist/types/utils/types.d.ts +2 -0
- package/dist/types/utils/url.d.ts +2 -1
- package/dist/types/utils/wallet.d.ts +9 -7
- package/package.json +4 -3
- package/dist/types/types/params.d.ts +0 -73
- /package/dist/esm/types/{params.js → methods.js} +0 -0
|
@@ -0,0 +1,148 @@
|
|
|
1
|
+
import { PrimaryAuthInfo, ServerAuthStateLogin, ServerAuthStateSignup, AuthMethod, ServerAuthStateVerify, VerifiedAuth, AuthExtras, TOAuthMethod, TWalletType } from '@getpara/user-management-client';
|
|
2
|
+
import { Theme } from './theme.js';
|
|
3
|
+
import { RecoveryStatus } from './recovery.js';
|
|
4
|
+
import { Wallet } from './wallet.js';
|
|
5
|
+
type Device = {
|
|
6
|
+
sessionId: string;
|
|
7
|
+
encryptionKey: string;
|
|
8
|
+
};
|
|
9
|
+
export type EmbeddedWalletType = Exclude<TWalletType, never>;
|
|
10
|
+
export type ExternalWalletType = Exclude<TWalletType, never>;
|
|
11
|
+
export type VerifyExternalWalletV1 = {
|
|
12
|
+
address: string;
|
|
13
|
+
signedMessage: string;
|
|
14
|
+
cosmosPublicKeyHex?: string;
|
|
15
|
+
cosmosSigner?: string;
|
|
16
|
+
};
|
|
17
|
+
export type PortalUrlType = 'createAuth' | 'createPassword' | 'loginAuth' | 'loginPassword' | 'txReview' | 'onRamp';
|
|
18
|
+
export type PortalUrlOptions = {
|
|
19
|
+
params?: Record<string, string | undefined | null>;
|
|
20
|
+
isForNewDevice?: boolean;
|
|
21
|
+
thisDevice?: Device;
|
|
22
|
+
newDevice?: Device;
|
|
23
|
+
sessionId?: string;
|
|
24
|
+
portalTheme?: Theme;
|
|
25
|
+
pathId?: string;
|
|
26
|
+
shorten?: boolean;
|
|
27
|
+
};
|
|
28
|
+
export type WithAuthMethod = {
|
|
29
|
+
/**
|
|
30
|
+
* Which authorization method to use for the URL, either `'passkey'` or `'passwprd'`.
|
|
31
|
+
*/
|
|
32
|
+
authMethod?: Uppercase<AuthMethod>;
|
|
33
|
+
};
|
|
34
|
+
export type WithCustomTheme = {
|
|
35
|
+
/**
|
|
36
|
+
* The theme to apply to generated URLs, if different from your configured theme.
|
|
37
|
+
*/
|
|
38
|
+
portalTheme?: Theme;
|
|
39
|
+
};
|
|
40
|
+
export type WithUseShortUrls = {
|
|
41
|
+
/**
|
|
42
|
+
* Whether to shorten generated URLs. This may correct any issues with generated QR codes. Defaults to `false`.
|
|
43
|
+
*/
|
|
44
|
+
useShortUrls?: boolean;
|
|
45
|
+
};
|
|
46
|
+
export type WithShorten = {
|
|
47
|
+
/**
|
|
48
|
+
* Whether to shorten the generated URL. This may correct any issues with generated QR codes. Defaults to `false`.
|
|
49
|
+
*/
|
|
50
|
+
shorten?: boolean;
|
|
51
|
+
};
|
|
52
|
+
export type PollParams = {
|
|
53
|
+
/**
|
|
54
|
+
* A callback function that will be invoked on each method poll.
|
|
55
|
+
*/
|
|
56
|
+
onPoll?: () => void;
|
|
57
|
+
/**
|
|
58
|
+
* A callback function that will be invoked if the method call is canceled.
|
|
59
|
+
*/
|
|
60
|
+
onCancel?: () => void;
|
|
61
|
+
};
|
|
62
|
+
export type LoginUrlParams = WithAuthMethod & WithCustomTheme & WithShorten & {
|
|
63
|
+
sessionId?: string;
|
|
64
|
+
};
|
|
65
|
+
export type NewCredentialUrlParams = WithAuthMethod & WithCustomTheme & WithShorten & {
|
|
66
|
+
/**
|
|
67
|
+
* Whether the URL is meant to add a passkey for a previous user on a new device. Defaults to `false`.
|
|
68
|
+
*/
|
|
69
|
+
isForNewDevice?: boolean;
|
|
70
|
+
};
|
|
71
|
+
export type OAuthUrlParams = {
|
|
72
|
+
/**
|
|
73
|
+
* The third-party OAuth service.
|
|
74
|
+
*/
|
|
75
|
+
method: Exclude<TOAuthMethod, 'TELEGRAM' | 'FARCASTER'>;
|
|
76
|
+
/**
|
|
77
|
+
* The deeplink URL to redirect to after OAuth is complete.
|
|
78
|
+
*/
|
|
79
|
+
deeplinkUrl?: string;
|
|
80
|
+
};
|
|
81
|
+
export type AuthStateBaseParams = WithCustomTheme & WithUseShortUrls;
|
|
82
|
+
export type AuthStateVerify = ServerAuthStateVerify;
|
|
83
|
+
export type AuthStateLogin = Omit<ServerAuthStateLogin, 'loginAuthMethods'> & {
|
|
84
|
+
/**
|
|
85
|
+
* A Para Portal URL for logging in via a WebAuth passkey. For best compatibility, you should open this URL in a new window or tab.
|
|
86
|
+
*/
|
|
87
|
+
passkeyUrl?: string;
|
|
88
|
+
/**
|
|
89
|
+
* A Para Portal URL for authorizing a new device using a WebAuth passkey located elsewhere, to be visited using that other device.
|
|
90
|
+
*/
|
|
91
|
+
passkeyKnownDeviceUrl?: string;
|
|
92
|
+
/**
|
|
93
|
+
* A Para Portal URL for logging in via a password.
|
|
94
|
+
*/
|
|
95
|
+
passwordUrl?: string;
|
|
96
|
+
};
|
|
97
|
+
export type AuthStateSignup = Omit<ServerAuthStateSignup, 'signupAuthMethods'> & {
|
|
98
|
+
/**
|
|
99
|
+
* A Para Portal URL for creating a new WebAuth passkey.
|
|
100
|
+
*/
|
|
101
|
+
passkeyUrl?: string;
|
|
102
|
+
/**
|
|
103
|
+
* A Para Portal URL for creating a new user password.
|
|
104
|
+
*/
|
|
105
|
+
passwordUrl?: string;
|
|
106
|
+
/**
|
|
107
|
+
* The Para system ID for the newly generated passkey.
|
|
108
|
+
*/
|
|
109
|
+
passkeyId?: string;
|
|
110
|
+
/**
|
|
111
|
+
* The Para system ID for the newly generated password.
|
|
112
|
+
*/
|
|
113
|
+
passwordId?: string;
|
|
114
|
+
};
|
|
115
|
+
export type AuthStateVerifyOrLogin = AuthStateVerify | AuthStateLogin;
|
|
116
|
+
export type AuthStateSignupOrLogin = AuthStateSignup | AuthStateLogin;
|
|
117
|
+
export type OAuthResponse = AuthStateSignupOrLogin;
|
|
118
|
+
export type AuthState = AuthStateVerify | AuthStateLogin | AuthStateSignup;
|
|
119
|
+
export type Verify2faParams = {
|
|
120
|
+
auth: VerifiedAuth;
|
|
121
|
+
verificationCode: string;
|
|
122
|
+
};
|
|
123
|
+
export type Verify2faResponse = {
|
|
124
|
+
/**
|
|
125
|
+
* When the 2FA verification code was sent.
|
|
126
|
+
*/
|
|
127
|
+
initiatedAt?: Date;
|
|
128
|
+
/**
|
|
129
|
+
* The status for the 2FA process.
|
|
130
|
+
*/
|
|
131
|
+
status?: RecoveryStatus;
|
|
132
|
+
/**
|
|
133
|
+
* The matched user ID.
|
|
134
|
+
*/
|
|
135
|
+
userId: string;
|
|
136
|
+
/**
|
|
137
|
+
* The wallets protected by this 2FA instance.
|
|
138
|
+
*/
|
|
139
|
+
wallets: Pick<Wallet, 'address' | 'id'>[];
|
|
140
|
+
};
|
|
141
|
+
export type CoreAuthInfo = PrimaryAuthInfo & AuthExtras;
|
|
142
|
+
export type StorageType = 'local' | 'session' | 'secure' | 'all';
|
|
143
|
+
export type GetWalletBalanceParams = {
|
|
144
|
+
walletId: string;
|
|
145
|
+
rpcUrl?: string;
|
|
146
|
+
};
|
|
147
|
+
export type GetWalletBalanceResponse = Promise<string | undefined>;
|
|
148
|
+
export {};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { Network, OnRampAsset, OnRampProvider, OnRampPurchaseType,
|
|
1
|
+
import { Network, OnRampAsset, OnRampProvider, OnRampPurchaseType, TWalletType } from '@getpara/user-management-client';
|
|
2
2
|
export type ProviderAssetInfo = [string, Partial<Record<OnRampPurchaseType, boolean>>];
|
|
3
|
-
export type OnRampAssetInfo = Record<
|
|
4
|
-
export type OnRampAssetInfoRow = [
|
|
3
|
+
export type OnRampAssetInfo = Record<TWalletType, Partial<Record<Network, Partial<Record<OnRampAsset, Partial<Record<OnRampProvider, ProviderAssetInfo>>>>>>>;
|
|
4
|
+
export type OnRampAssetInfoRow = [TWalletType, Network, OnRampAsset, Partial<Record<OnRampProvider, ProviderAssetInfo>>];
|
|
5
5
|
export declare enum OnRampMethod {
|
|
6
6
|
ACH = "ACH",
|
|
7
7
|
DEBIT = "Debit",
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import { PartnerEntity, TPregenIdentifierType,
|
|
2
|
-
import { EmbeddedWalletType, ExternalWalletType } from './params.js';
|
|
1
|
+
import { EmbeddedWalletType, ExternalWalletType, PartnerEntity, TPregenIdentifierType, TWalletScheme } from '@getpara/user-management-client';
|
|
3
2
|
export interface Wallet {
|
|
4
3
|
createdAt?: string;
|
|
5
4
|
id: string;
|
|
@@ -8,7 +7,7 @@ export interface Wallet {
|
|
|
8
7
|
address?: string;
|
|
9
8
|
addressSecondary?: string;
|
|
10
9
|
publicKey?: string;
|
|
11
|
-
scheme?:
|
|
10
|
+
scheme?: TWalletScheme;
|
|
12
11
|
type?: EmbeddedWalletType | ExternalWalletType;
|
|
13
12
|
isPregen?: boolean;
|
|
14
13
|
pregenIdentifier?: string;
|
|
@@ -20,9 +19,9 @@ export interface Wallet {
|
|
|
20
19
|
lastUsedPartner?: PartnerEntity;
|
|
21
20
|
lastUsedPartnerId?: string;
|
|
22
21
|
isExternal?: boolean;
|
|
22
|
+
isExternalWithParaAuth?: boolean;
|
|
23
23
|
ensName?: string | null;
|
|
24
24
|
ensAvatar?: string | null;
|
|
25
|
-
isExternalWithParaAuth?: boolean;
|
|
26
25
|
}
|
|
27
26
|
/** @deprecated */
|
|
28
27
|
export declare enum PregenIdentifierType {
|
|
@@ -40,3 +39,4 @@ export interface DeniedSignatureResWithUrl extends DeniedSignatureRes {
|
|
|
40
39
|
}
|
|
41
40
|
export type SignatureRes = SuccessfulSignatureRes | DeniedSignatureRes;
|
|
42
41
|
export type FullSignatureRes = SuccessfulSignatureRes | DeniedSignatureResWithUrl;
|
|
42
|
+
export type ExternalWalletConnectionType = 'NONE' | 'CONNECTION_ONLY' | 'AUTHENTICATED';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function autoBind(instance: any): void;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { TWalletType } from '@getpara/user-management-client';
|
|
2
2
|
export type Hex = `0x${string}`;
|
|
3
3
|
export interface Signature {
|
|
4
4
|
r: Hex;
|
|
@@ -11,9 +11,7 @@ export declare function hexToUint8Array(hex: string): Uint8Array;
|
|
|
11
11
|
export declare function hexToDecimal(hex: string): string;
|
|
12
12
|
export declare function decimalToHex(decimal: string): Hex;
|
|
13
13
|
export declare function getCosmosAddress(publicKey: string, prefix: string): string;
|
|
14
|
-
export declare function truncateAddress(str: string, addressType:
|
|
14
|
+
export declare function truncateAddress(str: string, addressType: TWalletType, { prefix, targetLength, }?: {
|
|
15
15
|
prefix?: string;
|
|
16
16
|
targetLength?: number;
|
|
17
17
|
}): string;
|
|
18
|
-
export declare function stringToPhoneNumber(str: string): string;
|
|
19
|
-
export declare function normalizePhoneNumber(countryCode: string, number: string): string | undefined;
|
|
@@ -1,6 +1,11 @@
|
|
|
1
|
+
export * from './autobind.js';
|
|
1
2
|
export * from './events.js';
|
|
2
3
|
export * from './formatting.js';
|
|
4
|
+
export * from './json.js';
|
|
5
|
+
export * from './listeners.js';
|
|
3
6
|
export * from './onRamps.js';
|
|
7
|
+
export * from './phone.js';
|
|
4
8
|
export * from './polling.js';
|
|
9
|
+
export * from './types.js';
|
|
5
10
|
export * from './url.js';
|
|
6
11
|
export * from './wallet.js';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export declare function jsonParse<T = any>(data: string | null | undefined, validate?: (res: any) => res is T): T | undefined;
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { Network, OnRampAsset, OnRampProvider, OnRampPurchaseType,
|
|
1
|
+
import { Network, OnRampAsset, OnRampProvider, OnRampPurchaseType, TWalletType } from '@getpara/user-management-client';
|
|
2
2
|
import { OnRampAssetInfoRow, OnRampAssetInfo } from '../types/index.js';
|
|
3
3
|
export declare function toAssetInfoArray(data: OnRampAssetInfo): OnRampAssetInfoRow[];
|
|
4
4
|
export declare function getOnRampNetworks(data: OnRampAssetInfo, { walletType, allowed, assets, providers, action, }?: {
|
|
5
|
-
walletType?:
|
|
5
|
+
walletType?: TWalletType;
|
|
6
6
|
allowed?: Network[];
|
|
7
7
|
assets?: OnRampAsset[];
|
|
8
8
|
providers?: OnRampProvider[];
|
|
9
9
|
action?: OnRampPurchaseType;
|
|
10
10
|
}): Network[];
|
|
11
11
|
export declare function getOnRampAssets(data: OnRampAssetInfo, { walletType, network, allowed, providers, action, }?: {
|
|
12
|
-
walletType?:
|
|
12
|
+
walletType?: TWalletType;
|
|
13
13
|
network?: Network;
|
|
14
14
|
allowed?: OnRampAsset[];
|
|
15
15
|
providers?: OnRampProvider[];
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export declare function formatPhoneNumber(phone: string, countryCode?: string | undefined, opts?: {
|
|
2
|
+
forDisplay: undefined | false;
|
|
3
|
+
}): `+${number}` | null;
|
|
4
|
+
export declare function formatPhoneNumber(phone: string, countryCode: string | undefined, opts: {
|
|
5
|
+
forDisplay: true;
|
|
6
|
+
}): string | null;
|
|
7
|
+
export declare function displayPhoneNumber(phone: string, countryCode?: string): string;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Environment } from '../types/index.js';
|
|
1
|
+
import { Ctx, Environment } from '../types/index.js';
|
|
2
2
|
export declare function getPortalDomain(env: Environment, isE2E?: boolean): "localhost" | "app.sandbox.usecapsule.com" | "app.beta.usecapsule.com" | "app.usecapsule.com";
|
|
3
3
|
export declare function getPortalBaseURL({ env, isE2E }: {
|
|
4
4
|
env: Environment;
|
|
@@ -13,3 +13,4 @@ export declare function constructUrl({ base, path, params, }: {
|
|
|
13
13
|
path: string;
|
|
14
14
|
params?: Record<string, string | undefined | null>;
|
|
15
15
|
}): string;
|
|
16
|
+
export declare function shortenUrl(ctx: Ctx, url: string): Promise<string>;
|
|
@@ -1,11 +1,13 @@
|
|
|
1
|
-
import { TPregenIdentifierType, WalletEntity,
|
|
2
|
-
import {
|
|
3
|
-
export declare const WalletSchemeTypeMap: Record<
|
|
1
|
+
import { CurrentWalletIds, SupportedWalletTypes, TPregenIdentifierType, WalletEntity, TWalletScheme, TWalletType } from '@getpara/user-management-client';
|
|
2
|
+
import { Wallet } from '../types/index.js';
|
|
3
|
+
export declare const WalletSchemeTypeMap: Record<TWalletScheme, Partial<Record<TWalletType, true>>>;
|
|
4
4
|
export declare function isPregenIdentifierMatch(a: string | null | undefined, b: string | null | undefined, type: TPregenIdentifierType): boolean;
|
|
5
|
-
export declare function isWalletSupported(types:
|
|
6
|
-
export declare function getSchemes(types:
|
|
7
|
-
export declare function getWalletTypes(schemes:
|
|
8
|
-
export declare function getEquivalentTypes(types:
|
|
5
|
+
export declare function isWalletSupported(types: TWalletType[], wallet: Omit<Wallet, 'signer'>): boolean;
|
|
6
|
+
export declare function getSchemes(types: TWalletType[] | SupportedWalletTypes): TWalletScheme[];
|
|
7
|
+
export declare function getWalletTypes(schemes: TWalletScheme[]): TWalletType[];
|
|
8
|
+
export declare function getEquivalentTypes(types: TWalletType[] | TWalletType): TWalletType[];
|
|
9
9
|
export declare function entityToWallet(w: WalletEntity): Omit<Wallet, 'signer'>;
|
|
10
10
|
export declare function migrateWallet(obj: Record<string, unknown>): Wallet;
|
|
11
|
+
export declare function supportedWalletTypesEq(a: SupportedWalletTypes, b: SupportedWalletTypes): boolean;
|
|
12
|
+
export declare function mergeCurrentWalletIds(original: CurrentWalletIds, additional: CurrentWalletIds): CurrentWalletIds;
|
|
11
13
|
export declare function newUuid(): string;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@getpara/core-sdk",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "2.0.0-alpha.5",
|
|
4
4
|
"main": "dist/cjs/index.js",
|
|
5
5
|
"module": "dist/esm/index.js",
|
|
6
6
|
"types": "dist/types/index.d.ts",
|
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
"@celo/utils": "^8.0.2",
|
|
11
11
|
"@cosmjs/encoding": "^0.32.4",
|
|
12
12
|
"@ethereumjs/util": "^9.1.0",
|
|
13
|
-
"@getpara/user-management-client": "
|
|
13
|
+
"@getpara/user-management-client": "2.0.0-alpha.5",
|
|
14
14
|
"@noble/hashes": "^1.5.0",
|
|
15
15
|
"base64url": "^3.0.1",
|
|
16
16
|
"libphonenumber-js": "1.11.2",
|
|
@@ -27,6 +27,7 @@
|
|
|
27
27
|
"test": "vitest run --coverage"
|
|
28
28
|
},
|
|
29
29
|
"devDependencies": {
|
|
30
|
+
"@faker-js/faker": "^9.5.1",
|
|
30
31
|
"typescript": "5.1.6"
|
|
31
32
|
},
|
|
32
33
|
"files": [
|
|
@@ -40,5 +41,5 @@
|
|
|
40
41
|
"require": "./dist/cjs/index.js"
|
|
41
42
|
}
|
|
42
43
|
},
|
|
43
|
-
"gitHead": "
|
|
44
|
+
"gitHead": "3ecfca088f24489f2e8fa5493d0f4459b08880e1"
|
|
44
45
|
}
|
|
@@ -1,73 +0,0 @@
|
|
|
1
|
-
import { AuthType, WalletType } from '@getpara/user-management-client';
|
|
2
|
-
import { Theme } from './theme.js';
|
|
3
|
-
export type EmbeddedWalletType = Exclude<WalletType, never>;
|
|
4
|
-
export type ExternalWalletType = Exclude<WalletType, never>;
|
|
5
|
-
export type ExternalWalletInfo = {
|
|
6
|
-
address: string;
|
|
7
|
-
type: ExternalWalletType;
|
|
8
|
-
provider?: string;
|
|
9
|
-
addressBech32?: string;
|
|
10
|
-
ensName?: string | null;
|
|
11
|
-
ensAvatar?: string | null;
|
|
12
|
-
withFullParaAuth?: boolean;
|
|
13
|
-
};
|
|
14
|
-
export type VerifyExternalWallet = {
|
|
15
|
-
signedMessage: string;
|
|
16
|
-
cosmosPublicKeyHex?: string;
|
|
17
|
-
cosmosSigner?: string;
|
|
18
|
-
};
|
|
19
|
-
export type PortalUrlOptions = {
|
|
20
|
-
params?: Record<string, string | undefined | null>;
|
|
21
|
-
authType?: AuthType;
|
|
22
|
-
isForNewDevice?: boolean;
|
|
23
|
-
loginEncryptionPublicKey?: string;
|
|
24
|
-
newDeviceSessionId?: string;
|
|
25
|
-
newDeviceEncryptionKey?: string;
|
|
26
|
-
partnerId?: string;
|
|
27
|
-
sessionId?: string;
|
|
28
|
-
theme?: Theme;
|
|
29
|
-
pathId?: string;
|
|
30
|
-
displayName?: string;
|
|
31
|
-
pfpUrl?: string;
|
|
32
|
-
};
|
|
33
|
-
export type GetWebAuthUrlForLoginParams = {
|
|
34
|
-
/**
|
|
35
|
-
* The session ID for the URL.
|
|
36
|
-
*/
|
|
37
|
-
sessionId: string;
|
|
38
|
-
/**
|
|
39
|
-
* Either 'email' | 'phone' | 'farcaster' | 'telegram'
|
|
40
|
-
*/
|
|
41
|
-
authType?: AuthType;
|
|
42
|
-
/**
|
|
43
|
-
* The public key to use for encrypting the login encryption key.
|
|
44
|
-
*/
|
|
45
|
-
loginEncryptionPublicKey: string;
|
|
46
|
-
/**
|
|
47
|
-
* The partner ID for the URL.
|
|
48
|
-
*/
|
|
49
|
-
partnerId?: string;
|
|
50
|
-
/**
|
|
51
|
-
* The session ID for the new device being registered.
|
|
52
|
-
*/
|
|
53
|
-
newDeviceSessionId?: string;
|
|
54
|
-
/**
|
|
55
|
-
* The public key for the new device being registered.
|
|
56
|
-
*/
|
|
57
|
-
newDeviceEncryptionKey?: string;
|
|
58
|
-
/**
|
|
59
|
-
* The Telegram or Farcaster display name for the user.
|
|
60
|
-
*/
|
|
61
|
-
displayName?: string;
|
|
62
|
-
/**
|
|
63
|
-
* The Telegram or Farcaster URL for the user's profile picture.
|
|
64
|
-
*/
|
|
65
|
-
pfpUrl?: string;
|
|
66
|
-
};
|
|
67
|
-
export type GetWalletBalanceParams = {
|
|
68
|
-
walletId: string;
|
|
69
|
-
rpcUrl?: string;
|
|
70
|
-
};
|
|
71
|
-
export type CreateGuestWalletsParams = {
|
|
72
|
-
types?: WalletType[];
|
|
73
|
-
};
|
|
File without changes
|