# Cancel payment intent This endpoint allows to cancel a payment intent while it's status is [open] and it has not been send to the terminal yet. **DELETE** `/point/integration-api/devices/{deviceid}/payment-intents/{paymentintentid}` ## Request parameters ### Header - `x-test-scope` (string, optional) This is a temporary header. It should be used only in the development stage with the value "sandbox". When going to production, it should be removed ### Path - `deviceId` (string, required) Identifier of the device that will have a payment intent queued - `paymentIntentId` (string, required) Payment intent identifier ## Response parameters - `id` (string, optional) ## Errors | Status | Error | Description | | ------- | ------- | ----------- | | 401 | 401 | Unauthorized Token is invalid | | 403 | 403 | Forbidden - Integrator isn't registered | | 409 | — | Error | | 500 | 500 | Internal server error | ## Request example ### cURL ```bash curl -X DELETE \ 'https://api.mercadopago.com/point/integration-api/devices/{deviceid}/payment-intents/{paymentintentid}' \ -H 'Content-Type: application/json' \ -H 'Authorization: Bearer ' ``` ## Response example ```json { "id": "d71e88d6-6281-416b-b8ed-592c27352c99" } ```