# Sign Typed Data

> Documentation index: [llms.txt](https://namera.ai/llms.txt).

Source: https://namera.ai/docs/cli/guides/signing/sign-typed-data

Sign an EIP-712 payload with explicit application context.

Install the CLI and [sign in](https://namera.ai/docs/cli/authentication). Replace the example
account ID, session-key ID, and recipient with your own. Use an active key
installed on **Base Sepolia** with permission for the operation.

Enable signature authority and permit the intended typed-data domain. Confirm
the domain's chain ID and verifying contract before signing.

## Prepare the Payload [#prepare-the-payload]

Save this example as `typed-data.json`, replacing the domain with your
application's real values:

```json title="typed-data.json"
{
  "domain": {
    "name": "Namera Example",
    "version": "1",
    "chainId": 84532,
    "verifyingContract": "0x2222222222222222222222222222222222222222"
  },
  "types": {
    "Note": [
      {
        "name": "contents",
        "type": "string"
      }
    ]
  },
  "primaryType": "Note",
  "message": {
    "contents": "Hello from Namera"
  }
}
```

The domain's numeric `chainId` and the CLI's selected network serve different
roles. Keep them consistent for a payload intended for that network.

## Sign the Payload [#sign-the-payload]

```sh
namera sign \
  --namespace evm \
  --wallet 0199dfe1-0000-7000-8000-000000000001 \
  --session-key 0199dfe1-0000-7000-8000-000000000002 \
  --network 'Base Sepolia' \
  --type typed-data \
  --typed-data "$(cat typed-data.json)"
```

<div className="docs-response">

```text
Signature created
-> Account: 👛 Example account
-> Network: Base Sepolia
-> Session key: Example session
-> Type: Typed data (EIP-712)
-> Signature: 0x0000000100111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111b
```

</div>

With `--output json` on the signing command:

<div className="docs-response">

```json
{
  "namespace": "eip155",
  "walletId": "0199dfe1-0000-7000-8000-000000000001",
  "chainId": "eip155:84532",
  "account": "0x1111111111111111111111111111111111111111",
  "signature": "0x0000000100111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111111b",
  "type": "typed-data"
}
```

</div>

Use `--output json` on the original invocation if another program will consume
the signature. Keep the complete typed-data object unchanged for verification.
Do not combine `--message` with `--typed-data`.

The example signature is a fixture value. A signature may authorize an action
even though this command itself does not submit a transaction.

Example output uses fixture accounts and hashes, captured with the CLI's output
formatters. Plain-text output is shown without terminal colors; your values and
relative expiry dates will differ.
