Skip to content

update_domain_contact async

update_domain_contact(
    domain_name: DomainName,
    *,
    config_overrides: Optional[AsyncRoute53DomainsClientConfig] = None,
    admin_contact: Optional[ContactDetail] = None,
    registrant_contact: Optional[ContactDetail] = None,
    tech_contact: Optional[ContactDetail] = None,
    consent: Optional[Consent] = None,
    billing_contact: Optional[ContactDetail] = None,
) -> UpdateDomainContactResponse

This operation updates the contact information for a particular domain. You must specify information for at least one contact: registrant, administrator, or technical.

If the update is successful, this method returns an operation ID that you can use to track the progress and completion of the operation. If the request is not completed successfully, the domain registrant will be notified by email.

Parameters:

  • domain_name (DomainName) –

    The name of the domain that you want to update contact information for.

  • admin_contact (Optional[ContactDetail], default: None ) –

    Provides detailed contact information.

  • registrant_contact (Optional[ContactDetail], default: None ) –

    Provides detailed contact information.

  • tech_contact (Optional[ContactDetail], default: None ) –

    Provides detailed contact information.

  • consent (Optional[Consent], default: None ) –

    The maximum amount that you agree to pay for the owner change. Required if the domain is not free (consent price is more than USD $0.00).

  • billing_contact (Optional[ContactDetail], default: None ) –

    Provides detailed contact information.

Raises:

  • DuplicateRequest –

    The request is already in progress for the domain.

  • InvalidInput –

    The requested item is not acceptable. For example, for APIs that accept a domain name, the request might specify a domain name that doesn't belong to the account that submitted the request. For AcceptDomainTransferFromAnotherAwsAccount, the password might be invalid.

  • OperationLimitExceeded –

    The number of operations or jobs running exceeded the allowed threshold for the account.

  • TLDRulesViolation –

    The top-level domain does not support this operation.

  • UnsupportedTLD –

    Amazon Route 53 does not support this top-level domain (TLD).

  • UnknownServiceError –

    The service returned an error code this client does not model.

Source code in docs_src/capo_route_53_domains/_services/async_route53_domains.py
async def update_domain_contact(
    self,
    domain_name: "capo_route_53_domains.types.domain_name.DomainName",
    *,
    config_overrides: Optional[AsyncRoute53DomainsClientConfig] = None,
    admin_contact: Optional[
        "capo_route_53_domains.types.contact_detail.ContactDetail"
    ] = None,
    registrant_contact: Optional[
        "capo_route_53_domains.types.contact_detail.ContactDetail"
    ] = None,
    tech_contact: Optional[
        "capo_route_53_domains.types.contact_detail.ContactDetail"
    ] = None,
    consent: Optional["capo_route_53_domains.types.consent.Consent"] = None,
    billing_contact: Optional[
        "capo_route_53_domains.types.contact_detail.ContactDetail"
    ] = None,
) -> "capo_route_53_domains.types.update_domain_contact_response.UpdateDomainContactResponse":
    """<p>This operation updates the contact information for a particular domain. You must specify information for at least one contact: registrant, administrator, or technical.</p> <p>If the update is successful, this method returns an operation ID that you can use to track the progress and completion of the operation. If the request is not completed successfully, the domain registrant will be notified by email.</p>

    Args:
        domain_name: <p>The name of the domain that you want to update contact information for.</p>
        admin_contact: <p>Provides detailed contact information.</p>
        registrant_contact: <p>Provides detailed contact information.</p>
        tech_contact: <p>Provides detailed contact information.</p>
        consent: <p> The maximum amount that you agree to pay for the owner change. Required if the domain is not free (consent price is more than USD $0.00).</p>
        billing_contact: <p>Provides detailed contact information.</p>

    Raises:
        capo_route_53_domains.errors.duplicate_request.DuplicateRequest: <p>The request is already in progress for the domain.</p>
        capo_route_53_domains.errors.invalid_input.InvalidInput: <p>The requested item is not acceptable. For example, for APIs that accept a domain name, the request might specify a domain name that doesn't belong to the account that submitted the request. For <code>AcceptDomainTransferFromAnotherAwsAccount</code>, the password might be invalid.</p>
        capo_route_53_domains.errors.operation_limit_exceeded.OperationLimitExceeded: <p>The number of operations or jobs running exceeded the allowed threshold for the account.</p>
        capo_route_53_domains.errors.tld_rules_violation.TLDRulesViolation: <p>The top-level domain does not support this operation.</p>
        capo_route_53_domains.errors.unsupported_tld.UnsupportedTLD: <p>Amazon Route 53 does not support this top-level domain (TLD).</p>
        capo_route_53_domains.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    async def _handler(
        req: "AsyncOperationRequest[capo_route_53_domains.types.update_domain_contact_request.UpdateDomainContactRequest]",
    ) -> AsyncOperationResponse[
        "capo_route_53_domains.types.update_domain_contact_response.UpdateDomainContactResponse"
    ]:
        import capo_route_53_domains._operations.route53_domains_v20140515.update_domain_contact

        (
            output,
            http_response,
        ) = await capo_route_53_domains._operations.route53_domains_v20140515.update_domain_contact.async_update_domain_contact(
            req.options, req.input
        )
        return AsyncOperationResponse(output=output, response=http_response)

    def _redact_input(
        input_: "capo_route_53_domains.types.update_domain_contact_request.UpdateDomainContactRequest",
    ) -> dict[str, Any]:
        import capo_route_53_domains.types.update_domain_contact_request

        return capo_route_53_domains.types.update_domain_contact_request.redact_sensitive(
            input_
        )

    interceptors_, options_ = self.operation_options(
        config_overrides,
        OperationLogging("UpdateDomainContact", redact_input=_redact_input),
    )
    input_: capo_route_53_domains.types.update_domain_contact_request.UpdateDomainContactRequest = {
        "domain_name": domain_name
    }
    if admin_contact is not None:
        input_["admin_contact"] = admin_contact
    if registrant_contact is not None:
        input_["registrant_contact"] = registrant_contact
    if tech_contact is not None:
        input_["tech_contact"] = tech_contact
    if consent is not None:
        input_["consent"] = consent
    if billing_contact is not None:
        input_["billing_contact"] = billing_contact

    response = await aexecute_pipeline(
        AsyncOperationRequest(input=input_, options=options_),
        handler=_handler,
        interceptors=list(interceptors_),
    )
    await response.response.aclose()
    return response.output