---
title: "confirm(intent:completion:)"
framework: intents
role: symbol
role_heading: Instance Method
path: "intents/inaddmediaintenthandling/confirm(intent:completion:)"
---

# confirm(intent:completion:)

Confirms the details of the media addition request.

## Declaration

```swift
optional func confirm(intent: INAddMediaIntent, completion: @escaping @Sendable (INAddMediaIntentResponse) -> Void)
```

```swift
optional func confirm(intent: INAddMediaIntent) async -> INAddMediaIntentResponse
```

## Parameters

- `intent`: The doc://com.apple.sirikit/documentation/Intents/INAddMediaIntent object that contains details about the user’s request.
- `completion`: The handler block to execute with your response. You must execute this handler while implementing this method. This handler has no return value and takes the following parameter:

## Discussion

Discussion Implement this method to determine whether your app can add the requested media. If it can, respond with the INAddMediaIntentResponseCode.ready response code. If your app can’t add the media, respond with the appropriate failure code.
