codekingpro/portable-devtools
114k
1// Copyright 2026 Google LLC2//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 at6//7// http://www.apache.org/licenses/LICENSE-2.08//9// Unless required by applicable law or agreed to in writing, software10// 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 and13// limitations under the License.14 15syntax = "proto3";16 17package google.api;18 19option go_package = "google.golang.org/genproto/googleapis/api/serviceconfig;serviceconfig";20option java_multiple_files = true;21option java_outer_classname = "BillingProto";22option java_package = "com.google.api";23option objc_class_prefix = "GAPI";24 25// Billing related configuration of the service.26//27// The following example shows how to configure monitored resources and metrics28// for billing, `consumer_destinations` is the only supported destination and29// the monitored resources need at least one label key30// `cloud.googleapis.com/location` to indicate the location of the billing31// usage, using different monitored resources between monitoring and billing is32// recommended so they can be evolved independently:33//34//35// monitored_resources:36// - type: library.googleapis.com/billing_branch37// labels:38// - key: cloud.googleapis.com/location39// description: |40// Predefined label to support billing location restriction.41// - key: city42// description: |43// Custom label to define the city where the library branch is located44// in.45// - key: name46// description: Custom label to define the name of the library branch.47// metrics:48// - name: library.googleapis.com/book/borrowed_count49// metric_kind: DELTA50// value_type: INT6451// unit: "1"52// billing:53// consumer_destinations:54// - monitored_resource: library.googleapis.com/billing_branch55// metrics:56// - library.googleapis.com/book/borrowed_count57message Billing {58 // Configuration of a specific billing destination (Currently only support59 // bill against consumer project).60 message BillingDestination {61 // The monitored resource type. The type must be defined in62 // [Service.monitored_resources][google.api.Service.monitored_resources]63 // section.64 string monitored_resource = 1;65 66 // Names of the metrics to report to this billing destination.67 // Each name must be defined in68 // [Service.metrics][google.api.Service.metrics] section.69 repeated string metrics = 2;70 }71 72 // Billing configurations for sending metrics to the consumer project.73 // There can be multiple consumer destinations per service, each one must have74 // a different monitored resource type. A metric can be used in at most75 // one consumer destination.76 repeated BillingDestination consumer_destinations = 8;77}78 