| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374 |
- # 由 openapi/scripts/generate.php 生成,请勿手改;补充写到 overrides/v3-glossaries-kind.yaml
- get:
- summary: 术语词汇表
- tags:
- - glossaries
- operationId: get_api_v3_glossaries_kind_
- description: |-
- 整表返回、不分页(客户端启动时拉一次,本地查词)。`meta.lang` 是实际用到的语言:
- 该语言没有这张表时回退到英文。条目的 `id`(术语 guid)只有 grammar 表给,community 表不给(省流量)。
- community 表带 `ETag`(`Cache-Control: public, no-cache`):浏览器下次自动带 `If-None-Match`,
- 表没变就回 304、不带正文。ETag 在社区术语任务每次跑完时更换。grammar 表暂不带。
- 实现:`V3\GlossaryController@__invoke`
- security:
- - { }
- -
- bearerAuth: []
- parameters:
- -
- name: kind
- in: path
- required: true
- schema:
- type: string
- enum:
- - grammar
- - community
- description: '哪张表:grammar 语法术语,community 社区译名'
- -
- name: lang
- in: query
- schema:
- type: string
- description: '语言,如 zh-Hans。缺省用界面语言(Accept-Language 协商的结果)'
- responses:
- 200:
- description: 成功
- content:
- application/json:
- schema:
- type: object
- properties:
- data:
- type: array
- items:
- type: object
- properties:
- id:
- type: string
- description: 仅在部分查询口径下返回。
- word:
- type: string
- tag:
- type: string
- nullable: true
- meaning:
- type: string
- other_meaning:
- type: string
- nullable: true
- meta:
- type: object
- properties:
- kind:
- type: string
- description: 哪张表
- lang:
- type: string
- description: '实际用到的语言(没有该语言的表时是 en)'
- total:
- type: integer
- description: 条数
- 422:
- $ref: '../../main.yaml#/components/responses/ProblemValidation'
|