PurchaseReservedNodesOfferingCommand

Allows you to purchase a reserved node offering. Reserved nodes are not eligible for cancellation and are non-refundable.

Example Syntax

Use a bare-bones client and the command you need to make an API call.

import { MemoryDBClient, PurchaseReservedNodesOfferingCommand } from "@aws-sdk/client-memorydb"; // ES Modules import
// const { MemoryDBClient, PurchaseReservedNodesOfferingCommand } = require("@aws-sdk/client-memorydb"); // CommonJS import
const client = new MemoryDBClient(config);
const input = { // PurchaseReservedNodesOfferingRequest
  ReservedNodesOfferingId: "STRING_VALUE", // required
  ReservationId: "STRING_VALUE",
  NodeCount: Number("int"),
  Tags: [ // TagList
    { // Tag
      Key: "STRING_VALUE",
      Value: "STRING_VALUE",
    },
  ],
};
const command = new PurchaseReservedNodesOfferingCommand(input);
const response = await client.send(command);
// { // PurchaseReservedNodesOfferingResponse
//   ReservedNode: { // ReservedNode
//     ReservationId: "STRING_VALUE",
//     ReservedNodesOfferingId: "STRING_VALUE",
//     NodeType: "STRING_VALUE",
//     StartTime: new Date("TIMESTAMP"),
//     Duration: Number("int"),
//     FixedPrice: Number("double"),
//     NodeCount: Number("int"),
//     OfferingType: "STRING_VALUE",
//     State: "STRING_VALUE",
//     RecurringCharges: [ // RecurringChargeList
//       { // RecurringCharge
//         RecurringChargeAmount: Number("double"),
//         RecurringChargeFrequency: "STRING_VALUE",
//       },
//     ],
//     ARN: "STRING_VALUE",
//   },
// };

PurchaseReservedNodesOfferingCommand Input

Parameter
Type
Description
ReservedNodesOfferingId
Required
string | undefined

The ID of the reserved node offering to purchase.

NodeCount
number | undefined

The number of node instances to reserve.

ReservationId
string | undefined

A customer-specified identifier to track this reservation.

Tags
Tag[] | undefined

A list of tags to be added to this resource. A tag is a key-value pair. A tag key must be accompanied by a tag value, although null is accepted.

PurchaseReservedNodesOfferingCommand Output

Parameter
Type
Description
$metadata
Required
ResponseMetadata
Metadata pertaining to this request.
ReservedNode
ReservedNode | undefined

Represents the output of a PurchaseReservedNodesOffering operation.

Throws

Name
Fault
Details
InvalidParameterCombinationException
client

InvalidParameterValueException
client

ReservedNodeAlreadyExistsFault
client

You already have a reservation with the given identifier.

ReservedNodeQuotaExceededFault
client

The request cannot be processed because it would exceed the user's node quota.

ReservedNodesOfferingNotFoundFault
client

The requested node offering does not exist.

ServiceLinkedRoleNotFoundFault
client

TagQuotaPerResourceExceeded
client

MemoryDBServiceException
Base exception class for all service exceptions from MemoryDB service.