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

# Clients

> Reference for managing and searching company clients.

The `clients` module provides tools to search, retrieve, create/link, and
inspect client profile access within the company scope.

| Key                  | Value         |
| :------------------- | :------------ |
| **Module Key**       | `clients`     |
| **Sensitivity**      | `operational` |
| **Consent Required** | None          |

***

## Available Tools

### `search_clients`

Search the company's client list by name or email. Returns paginated client summaries.

* **Type:** Read-only
* **Important Input Fields:**
  * `query` (string, optional): Search string matched against first name, last name, or email. Max 200 chars.
  * `relationshipStatus` (string, optional): Filter by status (e.g. `active`, `invited`, `inactive`).
  * `page` (integer, optional): Page number, starting at 1.
  * `limit` (integer, optional): Page size, max 50.

### `get_client`

Retrieve a client's complete profile.

* **Type:** Read-only
* **Important Input Fields:**
  * `clientId` (string, required): Unique client identifier.

### `create_client` **`Write`**

Create a new client profile or link an existing account by email to the company.

* **Type:** Write
* **Important Input Fields:**
  * `firstName` (string, required): Client first name. Min 2 chars.
  * `email` (string, required): Client email.
  * `lastName` (string, optional): Client last name.
  * `inviteByEmail` (boolean, optional): Whether to send invite email.

### `inspect_client_data_access`

Inspect the data access grants and connection status for a client.

* **Type:** Read-only
* **Important Input Fields:**
  * `clientId` (string, required): Unique client identifier.

***

## Natural Language Examples

* *"Find client Jane Doe in the database."*
* *"Create a new client named Tom Hardy with email [tom.hardy@example.com](mailto:tom.hardy@example.com)."*
* *"Check whether client 64b64c0f2f5f4c0012345678 granted nutrition history access."*

***

## JSON-RPC Call Example (`search_clients`)

```json theme={null}
{
  "jsonrpc": "2.0",
  "id": "clients-1",
  "method": "tools/call",
  "params": {
    "name": "search_clients",
    "arguments": {
      "query": "Hardy",
      "relationshipStatus": "active"
    }
  }
}
```
