sách gpt4 ai đã đi

Làm thế nào để tôi định nghĩa một kiểu thuộc tính là một danh sách các chuỗi (danh sách, tập hợp, mảng, bộ sưu tập) trong định nghĩa YAML Swagger của tôi?

In lại 作者:行者123 更新时间:2023-12-03 15:25:54 28 4
mua khóa gpt4 Nike

我正在为 API 编写一个 swagger 定义文件。 API 是用于 GET 请求的

/path/to/my/api:
get:
summary: My Custom API
description: |
Gets a List of FooBar IDs
produces:
- application/json
tags:
- FooBar
responses:
"200":
description: successful operation
schema:
$ref: "#/definitions/MyCustomType"

...
MyCustomType:
type: object
properties:
myCustomObject
type: ??? # list of string?

1 Câu trả lời

关于collections - 如何在我的 YAML Swagger 定义中将属性类型定义为字符串列表(列表、集合、数组、集合),我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/38553582/

28 4 0
行者123
Hồ sơ cá nhân

Tôi là một lập trình viên xuất sắc, rất giỏi!

Nhận phiếu giảm giá Didi Taxi miễn phí
Mã giảm giá Didi Taxi
Giấy chứng nhận ICP Bắc Kinh số 000000
Hợp tác quảng cáo: 1813099741@qq.com 6ren.com