update api/dingding.py.

master
newrain001 2 years ago committed by Gitee
parent b2e53a55b4
commit c4c4465d18
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
  1. 4
      api/dingding.py

@ -11,7 +11,7 @@ import sys
import os
import datetime
import sys
headers = {'Content-Type': 'application/json;charset=utf-8'}4
headers = {'Content-Type': 'application/json;charset=utf-8'}
# 需要修改,钉钉群助手中获取
api_url = ""
def msg(text):
@ -29,4 +29,4 @@ def msg(text):
}
print(requests.post(api_url,json.dumps(json_text),headers=headers).content)
msg("报警"+'\n'+sys.argv[1])
msg(sys.argv[1]+'\n'+sys.argv[2]+'\n'+sys.argv[3])

Loading…
Cancel
Save