startKeyUsage method

Future<StartKeyUsageOutput> startKeyUsage({
  1. required String keyIdentifier,
})

Enables an Amazon Web Services Payment Cryptography key, which makes it active for cryptographic operations within Amazon Web Services Payment Cryptography

Cross-account use: This operation supports cross-account use when the key has a resource-based policy that grants access. For more information, see Resource-based policies.

Related operations:

May throw AccessDeniedException. May throw ConflictException. May throw InternalServerException. May throw ResourceNotFoundException. May throw ServiceQuotaExceededException. May throw ServiceUnavailableException. May throw ThrottlingException. May throw ValidationException.

Parameter keyIdentifier : The KeyArn of the key.

Implementation

Future<StartKeyUsageOutput> startKeyUsage({
  required String keyIdentifier,
}) async {
  final headers = <String, String>{
    'Content-Type': 'application/x-amz-json-1.0',
    'X-Amz-Target': 'PaymentCryptographyControlPlane.StartKeyUsage'
  };
  final jsonResponse = await _protocol.send(
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    // TODO queryParams
    headers: headers,
    payload: {
      'KeyIdentifier': keyIdentifier,
    },
  );

  return StartKeyUsageOutput.fromJson(jsonResponse.body);
}