| // Copyright 2020 The Chromium Authors |
| // Use of this source code is governed by a BSD-style license that can be |
| // found in the LICENSE file. |
| |
| // This file defines protobufs for features and related business |
| // objects, e.g., hotlists. |
| |
| syntax = "proto3"; |
| |
| package monorail.v3; |
| |
| option go_package = "infra/monorailv2/api/v3/api_proto"; |
| |
| // All possible permissions on the Monorail site. |
| // Next available tag: 6 |
| enum Permission { |
| // Default value. This value is unused. |
| PERMISSION_UNSPECIFIED = 0; |
| // The permission needed to add and remove issues from a hotlist. |
| HOTLIST_EDIT = 1; |
| // The permission needed to delete a hotlist or change hotlist |
| // settings/members. |
| HOTLIST_ADMINISTER = 2; |
| // The permission needed to edit an issue. |
| ISSUE_EDIT = 3; |
| // The permission needed to edit a custom field definition. |
| FIELD_DEF_EDIT = 4; |
| // The permission needed to edit the value of a custom field. |
| // More permissions will be required in the specific issue |
| // where the user plans to edit that value, e.g. ISSUE_EDIT. |
| FIELD_DEF_VALUE_EDIT = 5; |
| } |
| |
| |
| // The set of a user's permissions for a single resource. |
| // Next available tag: 3 |
| message PermissionSet { |
| // The name of the resource `permissions` applies to. |
| string resource = 1; |
| // All the permissions a user has for `resource`. |
| repeated Permission permissions = 2; |
| } |