describeImage method

Future<DescribeImageResponse> describeImage({
  1. required String imageName,
})

Describes a SageMaker image.

May throw ResourceNotFound.

Parameter imageName : The name of the image to describe.

Implementation

Future<DescribeImageResponse> describeImage({
  required String imageName,
}) async {
  ArgumentError.checkNotNull(imageName, 'imageName');
  _s.validateStringLength(
    'imageName',
    imageName,
    1,
    63,
    isRequired: true,
  );
  final headers = <String, String>{
    'Content-Type': 'application/x-amz-json-1.1',
    'X-Amz-Target': 'SageMaker.DescribeImage'
  };
  final jsonResponse = await _protocol.send(
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    // TODO queryParams
    headers: headers,
    payload: {
      'ImageName': imageName,
    },
  );

  return DescribeImageResponse.fromJson(jsonResponse.body);
}