Redshift Serverless

2025/04/22 - Redshift Serverless - 5 new api methods

Changes  Provides new and updated API members to support the Redshift Serverless reservations feature.

ListReservations (new) Link ¶

Returns a list of Reservation objects.

See also: AWS API Documentation

Request Syntax

client.list_reservations(
    maxResults=123,
    nextToken='string'
)
type maxResults:

integer

param maxResults:

The maximum number of items to return for this call. The call also returns a token that you can specify in a subsequent call to get the next set of results.

type nextToken:

string

param nextToken:

The token for the next set of items to return. (You received this token from a previous call.)

rtype:

dict

returns:

Response Syntax

{
    'nextToken': 'string',
    'reservationsList': [
        {
            'capacity': 123,
            'endDate': datetime(2015, 1, 1),
            'offering': {
                'currencyCode': 'string',
                'duration': 123,
                'hourlyCharge': 123.0,
                'offeringId': 'string',
                'offeringType': 'ALL_UPFRONT'|'NO_UPFRONT',
                'upfrontCharge': 123.0
            },
            'reservationArn': 'string',
            'reservationId': 'string',
            'startDate': datetime(2015, 1, 1),
            'status': 'string'
        },
    ]
}

Response Structure

  • (dict) --

    • nextToken (string) --

      The token to use when requesting the next set of items.

    • reservationsList (list) --

      The serverless reservations returned by the request.

      • (dict) --

        Represents an Amazon Redshift Serverless reservation, which gives you the option to commit to a specified number of Redshift Processing Units (RPUs) for a year at a discount from Serverless on-demand (OD) rates.

        • capacity (integer) --

          The number of Redshift Processing Units (RPUs) to reserve.

        • endDate (datetime) --

          The end date for the serverless reservation. This date is one year after the start date that you specify.

        • offering (dict) --

          The type of offering for the reservation. The offering class determines the payment schedule for the reservation.

          • currencyCode (string) --

            The currency code for the offering.

          • duration (integer) --

            The duration, in seconds, for which the reservation reserves the RPUs.

          • hourlyCharge (float) --

            The rate you are charged for each hour the reservation is active.

          • offeringId (string) --

            The offering identifier.

          • offeringType (string) --

            Determines the payment schedule for the reservation.

          • upfrontCharge (float) --

            The up-front price you are charged for the reservation.

        • reservationArn (string) --

          The Amazon Resource Name (ARN) that uniquely identifies the serverless reservation.

        • reservationId (string) --

          The identifier that uniquely identifies the serverless reservation.

        • startDate (datetime) --

          The start date for the serverless reservation. This is the date you specified for the reservation to start when you created the reservation.

        • status (string) --

          The status of the reservation. Possible values include the following:

          • payment-pending

          • active

          • payment-failed

          • retired

ListReservationOfferings (new) Link ¶

Returns the current reservation offerings in your account.

See also: AWS API Documentation

Request Syntax

client.list_reservation_offerings(
    maxResults=123,
    nextToken='string'
)
type maxResults:

integer

param maxResults:

The maximum number of items to return for this call. The call also returns a token that you can specify in a subsequent call to get the next set of results.

type nextToken:

string

param nextToken:

The token for the next set of items to return. (You received this token from a previous call.)

rtype:

dict

returns:

Response Syntax

{
    'nextToken': 'string',
    'reservationOfferingsList': [
        {
            'currencyCode': 'string',
            'duration': 123,
            'hourlyCharge': 123.0,
            'offeringId': 'string',
            'offeringType': 'ALL_UPFRONT'|'NO_UPFRONT',
            'upfrontCharge': 123.0
        },
    ]
}

Response Structure

  • (dict) --

    • nextToken (string) --

      The token to use when requesting the next set of items.

    • reservationOfferingsList (list) --

      The returned list of reservation offerings.

      • (dict) --

        The class of offering for the reservation. The offering class determines the payment schedule for the reservation.

        • currencyCode (string) --

          The currency code for the offering.

        • duration (integer) --

          The duration, in seconds, for which the reservation reserves the RPUs.

        • hourlyCharge (float) --

          The rate you are charged for each hour the reservation is active.

        • offeringId (string) --

          The offering identifier.

        • offeringType (string) --

          Determines the payment schedule for the reservation.

        • upfrontCharge (float) --

          The up-front price you are charged for the reservation.

GetReservationOffering (new) Link ¶

Returns the reservation offering. The offering determines the payment schedule for the reservation.

See also: AWS API Documentation

Request Syntax

client.get_reservation_offering(
    offeringId='string'
)
type offeringId:

string

param offeringId:

[REQUIRED]

The identifier for the offering..

rtype:

dict

returns:

Response Syntax

{
    'reservationOffering': {
        'currencyCode': 'string',
        'duration': 123,
        'hourlyCharge': 123.0,
        'offeringId': 'string',
        'offeringType': 'ALL_UPFRONT'|'NO_UPFRONT',
        'upfrontCharge': 123.0
    }
}

Response Structure

  • (dict) --

    • reservationOffering (dict) --

      The returned reservation offering. The offering determines the payment schedule for the reservation.

      • currencyCode (string) --

        The currency code for the offering.

      • duration (integer) --

        The duration, in seconds, for which the reservation reserves the RPUs.

      • hourlyCharge (float) --

        The rate you are charged for each hour the reservation is active.

      • offeringId (string) --

        The offering identifier.

      • offeringType (string) --

        Determines the payment schedule for the reservation.

      • upfrontCharge (float) --

        The up-front price you are charged for the reservation.

