add options needed for SASL
This commit is contained in:
		
							parent
							
								
									c11118667e
								
							
						
					
					
						commit
						13c4356cfc
					
				| @ -2,6 +2,10 @@ | ||||
|     "server": "irc.libera.chat", | ||||
|     "port": 6697, | ||||
|     "nick": "chatgpt", | ||||
|     "secure": false, | ||||
|     "sasl": false, | ||||
|     "username": "chatgpt", | ||||
|     "password": "", | ||||
|     "channels": ["#chatgpt"], | ||||
|     "openaiApiKey": "[redacted]", | ||||
|     "initialSystemMessage": "You are a helpful assistant.", | ||||
|  | ||||
							
								
								
									
										7
									
								
								index.js
									
									
									
									
									
								
							
							
						
						
									
										7
									
								
								index.js
									
									
									
									
									
								
							| @ -61,7 +61,14 @@ if (fs.existsSync('./messages.json')) { | ||||
| } | ||||
| 
 | ||||
| const client = new irc.Client(config.server, config.nick, { | ||||
| 	showErrors: false, | ||||
|     debug: true, | ||||
|     port: config.port, | ||||
|     secure: config.secure, | ||||
|     channels: config.channels, | ||||
|     sasl: config.sasl, | ||||
|     userName: config.userName, | ||||
|     password: config.password, | ||||
| }); | ||||
| 
 | ||||
| // listen for messages that start with !chat and call the chatgpt api with a callback that prints the response line by line
 | ||||
|  | ||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user