deactivateKeySigningKey method

Future<DeactivateKeySigningKeyResponse> deactivateKeySigningKey({
  1. required String hostedZoneId,
  2. required String name,
})

Deactivates a key signing key (KSK) so that it will not be used for signing by DNSSEC. This operation changes the KSK status to INACTIVE.

May throw ConcurrentModification. May throw NoSuchKeySigningKey. May throw InvalidKeySigningKeyStatus. May throw InvalidSigningStatus. May throw KeySigningKeyInUse. May throw KeySigningKeyInParentDSRecord.

Parameter hostedZoneId : A unique string used to identify a hosted zone.

Parameter name : An alphanumeric string used to identify a key signing key (KSK).

Implementation

Future<DeactivateKeySigningKeyResponse> deactivateKeySigningKey({
  required String hostedZoneId,
  required String name,
}) async {
  ArgumentError.checkNotNull(hostedZoneId, 'hostedZoneId');
  _s.validateStringLength(
    'hostedZoneId',
    hostedZoneId,
    0,
    32,
    isRequired: true,
  );
  ArgumentError.checkNotNull(name, 'name');
  _s.validateStringLength(
    'name',
    name,
    3,
    128,
    isRequired: true,
  );
  final $result = await _protocol.send(
    method: 'POST',
    requestUri:
        '/2013-04-01/keysigningkey/${Uri.encodeComponent(hostedZoneId)}/${Uri.encodeComponent(name)}/deactivate',
    exceptionFnMap: _exceptionFns,
  );
  return DeactivateKeySigningKeyResponse.fromXml($result.body);
}