GetReservation (new) Link ¶

Gets an Amazon Redshift Serverless reservation. A reservation gives you the option to commit to a specified number of Redshift Processing Units (RPUs) for a year at a discount from Serverless on-demand (OD) rates.

See also: AWS API Documentation

Request Syntax

client.get_reservation(
    reservationId='string'
)
type reservationId:

string

param reservationId:

[REQUIRED]

The ID of the reservation to retrieve.

rtype:

dict

returns:

Response Syntax

{
    'reservation': {
        'capacity': 123,
        'endDate': datetime(2015, 1, 1),
        'offering': {
            'currencyCode': 'string',
            'duration': 123,
            'hourlyCharge': 123.0,
            'offeringId': 'string',
            'offeringType': 'ALL_UPFRONT'|'NO_UPFRONT',
            'upfrontCharge': 123.0
        },
        'reservationArn': 'string',
        'reservationId': 'string',
        'startDate': datetime(2015, 1, 1),
        'status': 'string'
    }
}

Response Structure

  • (dict) --

    • reservation (dict) --

      The returned reservation object.

      • capacity (integer) --

        The number of Redshift Processing Units (RPUs) to reserve.

      • endDate (datetime) --

        The end date for the serverless reservation. This date is one year after the start date that you specify.

      • offering (dict) --

        The type of offering for the reservation. The offering class determines the payment schedule for the reservation.

        • currencyCode (string) --

          The currency code for the offering.

        • duration (integer) --

          The duration, in seconds, for which the reservation reserves the RPUs.

        • hourlyCharge (float) --

          The rate you are charged for each hour the reservation is active.

        • offeringId (string) --

          The offering identifier.

        • offeringType (string) --

          Determines the payment schedule for the reservation.

        • upfrontCharge (float) --

          The up-front price you are charged for the reservation.

      • reservationArn (string) --

        The Amazon Resource Name (ARN) that uniquely identifies the serverless reservation.

      • reservationId (string) --

        The identifier that uniquely identifies the serverless reservation.

      • startDate (datetime) --

        The start date for the serverless reservation. This is the date you specified for the reservation to start when you created the reservation.

      • status (string) --

        The status of the reservation. Possible values include the following:

        • payment-pending

        • active

        • payment-failed

        • retired

CreateReservation (new) Link ¶

Creates an Amazon Redshift Serverless reservation, which gives you the option to commit to a specified number of Redshift Processing Units (RPUs) for a year at a discount from Serverless on-demand (OD) rates.

See also: AWS API Documentation

Request Syntax

client.create_reservation(
    capacity=123,
    clientToken='string',
    offeringId='string'
)
type capacity:

integer

param capacity:

[REQUIRED]

The number of Redshift Processing Units (RPUs) to reserve.

type clientToken:

string

param clientToken:

A unique, case-sensitive identifier that you provide to ensure the idempotency of the request. If not provided, the Amazon Web Services SDK populates this field. This token must be a valid UUIDv4 value. For more information about idempotency, see Making retries safe with idempotent APIs.

This field is autopopulated if not provided.

type offeringId:

string

param offeringId:

[REQUIRED]

The ID of the offering associated with the reservation. The offering determines the payment schedule for the reservation.

rtype:

dict

returns:

Response Syntax

{
    'reservation': {
        'capacity': 123,
        'endDate': datetime(2015, 1, 1),
        'offering': {
            'currencyCode': 'string',
            'duration': 123,
            'hourlyCharge': 123.0,
            'offeringId': 'string',
            'offeringType': 'ALL_UPFRONT'|'NO_UPFRONT',
            'upfrontCharge': 123.0
        },
        'reservationArn': 'string',
        'reservationId': 'string',
        'startDate': datetime(2015, 1, 1),
        'status': 'string'
    }
}

Response Structure

  • (dict) --

    • reservation (dict) --

      The reservation object that the CreateReservation action created.

      • capacity (integer) --

        The number of Redshift Processing Units (RPUs) to reserve.

      • endDate (datetime) --

        The end date for the serverless reservation. This date is one year after the start date that you specify.

      • offering (dict) --

        The type of offering for the reservation. The offering class determines the payment schedule for the reservation.

        • currencyCode (string) --

          The currency code for the offering.

        • duration (integer) --

          The duration, in seconds, for which the reservation reserves the RPUs.

        • hourlyCharge (float) --

          The rate you are charged for each hour the reservation is active.

        • offeringId (string) --

          The offering identifier.

        • offeringType (string) --

          Determines the payment schedule for the reservation.

        • upfrontCharge (float) --

          The up-front price you are charged for the reservation.

      • reservationArn (string) --

        The Amazon Resource Name (ARN) that uniquely identifies the serverless reservation.

      • reservationId (string) --

        The identifier that uniquely identifies the serverless reservation.

      • startDate (datetime) --

        The start date for the serverless reservation. This is the date you specified for the reservation to start when you created the reservation.

      • status (string) --

        The status of the reservation. Possible values include the following:

        • payment-pending

        • active

        • payment-failed

        • retired