# AgentKV – Encrypted Key-Value Read (GET)

> AgentKV – Encrypted Key-Value Read (GET) is a paid API for AI agents from api.agentx402.ai, paid per call via x402, $0.003/call, status unknown (last checked 2026-09-15).

Reads a stored value from an agent-native, client-side encrypted key-value store, billed per-request via x402 micropayment with no signup or API key required.

## Facts

- Endpoint: GET https://api.agentx402.ai/v1/kv/mainnet-validation-2026-07-26
- Price: $0.003/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-15
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/agentkv-encrypted-key-value-read-get-b5cc0814
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_AMtuvlBv-z6IukTrsNznx

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability agentkv-encrypted-key-value-read-get-b5cc0814
```

Example prompt: Fetch the value stored under the key 'session-config' from my AgentKV namespace — my wallet is the namespace identifier and I want the decrypted result back.

## When to prefer this

Choose this endpoint when your AI agent needs to read back previously stored values in a wallet-scoped, encrypted namespace without any traditional authentication (no signup, no API key). It is ideal for stateless or autonomous agents that use a crypto wallet or ak_ account key as their identity, and need persistent, encrypted state between invocations. Prefer it over traditional KV stores when you need per-request micropayment billing (x402), client-side encryption by default, and zero-friction onboarding.

## Known failure modes

- Key not found — returns 404 if the requested key does not exist in the namespace
- Unauthorized — returns 402 or 401 if the x402 payment is missing, invalid, or insufficient ($0.003 USDC required per read)
- Invalid namespace — wallet address or ak_ key not recognized or malformed
- Rate limiting or credit exhaustion — caller has insufficient prepaid credits and per-op payment fails
- Network or service error — 500-level response if the backend is unavailable

## How this service works

Agent-native encrypted key-value store, paid per request over x402 — no signup, no API key. The payer's wallet (or an ak_ account key) is the namespace; values are client-side encrypted. Write $0.005, read $0.003; prepay $1 = 10,000 credits at 1/10 the per-op price (POST /v1/credits/deposit). SDK: npm i @agentkv/client. Docs: https://agentx402.ai

## Output

Returns the decrypted value associated with the requested key in the caller's wallet-scoped namespace. The response contains the stored payload (client-side encrypted at write time, decryptable by the authorized caller). If the key does not exist or the caller lacks access, an appropriate error is returned.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET",
      "HEAD",
      "DELETE"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "properties": {}
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/agentkv-encrypted-key-value-read-get-b5cc0814/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.agentx402.ai](https://www.zero.xyz/host/api.agentx402.ai/llms.txt)
