# SDK Methods Networks
# Enabled Networks
Returns the enabled networks set by the Wallet dApp config.
enabled(): Promise<NetworkDetails[]>
NetworkDetails
:
{
selectedNode: string;
backupNodes: string[];
enabled: boolean;
name: string;
id: number;
chainId: number;
nativeCurrency: string;
networkBlockExplorer?: NetworkBlockExplorer | undefined;
feeWarningThreshold: BigNumber;
supportsFiatPrices: boolean;
supportsWalletConnect: boolean;
isProductionNetwork: boolean;
fixedGasPrice?: string | undefined;
}
# Current Network
Returns the authenticated user's current network details.
current(): Promise<NetworkDetails>
NetworkDetails
:
{
selectedNode: string;
backupNodes: string[];
enabled: boolean;
name: string;
id: number;
chainId: number;
nativeCurrency: string;
networkBlockExplorer?: NetworkBlockExplorer | undefined;
feeWarningThreshold: BigNumber;
supportsFiatPrices: boolean;
supportsWalletConnect: boolean;
isProductionNetwork: boolean;
fixedGasPrice?: string | undefined;
}
# Gas Recommendations
Get the gas recommendations
gasRecommendations(): Promise<NetworkGasRecommendationsResponse>
NetworkGasRecommendationsResponse
:
export interface NetworkGasRecommendationsResponse {
recommendations: {
speed: number;
gasPrice: string;
estimatedExecutionTime: number;
}[];
recommendedSpeed: number;
}
# Switch ethereum chain
Switch the users ethereum chain. This will show an approval network change modal to the user and the promise will be resolved once they have accepted or rejected. The JSONRPC call wallet_switchEthereumChain
is supported and can be called from our ethereum provider as well.
switchEthereumChain(chainId: string): Promise<null>