# Search Users (`search_users`)

Part of the [Outfield MCP Server](https://run.outfieldapp.com/docs/mcp) docs. All tools: [llms.txt](https://run.outfieldapp.com/docs/mcp/llms.txt). Server URL: https://run.outfieldapp.com/mcp

Find teammates by name, title, role, email or other profile data and get the user id other tools need.

Search accessible Outfield team members by name, title, role, email, or other profile data. Use a returned user id as user_id for get_user_activity. Admins can also use it for get_user_goals; non-admins can load only their own goals. If multiple users could match, ask the user to clarify before loading activity or goals. If the user names a team, call get_user_profile first and pass organization_id. Omit organization_id to search the current organization.

- Scopes: `ai:read`
- Requires: AI, not available to Viewer users
- Example prompts: "Find John Smith on my team."

### Parameters

- `query` (string; required): Full-text user search query
- `limit` (integer; optional): Max users returned. Default 10, max 25
- `organization_id` (integer; optional): Organization ID from get_user_profile. Omit to use the current organization. If the user names a team, call get_user_profile first and pass that id.

### Notes

- Returns up to 25 users. If several people match, confirm which one before loading their data.

### Example request

```json
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "search_users",
    "arguments": {
      "query": "John Smith"
    }
  }
}
```

### Example response (`structuredContent`, illustrative data)

```json
{
  "users": [
    {
      "id": 7311,
      "organization_id": 2044,
      "organization_name": "Acme Beverage Co.",
      "name": "Jordan Rivera",
      "title": "Field Representative",
      "role": "user",
      "is_active": true
    }
  ],
  "meta": {
    "query": "John Smith",
    "limit": 25,
    "result_count": 1,
    "truncated": false,
    "organization_id": 2044,
    "organization_name": "Acme Beverage Co."
  }
}
```

### Response fields

- `users` (object[])
  - `id` (integer)
  - `organization_id` (integer)
  - `organization_name` (string)
  - `name` (string | null)
  - `title` (string | null)
  - `role` (string | null)
  - `is_active` (boolean | null)
- `meta` (object)
  - `query` (string)
  - `limit` (integer)
  - `result_count` (integer)
  - `truncated` (boolean)
  - `organization_id` (integer)
  - `organization_name` (string)

Related tools: [get_user_activity](https://run.outfieldapp.com/docs/mcp/tools/get_user_activity.md), [get_user_goals](https://run.outfieldapp.com/docs/mcp/tools/get_user_goals.md), [get_user_performance](https://run.outfieldapp.com/docs/mcp/tools/get_user_performance.md), [get_user_deals](https://run.outfieldapp.com/docs/mcp/tools/get_user_deals.md)
