> For the complete documentation index, see [llms.txt](https://rwapact.gitbook.io/whitepaper/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://rwapact.gitbook.io/whitepaper/pact-execution/attestation.md).

# Attestation

## Attestation

Authorization decides whether a Trade Intent may reach the Execution Layer. Attestation preserves what RWAPACT evaluated and decided.

Without an attested record, it is difficult to establish which risk checks ran, which Policy Version applied, which Session was active, or whether the trade was approved or rejected. It is also difficult to connect the selected gas context to the decision.

KAR, the **Attestation Registry**, preserves this decision context on-chain. Its records support auditability, dispute resolution, and reputation.

### KAR and the Pact decision

KAR does not decide whether a trade is safe. KRO, KSO, KPV, and KGR supply the inputs to the Pact decision. KAR records the resulting Authorization or Rejection.

```
Trade Intent
  -> Pact Evaluation
  -> Authorization or Rejection
  -> KAR Attestation
  -> Execution Transaction Hash when execution occurs
```

This sequence preserves the context that existed before execution. An Attestation records the decision, not a guarantee that its underlying oracle or policy inputs were correct.

### What an Attestation contains

Each KAR Attestation uses the RWAPACT-specific schema below.

| Field                      | Decision context                                                     |
| -------------------------- | -------------------------------------------------------------------- |
| Attestation ID             | Identifies the recorded decision.                                    |
| Agent ID                   | Identifies the autonomous Agent that submitted the Trade Intent.     |
| Session ID                 | Connects the decision to its active Session.                         |
| Asset                      | Identifies the requested asset.                                      |
| Amount                     | Records the requested trade amount.                                  |
| Risk Score                 | Preserves the KRO result used during evaluation.                     |
| Policy Version             | Identifies the policy configuration active for the decision.         |
| Gas Route Hash             | Preserves the gas routing context from KGR.                          |
| Approved                   | Records whether the Pact authorized execution.                       |
| Reject Reason              | Preserves why the Pact denied execution, when applicable.            |
| Timestamp                  | Records when the Pact made its decision.                             |
| Execution Transaction Hash | Links to the execution transaction after execution, when applicable. |

### Approved and rejected Attestations

When `Can_Trade` is true, the Pact authorizes execution and KAR records an approved Attestation. The record preserves the relevant Pact context before the Execution Layer processes the trade.

When `Can_Trade` is false, the Pact rejects execution and KAR records a rejected Attestation. The Reject Reason preserves the failed condition. The Session and Policy Version can also be referenced through the same decision context.

Both outcomes are recorded. Attestation is not limited to trades that execute.

### Execution transaction linkage

The Execution Transaction Hash is associated with the Attestation after execution, when an execution transaction exists. It links an approved decision to the eventual transaction.

A rejected trade may have no Execution Transaction Hash. The trade never reaches the Execution Layer, so no execution transaction occurs.

### ERC-8273 compatibility

KAR is designed to be ERC-8273 compatible. This supports interoperability with other attestation-based systems while retaining the RWAPACT-specific Attestation schema.

The compatibility statement describes the specified attestation model. It does not add implementation details beyond the RWAPACT specification.

### Why the record matters

An Attestation lets a later reviewer reconstruct the decision context:

* What did the Agent try to do, and in which Session?
* Which Risk Score, Policy Version, and gas route informed the decision?
* Was the Trade Intent approved or rejected, and why?

The decision begins with [Authorization and Rejection](/whitepaper/pact-execution/authorization-and-rejection.md). KAR makes that decision and its context permanently available on-chain.

***


---

# 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 dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://rwapact.gitbook.io/whitepaper/pact-execution/attestation.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
