我尝试使用python-cloudflare:https://github.com/cloudflare/python-cloudflare。
规则:曾经重定向到https。
params = {
"target": "url",
"constraint": {
"operator": "matches",
"value": "http://*{0}*".format(domain)
},
"actions":
{
"id":"https",
"value":"on",
"priority":1,
"status":"active"
}
}
r = cf.zones.firewall.waf.packages.rules.post(zone_id, package_id=None,
params=params)
错误:
504服务器错误:网址的网关超时