purchaseProvisionedCapacity method
Future<PurchaseProvisionedCapacityOutput>
purchaseProvisionedCapacity({
- required String accountId,
This operation purchases a provisioned capacity unit for an AWS account.
May throw InvalidParameterValueException.
May throw LimitExceededException.
May throw MissingParameterValueException.
May throw NoLongerSupportedException.
May throw ServiceUnavailableException.
Parameter accountId :
The AWS account ID of the account that owns the vault. You can either
specify an AWS account ID or optionally a single '-' (hyphen), in which
case Amazon Glacier uses the AWS account ID associated with the
credentials used to sign the request. If you use an account ID, don't
include any hyphens ('-') in the ID.
Implementation
Future<PurchaseProvisionedCapacityOutput> purchaseProvisionedCapacity({
required String accountId,
}) async {
final response = await _protocol.sendRaw(
payload: null,
method: 'POST',
requestUri: '/${Uri.encodeComponent(accountId)}/provisioned-capacity',
exceptionFnMap: _exceptionFns,
);
final $json = await _s.jsonFromResponse(response);
return PurchaseProvisionedCapacityOutput(
capacityId:
_s.extractHeaderStringValue(response.headers, 'x-amz-capacity-id'),
);
}