Skip to content

update_registry_record async

update_registry_record(
    registry_id: RegistryIdentifier,
    record_id: RecordIdentifier,
    *,
    config_overrides: Optional[AsyncBedrockAgentCoreControlClientConfig] = None,
    name: Optional[RegistryRecordName] = None,
    description: Optional[UpdatedDescription] = None,
    descriptor_type: Optional[DescriptorType] = None,
    descriptors: Optional[UpdatedDescriptors] = None,
    record_version: Optional[RegistryRecordVersion] = None,
    synchronization_type: Optional[UpdatedSynchronizationType] = None,
    synchronization_configuration: Optional[UpdatedSynchronizationConfiguration] = None,
    trigger_synchronization: Optional[bool] = None,
) -> UpdateRegistryRecordResponse

Updates an existing registry record. This operation uses PATCH semantics, so you only need to specify the fields you want to change. The update is processed asynchronously and returns HTTP 202 Accepted.

Parameters:

  • registry_id (RegistryIdentifier) –

    The identifier of the registry containing the record. You can specify either the Amazon Resource Name (ARN) or the ID of the registry.

  • record_id (RecordIdentifier) –

    The identifier of the registry record to update. You can specify either the Amazon Resource Name (ARN) or the ID of the record.

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

    The updated name for the registry record.

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

    The updated description for the registry record. To clear the description, include the UpdatedDescription wrapper with optionalValue not specified.

  • descriptor_type (Optional[DescriptorType], default: None ) –

    The updated descriptor type for the registry record. Changing the descriptor type may require updating the descriptors field to match the new type's schema requirements.

  • descriptors (Optional[UpdatedDescriptors], default: None ) –

    The updated descriptor-type-specific configuration containing the resource schema and metadata. Uses PATCH semantics where individual descriptor fields can be updated independently.

  • record_version (Optional[RegistryRecordVersion], default: None ) –

    The version of the registry record for optimistic locking. If provided, it must match the current version of the record. The service automatically increments the version after a successful update.

  • synchronization_type (Optional[UpdatedSynchronizationType], default: None ) –

    The updated synchronization type for the registry record.

  • synchronization_configuration (Optional[UpdatedSynchronizationConfiguration], default: None ) –

    The updated synchronization configuration for the registry record.

  • trigger_synchronization (Optional[bool], default: None ) –

    Whether to trigger synchronization using the stored or provided configuration. When set to true, the service will synchronize the record metadata from the configured external source.

Raises:

