Contents

handle(intent:completion:)

Handles the scheduling of the transfer.

Declaration

func handle(intent: INTransferMoneyIntent, completion: @escaping  @Sendable (INTransferMoneyIntentResponse) -> Void)
func handle(intent: INTransferMoneyIntent) async -> INTransferMoneyIntentResponse

Parameters

  • intent:

    The intent object containing details about the user’s request. Your handler has already resolved and confirmed the information in this object.

  • completion:

    The handler block to execute with your response. You must execute this handler at some point during your implementation of this method. This handler has no return value and takes the following parameter:

    response

    The Intransfermoneyintentresponse object containing the status of the request. This parameter must not be nil.

Discussion

Your implementation of this method must schedule the transfer using the information provided by the intent object. The response you object that you provide should include the transaction details and the success or failure of the operation. The successful scheduling of a transfer means that your service has recorded the transaction details and can perform the transfer on the specified date.