getKnowledgeBase method

Future<GetKnowledgeBaseResponse> getKnowledgeBase({
  1. required String knowledgeBaseId,
})

Retrieves information about the knowledge base.

May throw AccessDeniedException. May throw ResourceNotFoundException. May throw ValidationException.

Parameter knowledgeBaseId : The identifier of the knowledge base. This should not be a QUICK_RESPONSES type knowledge base if you're storing Wisdom Content resource to it. Can be either the ID or the ARN. URLs cannot contain the ARN.

Implementation

Future<GetKnowledgeBaseResponse> getKnowledgeBase({
  required String knowledgeBaseId,
}) async {
  final response = await _protocol.send(
    payload: null,
    method: 'GET',
    requestUri: '/knowledgeBases/${Uri.encodeComponent(knowledgeBaseId)}',
    exceptionFnMap: _exceptionFns,
  );
  return GetKnowledgeBaseResponse.fromJson(response);
}