# Cancel a Request

This API call allows the integrator to cancel an onboarding request. The request can be cancelled from any state, as long as it is not already in a terminal state.

Once cancelled, the request will transition to the `cancelled` status and will follow the standard anonymization process. This operation is not reversible.

## Endpoint

* **URL:** `/request/{id}/userCancel`
* **Method:** `POST`


## Headers

Ensure you include the following headers in your request:

* `Content-Type: application/json`
* `X-Api-Key: YOUR_API_KEY` (replace `YOUR_API_KEY` with your actual API key)


## Path parameters

* `id` (required): The unique identifier of the request you want to cancel. This should be included in the URL path. Example: `123e4567-e89b-12d3-a456-426614174000`


## Body parameters

* `reason` (optional): A text message describing the reason for the cancellation.


## Example cURL API call


```
curl -X POST "https://test-eu-ie1-api.namirialonboarding.com/api/v2/request/YOUR_REQUEST_ID/userCancel" \
-H "X-Api-Key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"reason": "cancellation reason"}'
```

Replace `YOUR_API_KEY` with your actual API key and `YOUR_REQUEST_ID` with the ID of the request.