Hei*_*ich 1 rest swagger swagger-editor swashbuckle
我收到以下错误:
声明的路径参数“imageId”需要在路径或操作级别定义为路径参数
这是我的招摇定义的快照
'/api/v1/images/{unitnumber}/{type}/{imageId}':
delete:
tags:
- Images
summary: 'Summary'
description: "Description"
operationId: DeleteImage
consumes: []
produces:
- application/json
parameters:
- name: unitnumber
in: path
required: true
type: string
- name: type
in: path
required: true
type: string
- name: imageId
in: query
required: false
type: string
responses:
'400':
description: Bad Request
schema:
$ref: '#/definitions/ErrorResponse'
'401':
description: Unauthorized
schema:
type: string
'500':
description: Server Error
schema:
$ref: '#/definitions/ErrorResponse'
Run Code Online (Sandbox Code Playgroud)
我只可以摆脱错误的,如果我走了imageId,改变以path代替query其意向不大
- name: imageId
in: path
required: true
type: string
Run Code Online (Sandbox Code Playgroud)
知道我需要改变什么才能让它工作吗?
| 归档时间: |
|
| 查看次数: |
1860 次 |
| 最近记录: |