# dns_provider_token_invalid

The DNS provider did not accept that API token.

## What it means

The token pasted on the connect page for **Add it for me** was not accepted. Apexly used it for this one request and did not store it.

## Why it happens

- Part of the token was left out when copying.
- The token was deleted, disabled or has expired.
- The value is a Global API Key or a token ID, not an API token.

## What to do

1. Create a new token from the **Edit zone DNS** template, limited to this domain.
2. Copy the whole value Cloudflare shows once, and paste it again.

- [Connect page](/docs/connect-page)
- [Embed the connect flow](/docs/guides/embed-connect)

## In the API

```
HTTP 422

{
  "error": {
    "code": "dns_provider_token_invalid",
    "message": "The DNS provider did not accept that API token.",
    "fix": "Create a new token that can edit DNS for this domain, copy all of it, and paste it again.",
    "docs": "https://docs.apexly.dev/errors/dns_provider_token_invalid"
  }
}
```
