---
eip: 2256
label: EIP-2256
title: wallet_getOwnedAssets JSON-RPC Method
status: Stagnant
type: Standards Track
category: Interface
created: 2019-08-29
requires: 55, 155, 1474
official: https://eips.ethereum.org/EIPS/eip-2256
source: https://github.com/ethereum/EIPs/blob/master/EIPS/eip-2256.md
canonical: https://eips.huatuo.xyz/eip-2256/
lang: en
tldr: "Proposes a wallet_getOwnedAssets RPC method so a dapp can ask the user's wallet, with permission, for the tokens the user holds instead of scanning token lists itself."
tags: [json-rpc, wallet, assets, tokens, privacy]
---

# EIP-2256: wallet_getOwnedAssets JSON-RPC Method

> This is a proposal for a new JSON-RPC call for retrieving from a wallet a selection of owned assets by an Ethereum address, with the user's permission.

**TL;DR:** Proposes a wallet_getOwnedAssets RPC method so a dapp can ask the user's wallet, with permission, for the tokens the user holds instead of scanning token lists itself.

## What problem does it solve?

A dapp that needs to know a user's tokens, for tax calculation or to offer a choice of payment token, has no standard way to ask. It must keep its own list of popular token contracts and query a balance for each one. Every dapp duplicates this work, and the result is either incomplete (missing tokens) or cluttered with unwanted airdrops.

The user's wallet already knows which assets the user cares about. EIP-2256 proposes letting the dapp ask the wallet directly, with the user approving what is shared. It complements [EIP-747](/eip-747/) (`wallet_watchAsset`), which goes the other way: a dapp suggesting a token for the wallet to track.

## How it works

The dapp calls `wallet_getOwnedAssets` with:

- `address`: the account whose assets are requested.
- An optional options object:
  - `chainId`: restrict to one chain ([EIP-155](/eip-155/) chain ID).
  - `limit`: maximum number of assets the dapp wants back.
  - `types`: interface identifiers such as `["ERC20", "ERC721"]`.
  - `justification`: human-readable reason shown to the user (recommended).

The wallet shows a prompt. The user can accept, reject, or narrow the selection. The result is an array of records containing `address`, `chainId`, `type`, and asset-specific `options` (for ERC-20: `name`, `symbol`, `icon`, `balance`, `decimals`). Only assets the wallet already tracks for that account are returned.

## Sample code

Request:

```json
{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "wallet_getOwnedAssets",
  "params": [
    "0x3333333333333333333333333333333333333333",
    {
      "chainId": 1,
      "limit": 1,
      "types": ["ERC20"],
      "justification": "Select the token you want to pay with."
    }
  ]
}
```

Example response:

```json
{
  "id": 1,
  "jsonrpc": "2.0",
  "result": [
    {
      "address": "0x0000000000000000000000000000000000000001",
      "chainId": 1,
      "type": "ERC20",
      "options": { "name": "TokenA", "symbol": "TKA", "balance": 1000000000000, "decimals": 18 }
    }
  ]
}
```

Calling it through an [EIP-1193](/eip-1193/) provider, with a fallback:

```ts
async function getOwnedAssets(account: string) {
  try {
    return await window.ethereum.request({
      method: "wallet_getOwnedAssets",
      params: [account, { types: ["ERC20"], justification: "Show your balances" }],
    });
  } catch {
    return null; // method not supported or user rejected: fall back to your own token list
  }
}
```

## Things to know

- **Status: Stagnant.** Mainstream wallets do not generally implement this method, so always handle "method not found" and user rejection.
- Returned balances come from the wallet, not the chain. Re-read balances on-chain before relying on them for anything important.
- A list of holdings is sensitive. The spec makes user consent and the `justification` text central for this reason; dapps should request only what they need (`types`, `chainId`, `limit`).
- The spec builds on the JSON-RPC conventions of [EIP-1474](/eip-1474/). Related wallet methods include [EIP-3085](/eip-3085/) `wallet_addEthereumChain`.


---

This is an unofficial plain-language summary. Read the full specification: https://eips.ethereum.org/EIPS/eip-2256
