notifyProvisionProductEngineWorkflowResult method
Notifies the result of the provisioning engine execution.
May throw InvalidParametersException.
May throw ResourceNotFoundException.
Parameter recordId :
The identifier of the record.
Parameter status :
The status of the provisioning engine execution.
Parameter workflowToken :
The encrypted contents of the provisioning engine execution payload that
Service Catalog sends after the Terraform product provisioning workflow
starts.
Parameter failureReason :
The reason why the provisioning engine execution failed.
Parameter idempotencyToken :
The idempotency token that identifies the provisioning engine execution.
Parameter outputs :
The output of the provisioning engine execution.
Parameter resourceIdentifier :
The ID for the provisioned product resources that are part of a resource
group.
Implementation
Future<void> notifyProvisionProductEngineWorkflowResult({
required String recordId,
required EngineWorkflowStatus status,
required String workflowToken,
String? failureReason,
String? idempotencyToken,
List<RecordOutput>? outputs,
EngineWorkflowResourceIdentifier? resourceIdentifier,
}) async {
final headers = <String, String>{
'Content-Type': 'application/x-amz-json-1.1',
'X-Amz-Target':
'AWS242ServiceCatalogService.NotifyProvisionProductEngineWorkflowResult'
};
await _protocol.send(
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
// TODO queryParams
headers: headers,
payload: {
'RecordId': recordId,
'Status': status.value,
'WorkflowToken': workflowToken,
if (failureReason != null) 'FailureReason': failureReason,
'IdempotencyToken': idempotencyToken ?? _s.generateIdempotencyToken(),
if (outputs != null) 'Outputs': outputs,
if (resourceIdentifier != null)
'ResourceIdentifier': resourceIdentifier,
},
);
}