数组重复校验


表示判断以Jsonpath、Spel语法获取数组中某一个参数的值中是否有重复的VALUE值,默认true判断含有重复的值,false为不包含重复的值。

如响应体:

BODY
"{...}":
{
    "city": "杭州",
    "level": "二级(良)",
    "update": "2019-11-23 13:00:00",
    "aqi": "66",
    "pm25": "47",
    "co": null,
    "data": [{
        "position_name": "滨江",
        "aqi": 62,
        "level": "良",
        "pm25": "43",
    }, 
    {
        "position_name": "西溪",
        "aqi": 68,
        "level": "优",
        "pm25": "44",
    },
    {
        "position_name": "千岛湖",
        "aqi": 78,
        "level": "优",
        "pm25": "44",
    },
    ....
  ]
}

如判断data数组中position_name值无重复的,则在参数列中输入$.data[*].position_name(获取值:["滨江","西溪","千岛湖"]),值列中输入false。

Copyright © GoApi 2018 all right reserved,powered by Gitbook该文件修订时间: 2023-08-24 14:35:00

results matching ""

    No results matching ""