user-feedback.json 5.0 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175
  1. {
  2. "get": {
  3. "tags": ["Projects"],
  4. "description": "Return a list of user feedback items within this project.",
  5. "operationId": "List a Project's User Feedback",
  6. "parameters": [
  7. {
  8. "name": "organization_slug",
  9. "in": "path",
  10. "description": "The slug of the organization.",
  11. "required": true,
  12. "schema": {
  13. "type": "string"
  14. }
  15. },
  16. {
  17. "name": "project_slug",
  18. "in": "path",
  19. "description": "The slug of the project.",
  20. "required": true,
  21. "schema": {
  22. "type": "string"
  23. }
  24. }
  25. ],
  26. "responses": {
  27. "200": {
  28. "description": "Success",
  29. "content": {
  30. "application/json": {
  31. "schema": {
  32. "type": "array",
  33. "items": {
  34. "$ref": "../../components/schemas/user-feedback.json#/UserFeedback"
  35. }
  36. },
  37. "example": [
  38. {
  39. "comments": "It broke!",
  40. "dateCreated": "2018-11-06T21:20:11.468Z",
  41. "email": "jane@example.com",
  42. "event": {
  43. "eventID": "14bad9a2e3774046977a21440ddb39b2",
  44. "id": null
  45. },
  46. "eventID": "14bad9a2e3774046977a21440ddb39b2",
  47. "id": "1",
  48. "issue": null,
  49. "name": "Jane Smith",
  50. "user": null
  51. }
  52. ]
  53. }
  54. }
  55. },
  56. "403": {
  57. "description": "Forbidden"
  58. },
  59. "404": {
  60. "description": "Not Found"
  61. }
  62. },
  63. "security": [
  64. {
  65. "auth_token": ["project:read"]
  66. }
  67. ]
  68. },
  69. "post": {
  70. "tags": ["Projects"],
  71. "description": "Submit and associate user feedback with an issue.\n\nFeedback must be received by the server no more than 30 minutes after the event was saved.\n\nAdditionally, within 5 minutes of submitting feedback it may also be overwritten. This is useful in situations where you may need to retry sending a request due to network failures.\n\nIf feedback is rejected due to a mutability threshold, a 409 status code will be returned.\n\nNote: Feedback may be submitted with DSN authentication (see auth documentation).",
  72. "operationId": "Submit User Feedback",
  73. "parameters": [
  74. {
  75. "name": "organization_slug",
  76. "in": "path",
  77. "description": "The slug of the organization.",
  78. "required": true,
  79. "schema": {
  80. "type": "string"
  81. }
  82. },
  83. {
  84. "name": "project_slug",
  85. "in": "path",
  86. "description": "The slug of the project.",
  87. "required": true,
  88. "schema": {
  89. "type": "string"
  90. }
  91. }
  92. ],
  93. "requestBody": {
  94. "content": {
  95. "application/json": {
  96. "schema": {
  97. "required": ["event_id", "name", "email", "comments"],
  98. "type": "object",
  99. "properties": {
  100. "event_id": {
  101. "type": "string",
  102. "description": "The event ID. This can be retrieved from the [beforeSend callback](https://docs.sentry.io/platforms/javascript/configuration/filtering/#using-beforesend)."
  103. },
  104. "name": {
  105. "type": "string",
  106. "description": "User's name."
  107. },
  108. "email": {
  109. "type": "string",
  110. "description": "User's email address."
  111. },
  112. "comments": {
  113. "type": "string",
  114. "description": "Comments supplied by user."
  115. }
  116. }
  117. },
  118. "example": {
  119. "event_id": "14bad9a2e3774046977a21440ddb39b2",
  120. "name": "Jane Schmidt",
  121. "email": "jane@empowerplant.io",
  122. "comments": "It broke!"
  123. }
  124. }
  125. },
  126. "required": false
  127. },
  128. "responses": {
  129. "200": {
  130. "description": "Success",
  131. "content": {
  132. "application/json": {
  133. "schema": {
  134. "$ref": "../../components/schemas/user-feedback.json#/UserFeedback"
  135. },
  136. "example": {
  137. "comments": "It broke!",
  138. "dateCreated": "2018-11-06T21:20:11.468Z",
  139. "email": "jane@example.com",
  140. "event": {
  141. "eventID": "14bad9a2e3774046977a21440ddb39b2",
  142. "id": null
  143. },
  144. "eventID": "14bad9a2e3774046977a21440ddb39b2",
  145. "id": "1",
  146. "issue": null,
  147. "name": "Jane Smith",
  148. "user": null
  149. }
  150. }
  151. }
  152. },
  153. "400": {
  154. "description": "Bad Input"
  155. },
  156. "403": {
  157. "description": "Forbidden"
  158. },
  159. "404": {
  160. "description": "The requested resource does not exist"
  161. },
  162. "409": {
  163. "description": "Conflict"
  164. }
  165. },
  166. "security": [
  167. {
  168. "auth_token": ["project:write"]
  169. },
  170. {
  171. "dsn": []
  172. }
  173. ]
  174. }
  175. }