🎩 You're Invited:Meet the Socket team at Black Hat in Las Vegas, August 3-6.RSVP
Sign In

@safenest/cli

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@safenest/cli

SafeNest CLI - AI-powered child safety analysis from your terminal

latest
Source
npmnpm
Version
1.1.0
Version published
Weekly downloads
9
80%
Maintainers
1
Weekly downloads
 
Created
Source

SafeNest CLI

AI-powered child safety analysis from your terminal. Detect bullying, grooming, and unsafe content.

Installation

Homebrew (macOS/Linux)

brew install safenest/tap/safenest

npm

npm install -g @safenest/cli

Quick Start

# Login with your API key
safenest login <your-api-key>

# Analyze text for safety
safenest analyze "Some text to check"

# Detect bullying
safenest detect-bullying "You're so stupid"

# Detect unsafe content
safenest detect-unsafe "I want to hurt myself"

Commands

Authentication

safenest login <api-key>   # Save your API key
safenest logout            # Remove saved API key
safenest whoami            # Show login status

Safety Detection

# Quick analysis (bullying + unsafe)
safenest analyze "Text to analyze"

# Detect bullying/harassment
safenest detect-bullying "Text to check"
safenest bullying "Text to check"  # alias

# Detect unsafe content (self-harm, violence, etc.)
safenest detect-unsafe "Text to check"
safenest unsafe "Text to check"  # alias

# Detect grooming patterns in conversation
safenest detect-grooming -m '[{"role":"adult","content":"..."},{"role":"child","content":"..."}]'
safenest grooming -m '...' --age 12  # with child age

Analysis & Guidance

# Analyze emotions
safenest emotions "I'm feeling really sad today"

# Get action plan for a situation
safenest action-plan "Child is being bullied at school"
safenest plan "..." --age 12 --audience parent --severity high

Examples

Check a message for bullying

$ safenest bullying "You're worthless and nobody likes you"

⚠ BULLYING DETECTED

Severity:    HIGH
Confidence:  92%
Risk Score:  85%
Types:       verbal, exclusion

Rationale:
The message contains degrading language and exclusionary statements...

Action: flag_for_moderator

Analyze emotional content

$ safenest emotions "I don't want to go to school anymore, everyone hates me"

Emotion Analysis

Dominant:  sadness, anxiety, isolation
Trend:     📉 worsening

Summary:
The text indicates feelings of social rejection and school avoidance...

Recommended Follow-up:
Consider having a supportive conversation about their school experience...

Get an API Key

Sign up at safenest.dev to get your API key.

Best Practices

Message Batching

The bullying and unsafe commands analyze a single text input per request. If you're analyzing a conversation, concatenate a sliding window of recent messages into one string rather than piping each message individually. Single words or short fragments lack context for accurate detection and can be exploited to bypass safety filters.

# Bad — each line analyzed in isolation
cat messages.txt | while read line; do safenest bullying "$line"; done

# Good — analyze the full conversation
safenest bullying "$(cat messages.txt)"

The grooming command already accepts multiple messages and analyzes the full conversation in context.

PII Redaction

Enable PII_REDACTION_ENABLED=true on your SafeNest API to automatically strip emails, phone numbers, URLs, social handles, IPs, and other PII from detection summaries and webhook payloads. The original text is still analyzed in full — only stored outputs are scrubbed.

License

MIT

Keywords

safenest

FAQs

Package last updated on 12 Feb 2026

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts