describeServer method
Describes a file transfer protocol-enabled server that you specify by
passing the ServerId
parameter.
The response contains a description of a server's properties. When you set
EndpointType
to VPC, the response will contain the
EndpointDetails
.
May throw ServiceUnavailableException. May throw InternalServiceError. May throw InvalidRequestException. May throw ResourceNotFoundException.
Parameter serverId
:
A system-assigned unique identifier for a server.
Implementation
Future<DescribeServerResponse> describeServer({
required String serverId,
}) async {
ArgumentError.checkNotNull(serverId, 'serverId');
_s.validateStringLength(
'serverId',
serverId,
19,
19,
isRequired: true,
);
final headers = <String, String>{
'Content-Type': 'application/x-amz-json-1.1',
'X-Amz-Target': 'TransferService.DescribeServer'
};
final jsonResponse = await _protocol.send(
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
// TODO queryParams
headers: headers,
payload: {
'ServerId': serverId,
},
);
return DescribeServerResponse.fromJson(jsonResponse.body);
}