Skip to content
Start here

Custom Hostnames

List Custom Hostnames
client.CustomHostnames.List(ctx, params) (*V4PagePaginationArray[CustomHostnameListResponse], error)
GET/zones/{zone_id}/custom_hostnames
Custom Hostname Details
client.CustomHostnames.Get(ctx, customHostnameID, query) (*CustomHostnameGetResponse, error)
GET/zones/{zone_id}/custom_hostnames/{custom_hostname_id}
Create Custom Hostname
client.CustomHostnames.New(ctx, params) (*CustomHostnameNewResponse, error)
POST/zones/{zone_id}/custom_hostnames
Edit Custom Hostname
client.CustomHostnames.Edit(ctx, customHostnameID, params) (*CustomHostnameEditResponse, error)
PATCH/zones/{zone_id}/custom_hostnames/{custom_hostname_id}
Delete Custom Hostname (and any issued SSL certificates)
client.CustomHostnames.Delete(ctx, customHostnameID, body) (*CustomHostnameDeleteResponse, error)
DELETE/zones/{zone_id}/custom_hostnames/{custom_hostname_id}
ModelsExpand Collapse
type BundleMethod string

A ubiquitous bundle has the highest probability of being verified everywhere, even by clients using outdated or unusual trust stores. An optimal bundle uses the shortest chain and newest intermediates. And the force bundle verifies the chain, but does not otherwise modify it.

One of the following:
const BundleMethodUbiquitous BundleMethod = "ubiquitous"
const BundleMethodOptimal BundleMethod = "optimal"
const BundleMethodForce BundleMethod = "force"
type CustomHostname struct{…}
ID string

Identifier.

maxLength32
Hostname string

The custom hostname that will point to your hostname via CNAME.

maxLength255
CreatedAt Timeoptional

This is the time the hostname was created.

formatdate-time
CustomMetadata map[string, string]optional

Unique key/value metadata for this hostname. These are per-hostname (customer) settings.

CustomOriginServer stringoptional

a valid hostname that’s been added to your DNS zone as an A, AAAA, or CNAME record.

CustomOriginSNI stringoptional

A hostname that will be sent to your custom origin server as SNI for TLS handshake. This can be a valid subdomain of the zone or custom origin server name or the string ':request_host_header:' which will cause the host header in the request to be used as SNI. Not configurable with default/fallback origin server.

OwnershipVerification CustomHostnameOwnershipVerificationoptional

This is a record which can be placed to activate a hostname.

Name stringoptional

DNS Name for record.

Type CustomHostnameOwnershipVerificationTypeoptional

DNS Record type.

Value stringoptional

Content for the record.

OwnershipVerificationHTTP CustomHostnameOwnershipVerificationHTTPoptional

This presents the token to be served by the given http url to activate a hostname.

HTTPBody stringoptional

Token to be served.

HTTPURL stringoptional

The HTTP URL that will be checked during custom hostname verification and where the customer should host the token.

SSL CustomHostnameSSLoptional
ID stringoptional

Custom hostname SSL identifier tag.

maxLength36
minLength36
BundleMethod BundleMethodoptional

A ubiquitous bundle has the highest probability of being verified everywhere, even by clients using outdated or unusual trust stores. An optimal bundle uses the shortest chain and newest intermediates. And the force bundle verifies the chain, but does not otherwise modify it.

CertificateAuthority CertificateCAoptional

The Certificate Authority that will issue the certificate

CustomCertificate stringoptional

If a custom uploaded certificate is used.

CustomCsrID stringoptional

The identifier for the Custom CSR that was used.

CustomKey stringoptional

The key for a custom uploaded certificate.

DCVDelegationRecords []CustomHostnameSsldcvDelegationRecordoptional

DCV Delegation records for domain validation.

CNAME stringoptional

The CNAME record hostname for DCV delegation.

CNAMETarget stringoptional

The CNAME record target value for DCV delegation.

Emails []stringoptional

The set of email addresses that the certificate authority (CA) will use to complete domain validation.

HTTPBody stringoptional

The content that the certificate authority (CA) will expect to find at the http_url during the domain validation.

HTTPURL stringoptional

The url that will be checked during domain validation.

Status stringoptional

Status of the validation record.

TXTName stringoptional

The hostname that the certificate authority (CA) will check for a TXT record during domain validation .

TXTValue stringoptional

The TXT record that the certificate authority (CA) will check during domain validation.

ExpiresOn Timeoptional

The time the custom certificate expires on.

formatdate-time
Hosts []stringoptional

A list of Hostnames on a custom uploaded certificate.

Issuer stringoptional

The issuer on a custom uploaded certificate.

