Get supported permissions
ERC-7715 defines an RPC method that returns the execution permissions a wallet supports. Use the method to verify the available Advanced Permissions types and rules before sending requests.
Prerequisites
Request supported permissions
Request the supported Advanced Permissions types for a wallet with the
Wallet Client's getSupportedExecutionPermissions action.
- response.ts
- example.ts
- config.ts
{
"native-token-stream": {
"chainIds": [
1,
10,
],
"ruleTypes": [
"expiry"
]
},
// ...
}
import { walletClient } from "./config.ts";
const supportedPermissions = await walletClient.getSupportedExecutionPermissions();
import { createWalletClient, custom } from "viem";;
import { erc7715ProviderActions } from "@metamask/smart-accounts-kit/actions";
export const walletClient = createWalletClient({
transport: custom(window.ethereum),
}).extend(erc7715ProviderActions());
See the full list of supported Advanced Permissions.