---
title: Hostnames
---

[Skip to content](#_top)

[API Reference](https://developers.cloudflare.com/api/go)

Copy Markdown

Open in **Claude**Open in **ChatGPT**Open in **Cursor**

---

**Copy Markdown****View as Markdown**

# Hostnames

#### HostnamesSettings

#### HostnamesSettingsTLS

##### [List TLS setting for hostnames](https://developers.cloudflare.com/api/go/resources/hostnames/subresources/settings/subresources/tls/methods/list)

client.Hostnames.Settings.TLS.List(ctx, settingID, query) (\*SinglePage\[[SettingTLSListResponse](<https://developers.cloudflare.com/api/go/resources/hostnames#(resource)%20hostnames.settings.tls%20%3E%20(model)%20SettingTLSListResponse%20%3E%20(schema)>)], error)

GET/zones/{zone\_id}/hostnames/settings/{setting\_id}

##### [Get TLS setting for hostname](https://developers.cloudflare.com/api/go/resources/hostnames/subresources/settings/subresources/tls/methods/get)

client.Hostnames.Settings.TLS.Get(ctx, settingID, hostname, query) (\*[Setting](<https://developers.cloudflare.com/api/go/resources/hostnames#(resource)%20hostnames.settings.tls%20%3E%20(model)%20setting%20%3E%20(schema)>), error)

GET/zones/{zone\_id}/hostnames/settings/{setting\_id}/{hostname}

##### [Edit TLS setting for hostname](https://developers.cloudflare.com/api/go/resources/hostnames/subresources/settings/subresources/tls/methods/update)

client.Hostnames.Settings.TLS.Update(ctx, settingID, hostname, params) (\*[Setting](<https://developers.cloudflare.com/api/go/resources/hostnames#(resource)%20hostnames.settings.tls%20%3E%20(model)%20setting%20%3E%20(schema)>), error)

PUT/zones/{zone\_id}/hostnames/settings/{setting\_id}/{hostname}

##### [Delete TLS setting for hostname](https://developers.cloudflare.com/api/go/resources/hostnames/subresources/settings/subresources/tls/methods/delete)

client.Hostnames.Settings.TLS.Delete(ctx, settingID, hostname, body) (\*[SettingTLSDeleteResponse](<https://developers.cloudflare.com/api/go/resources/hostnames#(resource)%20hostnames.settings.tls%20%3E%20(model)%20SettingTLSDeleteResponse%20%3E%20(schema)>), error)

DELETE/zones/{zone\_id}/hostnames/settings/{setting\_id}/{hostname}

##### ModelsExpand Collapse

<details>

<summary>

type Setting struct{…}

</summary>

CreatedAt TimeOptional

This is the time the tls setting was originally created for this hostname.

formatdate-time

<a href="#(resource)%20hostnames.settings.tls%20%3E%20(model)%20setting%20%3E%20(schema)%20%3E%20(property)%20created_at">Link to this property</a>

Hostname stringOptional

The hostname for which the tls settings are set.

<a href="#(resource)%20hostnames.settings.tls%20%3E%20(model)%20setting%20%3E%20(schema)%20%3E%20(property)%20hostname">Link to this property</a>

Status stringOptional

Deployment status for the given tls setting.

<a href="#(resource)%20hostnames.settings.tls%20%3E%20(model)%20setting%20%3E%20(schema)%20%3E%20(property)%20status">Link to this property</a>

UpdatedAt TimeOptional

This is the time the tls setting was updated.

formatdate-time

<a href="#(resource)%20hostnames.settings.tls%20%3E%20(model)%20setting%20%3E%20(schema)%20%3E%20(property)%20updated_at">Link to this property</a>

Value <a href="https://developers.cloudflare.com/api/go/resources/hostnames#(resource)%20hostnames.settings.tls%20%3E%20(model)%20setting_value%20%3E%20(schema)">SettingValueUnion</a>Optional

The TLS setting value. The type depends on the <code>setting_id</code> used in the request path:

- <code>ciphers</code>: an array of allowed cipher suite strings in BoringSSL format (e.g., <code>["ECDHE-RSA-AES128-GCM-SHA256", "AES128-GCM-SHA256"]</code>).
- <code>min_tls_version</code>: a string indicating the minimum TLS version — one of <code>"1.0"</code>, <code>"1.1"</code>, <code>"1.2"</code>, or <code>"1.3"</code> (e.g., <code>"1.2"</code>).
- <code>http2</code>: a string indicating whether HTTP/2 is enabled — <code>"on"</code> or <code>"off"</code> (e.g., <code>"on"</code>).

<a href="#(resource)%20hostnames.settings.tls%20%3E%20(model)%20setting%20%3E%20(schema)%20%3E%20(property)%20value">Link to this property</a>

</details>

[Link to this property](<#(resource)%20hostnames.settings.tls%20%3E%20(model)%20setting%20%3E%20(schema)>)

<details>

<summary>

type SettingValueUnion interface{…}

The TLS setting value. The type depends on the <code>setting_id</code> used in the request path:

- <code>ciphers</code>: an array of allowed cipher suite strings in BoringSSL format (e.g., <code>["ECDHE-RSA-AES128-GCM-SHA256", "AES128-GCM-SHA256"]</code>).
- <code>min_tls_version</code>: a string indicating the minimum TLS version — one of <code>"1.0"</code>, <code>"1.1"</code>, <code>"1.2"</code>, or <code>"1.3"</code> (e.g., <code>"1.2"</code>).
- <code>http2</code>: a string indicating whether HTTP/2 is enabled — <code>"on"</code> or <code>"off"</code> (e.g., <code>"on"</code>).

</summary>

One of the following:

<details>

<summary>

type SettingValueString string

</summary>

One of the following:

const SettingValueString1\_0 SettingValueString = "1.0"

<a href="#(resource)%20hostnames.settings.tls%20%3E%20(model)%20setting_value%20%3E%20(schema)%20%3E%20(variant)%200%20%3E%20(member)%200">Link to this property</a>

const SettingValueString1\_1 SettingValueString = "1.1"

<a href="#(resource)%20hostnames.settings.tls%20%3E%20(model)%20setting_value%20%3E%20(schema)%20%3E%20(variant)%200%20%3E%20(member)%201">Link to this property</a>

const SettingValueString1\_2 SettingValueString = "1.2"

<a href="#(resource)%20hostnames.settings.tls%20%3E%20(model)%20setting_value%20%3E%20(schema)%20%3E%20(variant)%200%20%3E%20(member)%202">Link to this property</a>

const SettingValueString1\_3 SettingValueString = "1.3"

<a href="#(resource)%20hostnames.settings.tls%20%3E%20(model)%20setting_value%20%3E%20(schema)%20%3E%20(variant)%200%20%3E%20(member)%203">Link to this property</a>

const SettingValueStringOn SettingValueString = "on"

<a href="#(resource)%20hostnames.settings.tls%20%3E%20(model)%20setting_value%20%3E%20(schema)%20%3E%20(variant)%200%20%3E%20(member)%204">Link to this property</a>

const SettingValueStringOff SettingValueString = "off"

<a href="#(resource)%20hostnames.settings.tls%20%3E%20(model)%20setting_value%20%3E%20(schema)%20%3E%20(variant)%200%20%3E%20(member)%205">Link to this property</a>

</details>

<a href="#(resource)%20hostnames.settings.tls%20%3E%20(model)%20setting_value%20%3E%20(schema)%20%3E%20(variant)%200">Link to this property</a>

type SettingValueArray \[]string

Used when <code>setting_id</code> is <code>ciphers</code>. An array of allowed cipher suite strings.

<a href="#(resource)%20hostnames.settings.tls%20%3E%20(model)%20setting_value%20%3E%20(schema)%20%3E%20(variant)%201">Link to this property</a>

</details>

[Link to this property](<#(resource)%20hostnames.settings.tls%20%3E%20(model)%20setting_value%20%3E%20(schema)>)