key-details.json 4.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157
  1. {
  2. "put": {
  3. "tags": ["Projects"],
  4. "description": "Update a client key. This can be used to rename a key.",
  5. "operationId": "Update a Client Key",
  6. "parameters": [
  7. {
  8. "name": "organization_slug",
  9. "in": "path",
  10. "description": "The slug of the organization the client keys belong to.",
  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 the client keys belong to.",
  20. "required": true,
  21. "schema": {
  22. "type": "string"
  23. }
  24. },
  25. {
  26. "name": "key_id",
  27. "in": "path",
  28. "description": "The ID of the key to update.",
  29. "required": true,
  30. "schema": {
  31. "type": "string"
  32. }
  33. }
  34. ],
  35. "requestBody": {
  36. "content": {
  37. "application/json": {
  38. "schema": {
  39. "type": "object",
  40. "properties": {
  41. "name": {
  42. "type": "string",
  43. "description": "The new name for the client key."
  44. }
  45. }
  46. },
  47. "example": {
  48. "name": "Fluffy Key"
  49. }
  50. }
  51. },
  52. "required": true
  53. },
  54. "responses": {
  55. "200": {
  56. "description": "Success",
  57. "content": {
  58. "application/json": {
  59. "schema": {
  60. "$ref": "../../components/schemas/key.json#/Key"
  61. },
  62. "example": {
  63. "browserSdk": {
  64. "choices": [
  65. ["latest", "latest"],
  66. ["4.x", "4.x"]
  67. ]
  68. },
  69. "browserSdkVersion": "4.x",
  70. "dateCreated": "2018-11-06T21:20:07.941Z",
  71. "dsn": {
  72. "cdn": "https://sentry.io/js-sdk-loader/cec9dfceb0b74c1c9a5e3c135585f364.min.js",
  73. "csp": "https://sentry.io/api/2/csp-report/?sentry_key=cec9dfceb0b74c1c9a5e3c135585f364",
  74. "minidump": "https://sentry.io/api/2/minidump/?sentry_key=cec9dfceb0b74c1c9a5e3c135585f364",
  75. "public": "https://cec9dfceb0b74c1c9a5e3c135585f364@sentry.io/2",
  76. "secret": "https://cec9dfceb0b74c1c9a5e3c135585f364:4f6a592349e249c5906918393766718d@sentry.io/2",
  77. "security": "https://sentry.io/api/2/security/?sentry_key=cec9dfceb0b74c1c9a5e3c135585f364"
  78. },
  79. "id": "cec9dfceb0b74c1c9a5e3c135585f364",
  80. "isActive": true,
  81. "label": "Fluffy Key",
  82. "name": "Fluffy Key",
  83. "projectId": 2,
  84. "public": "cec9dfceb0b74c1c9a5e3c135585f364",
  85. "rateLimit": null,
  86. "secret": "4f6a592349e249c5906918393766718d"
  87. }
  88. }
  89. }
  90. },
  91. "400": {
  92. "description": "Bad Input"
  93. },
  94. "403": {
  95. "description": "Forbidden"
  96. },
  97. "404": {
  98. "description": "Project not found"
  99. }
  100. },
  101. "security": [
  102. {
  103. "auth_token": ["project:write"]
  104. }
  105. ]
  106. },
  107. "delete": {
  108. "tags": ["Projects"],
  109. "description": "Delete a client key.",
  110. "operationId": "Delete a Client Key",
  111. "parameters": [
  112. {
  113. "name": "organization_slug",
  114. "in": "path",
  115. "description": "The slug of the organization the client keys belong to.",
  116. "required": true,
  117. "schema": {
  118. "type": "string"
  119. }
  120. },
  121. {
  122. "name": "project_slug",
  123. "in": "path",
  124. "description": "The slug of the project the client keys belong to.",
  125. "required": true,
  126. "schema": {
  127. "type": "string"
  128. }
  129. },
  130. {
  131. "name": "key_id",
  132. "in": "path",
  133. "description": "The ID of the key to delete.",
  134. "required": true,
  135. "schema": {
  136. "type": "string"
  137. }
  138. }
  139. ],
  140. "responses": {
  141. "204": {
  142. "description": "Success"
  143. },
  144. "403": {
  145. "description": "Forbidden"
  146. },
  147. "404": {
  148. "description": "Project not found"
  149. }
  150. },
  151. "security": [
  152. {
  153. "auth_token": ["project:admin"]
  154. }
  155. ]
  156. }
  157. }