v2-wbwlookup.yaml 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118
  1. # 由 openapi/scripts/generate.php 生成,请勿手改;补充写到 overrides/v2-wbwlookup.yaml
  2. get:
  3. summary: '列出 wbwlookup'
  4. tags:
  5. - wbwlookup
  6. operationId: get_api_v2_wbwlookup
  7. description: 实现:`WbwLookupController@index`
  8. parameters:
  9. -
  10. name: word
  11. in: query
  12. schema:
  13. type: string
  14. -
  15. name: base
  16. in: query
  17. schema:
  18. type: string
  19. -
  20. name: deep
  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. -
  46. name: limit
  47. in: query
  48. description: 每页记录数
  49. schema:
  50. type: number
  51. -
  52. name: offset
  53. in: query
  54. description: 从第几条记录开始提取
  55. schema:
  56. type: number
  57. responses:
  58. 200:
  59. description: '成功。业务失败时 HTTP 仍可能为 200,以 ok 字段为准。'
  60. content:
  61. application/json:
  62. schema:
  63. type: object
  64. properties:
  65. ok:
  66. type: boolean
  67. message:
  68. type: string
  69. data:
  70. type: object
  71. properties:
  72. rows:
  73. type: array
  74. items:
  75. type: object
  76. count:
  77. type: integer
  78. 401:
  79. $ref: '../../main.yaml#/components/responses/Unauthorized'
  80. 422:
  81. $ref: '../../main.yaml#/components/responses/ValidationError'
  82. post:
  83. summary: 自动查词
  84. tags:
  85. - wbwlookup
  86. operationId: post_api_v2_wbwlookup
  87. description: 实现:`WbwLookupController@store`
  88. requestBody:
  89. required: false
  90. content:
  91. application/json:
  92. schema:
  93. type: object
  94. properties:
  95. channel_id:
  96. type: string
  97. data:
  98. type: string
  99. lang:
  100. type: string
  101. responses:
  102. 200:
  103. description: '成功。业务失败时 HTTP 仍可能为 200,以 ok 字段为准。'
  104. content:
  105. application/json:
  106. schema:
  107. type: object
  108. properties:
  109. ok:
  110. type: boolean
  111. message:
  112. type: string
  113. data:
  114. type: object
  115. 401:
  116. $ref: '../../main.yaml#/components/responses/Unauthorized'
  117. 422:
  118. $ref: '../../main.yaml#/components/responses/ValidationError'