Domains

Register a domain

Registers the domain in the user's name, with DNS and DNSSEC set up here, and whois privacy where the extension allows it. accept_registry_terms must be true: the user explicitly accepted the registry's terms (registry_terms_url from the check). max_price_eur is the total the user confirmed for all years; a higher price is refused. A name with a higher registry price (premium in the check) is bought for 1 year only, with accept_price_eur exactly the price the user confirmed, and only up to a ceiling; if the registry price changed just before the purchase, nothing is bought. Needs an Idempotency-Key; the same key returns the same domain, and a key whose attempt failed is never retried (use a new key). In live mode the price is deducted from the balance; in test mode nothing is bought. Real purchases in live mode are not open yet: until they are, a live key gets service_unavailable, and test mode works as described.

post/domains/register

Request

  • Base URL: https://api.hypamoon.com/api/v1
  • URL: https://api.hypamoon.com/api/v1/domains/register
  • Auth: one of:
    • HTTP bearer
    • OAuth 2 (authorization code, authorization URL https://app.hypamoon.com/oauth/authorize, token URL https://api.hypamoon.com/oauth/token, scopes: sites:write)

Headers

Idempotency-Keystring required

A unique key for this purchase, like a UUID.

Request body

domainstring required

The domain, like example.com.

yearsinteger

Registration period in years. Most extensions only allow 1.

accept_registry_termsboolean required

Must be true: the user (the registrant) explicitly accepted the terms of the registry at registry_terms_url from check_domain.

max_price_eurnumber required

The highest total the user agreed to pay for all years together, as shown by check_domain. Refused if the price is higher.

accept_price_eurnumber

Only for a name with a higher registry price (premium true in check_domain): the price_eur for the first year exactly as check_domain showed it and the user confirmed. Without it, or if the price changed, nothing is bought.

site_idstring uuid nullable

Optional. A site of this project to serve on the domain once it is active.

Response

The registered domain.

Changes

No recorded changes to this operation across all 1 revision of this API.