---
title: Domain Configuration
url: https://docs.kaltura.com/docs/events-collaboration/messaging-api/messaging-domain-configuration
---

## Domain Configuration

Verify sender domains with your email provider for improved deliverability.

### 12.1 Add a Domain

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `domain` | string | Yes | The sender domain to verify (e.g., `events.example.com`) |
| `subdomain` | string | No | Subdomain prefix for DNS records (e.g., `mail`) |

```bash
curl -X POST "$KALTURA_MESSAGING_URL/domain/add" \
  -H "Authorization: Bearer $KALTURA_KS" \
  -H "Content-Type: application/json" \
  -d '{
    "domain": "events.example.com",
    "subdomain": "mail"
  }'
```

**Response:** Contains the DNS records (CNAME, TXT) to configure for domain verification. Add these records to your DNS configuration before activating.

### 12.2 Activate a Domain

After DNS propagation, activate the domain.

| Field | Type | Required | Description |
|-------|------|----------|-------------|
| `domain` | string | Yes | The domain to activate (must match a previously added domain) |
| `subdomain` | string | No | Subdomain prefix (must match the value used in `domain/add`) |

```bash
curl -X POST "$KALTURA_MESSAGING_URL/domain/activate" \
  -H "Authorization: Bearer $KALTURA_KS" \
  -H "Content-Type: application/json" \
  -d '{
    "domain": "events.example.com",
    "subdomain": "mail"
  }'
```

**Response:** Confirmation of domain activation. If DNS records are not yet propagated, the activation fails with an error.
