> For the complete documentation index, see [llms.txt](https://docs.t-rex.network/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.t-rex.network/reference/identity-suite/easclaimissuer.md).

# EASClaimIssuer

`EASClaimIssuer` lets an attestation of the Ethereum Attestation Service count as a claim. The adapter is the issuer of the claim: an identity stores a record that points at the attestation, and the adapter answers `isClaimValid` from EAS at every check. The attester needs no ONCHAINID. The concept is in [External attestations](/identity-onchainid/external-attestations.md).

### At a glance

|                 |                                                                                                                                                     |
| --------------- | --------------------------------------------------------------------------------------------------------------------------------------------------- |
| **Source**      | `contracts/modules/claims/EASClaimIssuer.sol`                                                                                                       |
| **Interface**   | `IClaimIssuer`, of which it implements the validity reads only                                                                                      |
| **Deployed as** | One contract per EAS deployment it reads, not upgradeable. Built with the access manager of the network, the EAS contract and the `IdentityFactory` |
| **State**       | Per claim topic: one EAS schema and a list of accepted attesters. No claim, no key, no revocation list                                              |

### The record on the identity

The Identity Owner adds the claim with `addClaim` on its identity, with the adapter as `_issuer`.

| Field of the claim | Content                                                     |
| ------------------ | ----------------------------------------------------------- |
| `signature`        | The 32-byte UID of the attestation: `abi.encodePacked(uid)` |
| `data`             | The fields of the attestation, mirrored one for one         |
| `issuer`           | The adapter                                                 |

Guide: [29 Bring an EAS attestation in as a claim](/guides/claim-issuer/29.-bring-an-eas-attestation-in-as-a-claim.md).

### Validity

| Function                                           | Access       | Behavior                                                                                                                |
| -------------------------------------------------- | ------------ | ----------------------------------------------------------------------------------------------------------------------- |
| `isClaimValid(_identity, claimTopic, sig, data)`   | Anyone, read | True when `getClaimStatus` is `Valid`                                                                                   |
| `getClaimStatus(_identity, claimTopic, sig, data)` | Anyone, read | The status, read from EAS at the time of the call                                                                       |
| `getAttestationData(sig)`                          | Anyone, read | The payload of the attestation, whatever its state. Empty when `sig` is not a 32-byte UID. Never a basis for a decision |
| `isDigestRevoked(bytes32)`                         | Anyone, read | Always false: revocation is read from EAS                                                                               |

| Status         | Returned when                                                                                                                                                                                                                    |
| -------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `BadSignature` | The signature field is not a 32-byte UID                                                                                                                                                                                         |
| `NotIssued`    | The topic is bound to no schema, the attestation uses another schema, the attester is not accepted for the topic, the record does not mirror the attestation, or the recipient is neither the identity nor a wallet linked to it |
| `Revoked`      | The attester revoked the attestation on EAS                                                                                                                                                                                      |
| `Expired`      | The attestation reached its expiration time                                                                                                                                                                                      |
| `Valid`        | None of the above                                                                                                                                                                                                                |

### Settings

| Function                                                                                        | Access             | Behavior                                                                                                                                      |
| ----------------------------------------------------------------------------------------------- | ------------------ | --------------------------------------------------------------------------------------------------------------------------------------------- |
| `setSchemaForTopic(topic, schema)`                                                              | Network governance | Binds a claim topic to an EAS schema. A zero schema unbinds the topic: every claim of that topic stops being valid. Emits `SchemaForTopicSet` |
| `setAttester(topic, attester, allowed)`                                                         | Network governance | Adds an attester to the accepted set of a topic, or removes it. Reverts with `ZeroAddress`. Emits `AttesterSet`                               |
| `getSchemaForTopic(topic)`, `getIsAttesterAllowed(topic, attester)`, `getEAS()`, `getFactory()` | Anyone, read       |                                                                                                                                               |

### Functions that revert

The adapter is not an identity. Every other function of `IClaimIssuer` and `IIdentity` reverts with `EASNotSupported`: `addClaimTo`, `revokeClaimByDigest`, `getClaimHash`, `getIdentityType`, the key functions (`addKey`, `removeKey`, `getKey`, `getKeyPurposes`, `getKeysByPurpose`, `keyHasPurpose`) and the claim storage functions (`addClaim`, `removeClaim`, `getClaim`, `getClaimIdsByTopic`).

`IdentityFactory.identityTypeOf(adapter)` is 0: the adapter is not a factory identity. An Issuer that trusts it adds its address as a trusted issuer, like any Claim Issuer.

> **Trust statement.** A claim through the adapter rests on three parties: the attester, for what it attests, EAS, for the record and its revocation, and Network governance, for the binding of topics to schemas and the list of accepted attesters.

### Events

| Event                                                                                        | Emitted when                                                |
| -------------------------------------------------------------------------------------------- | ----------------------------------------------------------- |
| `AdapterInitialized(address indexed eas, address indexed factory)`                           | Once, at construction                                       |
| `SchemaForTopicSet(uint256 indexed topic, bytes32 indexed schema, address caller)`           | A topic is bound to a schema, or unbound with a zero schema |
| `AttesterSet(uint256 indexed topic, address indexed attester, bool allowed, address caller)` | An attester is accepted for a topic, or removed             |


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.t-rex.network/reference/identity-suite/easclaimissuer.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