Method DCVMethodoptional

Domain control validation (DCV) method used for this hostname.

SerialNumber stringoptional

The serial number on a custom uploaded certificate.

Settings CustomHostnameSSLSettingsoptional
Ciphers []stringoptional

An allowlist of ciphers for TLS termination. These ciphers must be in the BoringSSL format.

EarlyHints CustomHostnameSSLSettingsEarlyHintsoptional

Whether or not Early Hints is enabled.

One of the following:
const CustomHostnameSSLSettingsEarlyHintsOn CustomHostnameSSLSettingsEarlyHints = "on"
const CustomHostnameSSLSettingsEarlyHintsOff CustomHostnameSSLSettingsEarlyHints = "off"
HTTP2 CustomHostnameSSLSettingsHTTP2optional

Whether or not HTTP2 is enabled.

One of the following:
const CustomHostnameSSLSettingsHTTP2On CustomHostnameSSLSettingsHTTP2 = "on"
const CustomHostnameSSLSettingsHTTP2Off CustomHostnameSSLSettingsHTTP2 = "off"
MinTLSVersion CustomHostnameSSLSettingsMinTLSVersionoptional

The minimum TLS version supported.

One of the following:
const CustomHostnameSSLSettingsMinTLSVersion1_0 CustomHostnameSSLSettingsMinTLSVersion = "1.0"
const CustomHostnameSSLSettingsMinTLSVersion1_1 CustomHostnameSSLSettingsMinTLSVersion = "1.1"
const CustomHostnameSSLSettingsMinTLSVersion1_2 CustomHostnameSSLSettingsMinTLSVersion = "1.2"
const CustomHostnameSSLSettingsMinTLSVersion1_3 CustomHostnameSSLSettingsMinTLSVersion = "1.3"
TLS1_3 CustomHostnameSSLSettingsTLS1_3optional

Whether or not TLS 1.3 is enabled.

One of the following:
const CustomHostnameSSLSettingsTLS1_3On CustomHostnameSSLSettingsTLS1_3 = "on"
const CustomHostnameSSLSettingsTLS1_3Off CustomHostnameSSLSettingsTLS1_3 = "off"
Signature stringoptional

The signature on a custom uploaded certificate.

Status CustomHostnameSSLStatusoptional

Status of the hostname's SSL certificates.

One of the following:
const CustomHostnameSSLStatusInitializing CustomHostnameSSLStatus = "initializing"
const CustomHostnameSSLStatusPendingValidation CustomHostnameSSLStatus = "pending_validation"
const CustomHostnameSSLStatusDeleted CustomHostnameSSLStatus = "deleted"
const CustomHostnameSSLStatusPendingIssuance CustomHostnameSSLStatus = "pending_issuance"
const CustomHostnameSSLStatusPendingDeployment CustomHostnameSSLStatus = "pending_deployment"
const CustomHostnameSSLStatusPendingDeletion CustomHostnameSSLStatus = "pending_deletion"
const CustomHostnameSSLStatusPendingExpiration CustomHostnameSSLStatus = "pending_expiration"
const CustomHostnameSSLStatusExpired CustomHostnameSSLStatus = "expired"
const CustomHostnameSSLStatusActive CustomHostnameSSLStatus = "active"
const CustomHostnameSSLStatusInitializingTimedOut CustomHostnameSSLStatus = "initializing_timed_out"
const CustomHostnameSSLStatusValidationTimedOut CustomHostnameSSLStatus = "validation_timed_out"
const CustomHostnameSSLStatusIssuanceTimedOut CustomHostnameSSLStatus = "issuance_timed_out"
const CustomHostnameSSLStatusDeploymentTimedOut CustomHostnameSSLStatus = "deployment_timed_out"
const CustomHostnameSSLStatusDeletionTimedOut CustomHostnameSSLStatus = "deletion_timed_out"
const CustomHostnameSSLStatusPendingCleanup CustomHostnameSSLStatus = "pending_cleanup"
const CustomHostnameSSLStatusStagingDeployment CustomHostnameSSLStatus = "staging_deployment"
const CustomHostnameSSLStatusStagingActive CustomHostnameSSLStatus = "staging_active"
const CustomHostnameSSLStatusDeactivating CustomHostnameSSLStatus = "deactivating"
const CustomHostnameSSLStatusInactive CustomHostnameSSLStatus = "inactive"
const CustomHostnameSSLStatusBackupIssued CustomHostnameSSLStatus = "backup_issued"
const CustomHostnameSSLStatusHoldingDeployment CustomHostnameSSLStatus = "holding_deployment"

Level of validation to be used for this hostname. Domain validation (dv) must be used.

