getJob method
Returns a job for a branch of an Amplify app.
May throw BadRequestException. May throw UnauthorizedException. May throw InternalFailureException. May throw NotFoundException. May throw LimitExceededException.
Parameter appId
:
The unique ID for an Amplify app.
Parameter branchName
:
The branch name for the job.
Parameter jobId
:
The unique ID for the job.
Implementation
Future<GetJobResult> getJob({
required String appId,
required String branchName,
required String jobId,
}) async {
ArgumentError.checkNotNull(appId, 'appId');
_s.validateStringLength(
'appId',
appId,
1,
20,
isRequired: true,
);
ArgumentError.checkNotNull(branchName, 'branchName');
_s.validateStringLength(
'branchName',
branchName,
1,
255,
isRequired: true,
);
ArgumentError.checkNotNull(jobId, 'jobId');
_s.validateStringLength(
'jobId',
jobId,
0,
255,
isRequired: true,
);
final response = await _protocol.send(
payload: null,
method: 'GET',
requestUri:
'/apps/${Uri.encodeComponent(appId)}/branches/${Uri.encodeComponent(branchName)}/jobs/${Uri.encodeComponent(jobId)}',
exceptionFnMap: _exceptionFns,
);
return GetJobResult.fromJson(response);
}