---
title: "Spotlight Search (Realtime)"
slug: "spotlight-search-realtime"
updated: 2026-05-18T14:34:22Z
published: 2026-05-18T14:34:22Z
---

> ## Documentation Index
> Fetch the complete documentation index at: https://developer.rocket.chat/llms.txt
> Use this file to discover all available pages before exploring further.

# Spotlight Search (Realtime)

![](https://cdn.us.document360.io/27ca1fd4-36d7-4cde-b4eb-97fc1652954c/Images/Documentation/Deprecated.svg)

Search for rooms or users.

| Method | Requires Auth |
| --- | --- |
| `spotlight` | Yes |

## Payload parameters

| Argument | Example | Required | Description |
| --- | --- | --- | --- |
| `searchString` | `test` | Required | The term to be searched for. |
| `exclude` | `test.rc` | Optional | Any items to exclude from the results (e.g. users you already know about). |
| `options` | `{ "users": true, "rooms": false }` | Required | The kind of fields to search for. |

## Example call

```json
{
    "msg": "method",
    "method": "spotlight",
    "params": ["test", ["testrc"], {
        "users": true,
        "rooms": false
    }],
    "id": "74290"
}
```

## Example response

```json
{
    "msg": "result",
    "id": "74290",
    "result": {
        "users": [
            {
                "_id": "ZoJM4tvohREwJbtAh",
                "username": "testrc",
                "status": "offline",
                "name": "TestRc",
                "outside": true
            }
        ],
        "rooms": []
    }
}
```
