Skip to content

List a site's domains

Try it

The client's own domains connected to the site, the main one first, each with its status and the DNS records it needs.

GET/api/v1/sites/{site_id}/domains

Authentication

An API key as Authorization: Bearer or x-api-key. It needs the domains:read scope — see connected domains and their DNS records.

domains:readRead onlyMCP tool: list_domains

Parameters

Named placeholders go in the path; the rest in the query string.

site_idstringPath · required
The site's id.1 to 100 characters

Response

200 with JSON on success (schema on the right). Errors use the standard envelope.

curl
curl -X GET 'https://websites.workflowcorp.com/api/v1/sites/SITE_ID/domains' \
  -H "Authorization: Bearer $WEBSITEBUDDY_API_KEY"
Example arguments
{
  "site_id": "SITE_ID"
}
Response schema
{
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "type": "string"
          },
          "hostname": {
            "type": "string"
          },
          "status": {
            "type": "string",
            "enum": [
              "pending",
              "verified",
              "failed"
            ]
          },
          "primary": {
            "type": "boolean",
            "description": "The site's main address; the other domains send visitors here."
          },
          "verified_at": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ]
          },
          "last_checked_at": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ]
          },
          "last_error": {
            "anyOf": [
              {
                "type": "string"
              },
              {
                "type": "null"
              }
            ],
            "description": "What the last check found wrong, in plain words."
          },
          "https": {
            "type": "object",
            "properties": {
              "status": {
                "anyOf": [
                  {
                    "type": "string"
                  },
                  {
                    "type": "null"
                  }
                ],
                "description": "provisioning, active, failed — null while HTTPS isn't set up or the domain isn't verified."
              },
              "error": {
                "anyOf": [
                  {
                    "type": "string"
                  },
                  {
                    "type": "null"
                  }
                ]
              }
            },
            "required": [
              "status",
              "error"
            ],
            "additionalProperties": false
          },
          "dns_records": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "type": {
                  "type": "string"
                },
                "name": {
                  "type": "string"
                },
                "value": {
                  "type": "string"
                },
                "why": {
                  "type": "string"
                }
              },
              "required": [
                "type",
                "name",
                "value",
                "why"
              ],
              "additionalProperties": false
            },
            "description": "What to add at the company the domain is registered with, then call check_domain."
          },
          "created_at": {
            "type": "string"
          }
        },
        "required": [
          "id",
          "hostname",
          "status",
          "primary",
          "verified_at",
          "last_checked_at",
          "last_error",
          "https",
          "dns_records",
          "created_at"
        ],
        "additionalProperties": false
      }
    }
  },
  "required": [
    "data"
  ],
  "additionalProperties": false
}