v3-me-agent-threads-thread.yaml 6.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189
  1. # 由 openapi/scripts/generate.php 生成,请勿手改;补充写到 overrides/v3-me-agent-threads-thread.yaml
  2. get:
  3. summary: 查看一个会话
  4. tags:
  5. - agent-threads
  6. operationId: get_api_v3_me_agent_threads_thread_
  7. description: |-
  8. 带全部可见的问答轮次(runs),按提问先后排;被「重新生成」替换掉的轮次不返回。
  9. 实现:`V3\MeAgentThreadController@show`
  10. security:
  11. -
  12. bearerAuth: []
  13. parameters:
  14. -
  15. name: thread
  16. in: path
  17. required: true
  18. schema:
  19. type: string
  20. description: 'AG-UI threadId(uuid)'
  21. responses:
  22. 200:
  23. description: 成功
  24. content:
  25. application/json:
  26. schema:
  27. type: object
  28. properties:
  29. data:
  30. type: object
  31. properties:
  32. thread_id:
  33. type: string
  34. title:
  35. type: string
  36. client:
  37. type: string
  38. nullable: true
  39. archived_at:
  40. type: string
  41. nullable: true
  42. last_run_at:
  43. type: string
  44. created_at:
  45. type: string
  46. updated_at:
  47. type: string
  48. deleted_at:
  49. type: string
  50. nullable: true
  51. runs:
  52. type: array
  53. items:
  54. type: object
  55. properties: { run_id: { type: string }, question: { type: string }, answer: { type: string, nullable: true }, citations: { type: array, items: { type: object }, nullable: true }, deep: { type: boolean }, status: { type: string }, user_message_id: { type: string, nullable: true }, assistant_message_id: { type: string, nullable: true }, created_at: { type: string } }
  56. description: 仅在部分查询口径下返回。
  57. 401:
  58. $ref: '../../main.yaml#/components/responses/ProblemUnauthorized'
  59. 422:
  60. $ref: '../../main.yaml#/components/responses/ProblemValidation'
  61. delete:
  62. summary: 删除会话
  63. tags:
  64. - agent-threads
  65. operationId: delete_api_v3_me_agent_threads_thread_
  66. description: |-
  67. 软删:会话连同它的问答一起从我的历史里消失,之后任何接口都读不到;服务器上的数据永久保留(防滥用、改进回答)。
  68. 返回软删后的会话本身(200,`deleted_at` 非空),不是 204。
  69. 实现:`V3\MeAgentThreadController@destroy`
  70. security:
  71. -
  72. bearerAuth: []
  73. parameters:
  74. -
  75. name: thread
  76. in: path
  77. required: true
  78. schema:
  79. type: string
  80. description: 'AG-UI threadId(uuid)'
  81. responses:
  82. 200:
  83. description: 成功
  84. content:
  85. application/json:
  86. schema:
  87. type: object
  88. properties:
  89. data:
  90. type: object
  91. properties:
  92. thread_id:
  93. type: string
  94. title:
  95. type: string
  96. client:
  97. type: string
  98. nullable: true
  99. archived_at:
  100. type: string
  101. nullable: true
  102. last_run_at:
  103. type: string
  104. created_at:
  105. type: string
  106. updated_at:
  107. type: string
  108. deleted_at:
  109. type: string
  110. nullable: true
  111. runs:
  112. type: array
  113. items:
  114. type: object
  115. properties: { run_id: { type: string }, question: { type: string }, answer: { type: string, nullable: true }, citations: { type: array, items: { type: object }, nullable: true }, deep: { type: boolean }, status: { type: string }, user_message_id: { type: string, nullable: true }, assistant_message_id: { type: string, nullable: true }, created_at: { type: string } }
  116. description: 仅在部分查询口径下返回。
  117. 401:
  118. $ref: '../../main.yaml#/components/responses/ProblemUnauthorized'
  119. 422:
  120. $ref: '../../main.yaml#/components/responses/ProblemValidation'
  121. patch:
  122. summary: 修改会话(目前只有标题)
  123. tags:
  124. - agent-threads
  125. operationId: patch_api_v3_me_agent_threads_thread_
  126. description: 实现:`V3\MeAgentThreadController@update`
  127. security:
  128. -
  129. bearerAuth: []
  130. parameters:
  131. -
  132. name: thread
  133. in: path
  134. required: true
  135. schema:
  136. type: string
  137. description: 'AG-UI threadId(uuid)'
  138. requestBody:
  139. required: false
  140. content:
  141. application/json:
  142. schema:
  143. type: object
  144. properties:
  145. title:
  146. type: string
  147. description: '会话标题,1–255 字'
  148. responses:
  149. 200:
  150. description: 成功
  151. content:
  152. application/json:
  153. schema:
  154. type: object
  155. properties:
  156. data:
  157. type: object
  158. properties:
  159. thread_id:
  160. type: string
  161. title:
  162. type: string
  163. client:
  164. type: string
  165. nullable: true
  166. archived_at:
  167. type: string
  168. nullable: true
  169. last_run_at:
  170. type: string
  171. created_at:
  172. type: string
  173. updated_at:
  174. type: string
  175. deleted_at:
  176. type: string
  177. nullable: true
  178. runs:
  179. type: array
  180. items:
  181. type: object
  182. properties: { run_id: { type: string }, question: { type: string }, answer: { type: string, nullable: true }, citations: { type: array, items: { type: object }, nullable: true }, deep: { type: boolean }, status: { type: string }, user_message_id: { type: string, nullable: true }, assistant_message_id: { type: string, nullable: true }, created_at: { type: string } }
  183. description: 仅在部分查询口径下返回。
  184. 401:
  185. $ref: '../../main.yaml#/components/responses/ProblemUnauthorized'
  186. 422:
  187. $ref: '../../main.yaml#/components/responses/ProblemValidation'