Compare commits
	
		
			No commits in common. "a10f7e608005d5a1fcf5315ff505af25d2d101e7" and "6add3c6b70ee3a1b80e8bc3429458f7ac5f4b880" have entirely different histories.
		
	
	
		
			a10f7e6080
			...
			6add3c6b70
		
	
		
							
								
								
									
										1
									
								
								.gitignore
									
									
									
									
										vendored
									
									
								
							
							
						
						
									
										1
									
								
								.gitignore
									
									
									
									
										vendored
									
									
								
							@ -1 +0,0 @@
 | 
				
			|||||||
scripts/
 | 
					 | 
				
			||||||
@ -1,6 +0,0 @@
 | 
				
			|||||||
## [1.0.0] - 2025-09-01
 | 
					 | 
				
			||||||
### Added
 | 
					 | 
				
			||||||
- Initial version with control channel.
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
### Fixed
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
@ -1,8 +1,3 @@
 | 
				
			|||||||
# simplex-customerservicebot
 | 
					# simplex-customerservicebot
 | 
				
			||||||
 | 
					
 | 
				
			||||||
A bot to handle customer service using SimpleX chat.
 | 
					A bot to handle customer service using SimpleX chat
 | 
				
			||||||
The bot will join a group specified in the environment variable SXC_CONTROL_GROUP and announce newly created chats.
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
Members of the control group can then be invited into the customer chat group by typing 'join <customergroup>'
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
This requires a working simplex-chat in the background and joining the operator users as well as the bot into the control group.
 | 
					 | 
				
			||||||
@ -1,11 +0,0 @@
 | 
				
			|||||||
[Unit]
 | 
					 | 
				
			||||||
Description=Simplex Inviter bot
 | 
					 | 
				
			||||||
After=network.target
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
[Service]
 | 
					 | 
				
			||||||
User=simplex
 | 
					 | 
				
			||||||
ExecStart=/usr/local/bin/simplex-chat -p 5225
 | 
					 | 
				
			||||||
Restart=always
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
[Install]
 | 
					 | 
				
			||||||
WantedBy=multi-user.target
 | 
					 | 
				
			||||||
@ -1,13 +0,0 @@
 | 
				
			|||||||
[Unit]
 | 
					 | 
				
			||||||
Description=Taurix Simplex Customer Service inviter
 | 
					 | 
				
			||||||
After=network.target
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
[Service]
 | 
					 | 
				
			||||||
User=simplex
 | 
					 | 
				
			||||||
Environment="SXC_CONTROL_GROUP=TrxCustomerSupport"
 | 
					 | 
				
			||||||
WorkingDirectory=/home/simplex
 | 
					 | 
				
			||||||
ExecStart=/usr/local/bin/simplex_customerservicebot.py
 | 
					 | 
				
			||||||
Restart=always
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
[Install]
 | 
					 | 
				
			||||||
WantedBy=multi-user.target
 | 
					 | 
				
			||||||
@ -8,13 +8,13 @@ import websockets
 | 
				
			|||||||
from collections import defaultdict
 | 
					from collections import defaultdict
 | 
				
			||||||
from typing import Any, Dict, Iterable, Tuple
 | 
					from typing import Any, Dict, Iterable, Tuple
 | 
				
			||||||
 | 
					
 | 
				
			||||||
__version__ = "1.0.0" 
 | 
					__version__ = "0.5.6"  # exact/recency name resolver + robust sender + case-insensitive join + announce fix
 | 
				
			||||||
 | 
					
 | 
				
			||||||
# Defaults
 | 
					# Defaults
 | 
				
			||||||
WS_URL        = os.environ.get("SXC_WS", "ws://127.0.0.1:5225")
 | 
					WS_URL        = os.environ.get("SXC_WS", "ws://127.0.0.1:5225")
 | 
				
			||||||
CONTROL_GROUP = (os.environ.get("SXC_CONTROL_GROUP") or "BotTest").strip()
 | 
					CONTROL_GROUP = (os.environ.get("SXC_CONTROL_GROUP") or "BotTest").strip()
 | 
				
			||||||
ANNOUNCE_NEW  = os.environ.get("SXC_ANNOUNCE", "1").strip() != "0"
 | 
					ANNOUNCE_NEW  = os.environ.get("SXC_ANNOUNCE", "1").strip() != "0"
 | 
				
			||||||
DEBUG         = os.environ.get("SXC_DEBUG", "0").strip() == "1"
 | 
					DEBUG         = os.environ.get("SXC_DEBUG", "1").strip() == "1"
 | 
				
			||||||
LOG_RAW       = os.environ.get("SXC_LOG_RAW", "0").strip() == "1"
 | 
					LOG_RAW       = os.environ.get("SXC_LOG_RAW", "0").strip() == "1"
 | 
				
			||||||
 | 
					
 | 
				
			||||||
INVITE_CMDS   = ["/a", "a"]   # try WS-style first, then CLI-style
 | 
					INVITE_CMDS   = ["/a", "a"]   # try WS-style first, then CLI-style
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user