v2-sentpr-sentpr.yaml 4.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170
  1. # 由 openapi/scripts/generate.php 生成,请勿手改;补充写到 overrides/v2-sentpr-sentpr.yaml
  2. get:
  3. summary: '获取单个 sentpr/{sentpr}'
  4. tags:
  5. - sentpr
  6. operationId: get_api_v2_sentpr_sentpr_
  7. description: 实现:`SentPrController@show`
  8. parameters:
  9. -
  10. name: sentpr
  11. in: path
  12. required: true
  13. schema:
  14. type: string
  15. responses:
  16. 200:
  17. description: '成功。业务失败时 HTTP 仍可能为 200,以 ok 字段为准。'
  18. content:
  19. application/json:
  20. schema:
  21. type: object
  22. properties:
  23. ok:
  24. type: boolean
  25. message:
  26. type: string
  27. data:
  28. type: object
  29. properties:
  30. id:
  31. type: integer
  32. uid:
  33. type: string
  34. book:
  35. type: string
  36. paragraph:
  37. type: string
  38. word_start:
  39. type: string
  40. word_end:
  41. type: string
  42. editor:
  43. type: string
  44. channel:
  45. type: string
  46. content:
  47. type: string
  48. html:
  49. type: string
  50. role:
  51. type: string
  52. created_at:
  53. type: string
  54. updated_at:
  55. type: string
  56. 401:
  57. $ref: '../../main.yaml#/components/responses/Unauthorized'
  58. 422:
  59. $ref: '../../main.yaml#/components/responses/ValidationError'
  60. put:
  61. summary: '更新 sentpr/{sentpr}'
  62. tags:
  63. - sentpr
  64. operationId: put_api_v2_sentpr_sentpr_
  65. description: 实现:`SentPrController@update`
  66. parameters:
  67. -
  68. name: sentpr
  69. in: path
  70. required: true
  71. schema:
  72. type: string
  73. requestBody:
  74. required: false
  75. content:
  76. application/json:
  77. schema:
  78. type: object
  79. properties:
  80. text:
  81. type: string
  82. responses:
  83. 200:
  84. description: '成功。业务失败时 HTTP 仍可能为 200,以 ok 字段为准。'
  85. content:
  86. application/json:
  87. schema:
  88. type: object
  89. properties:
  90. ok:
  91. type: boolean
  92. message:
  93. type: string
  94. data:
  95. type: object
  96. 401:
  97. $ref: '../../main.yaml#/components/responses/Unauthorized'
  98. 422:
  99. $ref: '../../main.yaml#/components/responses/ValidationError'
  100. patch:
  101. summary: '更新 sentpr/{sentpr}'
  102. tags:
  103. - sentpr
  104. operationId: patch_api_v2_sentpr_sentpr_
  105. description: 实现:`SentPrController@update`
  106. parameters:
  107. -
  108. name: sentpr
  109. in: path
  110. required: true
  111. schema:
  112. type: string
  113. requestBody:
  114. required: false
  115. content:
  116. application/json:
  117. schema:
  118. type: object
  119. properties:
  120. text:
  121. type: string
  122. responses:
  123. 200:
  124. description: '成功。业务失败时 HTTP 仍可能为 200,以 ok 字段为准。'
  125. content:
  126. application/json:
  127. schema:
  128. type: object
  129. properties:
  130. ok:
  131. type: boolean
  132. message:
  133. type: string
  134. data:
  135. type: object
  136. 401:
  137. $ref: '../../main.yaml#/components/responses/Unauthorized'
  138. 422:
  139. $ref: '../../main.yaml#/components/responses/ValidationError'
  140. delete:
  141. summary: '删除 sentpr/{sentpr}'
  142. tags:
  143. - sentpr
  144. operationId: delete_api_v2_sentpr_sentpr_
  145. description: 实现:`SentPrController@destroy`
  146. parameters:
  147. -
  148. name: sentpr
  149. in: path
  150. required: true
  151. schema:
  152. type: string
  153. responses:
  154. 200:
  155. description: '成功。业务失败时 HTTP 仍可能为 200,以 ok 字段为准。'
  156. content:
  157. application/json:
  158. schema:
  159. type: object
  160. properties:
  161. ok:
  162. type: boolean
  163. message:
  164. type: string
  165. data:
  166. type: object
  167. 401:
  168. $ref: '../../main.yaml#/components/responses/Unauthorized'
  169. 422:
  170. $ref: '../../main.yaml#/components/responses/ValidationError'