hostname_associations
Creates, updates, deletes, gets or lists a hostname_associations resource.
Overview
| Name | hostname_associations |
| Type | Resource |
| Id | cloudflare.certificate_authorities.hostname_associations |
Fields
The following fields are returned by SELECT queries:
- list
List Hostname Associations Response
| Name | Datatype | Description |
|---|---|---|
errors | array | |
messages | array | |
result | object | |
success | boolean | Whether the API call was successful. (true) |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
list | select | zone_id | mtls_certificate_id | List Hostname Associations |
update | replace | zone_id | Replace Hostname Associations |
Parameters
Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.
| Name | Datatype | Description |
|---|---|---|
zone_id | string | The Cloudflare zone ID. |
mtls_certificate_id | string |
SELECT examples
- list
List Hostname Associations
SELECT
errors,
messages,
result,
success
FROM cloudflare.certificate_authorities.hostname_associations
WHERE zone_id = '{{ zone_id }}' -- required
AND mtls_certificate_id = '{{ mtls_certificate_id }}'
;
REPLACE examples
- update
Replace Hostname Associations
REPLACE cloudflare.certificate_authorities.hostname_associations
SET
hostnames = '{{ hostnames }}',
mtls_certificate_id = '{{ mtls_certificate_id }}'
WHERE
zone_id = '{{ zone_id }}' --required
RETURNING
errors,
messages,
result,
success;