ERC-8143 Smart credential lookup interface (Smart Credential Resolution Interface)

Draft · Signatures & auth · created 2025-12-15

A standard that allows third-party-issued credentials such as KYC, proof of personhood, and reputation to be looked up from any contract using the same functions and events.

Why it is needed

When each credential issuer uses different function names and return formats, clients such as wallets or agents must build separate integration code for each issuer. Also, even when a new credential is added on-chain, clients have no way to know about it in advance and can only look it up if they are externally told which key exists. ERC-3668 can handle credentials stored off-chain, but if each issuer has a different calling convention, it becomes difficult for clients to process them uniformly. This cost is especially significant as automated clients like AI agents become more common, since they must individually learn each issuer's distinct interface.

What to implement

In depth

Interface composition and ERC-165

IERC8143 consists of a single function, getCredential(string key), and a single event, CredentialSet(string key). Smart credentials must implement ERC-165 and must return true when supportsInterface is called with this interface's ID, 0xd091187f. The interface was deliberately limited to a single function to reduce implementation burden on clients.

Key format and return value format are non-standardized

This standard does not define the key format or the data format of the bytes returned by getCredential. Credential issuers must define and document their own keys and data formats. Keys may optionally use the parameterized format from ERC-8119 (key:param or key/param, with no space after the separator), but this is not required.

Role of the CredentialSet event

A contract must emit CredentialSet(key) whenever a credential for a given key is set or updated. This allows clients, including agent systems, to discover newly added credentials on-chain even without prior knowledge of which keys exist.

Off-chain credentials and ERC-3668

If a credential is stored off-chain, the contract may revert with ERC-3668's OffchainLookup, and clients must follow ERC-3668's client lookup protocol. The spec's example shows a getCredentialCallback function that verifies the gateway response, such as via a signature or Merkle proof, before decoding and returning it.

Client lookup procedure

Compliant clients must first call the getCredential function using ERC-3668, and since some libraries do not use ERC-3668 by default, a separate call may be needed to enable it. The returned value must be decoded according to the format defined by the issuer for that key, and interpreted as raw UTF-8 bytes if no known format exists.

Design rationale: ZKP support and simplicity

Compared to W3C Verifiable Credentials, smart credentials are distinctive in that they can support zero-knowledge proofs by leveraging on-chain ZKP verifiers. They are also designed to meet the need for records that a trusted third party, rather than the user, must manage, such as KYC and proof of personhood, and the interface is limited to a single function by design to make interoperability across multiple issuers easy to achieve.

Proposal status notice

This ERC is currently in Draft status. It is not yet a finalized standard, and its content may change or discussion may be discontinued.

Things to watch out for

Original ERC · ← ERCs