checkInLicense method

Future<void> checkInLicense({
  1. required String licenseConsumptionToken,
  2. String? beneficiary,
})

Checks in the specified license. Check in a license when it is no longer in use.

May throw AccessDeniedException. May throw AuthorizationException. May throw ConflictException. May throw InvalidParameterValueException. May throw RateLimitExceededException. May throw ResourceNotFoundException. May throw ServerInternalException. May throw ValidationException.

Parameter licenseConsumptionToken : License consumption token.

Parameter beneficiary : License beneficiary.

Implementation

Future<void> checkInLicense({
  required String licenseConsumptionToken,
  String? beneficiary,
}) async {
  final headers = <String, String>{
    'Content-Type': 'application/x-amz-json-1.1',
    'X-Amz-Target': 'AWSLicenseManager.CheckInLicense'
  };
  await _protocol.send(
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    // TODO queryParams
    headers: headers,
    payload: {
      'LicenseConsumptionToken': licenseConsumptionToken,
      if (beneficiary != null) 'Beneficiary': beneficiary,
    },
  );
}