common.proto 9.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333
  1. // Copyright 2017 Google Inc.
  2. //
  3. // Licensed under the Apache License, Version 2.0 (the "License");
  4. // you may not use this file except in compliance with the License.
  5. // You may obtain a copy of the License at
  6. //
  7. // http://www.apache.org/licenses/LICENSE-2.0
  8. //
  9. // Unless required by applicable law or agreed to in writing, software
  10. // distributed under the License is distributed on an "AS IS" BASIS,
  11. // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  12. // See the License for the specific language governing permissions and
  13. // limitations under the License.
  14. syntax = "proto3";
  15. package google.cloud.support.common;
  16. import "google/api/annotations.proto";
  17. import "google/protobuf/timestamp.proto";
  18. option go_package = "google.golang.org/genproto/googleapis/cloud/support/common;common";
  19. option java_outer_classname = "CloudSupportProto";
  20. option java_package = "com.google.cloud.support.common";
  21. // A Google Cloud Platform account that identifies support eligibility for a
  22. // Cloud resource. Currently the Cloud resource can only be an Organization
  23. // but this might change in future.
  24. message SupportAccount {
  25. // The current state of this SupportAccount.
  26. enum State {
  27. // Account is in an unknown state.
  28. STATE_UNSPECIFIED = 0;
  29. // Account is in an active state.
  30. ACTIVE = 1;
  31. // Account has been created but is being provisioned in support systems.
  32. PENDING = 2;
  33. // Account deletion has been requested by the user.
  34. PENDING_DELETION = 3;
  35. }
  36. // Pricing model applicable to this support account.
  37. enum PricingModel {
  38. // This account is subscribed to an unknown pricing model.
  39. PRICING_MODEL_UNKNOWN = 0;
  40. // Package based pricing (Platinum, Gold, Silver, Bronze).
  41. PACKAGES = 1;
  42. // Support charges are calculated based on user seats a.k.a,
  43. // "Pick Your Team" model.
  44. USER_ROLES = 2;
  45. }
  46. // The resource name for a support account in format
  47. // `supportAccounts/{account_id}`.
  48. // Output only.
  49. string name = 1;
  50. // Identifier for this entity that gets persisted in storage system. The
  51. // resource name is populated using this field in format
  52. // `supportAccounts/{account_id}`.
  53. string account_id = 2;
  54. // The Cloud resource with which this support account is associated.
  55. string cloud_resource = 3;
  56. // A user friendly display name assigned to this support account.
  57. string display_name = 4;
  58. // Indicates the current state of an account.
  59. State state = 5;
  60. // Time when this account was created.
  61. // Output only.
  62. google.protobuf.Timestamp create_time = 6;
  63. // The resource name of a billing account associated with this support
  64. // account. For example, `billingAccounts/ABCDEF-012345-567890`.
  65. string billing_account_name = 7;
  66. string unify_account_id = 8;
  67. // The PricingModel applicable to this support account.
  68. PricingModel pricing_model = 9;
  69. }
  70. // A support case created by the user.
  71. message Case {
  72. // The case priority with P0 being the most urgent and P4 the least.
  73. enum Priority {
  74. // Priority is undefined or has not been set yet.
  75. PRIORITY_UNSPECIFIED = 0;
  76. // Extreme impact on a production service - Service is hard down.
  77. P0 = 1;
  78. // Critical impact on a production service - Service is currently unusable.
  79. P1 = 2;
  80. // Severe impact on a production service - Service is usable but greatly
  81. // impaired.
  82. P2 = 3;
  83. // Medium impact on a production service - Service is available, but
  84. // moderately impaired.
  85. P3 = 4;
  86. // General questions or minor issues - Production service is fully
  87. // available.
  88. P4 = 5;
  89. }
  90. // The state of a case.
  91. enum State {
  92. // Case is in an unknown state.
  93. STATE_UNSPECIFIED = 0;
  94. // Case has been created but no one is assigned to work on it yet.
  95. NEW = 1;
  96. // Case has been assigned to a support agent.
  97. ASSIGNED = 2;
  98. // A support agent is currently investigating the case.
  99. IN_PROGRESS_GOOGLE_SUPPORT = 3;
  100. // Case has been forwarded to product team for further investigation.
  101. IN_PROGRESS_GOOGLE_ENG = 4;
  102. // Case is under investigation and relates to a known issue.
  103. IN_PROGRESS_KNOWN_ISSUE = 5;
  104. // Case is waiting for a response from the customer.
  105. WAITING_FOR_CUSTOMER_RESPONSE = 6;
  106. // A solution has been offered for the case but it isn't closed yet.
  107. SOLUTION_OFFERED = 7;
  108. // Cases has been fully resolved and is in a closed state.
  109. CLOSED = 8;
  110. }
  111. // The resource name for the Case in format
  112. // `supportAccounts/{account_id}/cases/{case_id}`
  113. string name = 1;
  114. // The short summary of the issue reported in this case.
  115. string display_name = 2;
  116. // The board description of issue provided with initial summary.
  117. string description = 3;
  118. // The product component for which this Case is reported.
  119. string component = 4;
  120. // The product subcomponent for which this Case is reported.
  121. string subcomponent = 5;
  122. // Timezone the client sending this request is in.
  123. // It should be in a format IANA recognizes: https://www.iana.org/time-zone
  124. // There is no additional validation done by the API.
  125. string client_timezone = 6;
  126. // The email addresses that can be copied to receive updates on this case.
  127. // Users can specify a maximum of 10 email addresses.
  128. repeated string cc_addresses = 7;
  129. // The Google Cloud Platform project ID for which this case is created.
  130. string project_id = 8;
  131. // List of customer issues associated with this case.
  132. repeated CustomerIssue issues = 10;
  133. // The current priority of this case.
  134. Priority priority = 11;
  135. // The current state of this case.
  136. State state = 12;
  137. // Time when this case was created.
  138. // Output only.
  139. google.protobuf.Timestamp create_time = 13;
  140. // Time when this case was last updated.
  141. // Output only.
  142. google.protobuf.Timestamp update_time = 14;
  143. // Email address of user who created this case.
  144. // Output only. It is inferred from credentials supplied during case creation.
  145. string creator_email = 15;
  146. // The issue category applicable to this case.
  147. string category = 16;
  148. }
  149. // Reference to a Google internal ticket used for investigating a support case.
  150. // Not every support case will have an internal ticket associated with it.
  151. // A support case can have multiple tickets linked to it.
  152. message CustomerIssue {
  153. // The status of a customer issue.
  154. enum IssueState {
  155. // Issue in an unknown state.
  156. ISSUE_STATE_UNSPECIFIED = 0;
  157. // Issue is currently open but the work on it has not been started.
  158. OPEN = 1;
  159. // Issue is currently being worked on.
  160. IN_PROGRESS = 2;
  161. // Issue is fixed.
  162. FIXED = 3;
  163. // Issue has been marked as invalid.
  164. WONT_FIX = 4;
  165. // Issue verified and in production.
  166. VERIFIED = 5;
  167. }
  168. // Unique identifier for the internal issue.
  169. // Output only.
  170. string issue_id = 1;
  171. // Represents current status of the internal ticket.
  172. // Output only.
  173. IssueState state = 2;
  174. // Time when the internal issue was created.
  175. // Output only.
  176. google.protobuf.Timestamp create_time = 3;
  177. // Time when the internal issue was marked as resolved.
  178. // Output only.
  179. google.protobuf.Timestamp resolve_time = 4;
  180. // Time when the internal issue was last updated.
  181. // Output only.
  182. google.protobuf.Timestamp update_time = 5;
  183. }
  184. // A message that contains mapping of a user and their role under a support
  185. // account.
  186. message SupportRole {
  187. // A role which determines the support resources and features a user might
  188. // get access to.
  189. enum Role {
  190. // An unknown role.
  191. ROLE_UNSPECIFIED = 0;
  192. // The basic support role.
  193. BASIC = 1;
  194. // The developer role.
  195. DEVELOPER = 2;
  196. // The operation role.
  197. OPERATION = 3;
  198. // The site reliability role.
  199. SITE_RELIABILITY = 4;
  200. }
  201. // Email address of user being added through this Role.
  202. string email = 1;
  203. // The type of role assigned to user.
  204. Role role = 2;
  205. }
  206. // The comment text associated with a `Case`.
  207. message Comment {
  208. // Text containing a maximum of 3000 characters.
  209. string text = 1;
  210. // Time when this update was created.
  211. // Output only.
  212. google.protobuf.Timestamp create_time = 2;
  213. // The email address/name of user who created this comment.
  214. // Output only.
  215. string author = 3;
  216. // The resource name for this comment in format
  217. // `supportAccounts/{account_id}/cases/{case_id}/{comment_id}`.
  218. // Output only.
  219. string name = 4;
  220. }
  221. // Represents the product component taxonomy that is to be used while creating
  222. // or updating a `Case`. A client should obtain the list of issue categories,
  223. // component/subcomponent from this object and specify it in `Case.category`,
  224. // `Case.component` and `Case.subcomponent` fields respectively.
  225. message IssueTaxonomy {
  226. // The representation of a product component. It is composed of a canonical
  227. // name for the product (e.g., Google App Engine), languages in which a
  228. // support ticket can be created under this component, a template that
  229. // provides hints on important details to be filled out before submitting a
  230. // case. It also contains an embedded list of product subcomponents that have
  231. // similar attributes as top-level components.
  232. // (e.g., Google App Engine > Memcache).
  233. message Component {
  234. // User friendly name of this component.
  235. string display_name = 1;
  236. // List of languages in which a support case can be created under this
  237. // component. Represented by language codes in ISO_639-1 standard.
  238. repeated string languages = 2;
  239. // Template to be used while filling the description of a support case.
  240. string template = 3;
  241. // List of subcomponents under this component.
  242. repeated Component subcomponents = 4;
  243. }
  244. // Represents the category of issue (Technical or Non-Technical)
  245. // reported through a support case.
  246. message Category {
  247. // User friendly name of this category.
  248. string display_name = 1;
  249. // Map of product components under this category.
  250. map<string, Component> components = 2;
  251. }
  252. // Map of available categories.
  253. map<string, Category> categories = 1;
  254. }