Skip to main content

domain_config

Creates, updates, deletes, gets or lists a domain_config resource.

Overview​

Namedomain_config
TypeResource
Idvercel.domains.domain_config

Fields​

The following fields are returned by SELECT queries:

NameDatatypeDescription
accepted_challengesarrayWhich challenge types the domain can use for issuing certs. (wire: acceptedChallenges)
configured_bystringHow we see the domain's configuration. - CNAME: Domain has a CNAME pointing to Vercel. - A: Domain's A record is resolving to Vercel. - http: Domain is resolving to Vercel but may be behind a Proxy. - dns-01: Domain is not resolving to Vercel but dns-01 challenge is enabled. - null: Domain is not resolving to Vercel. (A, CNAME, dns-01, http, ) (wire: configuredBy)
misconfiguredbooleanWhether or not the domain is configured AND we can automatically generate a TLS certificate. (false, true)
recommended_cnamearrayRecommended CNAMEs for the domain. rank=1 is the preferred value to use. (wire: recommendedCNAME)
recommended_i_pv_4arrayRecommended IPv4s for the domain. rank=1 is the preferred value(s) to use. Only using 1 ip value is acceptable. (wire: recommendedIPv4)

Methods​

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectdomainproject_id_or_name, strict, team_id, slugGet a Domain's configuration.

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.

NameDatatypeDescription
domainstringThe name of the domain.
project_id_or_namestringThe project id or name that will be associated with the domain. Use this when the domain is not yet associated with a project. (wire: projectIdOrName)
slugstringThe Team slug to perform the request on behalf of.
strictWhen true, the response will only include the nameservers assigned directly to the specified domain. When false and there are no nameservers assigned directly to the specified domain, the response will include the nameservers of the domain's parent zone.
team_idstringThe Team identifier to perform the request on behalf of. (wire: teamId)

SELECT examples​

Get a Domain's configuration.

SELECT
accepted_challenges,
configured_by,
misconfigured,
recommended_cname,
recommended_i_pv_4
FROM vercel.domains.domain_config
WHERE domain = '{{ domain }}' -- required
AND project_id_or_name = '{{ project_id_or_name }}'
AND strict = '{{ strict }}'
AND team_id = '{{ team_id }}'
AND slug = '{{ slug }}'
;