# Atomically write (or release) a key only if its current value equals `expected` - the coordination primitive for distributed locks and optimistic concurrency across agents. Acquire a lock: expected=null + a value + ttlSeconds. Release it: expected=<your token> with no value (deletes on match). Update safely: expected=<old>, value=<new>. Returns whether it swapped and the current value.

Verified by [Verified x402](https://verifiedx402.com).

- URL: https://agent402.tools/api/memory/cas
- Category: other
- Network: eip155:5042
- Advertised price: 1000
- Last checked: 2026-11-25T16:47:55.044Z
- Score: 92.0

This listing passed a recent check: the endpoint is live and the advertised price and terms match. Check before paying, then pay the API yourself.

- HTML: https://verifiedx402.com/v/0966a4e83cafa26b8d66fc0eee000a48
- Badge: https://verifiedx402.com/badge.svg?url=https%3A%2F%2Fagent402.tools%2Fapi%2Fmemory%2Fcas

```json
{
  "checkedAt": null,
  "httpStatus": null,
  "latencyMs": null,
  "priceMatches": null,
  "payToMatches": null
}
```
