Introduction
Guides
Components
- Appchain
- Buy
- Checkout
- Earn
- Fund
- Identity
- Mint
- <Signature />
- Swap
- Token
- <Transaction />
- Wallet
API
- Mint
- Swap
- Token
- Wallet
Utilities
- Config
- Earn
- Fund
- Identity
- Mint
- Token
- Wallet
Contribution
Types
Identity components & utilities Types
Glossary of Types in Identity components & utilities.
AddressReact
Copy
Ask AI
type AddressReact = {
address?: Address | null; // The Ethereum address to render.
className?: string; // Optional className override for top span element.
isSliced?: boolean; // Determines if the displayed address should be sliced.
hasCopyAddressOnClick?: boolean; // Defaults to true. Optional boolean to disable copy address on click functionality.
};
Attestation
Copy
Ask AI
type Attestation = {
attester: Address; // the attester who created the attestation.
decodedDataJson: string; // The attestation data decoded to JSON.
expirationTime: number; // The Unix timestamp when the attestation expires (0 for no expiration).
id: string; // The unique identifier of the attestation.
recipient: Address; // The Ethereum address of the recipient of the attestation.
revocationTime: number; // The Unix timestamp when the attestation was revoked, if applicable.
revoked: boolean; // A boolean indicating whether the attestation is revocable or not.
schemaId: EASSchemaUid; // The schema identifier associated with the attestation.
time: number; // The Unix timestamp when the attestation was created.
};
AvatarReact
Copy
Ask AI
type AvatarReact = {
address?: Address | null; // The Ethereum address to fetch the avatar for.
chain?: Chain; // Optional chain for domain resolution
className?: string; // Optional className override for top div element.
loadingComponent?: JSX.Element; // Optional custom component to display while the avatar data is loading.
defaultComponent?: JSX.Element; // Optional custom component to display when no ENS name or avatar is available.
children?: ReactNode; // Optional attestation by passing Badge component as its children
} & ImgHTMLAttributes<HTMLImageElement>; // Optional additional image attributes to apply to the avatar.
BadgeReact
Copy
Ask AI
type BadgeReact = {
className?: string; // Optional className override for top span element.
tooltip?: boolean | string; // Controls whether the badge shows a tooltip on hover. When true, the tooltip displays the attestation's name. When a string is provided, that text overrides the default display. Defaults to false.
};
BaseMainnetName
Copy
Ask AI
export type BaseMainnetName = `${string}.base.eth`;
Basename
Copy
Ask AI
type Basename = BaseMainnetName | BaseSepoliaName;
BaseSepoliaName
Copy
Ask AI
type BaseSepoliaName = `${string}.basetest.eth`;
EASSchemaUid
Copy
Ask AI
type EASSchemaUid = `0x${string}`;
EASChainDefinition
Copy
Ask AI
type EASChainDefinition = {
easGraphqlAPI: string; // EAS GraphQL API endpoint
id: number; // blockchain source id
schemaUids: EASSchemaUid[]; // Array of EAS Schema UIDs
};
EthBalanceReact
Copy
Ask AI
type EthBalanceReact = {
address?: Address;
className?: string;
};
GetAddress
Copy
Ask AI
type GetAddress = {
name: string | Basename; // Name to resolve
chain?: Chain; // Optional chain for domain resolution
};
GetAddressReturnType
Copy
Ask AI
type GetAddressReturnType = Address | null;
GetAttestationsOptions
Copy
Ask AI
type GetAttestationsOptions = {
schemas?: EASSchemaUid[];
revoked?: boolean;
expirationTime?: number;
limit?: number;
};
GetAvatar
Copy
Ask AI
type GetAvatar = {
ensName: string; // The ENS name to fetch the avatar for.
chain?: Chain; // Optional chain for domain resolution
};
GetAvatarReturnType
Copy
Ask AI
type GetAvatarReturnType = string | null;
GetName
Copy
Ask AI
type GetName = {
address: Address;
chain?: Chain;
};
GetNameReturnType
Copy
Ask AI
type GetNameReturnType = string | null;
GetNames
Copy
Ask AI
type GetNames = {
addresses: Address[]; // Array of Ethereum addresses to resolve names for
chain?: Chain; // Optional chain for domain resolution
};
IdentityCardReact
Copy
Ask AI
type IdentityCardReact = {
address?: Address;
chain?: Chain;
className?: string;
schemaId?: Address | null;
badgeTooltip?: boolean | string; // Controls whether the badge shows a tooltip on hover. When true, the tooltip displays the attestation's name. When a string is provided, that text overrides the default display. Defaults to false.
};
IdentityContextType
Copy
Ask AI
type IdentityContextType = {
address: Address; // The Ethereum address to fetch the avatar and name for.
schemaId?: Address | null; // The Ethereum address of the schema to use for EAS attestation.
};
IdentityReact
Copy
Ask AI
type IdentityReact = {
address?: Address; // The Ethereum address to fetch the avatar and name for.
chain?: Chain; // Optional chain for domain resolution
children: ReactNode;
className?: string; // Optional className override for top div element.
schemaId?: Address | null; // The Ethereum address of the schema to use for EAS attestation.
hasCopyAddressOnClick?: boolean; // Optional boolean to disable copy address on click functionality.
};
NameReact
Copy
Ask AI
type NameReact = {
address?: Address | null; // Ethereum address to be displayed.
children?: ReactNode; // Optional attestation by passing Badge component as its children
chain?: Chain; // Optional chain for domain resolution
className?: string; // Optional className override for top span element.
} & HTMLAttributes<HTMLSpanElement>; // Optional additional span attributes to apply to the name.
UseAddressOptions
Copy
Ask AI
type UseAddressOptions = {
name: string | Basename; // The ENS or Basename for which the Ethereum address is to be fetched
chain?: Chain; // Optional chain for domain resolution
};
UseAvatarOptions
Copy
Ask AI
type UseAvatarOptions = {
ensName: string;
chain?: Chain; // Optional chain for domain resolution
};
UseAvatarsOptions
Copy
Ask AI
type UseAvatarsOptions = {
ensNames: string[]; // Array of ENS names to resolve avatars for
chain?: Chain; // Optional chain for domain resolution
};
UseNameOptions
Copy
Ask AI
type UseNameOptions = {
address: Address; // The address for which the ENS or Basename is to be fetched.
chain?: Chain; // Optional chain for domain resolution
};
UseNamesOptions
Copy
Ask AI
type UseNamesOptions = {
addresses: Address[]; // Array of addresses to resolve ENS or Basenames for
chain?: Chain; // Optional chain for domain resolution
};
On this page
- AddressReact
- Attestation
- AvatarReact
- BadgeReact
- BaseMainnetName
- Basename
- BaseSepoliaName
- EASSchemaUid
- EASChainDefinition
- EthBalanceReact
- GetAddress
- GetAddressReturnType
- GetAttestationsOptions
- GetAvatar
- GetAvatarReturnType
- GetName
- GetNameReturnType
- GetNames
- IdentityCardReact
- IdentityContextType
- IdentityReact
- NameReact
- UseAddressOptions
- UseAvatarOptions
- UseAvatarsOptions
- UseNameOptions
- UseNamesOptions
Assistant
Responses are generated using AI and may contain mistakes.