UploadedOn Timeoptional

The time the custom certificate was uploaded.

formatdate-time
ValidationErrors []CustomHostnameSSLValidationErroroptional

Domain validation errors that have been received by the certificate authority (CA).

Message stringoptional

A domain validation error.

ValidationRecords []CustomHostnameSSLValidationRecordoptional
CNAME stringoptional

The CNAME record hostname for DCV delegation.

CNAMETarget stringoptional

The CNAME record target value for DCV delegation.

Emails []stringoptional

The set of email addresses that the certificate authority (CA) will use to complete domain validation.

HTTPBody stringoptional

The content that the certificate authority (CA) will expect to find at the http_url during the domain validation.

HTTPURL stringoptional

The url that will be checked during domain validation.

Status stringoptional

Status of the validation record.

TXTName stringoptional

The hostname that the certificate authority (CA) will check for a TXT record during domain validation .

TXTValue stringoptional

The TXT record that the certificate authority (CA) will check during domain validation.

Wildcard booloptional

Indicates whether the certificate covers a wildcard.

Status CustomHostnameStatusoptional

Status of the hostname's activation.

One of the following:
const CustomHostnameStatusActive CustomHostnameStatus = "active"
const CustomHostnameStatusPending CustomHostnameStatus = "pending"
const CustomHostnameStatusActiveRedeploying CustomHostnameStatus = "active_redeploying"
const CustomHostnameStatusMoved CustomHostnameStatus = "moved"
const CustomHostnameStatusPendingDeletion CustomHostnameStatus = "pending_deletion"
const CustomHostnameStatusDeleted CustomHostnameStatus = "deleted"
const CustomHostnameStatusPendingBlocked CustomHostnameStatus = "pending_blocked"
const CustomHostnameStatusPendingMigration CustomHostnameStatus = "pending_migration"
const CustomHostnameStatusPendingProvisioned CustomHostnameStatus = "pending_provisioned"
const CustomHostnameStatusTestPending CustomHostnameStatus = "test_pending"
const CustomHostnameStatusTestActive CustomHostnameStatus = "test_active"
const CustomHostnameStatusTestActiveApex CustomHostnameStatus = "test_active_apex"
const CustomHostnameStatusTestBlocked CustomHostnameStatus = "test_blocked"
const CustomHostnameStatusTestFailed CustomHostnameStatus = "test_failed"
const CustomHostnameStatusProvisioned CustomHostnameStatus = "provisioned"
const CustomHostnameStatusBlocked CustomHostnameStatus = "blocked"
VerificationErrors []stringoptional

These are errors that were encountered while trying to activate a hostname.

type DCVMethod string

Domain control validation (DCV) method used for this hostname.

One of the following:
const DCVMethodHTTP DCVMethod = "http"
const DCVMethodTXT DCVMethod = "txt"
const DCVMethodEmail DCVMethod = "email"
type DomainValidationType string

Level of validation to be used for this hostname. Domain validation (dv) must be used.

Custom HostnamesFallback Origin

Get Fallback Origin for Custom Hostnames
client.CustomHostnames.FallbackOrigin.Get(ctx, query) (*FallbackOriginGetResponse, error)
GET/zones/{zone_id}/custom_hostnames/fallback_origin
Update Fallback Origin for Custom Hostnames
client.CustomHostnames.FallbackOrigin.Update(ctx, params) (*FallbackOriginUpdateResponse, error)
PUT/zones/{zone_id}/custom_hostnames/fallback_origin
Delete Fallback Origin for Custom Hostnames
client.CustomHostnames.FallbackOrigin.Delete(ctx, body) (*FallbackOriginDeleteResponse, error)
DELETE/zones/{zone_id}/custom_hostnames/fallback_origin

Custom HostnamesCertificate Pack

Custom HostnamesCertificate PackCertificates

Replace Custom Certificate and Custom Key In Custom Hostname
client.CustomHostnames.CertificatePack.Certificates.Update(ctx, customHostnameID, certificatePackID, certificateID, params) (*CertificatePackCertificateUpdateResponse, error)
PUT/zones/{zone_id}/custom_hostnames/{custom_hostname_id}/certificate_pack/{certificate_pack_id}/certificates/{certificate_id}
Delete Single Certificate And Key For Custom Hostname
client.CustomHostnames.CertificatePack.Certificates.Delete(ctx, customHostnameID, certificatePackID, certificateID, body) (*CertificatePackCertificateDeleteResponse, error)
DELETE/zones/{zone_id}/custom_hostnames/{custom_hostname_id}/certificate_pack/{certificate_pack_id}/certificates/{certificate_id}