getImportJob method

Future<GetImportJobResponse> getImportJob({
  1. required String importJobId,
  2. required String knowledgeBaseId,
})

Retrieves the started import job.

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

Parameter importJobId : The identifier of the import job to retrieve.

Parameter knowledgeBaseId : The identifier of the knowledge base that the import job belongs to.

Implementation

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