mirror of
https://github.com/zhayujie/bot-on-anything.git
synced 2026-01-19 01:21:06 +08:00
fix: wechat mp channel listen host change #14
This commit is contained in:
@@ -220,8 +220,12 @@ Hit Ctrl-C to quit.
|
||||
```
|
||||
|
||||
### 5. Gmail
|
||||
|
||||
**需要:** 一个服务器、一个Gmail account
|
||||
Follow [官方文档](https://support.google.com/mail/answer/185833?hl=en) to create APP password for google account, config as below, then cheers!!!
|
||||
|
||||
Follow [官方文档](https://support.google.com/mail/answer/185833?hl=en) to create APP password for google account, config as below, then cheers!!! (contributed by [Simon](https://github.com/413675377)
|
||||
)
|
||||
|
||||
```json
|
||||
"channel": {
|
||||
"type": "gmail",
|
||||
|
||||
@@ -8,7 +8,7 @@ class TerminalChannel(Channel):
|
||||
# close log
|
||||
log.close_log()
|
||||
context = {"from_user_id": "User", "stream": True}
|
||||
print("Please input your question\n")
|
||||
print("\nPlease input your question")
|
||||
while True:
|
||||
try:
|
||||
prompt = self.get_input("User:\n")
|
||||
|
||||
@@ -24,6 +24,7 @@ class WechatSubsribeAccount(Channel):
|
||||
def startup(self):
|
||||
logger.info('[WX_Public] Wechat Public account service start!')
|
||||
robot.config['PORT'] = channel_conf(const.WECHAT_MP).get('port')
|
||||
robot.config['HOST'] = '0.0.0.0'
|
||||
robot.run()
|
||||
|
||||
def handle(self, msg, count=0):
|
||||
|
||||
@@ -20,6 +20,7 @@ class WechatServiceAccount(Channel):
|
||||
robot.config['PORT'] = channel_conf(const.WECHAT_MP).get('port')
|
||||
robot.config["APP_ID"] = channel_conf(const.WECHAT_MP).get('app_id')
|
||||
robot.config["APP_SECRET"] = channel_conf(const.WECHAT_MP).get('app_secret')
|
||||
robot.config['HOST'] = '0.0.0.0'
|
||||
robot.run()
|
||||
|
||||
def handle(self, msg, count=0):
|
||||
|
||||
@@ -15,6 +15,9 @@
|
||||
"group_name_white_list": ["ChatGPT测试群"],
|
||||
"image_create_prefix": ["画", "看", "找一张"],
|
||||
|
||||
"terminal": {
|
||||
},
|
||||
|
||||
"wechat": {
|
||||
},
|
||||
|
||||
|
||||
Reference in New Issue
Block a user