> ## Documentation Index
> Fetch the complete documentation index at: https://developers.pcibooking.net/llms.txt
> Use this file to discover all available pages before exploring further.

# Delete Card By Link Request

> Delete a Card By Link request. Clicking a deleted request's link shows an 'invalid link' message.

<Card title="Card By Link Guide" icon="book" href="/capture-cards/card-by-link">
  Send secure card capture links via email or SMS
</Card>

Use this endpoint to cancel an active Card By Link request. Once deleted, the capture link becomes invalid and the cardholder sees an "invalid link" message if they try to open it. Delete requests that are no longer needed or that were sent in error.

## Error Responses

| Code  | HTTP Status | Condition                                                                |
| ----- | ----------- | ------------------------------------------------------------------------ |
| -1003 | 401         | Missing or invalid API key in the `Authorization` header.                |
| -160  | 404         | Card request not found, or request has already been deleted or archived. |

## Parameters

### Headers

<ParamField header="Authorization" type="string" required>
  Your API key prefixed with `APIKEY`. Example: `APIKEY your-api-key`. See the [Authentication guide](/getting-started/authentication).
</ParamField>

### Path Parameters

<ParamField path="requestID" type="string" required>
  The request ID received from sending the card form to the customer.
</ParamField>

<RequestExample>
  ```javascript Node.js theme={null}
  const requestID = 'SULqe7pa22gghYDnX6O3J7QDMhyyUzNb';

  const response = await fetch(
    `https://service.pcibooking.net/api/cardrequest/${requestID}`,
    {
      method: 'DELETE',
      headers: {
        'Authorization': 'APIKEY your-api-key'
      }
    }
  );

  console.log('Deleted:', response.status === 200);
  ```

  ```python Python theme={null}
  import requests

  request_id = 'SULqe7pa22gghYDnX6O3J7QDMhyyUzNb'

  response = requests.delete(
      f'https://service.pcibooking.net/api/cardrequest/{request_id}',
      headers={
          'Authorization': 'APIKEY your-api-key'
      }
  )

  print('Deleted:', response.status_code == 200)
  ```
</RequestExample>

## Response

**200** - Empty body. The card request has been deleted.

<ResponseExample>
  ```text 200 theme={null}
  Empty response body. Card request deleted successfully.
  ```

  ```json 401 theme={null}
  {
      "code": -1003,
      "message": "Not authorized to access this resource",
      "moreInfo": "Bad or missing authorization data, expected APIKEY",
      "errorList": null
  }
  ```

  ```json 404 theme={null}
  {
      "code": -160,
      "message": "Uri not found",
      "moreInfo": "Card request not found",
      "errorList": null
  }
  ```
</ResponseExample>
