exportNotebook method

Future<ExportNotebookOutput> exportNotebook({
  1. required String notebookId,
})

Exports the specified notebook and its metadata.

May throw InternalServerException. May throw InvalidRequestException. May throw TooManyRequestsException.

Parameter notebookId : The ID of the notebook to export.

Implementation

Future<ExportNotebookOutput> exportNotebook({
  required String notebookId,
}) async {
  final headers = <String, String>{
    'Content-Type': 'application/x-amz-json-1.1',
    'X-Amz-Target': 'AmazonAthena.ExportNotebook'
  };
  final jsonResponse = await _protocol.send(
    method: 'POST',
    requestUri: '/',
    exceptionFnMap: _exceptionFns,
    // TODO queryParams
    headers: headers,
    payload: {
      'NotebookId': notebookId,
    },
  );

  return ExportNotebookOutput.fromJson(jsonResponse.body);
}