Skip to content

describe_reserved_nodes_offerings async

describe_reserved_nodes_offerings(
    *,
    config_overrides: Optional[AsyncMemoryDBClientConfig] = None,
    reserved_nodes_offering_id: Optional[String] = None,
    node_type: Optional[String] = None,
    duration: Optional[String] = None,
    offering_type: Optional[String] = None,
    max_results: Optional[IntegerOptional] = None,
    next_token: Optional[String] = None,
) -> DescribeReservedNodesOfferingsResponse

Lists available reserved node offerings.

Parameters:

  • reserved_nodes_offering_id (Optional[String], default: None ) –

    The offering identifier filter value. Use this parameter to show only the available offering that matches the specified reservation identifier.

  • node_type (Optional[String], default: None ) –

    The node type for the reserved nodes. For more information, see Supported node types.

  • duration (Optional[String], default: None ) –

    Duration filter value, specified in years or seconds. Use this parameter to show only reservations for a given duration.

  • offering_type (Optional[String], default: None ) –

    The offering type filter value. Use this parameter to show only the available offerings matching the specified offering type. Valid values: "All Upfront"|"Partial Upfront"| "No Upfront"

  • max_results (Optional[IntegerOptional], default: None ) –

    The maximum number of records to include in the response. If more records exist than the specified MaxRecords value, a marker is included in the response so that the remaining results can be retrieved.

  • next_token (Optional[String], default: None ) –

    An optional marker returned from a prior request. Use this marker for pagination of results from this operation. If this parameter is specified, the response includes only records beyond the marker, up to the value specified by MaxRecords.

Raises:

Source code in docs_src/capo_memorydb/_services/async_memory_db.py
async def describe_reserved_nodes_offerings(
    self,
    *,
    config_overrides: Optional[AsyncMemoryDBClientConfig] = None,
    reserved_nodes_offering_id: Optional[
        "capo_memorydb.types.string.String"
    ] = None,
    node_type: Optional["capo_memorydb.types.string.String"] = None,
    duration: Optional["capo_memorydb.types.string.String"] = None,
    offering_type: Optional["capo_memorydb.types.string.String"] = None,
    max_results: Optional[
        "capo_memorydb.types.integer_optional.IntegerOptional"
    ] = None,
    next_token: Optional["capo_memorydb.types.string.String"] = None,
) -> "capo_memorydb.types.describe_reserved_nodes_offerings_response.DescribeReservedNodesOfferingsResponse":
    """<p>Lists available reserved node offerings.</p>

    Args:
        reserved_nodes_offering_id: <p>The offering identifier filter value. Use this parameter to show only the available offering that matches the specified reservation identifier.</p>
        node_type: <p>The node type for the reserved nodes. For more information, see <a href="https://docs.aws.amazon.com/memorydb/latest/devguide/nodes.reserved.html#reserved-nodes-supported">Supported node types</a>.</p>
        duration: <p>Duration filter value, specified in years or seconds. Use this parameter to show only reservations for a given duration.</p>
        offering_type: <p>The offering type filter value. Use this parameter to show only the available offerings matching the specified offering type. Valid values: "All Upfront"|"Partial Upfront"| "No Upfront"</p>
        max_results: <p>The maximum number of records to include in the response. If more records exist than the specified MaxRecords value, a marker is included in the response so that the remaining results can be retrieved.</p>
        next_token: <p>An optional marker returned from a prior request. Use this marker for pagination of results from this operation. If this parameter is specified, the response includes only records beyond the marker, up to the value specified by MaxRecords.</p>

    Raises:
        capo_memorydb.errors.invalid_parameter_combination_exception.InvalidParameterCombinationException: <p>The specified parameter combination is not valid.</p>
        capo_memorydb.errors.invalid_parameter_value_exception.InvalidParameterValueException: <p>The specified parameter value is not valid.</p>
        capo_memorydb.errors.reserved_nodes_offering_not_found_fault.ReservedNodesOfferingNotFoundFault: <p>The requested node offering does not exist. </p>
        capo_memorydb.errors.service_linked_role_not_found_fault.ServiceLinkedRoleNotFoundFault: <p>The required service-linked role was not found.</p>
        capo_memorydb.errors.UnknownServiceError: The service returned an error code this client does not model.
    """

    async def _handler(
        req: "AsyncOperationRequest[capo_memorydb.types.describe_reserved_nodes_offerings_request.DescribeReservedNodesOfferingsRequest]",
    ) -> AsyncOperationResponse[
        "capo_memorydb.types.describe_reserved_nodes_offerings_response.DescribeReservedNodesOfferingsResponse"
    ]:
        import capo_memorydb._operations.amazon_memory_db.describe_reserved_nodes_offerings

        (
            output,
            http_response,
        ) = await capo_memorydb._operations.amazon_memory_db.describe_reserved_nodes_offerings.async_describe_reserved_nodes_offerings(
            req.options, req.input
        )
        return AsyncOperationResponse(output=output, response=http_response)

    interceptors_, options_ = self.operation_options(
        config_overrides, OperationLogging("DescribeReservedNodesOfferings")
    )
    input_: capo_memorydb.types.describe_reserved_nodes_offerings_request.DescribeReservedNodesOfferingsRequest = {}
    if reserved_nodes_offering_id is not None:
        input_["reserved_nodes_offering_id"] = reserved_nodes_offering_id
    if node_type is not None:
        input_["node_type"] = node_type
    if duration is not None:
        input_["duration"] = duration
    if offering_type is not None:
        input_["offering_type"] = offering_type
    if max_results is not None:
        input_["max_results"] = max_results
    if next_token is not None:
        input_["next_token"] = next_token

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