Skip to content

method

修改请求方法。

规则语法

txt
pattern method://value [filters...]
参数描述详细文档
pattern匹配请求 URL 的表达式匹配模式文档
valueget/post/head 等请求方法名称(不区分大小写)
filters可选过滤器,支持匹配:
• 请求URL/方法/头部/内容
• 响应状态码/头部
过滤器文档

配置示例

txt
# 访问 `https://www.example.com/path/to` 在 Whistle 抓包界面上可以看到请求方法为 `POST`
www.example.com/path method://post

# 带过滤条件的方法修改
www.example.com/path2 method://patch includeFilter://reqH.content-type=multipart/form-data