bhcli

A TUI for chatting on LE PHP Chats
git clone https://git.dasho.dev/bhcli.git
Log | Files | Refs | README

bhcli.1 (8552B)


      1 .TH BHCLI 1 "January 2026" "BHCLI 1.0" "User Commands"
      2 .SH NAME
      3 bhcli \- terminal client for le-chat-php chat systems
      4 .SH SYNOPSIS
      5 .B bhcli
      6 [\fIOPTIONS\fR]
      7 .SH DESCRIPTION
      8 .B bhcli
      9 is a sophisticated terminal-based client for anonymous communication over Tor. It connects to any le-chat-php chat server with full feature parity plus advanced capabilities like AI integration, bot automation, and developer tools.
     10 .PP
     11 Built for the darknet, optimized for Tor, works everywhere.
     12 .SH OPTIONS
     13 .SS "Authentication"
     14 .TP
     15 .BR \-u ", " \-\-username " \fIUSERNAME\fR"
     16 Set username (env: BHC_USERNAME)
     17 .TP
     18 .BR \-p ", " \-\-password " \fIPASSWORD\fR"
     19 Set password (env: BHC_PASSWORD)
     20 .TP
     21 .BR \-c ", " \-\-profile " \fIPROFILE\fR"
     22 Select configuration profile (default: "default")
     23 .TP
     24 .BR \-\-session " \fISESSION\fR"
     25 Use existing session ID to skip login
     26 .SS "Connection"
     27 .TP
     28 .BR \-\-url " \fIURL\fR"
     29 Override chat server URL
     30 .TP
     31 .BR \-\-page\-php " \fIPAGE\fR"
     32 Override chat page filename (default: chat.php)
     33 .TP
     34 .BR \-s ", " \-\-socks\-proxy\-url " \fIURL\fR"
     35 SOCKS proxy URL (default: socks5h://127.0.0.1:9050, env: BHC_PROXY_URL)
     36 .TP
     37 .BR \-\-no\-proxy
     38 Disable proxy usage
     39 .TP
     40 .BR \-r ", " \-\-refresh\-rate " \fISECONDS\fR"
     41 Message refresh rate (default: 5, env: BHC_REFRESH_RATE)
     42 .SS "Bot System"
     43 .TP
     44 .BR \-\-bot " \fINAME\fR"
     45 Enable background bot with specified name
     46 .TP
     47 .BR \-\-bot\-admins " \fIUSERS\fR"
     48 Comma-separated list of bot administrators
     49 .TP
     50 .BR \-\-bot\-data\-dir " \fIPATH\fR"
     51 Custom directory for bot data storage
     52 .SS "Display"
     53 .TP
     54 .BR \-g ", " \-\-guest\-color " \fICOLOR\fR"
     55 Set guest color theme
     56 .TP
     57 .BR \-m ", " \-\-manual\-captcha
     58 Enable manual captcha solving (env: BHC_MANUAL_CAPTCHA)
     59 .TP
     60 .BR \-\-sxiv
     61 Enable sxiv image viewer integration
     62 .SS "Integrations"
     63 .TP
     64 .BR \-\-dkf\-api\-key " \fIKEY\fR"
     65 DKF API key for notifications (env: DKF_API_KEY)
     66 .TP
     67 .BR \-\-dnmx\-username " \fIUSERNAME\fR"
     68 DNMX email username (env: DNMX_USERNAME)
     69 .TP
     70 .BR \-\-dnmx\-password " \fIPASSWORD\fR"
     71 DNMX email password (env: DNMX_PASSWORD)
     72 .SH KEYBOARD SHORTCUTS
     73 .SS "Navigation"
     74 .TP
     75 .BR j ", " "down arrow"
     76 Move down one message
     77 .TP
     78 .BR k ", " "up arrow"
     79 Move up one message
     80 .TP
     81 .BR J
     82 Jump down 5 messages
     83 .TP
     84 .BR K
     85 Jump up 5 messages
     86 .TP
     87 .BR gg
     88 Jump to top message
     89 .TP
     90 .BR "ctrl+d"
     91 Page down
     92 .TP
     93 .BR "ctrl+u"
     94 Page up
     95 .SS "Quick Actions"
     96 .TP
     97 .BR t
     98 Tag author of selected message
     99 .TP
    100 .BR p
    101 Start PM to author
    102 .TP
    103 .BR y ", " "ctrl+c"
    104 Copy selected message
    105 .TP
    106 .BR "shift+Y"
    107 Copy first link in message
    108 .TP
    109 .BR d
    110 Download embedded file
    111 .TP
    112 .BR D
    113 Download and open file
    114 .SS "View Toggles"
    115 .TP
    116 .BR m
    117 Toggle sound notifications
    118 .TP
    119 .BR "shift+G"
    120 Toggle guest view
    121 .TP
    122 .BR "shift+M"
    123 Toggle members view
    124 .TP
    125 .BR "ctrl+h"
    126 Toggle hidden messages
    127 .TP
    128 .BR backspace
    129 Hide selected message
    130 .SS "Input Editing"
    131 .TP
    132 .BR "ctrl+a"
    133 Move to start of line
    134 .TP
    135 .BR "ctrl+e"
    136 Move to end of line
    137 .TP
    138 .BR "ctrl+f"
    139 Move forward one word
    140 .TP
    141 .BR "ctrl+b"
    142 Move backward one word
    143 .TP
    144 .BR "ctrl+l"
    145 Toggle multiline mode
    146 .TP
    147 .BR "ctrl+." ", " "ctrl+x" ", " "ctrl+o"
    148 Open external editor
    149 .TP
    150 .BR "tab"
    151 Autocomplete username
    152 .SS "Moderation (Members+)"
    153 .TP
    154 .BR "ctrl+k"
    155 Prefill kick command
    156 .TP
    157 .BR "ctrl+b"
    158 Prefill ban command
    159 .TP
    160 .BR "ctrl+a"
    161 Prefill members message
    162 .TP
    163 .BR "ctrl+w"
    164 Send warning message
    165 .SH CHAT COMMANDS
    166 .SS "Basic"
    167 .TP
    168 .BR "/pm \fIUSER\fR \fIMESSAGE\fR"
    169 Send private message
    170 .TP
    171 .BR "/ignore \fIUSER\fR"
    172 Ignore user's messages
    173 .TP
    174 .BR "/unignore \fIUSER\fR"
    175 Unignore user
    176 .TP
    177 .BR "/f \fITERMS\fR"
    178 Filter messages by content
    179 .TP
    180 .BR "/u \fIPATH\fR [@\fIUSER\fR] [\fIMESSAGE\fR]"
    181 Upload file
    182 .SS "Moderation (Members+)"
    183 .TP
    184 .BR "/kick \fIUSER\fR [\fIREASON\fR]"
    185 Kick user from chat
    186 .TP
    187 .BR "/ban \fIUSER\fR"
    188 Ban user (fuzzy match)
    189 .TP
    190 .BR "/ban \(dq\fIUSER\fR\(dq"
    191 Ban exact username
    192 .TP
    193 .BR "/filter \fITEXT\fR"
    194 Add message filter
    195 .TP
    196 .BR "/unban \fIUSER\fR"
    197 Remove ban
    198 .TP
    199 .BR "/unfilter \fITEXT\fR"
    200 Remove filter
    201 .TP
    202 .BR "/banlist"
    203 Show banned users
    204 .TP
    205 .BR "/filterlist"
    206 Show filtered terms
    207 .TP
    208 .BR "/dl[\fIN\fR]"
    209 Delete last N messages (default: 1)
    210 .TP
    211 .BR "/dall"
    212 Delete all your messages
    213 .SS "ChatOps (30+ commands)"
    214 .TP
    215 .BR "/help [\fICOMMAND\fR]"
    216 List commands or get detailed help
    217 .TP
    218 .BR "/man \fICOMMAND\fR"
    219 System manual pages
    220 .TP
    221 .BR "/doc \fILANG\fR \fITERM\fR"
    222 Language documentation
    223 .TP
    224 .BR "/hash \fIALGO\fR \fITEXT\fR"
    225 Generate hash (md5/sha1/sha256/sha512)
    226 .TP
    227 .BR "/uuid"
    228 Generate UUID
    229 .TP
    230 .BR "/base64 \fIencode|decode\fR \fITEXT\fR"
    231 Base64 encoding/decoding
    232 .TP
    233 .BR "/regex \fIPATTERN\fR \fITEXT\fR"
    234 Test regex pattern
    235 .TP
    236 .BR "/github \fIUSER/REPO\fR"
    237 Repository information
    238 .TP
    239 .BR "/crates \fINAME\fR"
    240 Rust crate info
    241 .TP
    242 .BR "/npm \fINAME\fR"
    243 NPM package info
    244 .TP
    245 .BR "/pip \fINAME\fR"
    246 Python package info
    247 .TP
    248 .BR "/ping \fIHOST\fR"
    249 Test connectivity
    250 .TP
    251 .BR "/dig \fIDOMAIN\fR"
    252 DNS lookup
    253 .TP
    254 .BR "/whois \fIDOMAIN\fR"
    255 Domain registration info
    256 .SS "AI Features (requires OPENAI_API_KEY)"
    257 .TP
    258 .BR "/ai \fIoff|mod|reply\fR"
    259 Control AI mode
    260 .TP
    261 .BR "/ai \fIstrict|balanced|lenient\fR"
    262 Set moderation strictness
    263 .TP
    264 .BR "/translate \fILANG\fR \fITEXT\fR"
    265 Translate text
    266 .TP
    267 .BR "/detect \fITEXT\fR"
    268 Detect language
    269 .TP
    270 .BR "/sentiment \fITEXT\fR"
    271 Analyze sentiment
    272 .TP
    273 .BR "/summarize \fITEXT\fR"
    274 Summarize text
    275 .TP
    276 .BR "/fix \fICODE\fR"
    277 Get code fix suggestions
    278 .TP
    279 .BR "/review \fICODE\fR"
    280 Code quality review
    281 .SH BOT COMMANDS
    282 .PP
    283 Interact with bots by mentioning them in chat. Admin-only unless noted.
    284 .TP
    285 .BR "@\fIBOT\fR help"
    286 List bot commands (anyone)
    287 .TP
    288 .BR "@\fIBOT\fR stats \fIUSER\fR"
    289 View user statistics
    290 .TP
    291 .BR "@\fIBOT\fR recall \fITIME\fR"
    292 Find messages from specific time
    293 .TP
    294 .BR "@\fIBOT\fR search \fIQUERY\fR"
    295 Search message history
    296 .TP
    297 .BR "@\fIBOT\fR export \fIUSER\fR \fIDAYS\fR"
    298 Export user messages
    299 .TP
    300 .BR "@\fIBOT\fR restore \fIMSG_ID\fR"
    301 Restore deleted message
    302 .TP
    303 .BR "@\fIBOT\fR summary \fIHOURS\fR"
    304 Chat activity summary
    305 .TP
    306 .BR "@\fIBOT\fR users"
    307 List online users
    308 .SH CONFIGURATION
    309 .PP
    310 Configuration file: \fB~/.config/bhcli/bhcli.toml\fR
    311 .PP
    312 Example profile configuration:
    313 .PP
    314 .nf
    315 .RS
    316 [profiles]
    317 
    318 [profiles.default]
    319 username = "yourusername"
    320 password = "yourpassword"
    321 
    322 [commands]
    323 hello = "hey everyone!"
    324 afk = "away for a bit"
    325 .RE
    326 .fi
    327 .SH CUSTOM COMMANDS
    328 .PP
    329 Create shortcuts in config file under [commands] section. Use them with ! prefix:
    330 .PP
    331 .nf
    332 .RS
    333 !hello
    334 !afk
    335 !rules
    336 .RE
    337 .fi
    338 .SH ENVIRONMENT VARIABLES
    339 .TP
    340 .BR BHC_USERNAME
    341 Default username
    342 .TP
    343 .BR BHC_PASSWORD
    344 Default password
    345 .TP
    346 .BR BHC_PROXY_URL
    347 SOCKS proxy URL
    348 .TP
    349 .BR BHC_REFRESH_RATE
    350 Message refresh rate in seconds
    351 .TP
    352 .BR BHC_MANUAL_CAPTCHA
    353 Enable manual captcha mode
    354 .TP
    355 .BR OPENAI_API_KEY
    356 OpenAI API key for AI features
    357 .TP
    358 .BR DKF_API_KEY
    359 DKF API key for notifications
    360 .TP
    361 .BR DNMX_USERNAME
    362 DNMX email username
    363 .TP
    364 .BR DNMX_PASSWORD
    365 DNMX email password
    366 .SH FILES
    367 .TP
    368 .BR ~/.config/bhcli/bhcli.toml
    369 Main configuration file
    370 .TP
    371 .BR ./bhcli.log
    372 Log file (created in current directory)
    373 .TP
    374 .BR ./bot_data/
    375 Bot data storage directory
    376 .SH EXAMPLES
    377 .PP
    378 Basic usage with credentials:
    379 .PP
    380 .RS
    381 .nf
    382 bhcli -u myusername -p mypassword
    383 .fi
    384 .RE
    385 .PP
    386 Use specific profile:
    387 .PP
    388 .RS
    389 .nf
    390 bhcli -c myprofile
    391 .fi
    392 .RE
    393 .PP
    394 Connect through custom Tor port:
    395 .PP
    396 .RS
    397 .nf
    398 bhcli -s socks5h://127.0.0.1:9150
    399 .fi
    400 .RE
    401 .PP
    402 Direct connection (not recommended for darknet):
    403 .PP
    404 .RS
    405 .nf
    406 bhcli --no-proxy
    407 .fi
    408 .RE
    409 .PP
    410 Run with bot and admins:
    411 .PP
    412 .RS
    413 .nf
    414 bhcli --bot Assistant --bot-admins alice,bob
    415 .fi
    416 .RE
    417 .PP
    418 Using environment variables:
    419 .PP
    420 .RS
    421 .nf
    422 export BHC_USERNAME="myuser"
    423 export BHC_PASSWORD="mypass"
    424 export OPENAI_API_KEY="sk-..."
    425 bhcli
    426 .fi
    427 .RE
    428 .SH SECURITY
    429 .PP
    430 BHCLI is designed for anonymous communication:
    431 .IP \[bu] 2
    432 Always use Tor for darknet chats
    433 .IP \[bu]
    434 Never use --no-proxy with .onion addresses
    435 .IP \[bu]
    436 No telemetry or phone-home
    437 .IP \[bu]
    438 Local storage only
    439 .IP \[bu]
    440 Optional features minimize attack surface
    441 .PP
    442 For maximum security, route through Tor and use unique credentials per chat.
    443 .SH BUILDING
    444 .PP
    445 Build from source:
    446 .PP
    447 .RS
    448 .nf
    449 cargo build --release
    450 make release
    451 .fi
    452 .RE
    453 .PP
    454 Build without audio for headless servers:
    455 .PP
    456 .RS
    457 .nf
    458 cargo build --release --no-default-features
    459 make build-no-audio
    460 .fi
    461 .RE
    462 .PP
    463 Cross-platform builds:
    464 .PP
    465 .RS
    466 .nf
    467 make build-linux-musl
    468 make build-macos
    469 make build-windows
    470 make build-all
    471 .fi
    472 .RE
    473 .SH SEE ALSO
    474 .PP
    475 Full documentation: \fBMANUAL.md\fR
    476 .PP
    477 Optimization report: \fBOPTIMIZATION_REPORT.md\fR
    478 .PP
    479 Official repo: https://github.com/d-a-s-h-o/bhcli
    480 .SH BUGS
    481 .PP
    482 Report bugs at official mirror or GitHub issues.
    483 .SH AUTHOR
    484 .PP
    485 Built with ❤️ by Dasho.
    486 .SH COPYRIGHT
    487 .PP
    488 MIT License. See LICENSE file for details.