---
title: "Get a domain inventory record"
method: GET
path: "/v1/domains/{domainId}"
tags: ["Domains"]
---

# Get a domain inventory record

`GET /v1/domains/{domainId}`

## Request

- Base URL: `https://api.spacefast.com`
- URL: `https://api.spacefast.com/v1/domains/{domainId}`
- Auth: one of:
  - HTTP bearer
  - OAuth 2 (authorization code, authorization URL `https://api.spacefast.com/v1/auth/oauth2/authorize`, token URL `https://api.spacefast.com/v1/auth/oauth2/token`; client credentials, token URL `https://api.spacefast.com/v1/auth/oauth2/token`, scopes: `domains:read`)

Return a domain record with its verification, Space assignment, registration, and DNS state.

## Path parameters

- `domainId` string, required

## Response `200`

Response for status 200

- object
  - `$schema` string, uri: Canonical JSON Schema URL for this response body. The server also sends it in the `Link: rel="describedby"` response header.
  - `data` object, required
    - `id` string, required: Domain inventory record id (`dom_...`).
    - `tenantId` string, required: Tenant that owns this record (`ten_...`).
    - `principal` object, required: Tenant-local principal that owns this domain: a team in the main tenant, an external customer in partner integrations.
      - `tenantId` string, required
      - `principalType` 'team' | 'external', required
      - `principalId` string, required
    - `name` string, required: Canonical lowercase ASCII A-labels (IDNA2008/punycode), no trailing dot, no wildcard label.
    - `unicodeName` string: Read-only U-label form, present only when it differs from `name`.
    - `kind` 'hostname' | 'apex', required: Derived field, never create input: `apex` if and only if `name` equals `derivedGroup`.
    - `wildcardEnabled` boolean, required: Whether wildcard hostnames can be derived from this record.
    - `spaceId` string, nullable, required: Space this hostname selects (`spc_...`), or null when the record is inventory only. One Space per hostname; a Space may hold many domains.
    - `primary` boolean, required: Whether this domain is its Space's primary hostname (feeds `liveUrl`).
    - `redirect` object: Whole-host redirect target; present only on redirecting domains.
      - `to` union, required: Redirect destination: an absolute URL, or a space (optionally with a path).
        - object
          - `url` string, uri, required: Absolute URL to redirect to.
        - object
          - `spaceId` string, required: Space to redirect to (`spc_...`).
          - `path` string: Path on the target space.
      - `status` string, required
    - `derivedGroup` string, required: PSL registrable domain of `name`; server-computed, never client-supplied.
    - `registrar` object: Registration facet; present only on apex records.
      - `mode` 'spacefast' | 'external', required: Whether Spacefast manages this registration or an external registrar holds it.
      - `provider` string: Registrar provider key for a Spacefast-managed registration, for example `wpcom`.
      - `status` 'active' | 'pending_purchase' | 'pending_transfer_in' | 'expiring' | 'expired' | 'locked': Registration lifecycle status; `expiring` is derived from the expiry date.
      - `expiresAt` string, date-time: Instant when the registration expires.
      - `redemptionEndsAt` string, date-time: Instant when the provider grace or redemption window ends after expiry.
      - `autoRenew` boolean: Whether the registration renews automatically.
      - `transferLock` boolean: Whether outbound transfers are locked at the registrar.
    - `dns` object: DNS hosting facet; present only on zone-cut-owning records.
      - `mode` 'spacefast' | 'external', required: Whether Spacefast hosts the authoritative zone or an external DNS provider does.
      - `managementKind` 'unmanaged_external' | 'connected_provider' | 'spacefast_nameservers': Derived DNS management state. This field is additive. `mode` remains the v1 compatibility field.
      - `dnsMode` 'authoritative' | 'adapter': Hybrid DNS mode derived from `managementKind`: authoritative when Spacefast hosts the zone, or adapter when records are managed or observed on the user's existing host. This field is an additive read-model label.
      - `provider` string: DNS provider key for a Spacefast-hosted zone, for example `spacefast` or `wpcom`.
      - `assignedNameservers` string[]: Nameservers the registrar should use when Spacefast hosts the zone.
      - `observedNameservers` string[]: Nameservers currently observed in public DNS; polled in both modes.
      - `ownershipProof` object, nullable: The TXT record Spacefast DNS waits for before serving this zone. Add it at the DNS provider that answers for the domain now and keep the current nameservers until Spacefast sees it; Spacefast checks public DNS automatically. Present for Spacefast-hosted DNS; `null` when no proof is needed.
        - `type` 'A' | 'AAAA' | 'CNAME' | 'TXT' | 'ALIAS', required
        - `name` string, required: Record name to create, relative to the zone.
        - `value` string, required: Exact record value to set.
        - `ttl` integer
        - `purpose` 'verification' | 'routing' | 'ssl', required: Why this record is needed.
      - `snapshot` object: Connected-provider record snapshot freshness for portfolio lists.
        - `freshness` 'fresh' | 'stale' | 'refresh_running' | 'refresh_failed' | 'never_fetched', required
        - `lastFetchedAt` string, date-time, nullable, required
        - `version` string, nullable, required
      - `lastOperation` object: Latest DNS operation summary for portfolio and recovery surfaces.
        - `id` string, required
        - `kind` string, required
        - `status` 'queued' | 'running' | 'observing' | 'succeeded' | 'failed' | 'canceled', required
        - `updatedAt` string, date-time, required
    - `verification` object, required: Proof-of-control read model.
      - `status` 'not_required' | 'pending' | 'verified' | 'failed', required: Current proof of DNS control. `failed` alone never tears down compiled serving state.
      - `requiredRecords` object[]: DNS records the caller must create to prove control and route traffic.
        - `type` 'A' | 'AAAA' | 'CNAME' | 'TXT' | 'ALIAS', required
        - `name` string, required: Record name to create, relative to the zone.
        - `value` string, required: Exact record value to set.
        - `ttl` integer
        - `purpose` 'verification' | 'routing' | 'ssl', required: Why this record is needed.
      - `lastCheckedAt` string, date-time, nullable: Instant when observed DNS was last polled.
      - `lastVerifiedAt` string, date-time, nullable: Instant when this domain last proved DNS control.
      - `diagnostics` object[]: Structured verification diagnostics with stable codes.
        - `code` string, required: Stable snake_case diagnostic code naming the public contract that produced it.
        - `severity` 'info' | 'warning' | 'error', required: How actionable the diagnostic is.
        - `message` string, required: Human-readable explanation with enough detail to act on.
        - `path` string, nullable: Artifact path the diagnostic points at, for example "_headers:12", when one exists.
        - `provider` 'infra' | 'dns' | 'registrar' | 'runtime', nullable: Upstream system the diagnostic originated from, when not Spacefast itself.
        - `details` object, nullable: Machine-readable context for the diagnostic code.
        - `fix` string, nullable: Concrete, agent-actionable remediation hint, when one can be derived.
        - `retryable` boolean, nullable: Whether retrying the same operation can resolve this diagnostic without the caller changing anything.
    - `hints` object[]: Projected domain hints derived from diagnostics, actions, observations, and operations.
      - `id` string, required
      - `code` string, required
      - `severity` 'info' | 'warning' | 'error', required
      - `painLevel` 'info' | 'needs_attention' | 'blocked' | 'broken' | 'dangerous', required
      - `subjectFacet` 'dns_zone' | 'registrar' | 'hosting_binding' | 'email' | 'forwarding' | 'provider_connection', required
      - `subjectRef` object, required
        - `domainId` string, required
        - `zoneId` string
        - `bindingId` string
        - `connectionId` string
      - `owner` 'spacefast' | 'user' | 'registrar' | 'provider' | 'support' | 'waiting', required
      - `status` 'active' | 'waiting' | 'running' | 'resolved' | 'dismissed', required
      - `summary` string, required
      - `description` string, required
      - `impact` string, required
      - `evidence` object[], required
        - `label` string, required
        - `value` string, required
        - `observedAt` string, date-time
        - `source` 'provider_api' | 'public_dns' | 'registrar' | 'spacefast_db' | 'operation' | 'user_input', required
      - `suggestions` object[], required
        - `label` string, required
        - `description` string, required
        - `action` union, required
          - object
            - `type` 'open_pending_action', required
            - `actionId` string, required
          - object
            - `type` 'run_action', required
            - `actionKind` string, required
          - object
            - `type` 'copy_records', required
            - `records` object[], required
              - …
          - object
            - `type` 'refresh', required
            - `target` string, required
          - object
            - `type` 'reconnect_provider', required
            - `connectionId` string, required
          - object
            - `type` 'open_external', required
            - `url` string, uri, required
          - object
            - `type` 'wait', required
            - `retryAfter` string, date-time, required
        - `primary` boolean
        - `destructive` boolean
      - `docsUrl` string, uri
      - `operationId` string
      - `requestId` string
      - `providerRequestId` string
      - `expiresAt` string, date-time
    - `createdAt` string, date-time, required: Instant when the record was created.
    - `updatedAt` string, date-time, required: Instant when the record last changed.

## Other responses

- `default`: Problem details (RFC 9457). Any 4xx/5xx response is one `application/problem+json` document.

---

[API](https://skmtc.dev/spacefast/apis/spacefast-api.md) · [All operations](https://skmtc.dev/spacefast/apis/spacefast-api/llms.txt) · [OpenAPI document](https://skmtc.dev/spacefast/apis/spacefast-api/revisions/bd165bc7c983?raw)
