跳到主要内容
版本:1.0

allOf 与数组项

GET 

/allof-array-items

一个演示 allOf 与数组项作为子级的图书列表。

模式:

type: array
items:
$ref: '#/components/schemas/Book'

模式组件:

BookBase:
type: object
required:
- id
- title
- author
properties:
id:
type: integer
format: int64
description: 书籍的唯一标识符
title:
type: string
description: 书籍的标题
author:
type: string
description: 书籍的作者

AdditionalBookInfo:
type: object
properties:
publishedDate:
type: string
format: date
description: 书籍发布日期
genre:
type: string
description: 书籍的类型
tags:
type: array
items:
type: string
description: 与书籍相关的标签

Book:
allOf:
- $ref: '#/components/schemas/BookBase'
- $ref: '#/components/schemas/AdditionalBookInfo'

Responses

图书列表