getOperation method
Gets information about any operation that returns an operation ID in the
response, such as a CreateHttpNamespace request.
May throw InvalidInput.
May throw OperationNotFound.
Parameter operationId :
The ID of the operation that you want to get more information about.
Parameter ownerAccount :
The ID of the Amazon Web Services account that owns the namespace
associated with the operation, as specified in the namespace
ResourceOwner field. For operations associated with
namespaces that are shared with your account, you must specify an
OwnerAccount.
Implementation
Future<GetOperationResponse> getOperation({
required String operationId,
String? ownerAccount,
}) async {
final headers = <String, String>{
'Content-Type': 'application/x-amz-json-1.1',
'X-Amz-Target': 'Route53AutoNaming_v20170314.GetOperation'
};
final jsonResponse = await _protocol.send(
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
// TODO queryParams
headers: headers,
payload: {
'OperationId': operationId,
if (ownerAccount != null) 'OwnerAccount': ownerAccount,
},
);
return GetOperationResponse.fromJson(jsonResponse.body);
}