Introduction
Hi, I'm cardene, a software engineer and technical writer focused on blockchain and AI.
I've also authored Japanese technical books on specification-driven development with LLMs and decentralized application (DApp) development.
I also build and publish a variety of tools, libraries, and open-source projects.
This article examines EIP-2256, which proposes a JSON-RPC method allowing DApps to retrieve assets from a wallet with the user's permission.
This explanation translates, summarizes, and expands on the following specification.
For other EIPs, BIPs, SLIPs, and CAIPs, see https://cardene.dev/proposals.
Overview
EIP-2256 defines the JSON-RPC method wallet_getOwnedAssets for retrieving a list of assets, such as tokens and NFTs, from an Ethereum wallet.
Retrieval requires user permission. The wallet is intended to manage and return assets the user is interested in. DApps can therefore inspect assets without maintaining their own lists and repeatedly querying individual blockchain balances.
Motivation
DApps have traditionally needed lists of all possible or previously known assets and queried blockchain balances for each. Repeating this work across multiple DApps wastes development resources. It also creates a poor user experience: unsolicited airdrops and irrelevant tokens may appear, while assets that matter to the user may be missing.
With wallet_getOwnedAssets, the wallet manages assets of interest and returns those currently owned. This improves user experience and complements EIP-747, which proposes adding assets to wallets.
For EIP-747, see the following article.
EIP-747 Explained: Tracking Assets in Wallets
Specification
wallet_getOwnedAssets is a proposed JSON-RPC method for Web3-enabled browsers and wallets. Its purpose is to let a DApp retrieve user-approved assets already tracked or allowlisted in the wallet, including ERC-20 and ERC-721 tokens. Users need not share irrelevant assets, and DApps can retrieve relevant information efficiently.
The method supports filtering by EIP-155 chain ID and asset type, limiting the result count, and providing a justification. Returned asset information includes addresses, chain IDs, types, names, symbols, icons, balances, and decimals.
For EIP-155, see the following article.
EIP-155 Explained: Preventing Replay Attacks Across Ethereum Networks
Parameters
The first parameter specifies the Ethereum address owning the assets. The second is an optional object containing:
- chainId: the target chain ID, as defined by EIP-155.
- limit: the maximum number of assets to retrieve.
- types: asset interfaces to retrieve, for example
["ERC20", "ERC721"]. - justification: a human-readable explanation of why the DApp needs this information (recommended).
Return Data
The result is an array whose elements each describe one asset.
- address: the checksummed Ethereum address of the asset contract.
- chainId: the ID of the chain on which the asset is deployed.
- type: the asset type, such as ERC20 or ERC721.
- options: asset-specific information, such as name, symbol, icon, balance, and decimals.
Examples
A request for all assets specifies only the Ethereum address and justification, potentially returning assets across multiple chains and types. A request with conditions, for example chainId 1, ERC20 only, and a maximum of one result, returns only matching assets.
User Interface Recommendations
When the method is called, the wallet displays a confirmation screen. The user can approve, reject, or modify the request by reducing the number of returned assets.
When all assets are requested, the wallet should display the total number and allow the user to select which assets are returned. Frequently used assets should be prioritized, with other assets expandable as needed.
Additional Considerations
wallet_getOwnedAssets aims to improve user experience by eliminating the need for each DApp to maintain lists of all assets or previously known assets. It reduces duplicated asset-management work across DApps.
Options such as chainId and types let DApps narrow the assets shown to users. For example, a DApp can restrict selection to ERC-20 tokens on one chain. The limit parameter specifies the maximum number selectable; the proposal does not define a separate minimum parameter, and one is treated as the minimum selection in the original explanation.
The options field provides asset-specific details so that DApps can reuse familiar wallet labels and icons, improving the clarity of the interface.
The address and type fields enable identification and asset-specific functionality. The balance field allows a balance to be displayed without another blockchain query. Balances are normally publicly available, although wallet-provided values may require freshness checks.
Citation
Loredana Cirstea (@loredanacirstea), "EIP-2256: wallet_getOwnedAssets JSON-RPC Method [DRAFT]," Ethereum Improvement Proposals, no. 2256, August 2019. [Online serial]. Available: https://eips.ethereum.org/EIPS/eip-2256.
Conclusion
EIP-2256 proposes a wallet JSON-RPC method through which DApps can retrieve user-approved asset information.
Further reading and author links:




