Skip to main content
MetaMask

wallet_getPermissions

Summary: Gets the user's permissions.

Gets the user's permissions. Specified by EIP-2255.

Parameters

This method doesn't accept any parameters.

Returns

Permissions list array

An array of the user's permissions.

Permission object

Object containing information about the permission.

id string

The permission ID.

parentCapability string

The name of the permission being granted. For example, eth_accounts or endowment:permitted-chains.

invoker string

The URI of the dapp being granted this permission.

caveats array

An array of caveats that specify restrictions on the permission.

Caveat object

Object containing information about the caveat.

type string

Type of caveat.

value

Value of the caveat.

name string

Name of the caveat.

date number

The timestamp of the permission request.

Customize request
Connect your MetaMask wallet to run requests successfully.
Request
await window.ethereum.request({
"method": "wallet_getPermissions",
"params": [],
});