Interfaces
List of key TypeScript interfaces used throughout the SDK.
Profile
Profile
type Profile = {
profileId: string;
summary: ProfileSummary;
website: string;
email: string;
emailVerified: boolean;
mobile: string;
mobileVerified: boolean;
location: string;
telegramId: string;
telegramUsername: string;
roles: ProfileDomainRole[];
heldCollections: ProfileHeldCollection[];
heldDustDetails: ProfileHeldDustDetails;
};ProfileSummary
type ProfileSummary = {
profileId: string;
name: string;
description: string;
showcasePostUri: string;
wallets: ProfileWallet[];
profileImageUrl: string;
twitterId: string;
twitterHandle: string;
twitterUsername: string;
discordId: string;
discordUsername: string;
numFollowings: number;
numFollowers: number;
};Wallets and Networks
ProfileWallet
type ProfileWallet = {
address: string;
network: ProfileWalletNetwork;
};ProfileWalletNetwork
type ProfileDomainRole = {
domain: string;
roles: string[];
permissions: string[];
};ProfileWalletNetwork
enum ProfileWalletNetwork {
ETHEREUM = "ETHEREUM",
POLYGON = "POLYGON",
BITCOIN = "BITCOIN",
SOLANA = "SOLANA",
}Wallet Verification
ProfileVerificationMethod
enum ProfileVerificationMethod {
MESSAGE_SIGNATURE = "MESSAGE_SIGNATURE",
TXN_SIGNATURE = "TXN_SIGNATURE",
BITCOIN_BIP322_MESSAGE_SIGNATURE = "BITCOIN_BIP322_MESSAGE_SIGNATURE",
}Profile Domains and Permissions
ProfileDomainRole
type ProfileDomainRole = {
domain: string;
roles: string[];
permissions: string[];
};Socials
IdentityProviderName
type IdentityProviderName = "TWITTER" | "DISCORD" | "TELEGRAM";Notification Receivers
NotificationReceiverType
enum NotificationReceiverType {
EMAIL = "EMAIL",
MOBILE = "MOBILE",
}NFT Collections and Holdings
ProfileHeldCollection
type ProfileHeldCollection = {
network: ProfileWalletNetwork;
contract: string;
tokenIds: number[];
tokens: ProfileNftToken[];
};ProfileNftToken
type ProfileNftToken = {
wallet: string;
tokenId: number;
staked: boolean;
};ProfileHeldDustDetails
type ProfileHeldDustDetails = {
amount: number;
preciseAmount: string;
holdEnoughDust: boolean;
significantDustThreshold: number;
decimals: number;
};Authentication
BaseParams
interface BaseParams {
address: string | undefined;
isConnected: boolean;
profileParams: ProfileParams;
verifyParams: VerifyParams;
handleChangeProfileParams: (profileParams: ProfileParams) => void;
}ProfileParams
interface ProfileParams {
address: string | undefined;
network: ProfileWalletNetwork | undefined;
}VerifyParams
interface VerifyParams {
isLoadingVerifyWallet: boolean;
verifyWallet: (message: string) => Promise<string | null>;
verificationMethod: ProfileVerificationMethod;
}SignInData
interface SignInData {
accessToken: string;
refreshToken: string;
profile?: ProfileCoreOptions["profile"];
}SignOutOptions
interface SignOutOptions {
noReload?: boolean;
}AuthAccessOptions
interface AuthAccessOptions {
refetchProfileBefore?: boolean;
refetchProfileAfter?: boolean;
onInvalidTokens?: () => void;
}SyncProfileOptions
interface SyncProfileOptions {
accessToken?: string;
newProfile?: Profile;
refetchProfile?: boolean;
}Projects configuration
ProjectMetadata
interface ProjectMetadata {
id: string;
label: string;
contract: string;
}