startEngagementByAcceptingInvitationTask method
This action starts the engagement by accepting an
EngagementInvitation. The task is asynchronous and involves
the following steps: accepting the invitation, creating an opportunity in
the partner’s account from the AWS opportunity, and copying details for
tracking. When completed, an Opportunity Created event is
generated, indicating that the opportunity has been successfully created
in the partner's account.
May throw AccessDeniedException.
May throw ConflictException.
May throw InternalServerException.
May throw ResourceNotFoundException.
May throw ServiceQuotaExceededException.
May throw ThrottlingException.
May throw ValidationException.
Parameter catalog :
Specifies the catalog related to the task. Use AWS for
production engagements and Sandbox for testing scenarios.
Parameter identifier :
Specifies the unique identifier of the EngagementInvitation
to be accepted. Providing the correct identifier helps ensure that the
correct engagement is processed.
Parameter clientToken :
A unique, case-sensitive identifier provided by the client that helps to
ensure the idempotency of the request. This can be a random or meaningful
string but must be unique for each request.
Parameter tags :
A map of the key-value pairs of the tag or tags to assign.
Implementation
Future<StartEngagementByAcceptingInvitationTaskResponse>
startEngagementByAcceptingInvitationTask({
required String catalog,
required String identifier,
String? clientToken,
List<Tag>? tags,
}) async {
final headers = <String, String>{
'Content-Type': 'application/x-amz-json-1.0',
'X-Amz-Target':
'AWSPartnerCentralSelling.StartEngagementByAcceptingInvitationTask'
};
final jsonResponse = await _protocol.send(
method: 'POST',
requestUri: '/',
exceptionFnMap: _exceptionFns,
// TODO queryParams
headers: headers,
payload: {
'Catalog': catalog,
'Identifier': identifier,
'ClientToken': clientToken ?? _s.generateIdempotencyToken(),
if (tags != null) 'Tags': tags,
},
);
return StartEngagementByAcceptingInvitationTaskResponse.fromJson(
jsonResponse.body);
}