startPatientInsightsJob method
Future<StartPatientInsightsJobResponse>
startPatientInsightsJob({
- required String domainId,
- required PatientInsightsEncounterContext encounterContext,
- required InputDataConfig inputDataConfig,
- required InsightsContext insightsContext,
- required OutputDataConfig outputDataConfig,
- required PatientInsightsPatientContext patientContext,
- required UserContext userContext,
- String? clientToken,
Starts a new patient insights job.
May throw AccessDeniedException.
May throw ConflictException.
May throw InternalServerException.
May throw ResourceNotFoundException.
May throw ThrottlingException.
May throw ValidationException.
Parameter domainId :
Parameter encounterContext :
Parameter inputDataConfig :
Parameter insightsContext :
Parameter outputDataConfig :
Parameter patientContext :
Parameter userContext :
Parameter clientToken :
Unique, case-sensitive identifier that you provide to ensure the
idempotency of the request.
Implementation
Future<StartPatientInsightsJobResponse> startPatientInsightsJob({
required String domainId,
required PatientInsightsEncounterContext encounterContext,
required InputDataConfig inputDataConfig,
required InsightsContext insightsContext,
required OutputDataConfig outputDataConfig,
required PatientInsightsPatientContext patientContext,
required UserContext userContext,
String? clientToken,
}) async {
final $payload = <String, dynamic>{
'encounterContext': encounterContext,
'inputDataConfig': inputDataConfig,
'insightsContext': insightsContext,
'outputDataConfig': outputDataConfig,
'patientContext': patientContext,
'userContext': userContext,
'clientToken': clientToken ?? _s.generateIdempotencyToken(),
};
final response = await _protocol.send(
payload: $payload,
method: 'POST',
requestUri:
'/domain/${Uri.encodeComponent(domainId)}/patient-insights-job',
hostPrefix: 'runtime.',
exceptionFnMap: _exceptionFns,
);
return StartPatientInsightsJobResponse.fromJson(response);
}