在Apiary创建API蓝图,我在我的蓝图降价中遇到错误,该错误被标记为消息的语义问题:
第21行 - 忽略其他响应标头,而是在引用的模型定义中指定此标头。
第21行是引用[Cars] []模型定义的行。我不是要指定任何标题,我对此消息试图指示我做的事情感到困惑。任何人都可以对这个问题有所了解吗?
FORMAT: 1A # Automative Industry # Group Cars ## Cars [/cars] + Model (application/json) + Body { "name": "Taurus" } ### List all cars [GET] + Response 200 (application/json) [Cars][] + Response 401 + Response 403 + Response 500 + Response 503
答案 0 :(得分:3)
戈登,你定义了(application/json)
两次。只需在回复中删除它:
FORMAT: 1A
# Automative Industry
# Group Cars
## Cars [/cars]
+ Model (application/json)
+ Body
{
"name": "Taurus"
}
### List all cars [GET]
+ Response 200
[Cars][]
+ Response 401
+ Response 403
+ Response 500
+ Response 503