getDashboard method

Future<GetDashboardOutput> getDashboard({
  1. required String dashboardName,
})

Displays the details of the dashboard that you specify.

To copy an existing dashboard, use GetDashboard, and then use the data returned within DashboardBody as the template for the new dashboard when you call PutDashboard to create the copy.

May throw DashboardNotFoundError. May throw InternalServiceFault. May throw InvalidParameterValueException.

Parameter dashboardName : The name of the dashboard to be described.

Implementation

Future<GetDashboardOutput> getDashboard({
  required String dashboardName,
}) async {
  final headers = <String, String>{
    'Content-Type': 'application/x-amz-json-1.0',
    'X-Amz-Target': 'GraniteServiceVersion20100801.GetDashboard'
  };
  final jsonResponse = await _protocol.send(
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    // TODO queryParams
    headers: headers,
    payload: {
      'DashboardName': dashboardName,
    },
  );

  return GetDashboardOutput.fromJson(jsonResponse.body);
}