Redshift / Client / purchase_reserved_node_offering

purchase_reserved_node_offering#

Redshift.Client.purchase_reserved_node_offering(**kwargs)#

Allows you to purchase reserved nodes. Amazon Redshift offers a predefined set of reserved node offerings. You can purchase one or more of the offerings. You can call the DescribeReservedNodeOfferings API to obtain the available reserved node offerings. You can call this API by providing a specific reserved node offering and the number of nodes you want to reserve.

For more information about reserved node offerings, go to Purchasing Reserved Nodes in the Amazon Redshift Cluster Management Guide.

See also: AWS API Documentation

Request Syntax

response = client.purchase_reserved_node_offering(
    ReservedNodeOfferingId='string',
    NodeCount=123
)
Parameters:
  • ReservedNodeOfferingId (string) –

    [REQUIRED]

    The unique identifier of the reserved node offering you want to purchase.

  • NodeCount (integer) –

    The number of reserved nodes that you want to purchase.

    Default: 1

Return type:

dict

Returns:

Response Syntax

{
    'ReservedNode': {
        'ReservedNodeId': 'string',
        'ReservedNodeOfferingId': 'string',
        'NodeType': 'string',
        'StartTime': datetime(2015, 1, 1),
        'Duration': 123,
        'FixedPrice': 123.0,
        'UsagePrice': 123.0,
        'CurrencyCode': 'string',
        'NodeCount': 123,
        'State': 'string',
        'OfferingType': 'string',
        'RecurringCharges': [
            {
                'RecurringChargeAmount': 123.0,
                'RecurringChargeFrequency': 'string'
            },
        ],
        'ReservedNodeOfferingType': 'Regular'|'Upgradable'
    }
}

Response Structure

  • (dict) –

    • ReservedNode (dict) –

      Describes a reserved node. You can call the DescribeReservedNodeOfferings API to obtain the available reserved node offerings.

      • ReservedNodeId (string) –

        The unique identifier for the reservation.

      • ReservedNodeOfferingId (string) –

        The identifier for the reserved node offering.

      • NodeType (string) –

        The node type of the reserved node.

      • StartTime (datetime) –

        The time the reservation started. You purchase a reserved node offering for a duration. This is the start time of that duration.

      • Duration (integer) –

        The duration of the node reservation in seconds.

      • FixedPrice (float) –

        The fixed cost Amazon Redshift charges you for this reserved node.

      • UsagePrice (float) –

        The hourly rate Amazon Redshift charges you for this reserved node.

      • CurrencyCode (string) –

        The currency code for the reserved cluster.

      • NodeCount (integer) –

        The number of reserved compute nodes.

      • State (string) –

        The state of the reserved compute node.

        Possible Values:

        • pending-payment-This reserved node has recently been purchased, and the sale has been approved, but payment has not yet been confirmed.

        • active-This reserved node is owned by the caller and is available for use.

        • payment-failed-Payment failed for the purchase attempt.

        • retired-The reserved node is no longer available.

        • exchanging-The owner is exchanging the reserved node for another reserved node.

      • OfferingType (string) –

        The anticipated utilization of the reserved node, as defined in the reserved node offering.

      • RecurringCharges (list) –

        The recurring charges for the reserved node.

        • (dict) –

          Describes a recurring charge.

          • RecurringChargeAmount (float) –

            The amount charged per the period of time specified by the recurring charge frequency.

          • RecurringChargeFrequency (string) –

            The frequency at which the recurring charge amount is applied.

      • ReservedNodeOfferingType (string) –

Exceptions

  • Redshift.Client.exceptions.ReservedNodeOfferingNotFoundFault

  • Redshift.Client.exceptions.ReservedNodeAlreadyExistsFault

  • Redshift.Client.exceptions.ReservedNodeQuotaExceededFault

  • Redshift.Client.exceptions.UnsupportedOperationFault