Skip to content
Start here

Domains

List Domains
workers.domains.list(DomainListParams**kwargs) -> SyncSinglePage[DomainListResponse]
GET/accounts/{account_id}/workers/domains
Get Domain
workers.domains.get(strdomain_id, DomainGetParams**kwargs) -> DomainGetResponse
GET/accounts/{account_id}/workers/domains/{domain_id}
Attach Domain
workers.domains.update(DomainUpdateParams**kwargs) -> DomainUpdateResponse
PUT/accounts/{account_id}/workers/domains
Detach Domain
workers.domains.delete(strdomain_id, DomainDeleteParams**kwargs) -> DomainDeleteResponse
DELETE/accounts/{account_id}/workers/domains/{domain_id}
ModelsExpand Collapse
class DomainListResponse:
id: str

Immutable ID of the domain.

cert_id: str

ID of the TLS certificate issued for the domain.

formatuuid
Deprecatedenvironment: str

Worker environment associated with the domain.

hostname: str

Hostname of the domain. Can be either the zone apex or a subdomain of the zone. Requests to this hostname will be routed to the configured Worker.

service: str

Name of the Worker associated with the domain. Requests to the configured hostname will be routed to this Worker.

zone_id: str

ID of the zone containing the domain hostname.

zone_name: str

Name of the zone containing the domain hostname.

class DomainGetResponse:
id: str

Immutable ID of the domain.

cert_id: str

ID of the TLS certificate issued for the domain.

formatuuid
Deprecatedenvironment: str

Worker environment associated with the domain.

hostname: str

Hostname of the domain. Can be either the zone apex or a subdomain of the zone. Requests to this hostname will be routed to the configured Worker.

service: str

Name of the Worker associated with the domain. Requests to the configured hostname will be routed to this Worker.

zone_id: str

ID of the zone containing the domain hostname.

zone_name: str

Name of the zone containing the domain hostname.

class DomainUpdateResponse:
id: str

Immutable ID of the domain.

cert_id: str

ID of the TLS certificate issued for the domain.

formatuuid
Deprecatedenvironment: str

Worker environment associated with the domain.

hostname: str

Hostname of the domain. Can be either the zone apex or a subdomain of the zone. Requests to this hostname will be routed to the configured Worker.

service: str

Name of the Worker associated with the domain. Requests to the configured hostname will be routed to this Worker.

zone_id: str

ID of the zone containing the domain hostname.

zone_name: str

Name of the zone containing the domain hostname.

class DomainDeleteResponse:
errors: List[Error]
code: int
minimum1000
message: str
documentation_url: Optional[str]
source: Optional[ErrorSource]
pointer: Optional[str]
messages: List[Message]
code: int
minimum1000
message: str
documentation_url: Optional[str]
source: Optional[MessageSource]
pointer: Optional[str]
success: Literal[true]

Whether the API call was successful.