{"eip":7795,"title":"Wallet Call Token Capabilities","description":"Wallet Call API extension for transaction prerequisites for common token types","authors":["Agustín Aguilar (@agusx1211)","Michael Standen (@ScreamingHawk)","Peter Kieltyka (@pkieltyka)","William Hua (@attente)","Philippe Castonguay (@PhABC)"],"status":"Draft","type":"Standards Track","category":"ERC","created":"2024-10-22","requires":[20,721,1155,5792],"discussionsTo":"https://ethereum-magicians.org/t/erc-7795-wallet-call-token-capabilities/21426","repo":"ERCs","label":"ERC-7795","officialUrl":"https://eips.ethereum.org/EIPS/eip-7795","sourceUrl":"https://github.com/ethereum/ERCs/blob/master/ERCS/erc-7795.md","url":"https://eips.huatuo.xyz/eip-7795/","tldr":{"en":"Adds EIP-5792 capabilities that let a dapp state token prerequisites (a minimum ERC-20 balance, an allowance, NFT ownership) so the wallet can bridge, swap or approve first and then run the call.","ja":"dapp がトークンの前提条件（ERC-20 の最低残高、allowance、NFT の所有）を宣言できる EIP-5792 の capability を追加する。ウォレットは先にブリッジ、スワップ、承認を行ってから呼び出しを実行できる。","ko":"dapp이 토큰 선행 조건(최소 ERC-20 잔액, allowance, NFT 소유)을 명시할 수 있게 하는 EIP-5792 capability를 추가한다. 지갑은 브리지, 스왑, 승인을 먼저 처리한 뒤 호출을 실행할 수 있다.","zh":"新增 EIP-5792 capability，让 dapp 声明代币前置条件（最低 ERC-20 余额、授权额度、NFT 所有权），钱包可先完成跨链、兑换或授权，再执行调用。"},"tags":["wallet","capabilities","cross-chain","token","intents"],"explainers":{"en":{"lang":"en","tldr":"Adds EIP-5792 capabilities that let a dapp state token prerequisites (a minimum ERC-20 balance, an allowance, NFT ownership) so the wallet can bridge, swap or approve first and then run the call.","tags":["wallet","capabilities","cross-chain","token","intents"],"related":[5792,20,721,1155,7677],"updated":"2026-10-19","url":"https://eips.huatuo.xyz/eip-7795/","markdown":"## What problem does it solve?\n\nA dapp usually lives on one chain and expects one token. Users hold funds spread across many chains and assets. Today the dapp can only send the *final* transaction (\"buy this NFT for 1,000 USDC on chain A\"), and it is up to the user to figure out the steps before it: bridge, swap, approve. As the number of chains grows, this mismatch gets worse.\n\nERC-7795 lets the dapp describe what must be true *before* its call runs. The wallet, which knows the user's balances everywhere, works out how to make it true.\n\n## How it works\n\nIt defines six new [EIP-5792](/eip-5792/) capabilities, each discoverable through `wallet_getCapabilities` (`{ supported, versions }`) and used in `wallet_sendCalls`:\n\n| Capability | Requirement on `owner` |\n| --- | --- |\n| `erc20MinBalance` | holds at least `minAmount` of `token` |\n| `erc20MinAllowance` | has approved `operator` for at least `minAmount` |\n| `erc721Ownership` | owns `tokenId` of `token` |\n| `erc721Approval` | has approved `operator` for `tokenId` |\n| `erc1155MinBalance` | holds at least `minAmount` of `tokenId` |\n| `erc1155MinAllowance` | has approved `operator` for `minAmount` of `tokenId` |\n\nEvery requirement also carries `version` (currently `\"1.0\"`) and the `chainId` it applies to. Amounts and IDs are hex strings.\n\nThe wallet should compute a way to meet the requirement and must ensure it is met before executing the main calls. An EOA wallet might prompt the user to sign a bridge transaction first; a smart contract wallet might have the user sign everything at once and hand the pieces to bundlers. Dapps can track progress with the usual `wallet_getCallsStatus`.\n\nSplitting each token type into its own capability lets wallets support only what they can handle and version each requirement independently.\n\n## Sample code\n\nAsk the wallet to ensure 1 USDC (6 decimals, `0x0f4240`) on Ethereum mainnet before calling a contract:\n\n```ts\nconst caps = await provider.request({ method: \"wallet_getCapabilities\", params: [account] });\n\nif (caps[\"0x1\"]?.erc20MinBalance?.supported) {\n  await provider.request({\n    method: \"wallet_sendCalls\",\n    params: [{\n      version: \"1.0\",\n      from: account,\n      calls: [{ to: shop, value: \"0x0\", data: buyCalldata, chainId: \"0x1\" }],\n      capabilities: {\n        erc20MinBalance: {\n          version: \"1.0\",\n          chainId: \"0x1\",\n          owner: account,\n          token: \"0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48\", // USDC\n          minAmount: \"0x0f4240\",\n        },\n      },\n    }],\n  });\n}\n```\n\n## Things to know\n\n- Status is **Draft**. Capability names and parameter shapes may change, and wallet support is not guaranteed; always check `wallet_getCapabilities` first.\n- The spec leaves *how* the wallet satisfies a requirement (which bridge, which swap route) entirely to the wallet.\n- The allowance and approval capabilities do not imply the owner actually holds the tokens; combine with a balance capability if you need both.\n- Dapps may skip these capabilities and handle prerequisites themselves.\n- It composes with other EIP-5792 capabilities, for example [ERC-7677](/eip-7677/) paymaster sponsorship.\n"},"ja":{"lang":"ja","tldr":"dapp がトークンの前提条件（ERC-20 の最低残高、allowance、NFT の所有）を宣言できる EIP-5792 の capability を追加する。ウォレットは先にブリッジ、スワップ、承認を行ってから呼び出しを実行できる。","tags":["wallet","capabilities","cross-chain","token","intents"],"related":[5792,20,721,1155,7677],"updated":"2026-10-19","url":"https://eips.huatuo.xyz/ja/eip-7795/","markdown":"## 何を解決するのか\n\ndapp は通常 1 つのチェーンに存在し、1 種類のトークンを想定しています。一方、ユーザーの資金は多くのチェーンと資産に分散しています。現状では、dapp が送れるのは*最終的な*トランザクション（「チェーン A で 1,000 USDC を払ってこの NFT を買う」）だけで、その前の手順（ブリッジ、スワップ、承認）はユーザーが自分で考えなければなりません。チェーンの数が増えるほど、このミスマッチは悪化します。\n\nERC-7795 では、dapp が自分の呼び出しが実行される*前に*満たされているべき条件を記述できます。あらゆるチェーンでのユーザーの残高を知っているウォレットが、それを満たす方法を考えます。\n\n## 仕組み\n\n6 つの新しい [EIP-5792](/eip-5792/) capability を定義します。それぞれ `wallet_getCapabilities`（`{ supported, versions }`）で発見でき、`wallet_sendCalls` で使われます。\n\n| Capability | `owner` に対する要件 |\n| --- | --- |\n| `erc20MinBalance` | `token` を `minAmount` 以上保有している |\n| `erc20MinAllowance` | `operator` に対して `minAmount` 以上を承認している |\n| `erc721Ownership` | `token` の `tokenId` を所有している |\n| `erc721Approval` | `tokenId` について `operator` を承認している |\n| `erc1155MinBalance` | `tokenId` を `minAmount` 以上保有している |\n| `erc1155MinAllowance` | `tokenId` の `minAmount` について `operator` を承認している |\n\nどの要件にも `version`（現在は `\"1.0\"`）と、適用先の `chainId` が付きます。金額と ID は 16 進文字列です。\n\nウォレットは要件を満たす方法を算出すべきであり、メインの呼び出しを実行する前に必ず満たされるようにしなければなりません。EOA ウォレットは、まずユーザーにブリッジのトランザクションへの署名を求めるかもしれません。スマートコントラクトウォレットは、ユーザーにすべてを一度に署名させ、それぞれの部分を Bundler に渡すかもしれません。dapp は通常の `wallet_getCallsStatus` で進捗を追跡できます。\n\nトークンの種類ごとに capability を分けることで、ウォレットは対応できるものだけをサポートでき、各要件を個別にバージョン管理できます。\n\n## サンプルコード\n\nコントラクトを呼ぶ前に、Ethereum メインネット上で 1 USDC（小数 6 桁、`0x0f4240`）を確保するようウォレットに依頼する例:\n\n```ts\nconst caps = await provider.request({ method: \"wallet_getCapabilities\", params: [account] });\n\nif (caps[\"0x1\"]?.erc20MinBalance?.supported) {\n  await provider.request({\n    method: \"wallet_sendCalls\",\n    params: [{\n      version: \"1.0\",\n      from: account,\n      calls: [{ to: shop, value: \"0x0\", data: buyCalldata, chainId: \"0x1\" }],\n      capabilities: {\n        erc20MinBalance: {\n          version: \"1.0\",\n          chainId: \"0x1\",\n          owner: account,\n          token: \"0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48\", // USDC\n          minAmount: \"0x0f4240\",\n        },\n      },\n    }],\n  });\n}\n```\n\n## 知っておくべきこと\n\n- ステータスは **Draft** です。capability の名前やパラメーターの形が変わる可能性があり、ウォレットの対応も保証されません。必ず先に `wallet_getCapabilities` を確認してください。\n- ウォレットが要件を*どのように*満たすか（どのブリッジ、どのスワップ経路か）は、仕様ではすべてウォレットに任されています。\n- allowance と approval の capability は、オーナーが実際にトークンを保有していることを意味しません。両方が必要なら、残高の capability と組み合わせてください。\n- dapp はこれらの capability を使わず、前提条件を自分で処理してもかまいません。\n- 他の EIP-5792 capability、たとえば [ERC-7677](/eip-7677/) の Paymaster によるスポンサーと組み合わせられます。\n"},"ko":{"lang":"ko","tldr":"dapp이 토큰 선행 조건(최소 ERC-20 잔액, allowance, NFT 소유)을 명시할 수 있게 하는 EIP-5792 capability를 추가한다. 지갑은 브리지, 스왑, 승인을 먼저 처리한 뒤 호출을 실행할 수 있다.","tags":["wallet","capabilities","cross-chain","token","intents"],"related":[5792,20,721,1155,7677],"updated":"2026-10-19","url":"https://eips.huatuo.xyz/ko/eip-7795/","markdown":"## 어떤 문제를 해결하나요?\n\ndapp은 보통 하나의 체인에 있고 하나의 토큰을 기대합니다. 반면 사용자의 자금은 여러 체인과 자산에 흩어져 있습니다. 지금은 dapp이 *최종* 트랜잭션(\"체인 A에서 1,000 USDC로 이 NFT를 구매\")만 보낼 수 있고, 그 앞의 단계(브리지, 스왑, 승인)는 사용자가 직접 알아내야 합니다. 체인 수가 늘어날수록 이런 불일치는 심해집니다.\n\nERC-7795는 dapp이 자신의 호출이 실행되기 *전에* 참이어야 하는 조건을 기술하게 합니다. 모든 체인에서 사용자의 잔액을 아는 지갑이 그 조건을 충족시키는 방법을 알아냅니다.\n\n## 어떻게 동작하나요?\n\n여섯 개의 새로운 [EIP-5792](/eip-5792/) capability를 정의하며, 각각 `wallet_getCapabilities`(`{ supported, versions }`)로 확인할 수 있고 `wallet_sendCalls`에서 사용됩니다.\n\n| Capability | `owner`에 대한 요건 |\n| --- | --- |\n| `erc20MinBalance` | `token`을 최소 `minAmount`만큼 보유 |\n| `erc20MinAllowance` | `operator`에게 최소 `minAmount`를 승인 |\n| `erc721Ownership` | `token`의 `tokenId`를 소유 |\n| `erc721Approval` | `tokenId`에 대해 `operator`를 승인 |\n| `erc1155MinBalance` | `tokenId`를 최소 `minAmount`만큼 보유 |\n| `erc1155MinAllowance` | `tokenId`의 `minAmount`에 대해 `operator`를 승인 |\n\n모든 요건에는 `version`(현재 `\"1.0\"`)과 적용 대상 `chainId`도 함께 들어갑니다. 금액과 ID는 16진수 문자열입니다.\n\n지갑은 요건을 충족하는 방법을 계산해야 하며, 주된 호출을 실행하기 전에 반드시 충족되도록 해야 합니다. EOA 지갑은 먼저 사용자에게 브리지 트랜잭션 서명을 요청할 수 있고, 스마트 컨트랙트 지갑은 사용자가 모든 것을 한 번에 서명하게 한 뒤 각 부분을 bundler에 넘길 수 있습니다. dapp은 일반적인 `wallet_getCallsStatus`로 진행 상황을 추적할 수 있습니다.\n\n토큰 종류마다 capability를 나누면 지갑은 처리할 수 있는 것만 지원할 수 있고, 각 요건을 독립적으로 버전 관리할 수 있습니다.\n\n## 샘플 코드\n\n컨트랙트를 호출하기 전에 이더리움 메인넷에서 1 USDC(소수점 6자리, `0x0f4240`)를 확보하도록 지갑에 요청하기:\n\n```ts\nconst caps = await provider.request({ method: \"wallet_getCapabilities\", params: [account] });\n\nif (caps[\"0x1\"]?.erc20MinBalance?.supported) {\n  await provider.request({\n    method: \"wallet_sendCalls\",\n    params: [{\n      version: \"1.0\",\n      from: account,\n      calls: [{ to: shop, value: \"0x0\", data: buyCalldata, chainId: \"0x1\" }],\n      capabilities: {\n        erc20MinBalance: {\n          version: \"1.0\",\n          chainId: \"0x1\",\n          owner: account,\n          token: \"0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48\", // USDC\n          minAmount: \"0x0f4240\",\n        },\n      },\n    }],\n  });\n}\n```\n\n## 알아둘 점\n\n- 상태는 **Draft**입니다. capability 이름과 파라미터 형태가 바뀔 수 있고 지갑의 지원도 보장되지 않으므로, 항상 먼저 `wallet_getCapabilities`를 확인하세요.\n- 지갑이 요건을 *어떻게* 충족하는지(어떤 브리지, 어떤 스왑 경로)는 스펙이 전적으로 지갑에 맡깁니다.\n- allowance와 approval capability는 소유자가 실제로 토큰을 보유하고 있음을 의미하지 않습니다. 둘 다 필요하면 잔액 capability와 함께 쓰세요.\n- dapp은 이 capability를 쓰지 않고 선행 조건을 직접 처리해도 됩니다.\n- 다른 EIP-5792 capability, 예컨대 [ERC-7677](/eip-7677/) paymaster 후원과 함께 조합할 수 있습니다.\n"},"zh":{"lang":"zh","tldr":"新增 EIP-5792 capability，让 dapp 声明代币前置条件（最低 ERC-20 余额、授权额度、NFT 所有权），钱包可先完成跨链、兑换或授权，再执行调用。","tags":["wallet","capabilities","cross-chain","token","intents"],"related":[5792,20,721,1155,7677],"updated":"2026-10-19","url":"https://eips.huatuo.xyz/zh/eip-7795/","markdown":"## 它解决什么问题？\n\ndapp 通常只存在于一条链上，并期望使用一种代币。而用户的资金分散在许多链和资产上。如今 dapp 只能发送*最终*交易（\"在链 A 上用 1,000 USDC 购买这个 NFT\"），之前的步骤（跨链、兑换、授权）要由用户自己想办法。随着链数量增加，这种错位会更严重。\n\nERC-7795 让 dapp 描述其调用执行*之前*必须成立的条件。了解用户在各处余额的钱包，则负责想办法让这些条件成立。\n\n## 它如何运作\n\n它定义了六个新的 [EIP-5792](/eip-5792/) capability，每个都可通过 `wallet_getCapabilities`（`{ supported, versions }`）发现，并在 `wallet_sendCalls` 中使用：\n\n| Capability | 对 `owner` 的要求 |\n| --- | --- |\n| `erc20MinBalance` | 持有至少 `minAmount` 的 `token` |\n| `erc20MinAllowance` | 已授权 `operator` 至少 `minAmount` |\n| `erc721Ownership` | 拥有 `token` 的 `tokenId` |\n| `erc721Approval` | 已就 `tokenId` 授权 `operator` |\n| `erc1155MinBalance` | 持有至少 `minAmount` 的 `tokenId` |\n| `erc1155MinAllowance` | 已就 `tokenId` 的 `minAmount` 授权 `operator` |\n\n每项要求还带有 `version`（目前为 `\"1.0\"`）和其适用的 `chainId`。数量和 ID 是十六进制字符串。\n\n钱包应当算出满足要求的办法，并且必须在执行主调用之前确保要求已被满足。EOA 钱包可能先提示用户签署一笔跨链交易；智能合约钱包则可能让用户一次性签署所有内容，再把各部分交给 bundler。dapp 可以用常规的 `wallet_getCallsStatus` 跟踪进度。\n\n把每种代币类型拆成各自的 capability，钱包就可以只支持自己能处理的部分，并为每项要求独立设定版本。\n\n## 示例代码\n\n请钱包在调用合约之前，先在以太坊主网上确保有 1 USDC（6 位小数，`0x0f4240`）：\n\n```ts\nconst caps = await provider.request({ method: \"wallet_getCapabilities\", params: [account] });\n\nif (caps[\"0x1\"]?.erc20MinBalance?.supported) {\n  await provider.request({\n    method: \"wallet_sendCalls\",\n    params: [{\n      version: \"1.0\",\n      from: account,\n      calls: [{ to: shop, value: \"0x0\", data: buyCalldata, chainId: \"0x1\" }],\n      capabilities: {\n        erc20MinBalance: {\n          version: \"1.0\",\n          chainId: \"0x1\",\n          owner: account,\n          token: \"0xa0b86991c6218b36c1d19d4a2e9eb0ce3606eb48\", // USDC\n          minAmount: \"0x0f4240\",\n        },\n      },\n    }],\n  });\n}\n```\n\n## 需要注意\n\n- 状态为 **Draft**。capability 名称和参数结构可能变化，钱包支持也无法保证；务必先检查 `wallet_getCapabilities`。\n- 钱包*如何*满足要求（用哪座桥、哪条兑换路径），规范完全交给钱包决定。\n- 授权额度和授权类 capability 并不意味着所有者实际持有这些代币；如果两者都需要，请与余额类 capability 组合使用。\n- dapp 也可以不使用这些 capability，自行处理前置条件。\n- 它可以与其他 EIP-5792 capability 组合，例如 [ERC-7677](/eip-7677/) 的 paymaster 赞助。\n"}}}
