Skip to content

update_quote async

update_quote(
    quote_identifier: QuoteIdentifier,
    *,
    config_overrides: Optional[AsyncOutpostsClientConfig] = None,
    outpost_identifier: Optional[OutpostIdentifierOrEmpty] = None,
    country_code: Optional[CountryCode] = None,
    requested_capacities: Optional[QuoteCapacityList] = None,
    requested_constraints: Optional[QuoteConstraintList] = None,
    requested_payment_options: Optional[PaymentOptionList] = None,
    requested_payment_terms: Optional[PaymentTermList] = None,
    description: Optional[QuoteDescription] = None,
) -> UpdateQuoteOutput

Updates the specified quote. You can modify the requested capacities, constraints, payment options, payment terms, or Outpost association.

Parameters:

  • quote_identifier (QuoteIdentifier) –

    The ID of the quote.

  • outpost_identifier (Optional[OutpostIdentifierOrEmpty], default: None ) –

    The ID or ARN of the Outpost to associate with the quote. Specify an empty string to remove the Outpost association.

  • country_code (Optional[CountryCode], default: None ) –

    The country code for the Outpost site location.

  • requested_capacities (Optional[QuoteCapacityList], default: None ) –

    The updated capacity requirements for the quote.

  • requested_constraints (Optional[QuoteConstraintList], default: None ) –

    The updated physical constraints for the quote.

  • requested_payment_options (Optional[PaymentOptionList], default: None ) –

    The updated payment options to include in the quote pricing.

  • requested_payment_terms (Optional[PaymentTermList], default: None ) –

    The updated payment terms to include in the quote pricing.

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

    A description for the quote.

Raises:

Source code in docs_src/capo_outposts/_services/async_outposts.py
async def update_quote(
    self,
    quote_identifier: "capo_outposts.types.quote_identifier.QuoteIdentifier",
    *,
    config_overrides: Optional[AsyncOutpostsClientConfig] = None,
    outpost_identifier: Optional[
        "capo_outposts.types.outpost_identifier_or_empty.OutpostIdentifierOrEmpty"
    ] = None,
    country_code: Optional["capo_outposts.types.country_code.CountryCode"] = None,
    requested_capacities: Optional[
        "capo_outposts.types.quote_capacity_list.QuoteCapacityList"
    ] = None,
    requested_constraints: Optional[
        "capo_outposts.types.quote_constraint_list.QuoteConstraintList"
    ] = None,
    requested_payment_options: Optional[
        "capo_outposts.types.payment_option_list.PaymentOptionList"
    ] = None,
    requested_payment_terms: Optional[
        "capo_outposts.types.payment_term_list.PaymentTermList"
    ] = None,
    description: Optional[
        "capo_outposts.types.quote_description.QuoteDescription"
    ] = None,
) -> "capo_outposts.types.update_quote_output.UpdateQuoteOutput":
    """<p>Updates the specified quote. You can modify the requested capacities, constraints, payment options, payment terms, or Outpost association.</p>

    Args:
        quote_identifier: <p>The ID of the quote.</p>
        outpost_identifier: <p>The ID or ARN of the Outpost to associate with the quote. Specify an empty string to remove the Outpost association.</p>
        country_code: <p>The country code for the Outpost site location.</p>
        requested_capacities: <p>The updated capacity requirements for the quote.</p>
        requested_constraints: <p>The updated physical constraints for the quote.</p>
        requested_payment_options: <p>The updated payment options to include in the quote pricing.</p>
        requested_payment_terms: <p>The updated payment terms to include in the quote pricing.</p>
        description: <p>A description for the quote.</p>

    Raises:
        capo_outposts.errors.access_denied_exception.AccessDeniedException: <p>You do not have permission to perform this operation.</p>
        capo_outposts.errors.internal_server_exception.InternalServerException: <p>An internal error has occurred.</p>
        capo_outposts.errors.not_found_exception.NotFoundException: <p>The specified request is not valid.</p>
        capo_outposts.errors.validation_exception.ValidationException: <p>A parameter is not valid.</p>
        capo_outposts.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    async def _handler(
        req: "AsyncOperationRequest[capo_outposts.types.update_quote_input.UpdateQuoteInput]",
    ) -> AsyncOperationResponse[
        "capo_outposts.types.update_quote_output.UpdateQuoteOutput"
    ]:
        import capo_outposts._operations.outposts_olaf_service.update_quote

        (
            output,
            http_response,
        ) = await capo_outposts._operations.outposts_olaf_service.update_quote.async_update_quote(
            req.options, req.input
        )
        return AsyncOperationResponse(output=output, response=http_response)

    def _redact_input(
        input_: "capo_outposts.types.update_quote_input.UpdateQuoteInput",
    ) -> dict[str, Any]:
        import capo_outposts.types.update_quote_input

        return capo_outposts.types.update_quote_input.redact_sensitive(input_)

    def _redact_output(
        output: "capo_outposts.types.update_quote_output.UpdateQuoteOutput",
    ) -> dict[str, Any]:
        import capo_outposts.types.update_quote_output

        return capo_outposts.types.update_quote_output.redact_sensitive(output)

    interceptors_, options_ = self.operation_options(
        config_overrides,
        OperationLogging(
            "UpdateQuote", redact_input=_redact_input, redact_output=_redact_output
        ),
    )
    input_: capo_outposts.types.update_quote_input.UpdateQuoteInput = {
        "quote_identifier": quote_identifier
    }
    if outpost_identifier is not None:
        input_["outpost_identifier"] = outpost_identifier
    if country_code is not None:
        input_["country_code"] = country_code
    if requested_capacities is not None:
        input_["requested_capacities"] = requested_capacities
    if requested_constraints is not None:
        input_["requested_constraints"] = requested_constraints
    if requested_payment_options is not None:
        input_["requested_payment_options"] = requested_payment_options
    if requested_payment_terms is not None:
        input_["requested_payment_terms"] = requested_payment_terms
    if description is not None:
        input_["description"] = description

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