#!name=高德地图去广告
#!desc=需全新应用
#!category=ADBlock

# 修改自:https://raw.githubusercontent.com/ddgksf2013/Rewrite/master/AdBlock/Amap.conf

[URL Rewrite]
# 通用广告请求
^https?:\/\/m5\.amap\.com\/ws\/asa\/ads_attribution - reject

[Map Local]
# 搜索框 | 左下天气
^https?:\/\/m5\.amap\.com\/ws\/(shield\/scene\/recommend|valueadded\/weather) data="https://raw.githubusercontent.com/kokoryh/Script/master/data/blank_dict.json"
# Tip请求,如招聘代驾的广告等
^https?:\/\/m5-zb\.amap\.com\/ws\/boss\/order_web\/\w{8}_information data="https://raw.githubusercontent.com/kokoryh/Script/master/data/blank.txt"

[Script]
# 这条必须屏蔽,否则模块无效
http-response ^http:\/\/amdc\.m\.taobao\.com requires-body=0,script-path=https://raw.githubusercontent.com/kokoryh/Script/master/js/self_use.js
# 搜索框热词 | 附近页面 | 我的页面 | 首页右中
http-response ^https?:\/\/m5\.amap\.com\/ws\/shield\/(search\/(new_hotword|nearbyrec_smart)|dsp\/profile\/index\/nodefaas|frogserver\/aocs\/updatable) requires-body=1,script-path=https://raw.githubusercontent.com/kokoryh/Script/master/js/amap.js
# 开屏广告 | 首页底部 | 底栏角标
http-response ^https?:\/\/m5\.amap\.com\/ws\/(valueadded\/alimama\/splash_screen|faas\/amap-navigation\/main-page|message\/notice\/list) requires-body=1,script-path=https://raw.githubusercontent.com/kokoryh/Script/master/js/amap.js
# 打车页面
http-response ^https?:\/\/m5-zb\.amap\.com\/ws\/promotion-web\/resource requires-body=1,script-path=https://raw.githubusercontent.com/kokoryh/Script/master/js/amap.js
# 首页顶部横幅
http-response ^https?:\/\/sns\.amap\.com\/ws\/msgbox\/pull requires-body=1,script-path=https://raw.githubusercontent.com/kokoryh/Script/master/js/amap.js

[MITM]
hostname = %INSERT% m5*.amap.com, sns.amap.com