Types and interfaces

List of important types.

declare type InitParams = {
    appName: string;
    sessionParams: SessionParameters;
    paymasterParams?: PaymasterParameters;
    webwalletUrl?: string;
    environment?: keyof typeof ENVIRONMENTS;
    provider?: ProviderInterface;
};
type SessionParameters = {
  allowedMethods: Array<{
    contract: string;
    selector: string;
  }>;
  validityDays?: number;
};
type PaymasterParameters = {
    baseUrl?: string;
    apiKey?: string;
    tokenAddress?: Address;
};
type ConnectResponse = {
    account: SessionAccount;
    user?: User;
    callbackData?: string;
    approvalTransactionHash?: string;
    approvalRequestsCalls?: Call[];
    deploymentPayload?: AccountDeploymentPayload;  
};

Last updated

Was this helpful?