---
updatedAt: 2026-08-04T00:01:49.000Z
agentTools:
  projectIndex: https://developers.akahu.nz/llms.txt
---

# Revoke a payment consent

Revoke one of the enduring payment consents granted for an account.

You can find the `_id` of a consent by looking at the `payment_consents` array on the [account](/reference/get_accounts-id) it belongs to.

Revoking a consent immediately prevents it from being used to initiate any further payments. This does not affect any other consents on the account, or the account's connection to your application.

For more details see:
  - [📚 Requesting Payment Consent guide](/docs/enduring-payments-authorisation)
  - [📖 Account model](/docs/the-account-model)

# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "info": {
    "title": "Akahu Enduring API",
    "description": "This API is the primary way for apps to interact with a user's data.",
    "version": "1.0.0"
  },
  "servers": [
    {
      "url": "https://api.akahu.io/v1"
    }
  ],
  "components": {
    "parameters": {
      "xAkahuId": {
        "name": "X-Akahu-Id",
        "in": "header",
        "required": true,
        "description": "Your **App ID Token**.",
        "schema": {
          "type": "string"
        },
        "example": "{{app_token}}"
      }
    },
    "securitySchemes": {
      "user_token": {
        "type": "http",
        "scheme": "bearer",
        "description": "User-level Authentication:\n\nHttp Bearer Auth with the token being a consented **User Access Token**.\n> `Bearer {user_token}`\n\nThis will allow you to act on a **user's** behalf when accessing the API."
      }
    },
    "responses": {
      "400": {
        "description": "Your request was malformed or otherwise unacceptable. More details are provided under the `message` key in the response.",
        "content": {
          "application/json": {
            "schema": {
              "type": "object",
              "properties": {
                "success": {
                  "type": "boolean",
                  "example": false
                },
                "message": {
                  "type": "string",
                  "example": "Invalid Content-Type"
                }
              }
            }
          }
        }
      },
      "401": {
        "description": "You are not authorised to access this content.",
        "content": {
          "application/json": {
            "schema": {
              "type": "object",
              "properties": {
                "success": {
                  "type": "boolean",
                  "example": false
                },
                "message": {
                  "type": "string",
                  "example": "Permission Denied"
                }
              }
            }
          }
        }
      },
      "403": {
        "description": "You are not allowed to access this content.",
        "content": {
          "application/json": {
            "schema": {
              "type": "object",
              "properties": {
                "success": {
                  "type": "boolean",
                  "example": false
                },
                "message": {
                  "type": "string",
                  "example": "Forbidden"
                }
              }
            }
          }
        }
      },
      "404": {
        "description": "The item you are trying to access doesn't exist.",
        "content": {
          "application/json": {
            "schema": {
              "type": "object",
              "properties": {
                "success": {
                  "type": "boolean",
                  "example": false
                },
                "message": {
                  "type": "string",
                  "example": "Not Found"
                }
              }
            }
          }
        }
      },
      "500": {
        "description": "An internal error has prevented us from processing the request. More detail may be supplied in the `message` key.",
        "content": {
          "application/json": {
            "schema": {
              "type": "object",
              "properties": {
                "success": {
                  "type": "boolean",
                  "example": false
                },
                "message": {
                  "type": "string",
                  "example": "Something went wrong"
                }
              }
            }
          }
        }
      }
    }
  },
  "tags": [
    {
      "name": "Accounts"
    }
  ],
  "paths": {
    "/accounts/{id}/payment-consents/{consent_id}": {
      "parameters": [
        {
          "name": "id",
          "in": "path",
          "required": true,
          "description": "An Akahu Account ID",
          "example": "acc_1111111111111111111111111",
          "schema": {
            "type": "string"
          }
        },
        {
          "name": "consent_id",
          "in": "path",
          "required": true,
          "description": "An Akahu Payment Consent ID",
          "example": "consent_1111111111111111111111111",
          "schema": {
            "type": "string"
          }
        }
      ],
      "delete": {
        "tags": [
          "Accounts"
        ],
        "summary": "Revoke a payment consent",
        "security": [
          {
            "user_token": []
          }
        ],
        "description": "Revoke one of the enduring payment consents granted for an account.\n\nYou can find the `_id` of a consent by looking at the `payment_consents` array on the [account](/reference/get_accounts-id) it belongs to.\n\nRevoking a consent immediately prevents it from being used to initiate any further payments. This does not affect any other consents on the account, or the account's connection to your application.\n\nFor more details see:\n  - [📚 Requesting Payment Consent guide](/docs/enduring-payments-authorisation)\n  - [📖 Account model](/docs/the-account-model)",
        "parameters": [
          {
            "$ref": "#/components/parameters/xAkahuId"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful response.",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object",
                  "properties": {
                    "success": {
                      "type": "boolean"
                    }
                  }
                },
                "example": {
                  "success": true
                }
              }
            }
          },
          "400": {
            "$ref": "#/components/responses/400"
          },
          "401": {
            "$ref": "#/components/responses/401"
          },
          "403": {
            "$ref": "#/components/responses/403"
          },
          "404": {
            "$ref": "#/components/responses/404"
          },
          "500": {
            "$ref": "#/components/responses/500"
          }
        }
      }
    }
  }
}
```