OLD | NEW |
(Empty) | |
| 1 // Copyright 2016 The Chromium Authors. All Rights Reserved. |
| 2 // Use of this source code is governed by the Apache v2.0 license that can be |
| 3 // found in the LICENSE file. |
| 4 |
| 5 // Schemas for monorail api client configs. |
| 6 // Command to generate api_clients_config_pb2.py: in monorail/ directory: |
| 7 // protoc ./proto/api_clients_config.proto --proto_path=./proto/ --python_out=./
proto |
| 8 |
| 9 |
| 10 syntax = "proto2"; |
| 11 |
| 12 package monorail; |
| 13 |
| 14 message ProjectPermission { |
| 15 enum Role { |
| 16 committer = 1; |
| 17 contributor = 2; |
| 18 } |
| 19 |
| 20 optional string project = 1; |
| 21 optional Role role = 2 [default = contributor]; |
| 22 repeated string extra_permissions = 3; |
| 23 } |
| 24 |
| 25 message Client { |
| 26 optional string client_email = 1; |
| 27 optional string display_name = 2; |
| 28 optional string client_id = 3; |
| 29 optional string description = 4; |
| 30 repeated ProjectPermission project_permissions = 5; |
| 31 optional int32 period_limit = 6 [default = 100000]; |
| 32 optional int32 lifetime_limit = 7 [default = 1000000]; |
| 33 repeated string contacts = 8; |
| 34 } |
| 35 |
| 36 message ClientCfg { |
| 37 repeated Client clients = 1; |
| 38 } |
OLD | NEW |