Skip to content

update_glossary async

update_glossary(
    domain_identifier: DomainId,
    identifier: GlossaryId,
    *,
    config_overrides: Optional[AsyncDataZoneClientConfig] = None,
    name: Optional[GlossaryName] = None,
    description: Optional[GlossaryDescription] = None,
    status: Optional[GlossaryStatus] = None,
    client_token: Optional[ClientToken] = None,
) -> UpdateGlossaryOutput

Updates the business glossary in Amazon DataZone.

Prerequisites:

  • The glossary must exist in the given domain.

  • The caller must have the datazone:UpdateGlossary permission to update it.

  • When updating the name, the new name must be unique within the domain.

  • The glossary must not be deleted or in a terminal state.

Parameters:

  • domain_identifier (DomainId) –

    The identifier of the Amazon DataZone domain in which a business glossary is to be updated.

  • identifier (GlossaryId) –

    The identifier of the business glossary to be updated.

  • name (Optional[GlossaryName], default: None ) –

    The name to be updated as part of the UpdateGlossary action.

  • description (Optional[GlossaryDescription], default: None ) –

    The description to be updated as part of the UpdateGlossary action.

  • status (Optional[GlossaryStatus], default: None ) –

    The status to be updated as part of the UpdateGlossary action.

  • client_token (Optional[ClientToken], default: None ) –

    A unique, case-sensitive identifier that is provided to ensure the idempotency of the request.

Raises:

Source code in docs_src/capo_datazone/_services/async_data_zone.py
async def update_glossary(
    self,
    domain_identifier: "capo_datazone.types.domain_id.DomainId",
    identifier: "capo_datazone.types.glossary_id.GlossaryId",
    *,
    config_overrides: Optional[AsyncDataZoneClientConfig] = None,
    name: Optional["capo_datazone.types.glossary_name.GlossaryName"] = None,
    description: Optional[
        "capo_datazone.types.glossary_description.GlossaryDescription"
    ] = None,
    status: Optional["capo_datazone.types.glossary_status.GlossaryStatus"] = None,
    client_token: Optional["capo_datazone.types.client_token.ClientToken"] = None,
) -> "capo_datazone.types.update_glossary_output.UpdateGlossaryOutput":
    """<p>Updates the business glossary in Amazon DataZone.</p> <p>Prerequisites:</p> <ul> <li> <p>The glossary must exist in the given domain. </p> </li> <li> <p>The caller must have the <code>datazone:UpdateGlossary</code> permission to update it.</p> </li> <li> <p>When updating the name, the new name must be unique within the domain.</p> </li> <li> <p>The glossary must not be deleted or in a terminal state.</p> </li> </ul>

    Args:
        domain_identifier: <p>The identifier of the Amazon DataZone domain in which a business glossary is to be updated.</p>
        identifier: <p>The identifier of the business glossary to be updated.</p>
        name: <p>The name to be updated as part of the <code>UpdateGlossary</code> action.</p>
        description: <p>The description to be updated as part of the <code>UpdateGlossary</code> action.</p>
        status: <p>The status to be updated as part of the <code>UpdateGlossary</code> action.</p>
        client_token: <p>A unique, case-sensitive identifier that is provided to ensure the idempotency of the request.</p>

    Raises:
        capo_datazone.errors.access_denied_exception.AccessDeniedException: <p>You do not have sufficient access to perform this action.</p>
        capo_datazone.errors.throttling_exception.ThrottlingException: <p>The request was denied due to request throttling.</p>
        capo_datazone.errors.unauthorized_exception.UnauthorizedException: <p>You do not have permission to perform this action.</p>
        capo_datazone.errors.conflict_exception.ConflictException: <p>There is a conflict while performing this action.</p>
        capo_datazone.errors.internal_server_exception.InternalServerException: <p>The request has failed because of an unknown error, exception or failure.</p>
        capo_datazone.errors.resource_not_found_exception.ResourceNotFoundException: <p>The specified resource cannot be found.</p>
        capo_datazone.errors.validation_exception.ValidationException: <p>The input fails to satisfy the constraints specified by the Amazon Web Services service.</p>
        capo_datazone.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    async def _handler(
        req: "AsyncOperationRequest[capo_datazone.types.update_glossary_input.UpdateGlossaryInput]",
    ) -> AsyncOperationResponse[
        "capo_datazone.types.update_glossary_output.UpdateGlossaryOutput"
    ]:
        import capo_datazone._operations.data_zone.update_glossary

        (
            output,
            http_response,
        ) = await capo_datazone._operations.data_zone.update_glossary.async_update_glossary(
            req.options, req.input
        )
        return AsyncOperationResponse(output=output, response=http_response)

    def _redact_input(
        input_: "capo_datazone.types.update_glossary_input.UpdateGlossaryInput",
    ) -> dict[str, Any]:
        import capo_datazone.types.update_glossary_input

        return capo_datazone.types.update_glossary_input.redact_sensitive(input_)

    def _redact_output(
        output: "capo_datazone.types.update_glossary_output.UpdateGlossaryOutput",
    ) -> dict[str, Any]:
        import capo_datazone.types.update_glossary_output

        return capo_datazone.types.update_glossary_output.redact_sensitive(output)

    interceptors_, options_ = self.operation_options(
        config_overrides,
        OperationLogging(
            "UpdateGlossary",
            redact_input=_redact_input,
            redact_output=_redact_output,
        ),
    )
    input_: capo_datazone.types.update_glossary_input.UpdateGlossaryInput = {
        "domain_identifier": domain_identifier,
        "identifier": identifier,
    }
    if name is not None:
        input_["name"] = name
    if description is not None:
        input_["description"] = description
    if status is not None:
        input_["status"] = status
    if client_token is None:
        client_token = str(uuid.uuid4())
    input_["client_token"] = client_token

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