---
title: Resolving the Parameters of an Intent
framework: sirikit
role: article
role_heading: Article
path: sirikit/resolving-the-parameters-of-an-intent
---

# Resolving the Parameters of an Intent

Validate the parameters of an intent and make sure that you have the information you need to continue.

## Overview

Overview You must resolve the parameters of an intent to verify that you have the information you need to fulfill the user’s request. When the user talks to Siri, Siri converts the user’s spoken commands into actionable data and places that data in an intent object. During resolution, SiriKit prompts you to verify each parameter individually by calling the resolution methods of your handler object. In each method, you validate the provided data and create a resolution result object indicating your success or failure in resolving the parameter. SiriKit uses your resolution result object to determine how to proceed. For example, if your resolution result asks the user to disambiguate from among two or more choices, SiriKit prompts the user to select one of those choices. The example below shows how a ride booking app might resolve the drop-off location of the user’s ride. In this example, the user must provide a valid drop-off location before the app can fulfill the ride request. If the user supplies a drop-off location that is within the app’s service area, the method returns a successful resolution result. If the drop-off location is outside the valid service area, the resolution result indicates that the location is unsupported. If the user did not specify a drop-off location at all, the method creates a resolution result indicating that the value is needed. func resolveDropOffLocation(             forRequestRide intent: INRequestRideIntent,             with completion: @escaping (INPlacemarkResolutionResult) -> Void) {         var result: INPlacemarkResolutionResult             if let location = intent.dropOffLocation {       // If the location is valid, use it; otherwise,       // let the user know it is not supported       if self.locationIsInsideServiceArea(location) {          result = INPlacemarkResolutionResult.success(with: location)       } else {          result = INPlacemarkResolutionResult.unsupported()       }    } else {       // Ask for the drop-off location.       result = INPlacemarkResolutionResult.needsValue()    }

// Return the result back to SiriKit.    completion(result) }

Each resolvable parameter has a corresponding resolution result class that you use to communicate your results back to SiriKit. For example, resolving the CLPlacemark object in the preceding example requires the creation of an INPlacemarkResolutionResult object. All resolution result classes inherit from the INIntentResolutionResult base class, which defines the common ways to resolve parameters of any type. When returning a resolution to SiriKit, always include as much information as you can about the actual result. After each resolution attempt, SiriKit updates the intent object with the information you provide. If resolution was unsuccessful and SiriKit needs to call your resolution method again, you can use the extra information to reach a resolution more quickly. For example, if you find two contacts with the same name during resolution, you might populate the customIdentifier property of each INPerson object with a unique string that you can use to look up the selected contact later. Your resolution method can then look for that identifier first and bypass any other contact-matching logic. Choosing the Correct Resolution Result The resolution result object you give back to SiriKit determines whether any further user interactions will occur. You must resolve all parameters successfully or let SiriKit know that the parameter is not required. All other resolutions require Siri to gather more information from the user. To create a resolution result object, choose the appropriate class method. Each specific resolution result class has methods defining the possible resolutions for the corresponding type. The INIntentResolutionResult base class also defines a set of common resolutions. This table lists the resolution types and their meaning:  |   |   |   |   |   |   |  Try to reach a resolution of “Success” or “Not required” as quickly as possible. Other resolution results lead to additional user interactions and additional calls to your handler. You should also avoid repeatedly asking for clarification of the same parameter, which could frustrate the user. Whenever possible, choose reasonable values based on the user’s patterns and habits, and ask for disambiguation or confirmation only as needed.

## See Also

### Articles

- [Adding User Interactivity with Siri Shortcuts and the Shortcuts App](sirikit/adding-user-interactivity-with-siri-shortcuts-and-the-shortcuts-app.md)
- [Defining Relevant Shortcuts for the Siri Watch Face](sirikit/defining-relevant-shortcuts-for-the-siri-watch-face.md)
- [Deleting Donated Shortcuts](sirikit/deleting-donated-shortcuts.md)
- [Dispatching intents to handlers](sirikit/dispatching-intents-to-handlers.md)
- [Improving Siri Media Interactions and App Selection](sirikit/improving-siri-media-interactions-and-app-selection.md)
- [Improving interactions between Siri and your messaging app](sirikit/improving-interactions-between-siri-and-your-messaging-app.md)
- [Registering Custom Vocabulary with SiriKit](sirikit/registering-custom-vocabulary-with-sirikit.md)
- [Confirming the Details of an Intent](sirikit/confirming-the-details-of-an-intent.md)
- [Handling an Intent](sirikit/handling-an-intent.md)
- [Generating a List of Ride Options](sirikit/generating-a-list-of-ride-options.md)
- [Handling the Ride-Booking Intents](sirikit/handling-the-ride-booking-intents.md)
- [Donating Reservations](sirikit/donating-reservations.md)
- [Specifying Synonyms for Your App Name](sirikit/specifying-synonyms-for-your-app-name.md)
- [Intent Phrases](sirikit/intent-phrases.md)
- [Localizing Your Vocabulary for Chinese Dialects](sirikit/localizing-your-vocabulary-for-chinese-dialects.md)
