> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.adid.dev/llms.txt.
> For full documentation content, see https://docs.adid.dev/llms-full.txt.

# Environment Variables

## Consumed by the Go API server

| Variable               | Required | Default                | Description                             |
| ---------------------- | -------- | ---------------------- | --------------------------------------- |
| `DB_HOST`              | yes      | `postgres`             | Postgres host                           |
| `DB_PORT`              | yes      | `5432`                 | Postgres port                           |
| `DB_USER`              | yes      | `ida`                  | Postgres user                           |
| `DB_PASS`              | yes      | —                      | Postgres password (use a Secret in K8s) |
| `DB_NAME`              | yes      | `ida`                  | Postgres database name                  |
| `REDIS_URL`            | yes      | `redis://redis:6379/0` | Redis URL                               |
| `BLOCKCHAIN_RPC`       | yes      | `http://hardhat:8545`  | ADI RPC endpoint                        |
| `DID_REGISTRY_ADDRESS` | yes      | —                      | DIDRegistry contract address            |
| `API_KEY`              | no       | —                      | Server-to-server API key                |
| `LOG_LEVEL`            | no       | `info`                 | Zap log level                           |

## Informational / forward-compatibility

| Variable                       | Used by      | Description                                                              |
| ------------------------------ | ------------ | ------------------------------------------------------------------------ |
| `BLOCKCHAIN_CHAIN_ID`          | Portal / SDK | Network identifier (8400 / 99999 / 31337)                                |
| `SCHEMA_REGISTRY_ADDRESS`      | Portal / SDK | Reserved — not yet read by the API Config struct in v2.0                 |
| `REVOCATION_REGISTRY_ADDRESS`  | Portal / SDK | Reserved — see above                                                     |
| `AGENT_TRUST_REGISTRY_ADDRESS` | Portal / SDK | Reserved — see above                                                     |
| `ZK_PROOF_VERIFIER_ADDRESS`    | Portal / SDK | Reserved for ZKProofVerifier integration; not consumed by Config in v2.0 |