GO/README.md
2023-04-04 16:53:26 +08:00

50 lines
1.3 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

# 丝芙兰短信自动化
## 版本历史
- **V1.0**Go编写定时获取sftp文件并解析文件入库完成后发送邮件提醒。
- **V1.1**:增加推送至发送平台功能。
- **V1.2**增加lastCall业务逻辑通过WebSocket通信。
- **V1.3**修改数据从SqlServer 为MySQL。
- **V1.4**:增加历史数据清除功能。
## 测试环境启动
./iniDataForMacOs -env dev
## 正式环境启动
./iniDataForMacOs -env prod
## PHP WebSocket 指令与签名demosign_message.php
## MacOS 终端调试WebSocket方法
安装nodebrew install node
安装wscatnpm install -g wscat
使用wscat链接WebSocketwscat -c ws://localhost:8080/ws
## 发送消息给服务器(不要换行,一行输入):
```json
{
"TaskData":{
"command":"lastCall",
"excluded_filename":"lastCall.txt",
"batch_filename":"Communication_definition_SMS_1_wemedia_20230303185518.txt",
"data_filename":"Communication_targets_SMS_1_wemedia_20230303185518.txt"
},
"signature":{
"signature":"7fb34f2cb94c1ee5d969a1ee974c93aff0e2b1f31f3a54b350202672b041ff6c",
"timestamp":1678183659,
"nonce":"dd29nwj4D9rosZ=p-UL15ubUSpc0)AIu))@Q-Taln(ByynnQlkBVwnRXkJfXeUB7"
}
}
```