正确 json 路径

Correct json Path

请帮我改正 json 路径。我正在尝试从 "value" 中提取“500”。

Json(部分)看起来像这样:

Vehicle {
"code": "BCA",
"name": "COLL",
"description": "Collision",
"limitTerms": [],
"deductibleTerms": [
{
"code": "qsw",
"name": "",
"value": "500",
"valueCode": "",
"valueDescription": "",
}
],
"otherTerms": [],
},

我想使用名称或描述,而不是达到 deductibleTerms 并从中提取价值。

我试过写 json 那样的路径(这肯定是错误的)

"$.vehicle[description='Collision' and .deductibleTerms[*].value]"

.deductibleTerms[*].value 不应在表达式的过滤器 [] 部分内,因为您没有对其进行过滤。

$.vehicle[description='Collision'].deductibleTerms[*].value