---
title: "Cancel a payment"
method: PUT
path: "/payments/{id}/cancel"
tags: ["Payments"]
---

# Cancel a payment

`PUT /payments/{id}/cancel`

This endpoint cancels a user's payment that is in the `PENDING_APPROVAL` state.

For more details about payments see:
  - [📚 Payment lifecycle guide](/docs/making-a-payment#payment-lifecycle)
  - [📚 Payment webhooks](/docs/reference-webhooks#payment)
  - [📖 Making a payment guide](/docs/making-a-payment)

## Headers

- `X-Akahu-Id` string, required

## Response `200`

Successful response.

- object
  - `success` boolean

## Other responses

- `400` — Your request was malformed or otherwise unacceptable. More details are provided under the `message` key in the response.
- `401` — You are not authorised to access this content.
- `403` — You are not allowed to access this content.
- `404` — The item you are trying to access doesn't exist.
- `500` — An internal error has prevented us from processing the request. More detail may be supplied in the `message` key.

---

[API](https://skmtc.dev/akahu/apis/akahu-enduring-api.md) · [All operations](https://skmtc.dev/akahu/apis/akahu-enduring-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/akahu/akahu-enduring-api/revisions/b2de9915920d/schema)
