v2-search-title-index.yaml 2.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394
  1. # 由 openapi/scripts/generate.php 生成,请勿手改;补充写到 overrides/v2-search-title-index.yaml
  2. get:
  3. summary: '列出 search-title-index'
  4. tags:
  5. - search-title-index
  6. operationId: get_api_v2_search_title_index
  7. description: 实现:`SearchTitleController@index`
  8. parameters:
  9. -
  10. name: key
  11. in: query
  12. schema:
  13. type: string
  14. -
  15. name: offset
  16. in: query
  17. schema:
  18. type: string
  19. -
  20. name: limit
  21. in: query
  22. schema:
  23. type: string
  24. -
  25. name: search
  26. in: query
  27. description: 搜索关键字
  28. schema:
  29. type: string
  30. -
  31. name: order
  32. in: query
  33. description: 排序字段
  34. schema:
  35. type: string
  36. -
  37. name: dir
  38. in: query
  39. description: 排序方向
  40. schema:
  41. type: string
  42. enum:
  43. - desc
  44. - asc
  45. responses:
  46. 200:
  47. description: '成功。业务失败时 HTTP 仍可能为 200,以 ok 字段为准。'
  48. content:
  49. application/json:
  50. schema:
  51. type: object
  52. properties:
  53. ok:
  54. type: boolean
  55. message:
  56. type: string
  57. data:
  58. type: object
  59. properties:
  60. rows:
  61. type: array
  62. items:
  63. type: object
  64. properties: { word: { type: string }, count: { type: integer }, bold: { type: string } }
  65. count:
  66. type: integer
  67. 401:
  68. $ref: '../../main.yaml#/components/responses/Unauthorized'
  69. 422:
  70. $ref: '../../main.yaml#/components/responses/ValidationError'
  71. post:
  72. summary: '新建 search-title-index'
  73. tags:
  74. - search-title-index
  75. operationId: post_api_v2_search_title_index
  76. description: 实现:`SearchTitleController@store`
  77. responses:
  78. 200:
  79. description: '成功。业务失败时 HTTP 仍可能为 200,以 ok 字段为准。'
  80. content:
  81. application/json:
  82. schema:
  83. type: object
  84. properties:
  85. ok:
  86. type: boolean
  87. message:
  88. type: string
  89. data:
  90. type: object
  91. 401:
  92. $ref: '../../main.yaml#/components/responses/Unauthorized'
  93. 422:
  94. $ref: '../../main.yaml#/components/responses/ValidationError'