Skip to main content
POST /v1/account/domains API Key

Register a domain

Register a new domain for the account. The first domain registered becomes
the primary domain. New domains start in pending verification status.

After registration, use the returned verification instructions to add DNS
records for both TXT (ownership) and CNAME (routing) verification.

Parameters

Name Location Type Description
X-API-Key * header string API key for authentication

* Required parameter

Request Body

application/json

Parameters for registering a domain

domain * string

Domain name to register

Example: trust.example.com

Response

201 Domain registered

Content-Type: application/json

success boolean
data object

A custom domain for the account's verifiable credentials

domain * string

The domain name (also serves as unique identifier)

Example: trust.example.com

did * string

The DID derived from this domain

Example: did:web:trust.example.com

primary * boolean

Whether this is the primary domain for the account

Example: true

fully_verified * boolean

Whether both TXT and CNAME verification have passed

Example: true

txt_status * string

TXT record verification status

Allowed values: "pending", "verified", "failed"

Example: verified

txt_verified_at string (date-time) nullable

When TXT verification passed

Example: 2025-01-10T09:00:00Z

cname_verified * boolean

Whether CNAME verification has passed

Example: true

cname_verified_at string (date-time) nullable

When CNAME verification passed

Example: 2025-01-10T09:30:00Z

created_at * string (date-time)

When the domain was created

Example: 2025-01-01T00:00:00Z

updated_at * string (date-time)

When the domain was last updated

Example: 2025-01-10T09:30:00Z

verification object

Domain verification instructions

txt object
host string

DNS host for TXT record

Example: _aho_35ef2763-464d-4030-adb2-ae82a961e8ca.example.com

value string

TXT record value

Example: 289a830e17ef62cf5e0ce5c6da37fe94a86a319d415fb39a37e3cb2282a1a61e

instructions string

Human-readable instructions

Example: Add a TXT record with the specified value

cname object
host string

Domain to configure CNAME for

Example: trust.example.com

target string

CNAME target

Example: customers.aho.com

instructions string

Human-readable instructions

Example: Add a CNAME record pointing to the target

Code Examples

import os
from aho_sdk import AhoSdk

client = AhoSdk.account(api_key=os.environ["AHO_API_KEY"])

result = client.domains.create(
    body={
        "domain": "trust.example.com"
    }
)

Try It

Log in to test this endpoint directly from the documentation.

Log in