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

# CLI

> Install and use the Tuteliq command-line interface

The Tuteliq CLI lets you test safety endpoints, analyze files, and manage API keys directly from the terminal. It's built for developers who want to prototype and debug without writing code.

## Installation

```bash theme={"dark"}
npm install -g @tuteliq/cli
```

Or with Homebrew:

```bash theme={"dark"}
brew install tuteliq/tap/tuteliq
```

## Authentication

Set your API key:

```bash theme={"dark"}
tuteliq auth login
```

Or pass it as an environment variable:

```bash theme={"dark"}
export TUTELIQ_API_KEY=your_api_key
```

## Detect unsafe content

Analyze a text string:

```bash theme={"dark"}
tuteliq detect unsafe "Let's meet at the park after school, don't tell your parents" --age-group 10-12
```

Output:

```json theme={"dark"}
{
  "safe": false,
  "severity": "high",
  "categories": ["grooming", "secrecy"],
  "risk_score": 87,
  "rationale": "Message contains secrecy request and meeting solicitation..."
}
```

## Detect grooming patterns

Analyze a conversation from a JSON file:

```bash theme={"dark"}
tuteliq detect grooming --file conversation.json --age-group 10-12
```

Where `conversation.json` contains:

```json theme={"dark"}
{
  "messages": [
    { "role": "stranger", "text": "Hey, how old are you?" },
    { "role": "child", "text": "I'm 11" },
    { "role": "stranger", "text": "Cool. Do you have your own phone?" },
    { "role": "stranger", "text": "Let's talk on a different app, just us" }
  ]
}
```

## Analyze emotions

```bash theme={"dark"}
tuteliq analyze emotions "Nobody at school talks to me anymore. I just sit alone every day." --age-group 13-15
```

## Analyze voice

Analyze an audio file:

```bash theme={"dark"}
tuteliq analyze voice recording.wav --age-group 13-15
```

## Analyze image

Analyze an image file:

```bash theme={"dark"}
tuteliq analyze image screenshot.png --age-group 10-12
```

## Fraud detection

Detect social engineering, app fraud, romance scams, and mule recruitment.

```bash theme={"dark"}
# Detect social engineering
tuteliq detect social-engineering "If you really trusted me you'd send your address" --age-group 10-12

# Detect romance scam
tuteliq detect romance-scam "You're so mature for your age. Keep us a secret." --age-group 13-15

# Detect app fraud
tuteliq detect app-fraud "Download this app and enter your parent's card details" --age-group 10-12

# Detect mule recruitment
tuteliq detect mule-recruitment "I just need you to receive some money in your account" --age-group 13-15
```

## Safety extended

Detect gambling harm, coercive control, vulnerability exploitation, and radicalisation.

```bash theme={"dark"}
# Detect gambling harm
tuteliq detect gambling-harm "I know a way to get free V-Bucks, just put in your card" --age-group 10-12

# Detect coercive control
tuteliq detect coercive-control "You're not allowed to talk to anyone else. Only me." --age-group 13-15

# Detect vulnerability exploitation
tuteliq detect vulnerability-exploitation "I know your parents don't listen. I actually care about you." --age-group 13-15

# Detect radicalisation
tuteliq detect radicalisation "They're all against us. Only our group understands the truth." --age-group 13-15
```

## Multi-endpoint analysis

Run multiple detections on a single text in one command.

```bash theme={"dark"}
tuteliq detect multi "You're so special. Send me a photo." \
  --endpoints social-engineering,grooming,romance-scam \
  --age-group 13-15
```

Output:

```json theme={"dark"}
{
  "summary": {
    "overall_risk_level": "high",
    "detected_count": 2,
    "total_endpoints": 3
  },
  "results": [
    { "endpoint": "social-engineering", "detected": false, "risk_score": 0.2 },
    { "endpoint": "grooming", "detected": true, "risk_score": 0.87 },
    { "endpoint": "romance-scam", "detected": true, "risk_score": 0.91 }
  ]
}
```

## Analyze video

Analyze a video file for safety concerns.

```bash theme={"dark"}
tuteliq analyze video clip.mp4 --age-group 13-15
```

Output:

```json theme={"dark"}
{
  "frames_analyzed": 24,
  "overall_risk_score": 0.65,
  "overall_severity": "medium",
  "safety_findings": [
    { "frame_index": 12, "timestamp": 4.5, "description": "...", "severity": 0.7 }
  ]
}
```

## Batch processing

Analyze multiple inputs from a file:

```bash theme={"dark"}
tuteliq batch detect unsafe --file messages.jsonl --age-group 13-15 --output results.jsonl
```

<Info>
  Batch mode processes inputs in parallel and writes results as newline-delimited JSON (JSONL).
</Info>

## Output formats

Control output format with `--format`:

```bash theme={"dark"}
# JSON (default)
tuteliq detect unsafe "text" --format json

# Table view
tuteliq detect unsafe "text" --format table

# Minimal (just severity)
tuteliq detect unsafe "text" --format minimal
```

## API key management

```bash theme={"dark"}
# View current key info
tuteliq auth status

# Check credit balance
tuteliq usage

# Rotate key
tuteliq auth rotate
```

## Configuration

View and set defaults:

```bash theme={"dark"}
# Set default age group
tuteliq config set age-group 13-15

# Set default output format
tuteliq config set format table

# View all settings
tuteliq config list
```

## All commands

| Command                                     | Description                         |
| ------------------------------------------- | ----------------------------------- |
| `tuteliq detect unsafe`                     | Detect unsafe content in text       |
| `tuteliq detect bullying`                   | Detect bullying in text             |
| `tuteliq detect grooming`                   | Detect grooming in conversations    |
| `tuteliq detect social-engineering`         | Detect social engineering tactics   |
| `tuteliq detect app-fraud`                  | Detect app-based fraud patterns     |
| `tuteliq detect romance-scam`               | Detect romance scam patterns        |
| `tuteliq detect mule-recruitment`           | Detect money mule recruitment       |
| `tuteliq detect gambling-harm`              | Detect gambling harm indicators     |
| `tuteliq detect coercive-control`           | Detect coercive control patterns    |
| `tuteliq detect vulnerability-exploitation` | Detect vulnerability exploitation   |
| `tuteliq detect radicalisation`             | Detect radicalisation indicators    |
| `tuteliq detect multi`                      | Run multiple detections on one text |
| `tuteliq analyze emotions`                  | Analyze emotional well-being        |
| `tuteliq analyze voice`                     | Analyze audio files                 |
| `tuteliq analyze image`                     | Analyze image files                 |
| `tuteliq analyze video`                     | Analyze video files                 |
| `tuteliq batch`                             | Batch-process multiple inputs       |
| `tuteliq auth`                              | Manage API key authentication       |
| `tuteliq usage`                             | View credit balance and usage       |
| `tuteliq config`                            | View and set CLI configuration      |

## Next steps

<CardGroup cols={2}>
  <Card title="API Reference" icon="code" href="/api-reference/introduction">
    Explore the full API specification.
  </Card>

  <Card title="Node.js SDK" icon="node-js" href="/sdks/node">
    See the Node.js SDK guide.
  </Card>
</CardGroup>
