1// Copyright 2020 Google LLC 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 15syntax = "proto3"; 16 17package google.cloud.dataqna.v1alpha; 18 19import "google/api/field_behavior.proto"; 20import "google/api/resource.proto"; 21 22option csharp_namespace = "Google.Cloud.DataQnA.V1Alpha"; 23option go_package = "cloud.google.com/go/dataqna/apiv1alpha/dataqnapb;dataqnapb"; 24option java_multiple_files = true; 25option java_outer_classname = "UserFeedbackProto"; 26option java_package = "com.google.cloud.dataqna.v1alpha"; 27option php_namespace = "Google\\Cloud\\DataQnA\\V1alpha"; 28option ruby_package = "Google::Cloud::DataQnA::V1alpha"; 29 30// Feedback provided by a user. 31message UserFeedback { 32 option (google.api.resource) = { 33 type: "dataqna.googleapis.com/UserFeedback" 34 pattern: "projects/{project}/locations/{location}/questions/{question}/userFeedback" 35 }; 36 37 // Enumeration of feedback ratings. 38 enum UserFeedbackRating { 39 // No rating was specified. 40 USER_FEEDBACK_RATING_UNSPECIFIED = 0; 41 42 // The user provided positive feedback. 43 POSITIVE = 1; 44 45 // The user provided negative feedback. 46 NEGATIVE = 2; 47 } 48 49 // Required. The unique identifier for the user feedback. 50 // User feedback is a singleton resource on a Question. 51 // Example: `projects/foo/locations/bar/questions/1234/userFeedback` 52 string name = 1 [(google.api.field_behavior) = REQUIRED]; 53 54 // Free form user feedback, such as a text box. 55 string free_form_feedback = 2; 56 57 // The user feedback rating 58 UserFeedbackRating rating = 3; 59} 60