Source code in docs_src/capo_bedrock_agentcore_control/_services/async_bedrock_agent_core_control.py
async def update_registry_record(
    self,
    registry_id: "capo_bedrock_agentcore_control.types.registry_identifier.RegistryIdentifier",
    record_id: "capo_bedrock_agentcore_control.types.record_identifier.RecordIdentifier",
    *,
    config_overrides: Optional[AsyncBedrockAgentCoreControlClientConfig] = None,
    name: Optional[
        "capo_bedrock_agentcore_control.types.registry_record_name.RegistryRecordName"
    ] = None,
    description: Optional[
        "capo_bedrock_agentcore_control.types.updated_description.UpdatedDescription"
    ] = None,
    descriptor_type: Optional[
        "capo_bedrock_agentcore_control.types.descriptor_type.DescriptorType"
    ] = None,
    descriptors: Optional[
        "capo_bedrock_agentcore_control.types.updated_descriptors.UpdatedDescriptors"
    ] = None,
    record_version: Optional[
        "capo_bedrock_agentcore_control.types.registry_record_version.RegistryRecordVersion"
    ] = None,
    synchronization_type: Optional[
        "capo_bedrock_agentcore_control.types.updated_synchronization_type.UpdatedSynchronizationType"
    ] = None,
    synchronization_configuration: Optional[
        "capo_bedrock_agentcore_control.types.updated_synchronization_configuration.UpdatedSynchronizationConfiguration"
    ] = None,
    trigger_synchronization: Optional[bool] = None,
) -> "capo_bedrock_agentcore_control.types.update_registry_record_response.UpdateRegistryRecordResponse":
    """<p>Updates an existing registry record. This operation uses PATCH semantics, so you only need to specify the fields you want to change. The update is processed asynchronously and returns HTTP 202 Accepted.</p>

    Args:
        registry_id: <p>The identifier of the registry containing the record. You can specify either the Amazon Resource Name (ARN) or the ID of the registry.</p>
        record_id: <p>The identifier of the registry record to update. You can specify either the Amazon Resource Name (ARN) or the ID of the record.</p>
        name: <p>The updated name for the registry record.</p>
        description: <p>The updated description for the registry record. To clear the description, include the <code>UpdatedDescription</code> wrapper with <code>optionalValue</code> not specified.</p>
        descriptor_type: <p>The updated descriptor type for the registry record. Changing the descriptor type may require updating the <code>descriptors</code> field to match the new type's schema requirements.</p>
        descriptors: <p>The updated descriptor-type-specific configuration containing the resource schema and metadata. Uses PATCH semantics where individual descriptor fields can be updated independently.</p>
        record_version: <p>The version of the registry record for optimistic locking. If provided, it must match the current version of the record. The service automatically increments the version after a successful update.</p>
        synchronization_type: <p>The updated synchronization type for the registry record.</p>
        synchronization_configuration: <p>The updated synchronization configuration for the registry record.</p>
        trigger_synchronization: <p>Whether to trigger synchronization using the stored or provided configuration. When set to <code>true</code>, the service will synchronize the record metadata from the configured external source.</p>

    Raises:
        capo_bedrock_agentcore_control.errors.access_denied_exception.AccessDeniedException: <p>This exception is thrown when a request is denied per access permissions</p>
        capo_bedrock_agentcore_control.errors.conflict_exception.ConflictException: <p>This exception is thrown when there is a conflict performing an operation</p>
        capo_bedrock_agentcore_control.errors.internal_server_exception.InternalServerException: <p>This exception is thrown if there was an unexpected error during processing of request</p>
        capo_bedrock_agentcore_control.errors.resource_not_found_exception.ResourceNotFoundException: <p>This exception is thrown when a resource referenced by the operation does not exist</p>
        capo_bedrock_agentcore_control.errors.throttling_exception.ThrottlingException: <p>This exception is thrown when the number of requests exceeds the limit</p>
        capo_bedrock_agentcore_control.errors.validation_exception.ValidationException: <p>The input fails to satisfy the constraints specified by the service.</p>
        capo_bedrock_agentcore_control.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    async def _handler(
        req: "AsyncOperationRequest[capo_bedrock_agentcore_control.types.update_registry_record_request.UpdateRegistryRecordRequest]",
    ) -> AsyncOperationResponse[
        "capo_bedrock_agentcore_control.types.update_registry_record_response.UpdateRegistryRecordResponse"
    ]:
        import capo_bedrock_agentcore_control._operations.amazon_bedrock_agent_core_control.update_registry_record

        (
            output,
            http_response,
        ) = await capo_bedrock_agentcore_control._operations.amazon_bedrock_agent_core_control.update_registry_record.async_update_registry_record(
            req.options, req.input
        )
        return AsyncOperationResponse(output=output, response=http_response)

    def _redact_input(
        input_: "capo_bedrock_agentcore_control.types.update_registry_record_request.UpdateRegistryRecordRequest",
    ) -> dict[str, Any]:
        import capo_bedrock_agentcore_control.types.update_registry_record_request

        return capo_bedrock_agentcore_control.types.update_registry_record_request.redact_sensitive(
            input_
        )

    def _redact_output(
        output: "capo_bedrock_agentcore_control.types.update_registry_record_response.UpdateRegistryRecordResponse",
    ) -> dict[str, Any]:
        import capo_bedrock_agentcore_control.types.update_registry_record_response

        return capo_bedrock_agentcore_control.types.update_registry_record_response.redact_sensitive(
            output
        )

    interceptors_, options_ = self.operation_options(
        config_overrides,
        OperationLogging(
            "UpdateRegistryRecord",
            redact_input=_redact_input,
            redact_output=_redact_output,
        ),
    )
    input_: capo_bedrock_agentcore_control.types.update_registry_record_request.UpdateRegistryRecordRequest = {
        "registry_id": registry_id,
        "record_id": record_id,
    }
    if name is not None:
        input_["name"] = name
    if description is not None:
        input_["description"] = description
    if descriptor_type is not None:
        input_["descriptor_type"] = descriptor_type
    if descriptors is not None:
        input_["descriptors"] = descriptors
    if record_version is not None:
        input_["record_version"] = record_version
    if synchronization_type is not None:
        input_["synchronization_type"] = synchronization_type
    if synchronization_configuration is not None:
        input_["synchronization_configuration"] = synchronization_configuration
    if trigger_synchronization is not None:
        input_["trigger_synchronization"] = trigger_synchronization

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