# Connect a Cloudflare token scoped to this zone

`POST /workspace/domains/{d}/cloudflare` · Rivier · domains

Connect a Cloudflare token scoped to this zone. The token is sealed and never returned.

- Scope: domains:write
- Sdk: domains.domain.connectCloudflare
- Cli: domains domain connect cloudflare

## Parameters

- `d` (path, required), string

## Request body

`application/json`

```json
{
  "type": "object",
  "properties": {
    "token": {
      "type": "string",
      "minLength": 20,
      "maxLength": 200
    }
  },
  "required": [
    "token"
  ],
  "additionalProperties": false
}
```

## Responses

- `200`: Success
- `400`: The request was malformed
- `401`: No valid credential
- `403`: The credential lacks the scope, origin or address
- `429`: Over the key's rate limit; see Retry-After

## Example

```sh
curl -X POST 'https://api.rivier.ai/workspace/domains/{d}/cloudflare' \
  -H 'Authorization: Bearer $KEY' \
  -H 'Content-Type: application/json' \
  -d '{
  "token": "string"
}'
```
