---
title: queryToken
framework: corespotlight
role: symbol
role_heading: Instance Property
path: corespotlight/spotlightsearchtool/searchreply/querytoken-swift.property
---

# queryToken

An opaque value you use to identify the query that generated the reply.

## Declaration

```swift
let queryToken: SpotlightSearchTool.SearchReply.QueryToken
```

## Mentioned in

Making your indexed content available to Foundation Models

## Discussion

Discussion When processing a request, a model might create multiple queries to find and refine search results. Use this property to associate replies with a specific query. The token itself is an opaque value you save and compare against tokens in other search replies. You might use this value to partition the data you receive.

## See Also

### Getting the tokens

- [stageToken](corespotlight/spotlightsearchtool/searchreply/stagetoken-swift.property.md)
- [SpotlightSearchTool.SearchReply.QueryToken](corespotlight/spotlightsearchtool/searchreply/querytoken-swift.struct.md)
- [SpotlightSearchTool.SearchReply.StageToken](corespotlight/spotlightsearchtool/searchreply/stagetoken-swift.struct.md)
