# a2apay Agent Memory

> a2apay Agent Memory is a paid API for AI agents from a2apay.io, paid per call via x402, $0.028/call, status unknown (last checked 2026-10-10).

Stores persistent key-value memory for AI agents on-chain via ICP infrastructure, with pay-per-write pricing.

## Facts

- Endpoint: POST https://a2apay.io/api/agent-memory?utm_source=zero.xyz
- Price: $0.028/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-10
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/a2apay-agent-memory-9881145d
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_zKHTOuX6aeaYWTjqkr39f

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 a2apay-agent-memory-9881145d -d '<json body>'
```

Example prompt: Store the following context in my agent's on-chain memory so it can be retrieved in future sessions: the user prefers dark mode, their timezone is UTC-5, and their last completed task was 'send weekly report'.

## When to prefer this

Choose this endpoint when an AI agent needs durable, decentralized, on-chain persistent memory that survives restarts and is resilient to single points of failure. Prefer it over centralized key-value stores when tamper-resistance, redundancy via ICP canisters, and pay-per-write economics are priorities. Best suited for agents that need to checkpoint state, store user context, or maintain knowledge across independent sessions without managing a traditional database.

## Known failure modes

- Payment not included or insufficient USDC causes 402 Payment Required
- Malformed JSON body results in 400 Bad Request
- ICP canister temporarily unavailable returns 503 or timeout
- Missing required 'input' field returns validation error
- Oversized payload may be rejected with a 413 error

## How this service works

Persistent memory for AI agents — secure, automatically backed up, and running on redundant ICP infrastructure with no single point of failure. Store what your agent needs to remember, on-chain, pay-per-write.

## Output

A confirmation response indicating whether the memory write was successful, along with any returned receipt or reference ID for the stored record on the ICP canister.

## 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",
    "bodyType",
    "body"
   ],
   "properties": {
    "body": {
     "properties": {}
    },
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "POST"
     ],
     "type": "string"
    },
    "bodyType": {
     "enum": [
      "json",
      "form-data",
      "text"
     ],
     "type": "string"
    }
   },
   "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/a2apay-agent-memory-9881145d/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from a2apay.io](https://www.zero.xyz/host/a2apay.io/llms.txt)
