<!--
{
  "availability" : [
    "iOS: 18.0.0 -",
    "iPadOS: 18.0.0 -",
    "macCatalyst: 18.0.0 -",
    "macOS: 15.0.0 -",
    "visionOS: 2.0.0 -"
  ],
  "documentType" : "symbol",
  "framework" : "CoreSpotlight",
  "identifier" : "/documentation/CoreSpotlight/CSUserQuery/userEngaged(_:visibleItems:interaction:)",
  "metadataVersion" : "0.1.0",
  "role" : "Instance Method",
  "symbol" : {
    "kind" : "Instance Method",
    "modules" : [
      "Core Spotlight",
      "CoreSpotlight"
    ],
    "preciseIdentifier" : "s:So11CSUserQueryC13CoreSpotlightE11userEngaged_12visibleItems11interactionyAbCE4ItemV_SayAHGSo0A11InteractionVtF"
  },
  "title" : "userEngaged(_:visibleItems:interaction:)"
}
-->

# userEngaged(_:visibleItems:interaction:)

Notifies the system that someone engaged with a specific search
result in your app’s interface.

```
func userEngaged(_ item: CSUserQuery.Item, visibleItems: [CSUserQuery.Item], interaction: CSUserQuery.UserInteractionKind)
```

## Parameters

`item`

The search result that someone chose.

`visibleItems`

The set of search results your app was displaying.

`interaction`

The type of interaction with the item. Use
this parameter to indicate whether the person selected the item or
interacted with it in another way.

## Discussion

When someone selects or interacts with a specific search result in your
app’s UI, call this method to tell Spotlight about the interaction.
Reporting this type of engagement helps Spotlight deliver better results
more quickly in future queries. It also improves the ranked results
Spotlight delivers to your app. The system keeps all information about
these interactions on the current device

---

Copyright &copy; 2026 Apple Inc. All rights reserved. | [Terms of Use](https://www.apple.com/legal/internet-services/terms/site.html) | [Privacy Policy](https://www.apple.com/privacy/privacy-policy)