---
title: "Prepare a grant revocation"
method: POST
path: "/v1/treasury/passkey-safes/{id}/grants/{grant_id}/revoke"
tags: ["Key Custody"]
---

# Prepare a grant revocation

`POST /v1/treasury/passkey-safes/{id}/grants/{grant_id}/revoke`

## Request

- Base URL: `https://api.1claw.co`
- URL: `https://api.1claw.co/v1/treasury/passkey-safes/{id}/grants/{grant_id}/revoke`
- Auth: HTTP bearer

Prepares `AllowanceModule.removeDelegate(delegate, true)` for the owner's
passkey to sign; `execute` with `grant_id` relays it and marks the grant
`revoked`. Audited as `passkey_safe.grant_revoked`.

## Response `200`

Grant and what to sign

- PasskeySafeGrantPrepare
  - `grant` PasskeySafeGrant
    - `id` string, uuid
    - `safe_id` string, uuid
    - `agent_id` string, uuid
    - `chain` string
    - `delegate_address` string: The agent's Ethereum signing key at grant time.
    - `token_address` string: 0x000…0 for the native token.
    - `allowance_amount` string: Base units per reset period.
    - `reset_time_min` integer
    - `status` 'pending' | 'active' | 'revoking' | 'revoked'
    - `setup_tx_hash` string, nullable
    - `revoke_tx_hash` string, nullable
    - `created_at` string, date-time
  - `prepare` PasskeySafePrepare
    - `safe_id` string, uuid
    - `safe_address` string
    - `chain` string
    - `chain_id` integer
    - `to` string
    - `value_wei` string
    - `data` string
    - `nonce` integer
    - `operation` integer: Pass back to `execute` unchanged.
    - `grant_id` string, uuid: Present for grant setup / revoke; pass back to `execute`.
    - `deploy_required` boolean
    - `safe_tx_hash` string: Hex SafeTx hash — the WebAuthn challenge (raw 32 bytes).
    - `credential_id` string
    - `transports` string[], nullable: The passkey's registered transports (`internal`, `hybrid`, `usb`…) — pass as the `allowCredentials` hint so the browser asks the right authenticator.
    - `passkey_name` string, nullable
    - `rp_id` string

## Other responses

- `401`: Authentication required or invalid
- `404`: Resource not found
- `409`: Resource already exists or conflict

---

[API](https://skmtc.dev/1claw/apis/1claw-api.md) · [All operations](https://skmtc.dev/1claw/apis/1claw-api/llms.txt) · [OpenAPI document](https://skmtc.dev/1claw/apis/1claw-api/revisions/5fa0918f3b41?raw)
