xref: /aosp_15_r20/external/googleapis/google/ads/admanager/v1/network_service.proto (revision d5c09012810ac0c9f33fe448fb6da8260d444cc9)
1// Copyright 2023 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.ads.admanager.v1;
18
19import "google/api/annotations.proto";
20import "google/api/client.proto";
21import "google/api/field_behavior.proto";
22import "google/api/resource.proto";
23
24option csharp_namespace = "Google.Ads.AdManager.V1";
25option go_package = "google.golang.org/genproto/googleapis/ads/admanager/v1;admanager";
26option java_multiple_files = true;
27option java_outer_classname = "NetworkServiceProto";
28option java_package = "com.google.ads.admanager.v1";
29option objc_class_prefix = "GAA";
30option php_namespace = "Google\\Ads\\AdManager\\V1";
31
32// Provides methods for handling Network objects.
33service NetworkService {
34  option (google.api.default_host) = "admanager.googleapis.com";
35
36  // API to retrieve a Network object.
37  rpc GetNetwork(GetNetworkRequest) returns (Network) {
38    option (google.api.http) = {
39      get: "/v1/{name=networks/*}"
40    };
41    option (google.api.method_signature) = "name";
42  }
43}
44
45// The Network resource.
46message Network {
47  option (google.api.resource) = {
48    type: "admanager.googleapis.com/Network"
49    pattern: "networks/{network_code}"
50    plural: "networks"
51    singular: "network"
52  };
53
54  // Identifier. The resource name of the Network.
55  // Format: networks/{network_code}
56  string name = 1 [(google.api.field_behavior) = IDENTIFIER];
57
58  // Optional. Display name for Network.
59  string display_name = 2 [(google.api.field_behavior) = OPTIONAL];
60
61  // Output only. Network Code.
62  string network_code = 3 [(google.api.field_behavior) = OUTPUT_ONLY];
63
64  // Output only. Property code.
65  string property_code = 4 [(google.api.field_behavior) = OUTPUT_ONLY];
66
67  // Output only. Time zone associated with the delivery of orders and
68  // reporting.
69  string time_zone = 5 [(google.api.field_behavior) = OUTPUT_ONLY];
70
71  // Output only. Primary currency code, in ISO-4217 format.
72  string currency_code = 6 [(google.api.field_behavior) = OUTPUT_ONLY];
73
74  // Optional. Currency codes that can be used as an alternative to the primary
75  // currency code for trafficking Line Items.
76  repeated string secondary_currency_codes = 7
77      [(google.api.field_behavior) = OPTIONAL];
78
79  // Output only. Top most [Ad Unit](google.ads.admanager.v1.AdUnit) to which
80  // descendant Ad Units can be added.
81  // Format: networks/{network_code}/adUnit/{ad_unit_id}
82  string effective_root_ad_unit = 8 [
83    (google.api.field_behavior) = OUTPUT_ONLY,
84    (google.api.resource_reference) = {
85      type: "admanager.googleapis.com/AdUnit"
86    }
87  ];
88
89  // Output only. Whether this is a test network.
90  bool test_network = 10 [(google.api.field_behavior) = OUTPUT_ONLY];
91
92  // Output only. Network ID.
93  int64 network_id = 11 [(google.api.field_behavior) = OUTPUT_ONLY];
94}
95
96// Request to get Network
97message GetNetworkRequest {
98  // Required. Resource name of Network.
99  // Format: networks/{network_code}
100  string name = 1 [
101    (google.api.field_behavior) = REQUIRED,
102    (google.api.resource_reference) = {
103      type: "admanager.googleapis.com/Network"
104    }
105  ];
106}
107