Skip to main content

Domains API

Connect custom domains and subdomains to your workspace, manage DNS verification, and create URL mappings to route visitors to specific forms.

List Domains

curl https://www.zevform.com/api/v1/domains \
  -H "Authorization: Bearer zev_your_api_key"

Response

{
  "data": [
    {
      "id": "d1a2b3c4-...",
      "domain": "forms.example.com",
      "status": "verified",
      "created_at": "2026-03-28T10:00:00Z",
      "verified_at": "2026-03-28T10:05:00Z"
    },
    {
      "id": "e5f6a7b8-...",
      "domain": "myworkspace.zevform.com",
      "status": "verified",
      "created_at": "2026-03-27T08:00:00Z",
      "verified_at": "2026-03-27T08:00:00Z"
    }
  ]
}

Add Domain

Add a custom domain or subdomain. Subdomains (yourslug.zevform.com) are verified automatically. Custom domains require DNS verification.
curl -X POST https://www.zevform.com/api/v1/domains \
  -H "Authorization: Bearer zev_your_api_key" \
  -H "Content-Type: application/json" \
  -d '{ "domain": "forms.example.com" }'

Response

{
  "data": {
    "id": "d1a2b3c4-...",
    "domain": "forms.example.com",
    "status": "pending",
    "verification_token": "zevform-verify-abc123...",
    "created_at": "2026-03-28T10:00:00Z",
    "verified_at": null
  }
}

DNS Setup

For custom domains, create a CNAME record pointing to:
bccf2b63ee5f8a61.vercel-dns-016.com
Then call the verify endpoint to confirm.

Get Domain

curl https://www.zevform.com/api/v1/domains/{domainId} \
  -H "Authorization: Bearer zev_your_api_key"

Response

{
  "data": {
    "id": "d1a2b3c4-...",
    "domain": "forms.example.com",
    "status": "verified",
    "verification_token": "zevform-verify-abc123...",
    "created_at": "2026-03-28T10:00:00Z",
    "verified_at": "2026-03-28T10:05:00Z",
    "ssl": {
      "configured": true,
      "verified": true,
      "sslReady": true
    }
  }
}

Verify Domain

Trigger DNS verification for a pending custom domain.
curl -X PATCH https://www.zevform.com/api/v1/domains/{domainId} \
  -H "Authorization: Bearer zev_your_api_key"

Response

{
  "data": {
    "status": "verified",
    "message": "Domain verified successfully"
  }
}

Delete Domain

Removes the domain and all its URL mappings.
curl -X DELETE https://www.zevform.com/api/v1/domains/{domainId} \
  -H "Authorization: Bearer zev_your_api_key"

URL Mappings

Map URL paths on your domain to specific forms.

List URL Mappings

curl https://www.zevform.com/api/v1/domains/{domainId}/urls \
  -H "Authorization: Bearer zev_your_api_key"

Response

{
  "data": [
    {
      "id": "url_001",
      "form_id": "form_abc123",
      "slug": "feedback",
      "is_default": false,
      "created_at": "2026-03-28T12:00:00Z",
      "updated_at": "2026-03-28T12:00:00Z"
    }
  ]
}

Create URL Mapping

curl -X POST https://www.zevform.com/api/v1/domains/{domainId}/urls \
  -H "Authorization: Bearer zev_your_api_key" \
  -H "Content-Type: application/json" \
  -d '{
    "form_id": "form_abc123",
    "slug": "feedback",
    "is_default": false
  }'
ParameterTypeRequiredDescription
form_idstringYesID of the form to map
slugstringYesURL path (lowercase letters, numbers, hyphens)
is_defaultbooleanNoShow this form at the root of the domain

Update URL Mapping

curl -X PATCH https://www.zevform.com/api/v1/domains/{domainId}/urls/{urlId} \
  -H "Authorization: Bearer zev_your_api_key" \
  -H "Content-Type: application/json" \
  -d '{ "slug": "new-slug" }'

Delete URL Mapping

curl -X DELETE https://www.zevform.com/api/v1/domains/{domainId}/urls/{urlId} \
  -H "Authorization: Bearer zev_your_api_key"