google-cloud-resource_manager-v3 0.4.0 → 0.5.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (61) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +1 -1
  3. data/lib/google/cloud/resource_manager/v3/folders/client.rb +47 -35
  4. data/lib/google/cloud/resource_manager/v3/folders/operations.rb +2 -2
  5. data/lib/google/cloud/resource_manager/v3/folders/rest/client.rb +47 -35
  6. data/lib/google/cloud/resource_manager/v3/folders/rest/operations.rb +2 -2
  7. data/lib/google/cloud/resource_manager/v3/organizations/client.rb +12 -10
  8. data/lib/google/cloud/resource_manager/v3/organizations/rest/client.rb +12 -10
  9. data/lib/google/cloud/resource_manager/v3/projects/client.rb +53 -54
  10. data/lib/google/cloud/resource_manager/v3/projects/operations.rb +2 -2
  11. data/lib/google/cloud/resource_manager/v3/projects/rest/client.rb +53 -54
  12. data/lib/google/cloud/resource_manager/v3/projects/rest/operations.rb +2 -2
  13. data/lib/google/cloud/resource_manager/v3/rest.rb +1 -0
  14. data/lib/google/cloud/resource_manager/v3/tag_bindings/client.rb +115 -17
  15. data/lib/google/cloud/resource_manager/v3/tag_bindings/operations.rb +2 -2
  16. data/lib/google/cloud/resource_manager/v3/tag_bindings/rest/client.rb +96 -17
  17. data/lib/google/cloud/resource_manager/v3/tag_bindings/rest/operations.rb +2 -2
  18. data/lib/google/cloud/resource_manager/v3/tag_bindings/rest/service_stub.rb +57 -0
  19. data/lib/google/cloud/resource_manager/v3/tag_bindings/rest.rb +1 -1
  20. data/lib/google/cloud/resource_manager/v3/tag_bindings.rb +1 -1
  21. data/lib/google/cloud/resource_manager/v3/tag_holds/client.rb +640 -0
  22. data/lib/google/cloud/resource_manager/v3/tag_holds/credentials.rb +52 -0
  23. data/lib/google/cloud/resource_manager/v3/tag_holds/operations.rb +768 -0
  24. data/lib/google/cloud/resource_manager/v3/tag_holds/paths.rb +64 -0
  25. data/lib/google/cloud/resource_manager/v3/tag_holds/rest/client.rb +533 -0
  26. data/lib/google/cloud/resource_manager/v3/tag_holds/rest/operations.rb +793 -0
  27. data/lib/google/cloud/resource_manager/v3/tag_holds/rest/service_stub.rb +226 -0
  28. data/lib/google/cloud/resource_manager/v3/tag_holds/rest.rb +57 -0
  29. data/lib/google/cloud/resource_manager/v3/tag_holds.rb +60 -0
  30. data/lib/google/cloud/resource_manager/v3/tag_keys/client.rb +114 -24
  31. data/lib/google/cloud/resource_manager/v3/tag_keys/operations.rb +2 -2
  32. data/lib/google/cloud/resource_manager/v3/tag_keys/rest/client.rb +99 -24
  33. data/lib/google/cloud/resource_manager/v3/tag_keys/rest/operations.rb +2 -2
  34. data/lib/google/cloud/resource_manager/v3/tag_keys/rest/service_stub.rb +57 -0
  35. data/lib/google/cloud/resource_manager/v3/tag_values/client.rb +123 -29
  36. data/lib/google/cloud/resource_manager/v3/tag_values/operations.rb +2 -2
  37. data/lib/google/cloud/resource_manager/v3/tag_values/rest/client.rb +108 -29
  38. data/lib/google/cloud/resource_manager/v3/tag_values/rest/operations.rb +2 -2
  39. data/lib/google/cloud/resource_manager/v3/tag_values/rest/service_stub.rb +57 -0
  40. data/lib/google/cloud/resource_manager/v3/version.rb +1 -1
  41. data/lib/google/cloud/resource_manager/v3.rb +1 -0
  42. data/lib/google/cloud/resourcemanager/v3/folders_services_pb.rb +23 -17
  43. data/lib/google/cloud/resourcemanager/v3/projects_services_pb.rb +16 -13
  44. data/lib/google/cloud/resourcemanager/v3/tag_bindings_pb.rb +22 -0
  45. data/lib/google/cloud/resourcemanager/v3/tag_bindings_services_pb.rb +7 -5
  46. data/lib/google/cloud/resourcemanager/v3/tag_holds_pb.rb +63 -0
  47. data/lib/google/cloud/resourcemanager/v3/tag_holds_services_pb.rb +54 -0
  48. data/lib/google/cloud/resourcemanager/v3/tag_keys_pb.rb +11 -0
  49. data/lib/google/cloud/resourcemanager/v3/tag_keys_services_pb.rb +6 -2
  50. data/lib/google/cloud/resourcemanager/v3/tag_values_pb.rb +4 -0
  51. data/lib/google/cloud/resourcemanager/v3/tag_values_services_pb.rb +7 -4
  52. data/proto_docs/google/api/client.rb +67 -4
  53. data/proto_docs/google/cloud/resourcemanager/v3/folders.rb +25 -19
  54. data/proto_docs/google/cloud/resourcemanager/v3/organizations.rb +13 -11
  55. data/proto_docs/google/cloud/resourcemanager/v3/projects.rb +41 -45
  56. data/proto_docs/google/cloud/resourcemanager/v3/tag_bindings.rb +104 -15
  57. data/proto_docs/google/cloud/resourcemanager/v3/tag_holds.rb +161 -0
  58. data/proto_docs/google/cloud/resourcemanager/v3/tag_keys.rb +93 -27
  59. data/proto_docs/google/cloud/resourcemanager/v3/tag_values.rb +52 -29
  60. data/proto_docs/google/iam/v1/policy.rb +8 -4
  61. metadata +14 -2
@@ -22,9 +22,8 @@ module Google
22
22
  module ResourceManager
23
23
  module V3
24
24
  # A TagBinding represents a connection between a TagValue and a cloud
25
- # resource (currently project, folder, or organization). Once a TagBinding is
26
- # created, the TagValue is applied to all the descendants of the cloud
27
- # resource.
25
+ # resource Once a TagBinding is created, the TagValue is applied to all the
26
+ # descendants of the Google Cloud resource.
28
27
  # @!attribute [r] name
29
28
  # @return [::String]
30
29
  # Output only. The name of the TagBinding. This is a String of the form:
@@ -38,6 +37,15 @@ module Google
38
37
  # @return [::String]
39
38
  # The TagValue of the TagBinding.
40
39
  # Must be of the form `tagValues/456`.
40
+ # @!attribute [rw] tag_value_namespaced_name
41
+ # @return [::String]
42
+ # The namespaced name for the TagValue of the TagBinding.
43
+ # Must be in the format
44
+ # `{parent_id}/{tag_key_short_name}/{short_name}`.
45
+ #
46
+ # For methods that support TagValue namespaced name, only one of
47
+ # tag_value_namespaced_name or tag_value may be filled. Requests with both
48
+ # fields will be rejected.
41
49
  class TagBinding
42
50
  include ::Google::Protobuf::MessageExts
43
51
  extend ::Google::Protobuf::MessageExts::ClassMethods
@@ -55,8 +63,8 @@ module Google
55
63
  # Required. The TagBinding to be created.
56
64
  # @!attribute [rw] validate_only
57
65
  # @return [::Boolean]
58
- # Optional. Set to true to perform the validations necessary for creating the resource,
59
- # but not actually perform the action.
66
+ # Optional. Set to true to perform the validations necessary for creating the
67
+ # resource, but not actually perform the action.
60
68
  class CreateTagBindingRequest
61
69
  include ::Google::Protobuf::MessageExts
62
70
  extend ::Google::Protobuf::MessageExts::ClassMethods
@@ -82,18 +90,18 @@ module Google
82
90
  # The request message to list all TagBindings for a parent.
83
91
  # @!attribute [rw] parent
84
92
  # @return [::String]
85
- # Required. The full resource name of a resource for which you want to list existing
86
- # TagBindings.
87
- # E.g. "//cloudresourcemanager.googleapis.com/projects/123"
93
+ # Required. The full resource name of a resource for which you want to list
94
+ # existing TagBindings. E.g.
95
+ # "//cloudresourcemanager.googleapis.com/projects/123"
88
96
  # @!attribute [rw] page_size
89
97
  # @return [::Integer]
90
- # Optional. The maximum number of TagBindings to return in the response. The server
91
- # allows a maximum of 300 TagBindings to return. If unspecified, the server
92
- # will use 100 as the default.
98
+ # Optional. The maximum number of TagBindings to return in the response. The
99
+ # server allows a maximum of 300 TagBindings to return. If unspecified, the
100
+ # server will use 100 as the default.
93
101
  # @!attribute [rw] page_token
94
102
  # @return [::String]
95
- # Optional. A pagination token returned from a previous call to `ListTagBindings`
96
- # that indicates where this listing should continue from.
103
+ # Optional. A pagination token returned from a previous call to
104
+ # `ListTagBindings` that indicates where this listing should continue from.
97
105
  class ListTagBindingsRequest
98
106
  include ::Google::Protobuf::MessageExts
99
107
  extend ::Google::Protobuf::MessageExts::ClassMethods
@@ -102,8 +110,7 @@ module Google
102
110
  # The ListTagBindings response.
103
111
  # @!attribute [rw] tag_bindings
104
112
  # @return [::Array<::Google::Cloud::ResourceManager::V3::TagBinding>]
105
- # A possibly paginated list of TagBindings for the specified TagValue or
106
- # resource.
113
+ # A possibly paginated list of TagBindings for the specified resource.
107
114
  # @!attribute [rw] next_page_token
108
115
  # @return [::String]
109
116
  # Pagination token.
@@ -121,6 +128,88 @@ module Google
121
128
  include ::Google::Protobuf::MessageExts
122
129
  extend ::Google::Protobuf::MessageExts::ClassMethods
123
130
  end
131
+
132
+ # The request message to ListEffectiveTags
133
+ # @!attribute [rw] parent
134
+ # @return [::String]
135
+ # Required. The full resource name of a resource for which you want to list
136
+ # the effective tags. E.g.
137
+ # "//cloudresourcemanager.googleapis.com/projects/123"
138
+ # @!attribute [rw] page_size
139
+ # @return [::Integer]
140
+ # Optional. The maximum number of effective tags to return in the response.
141
+ # The server allows a maximum of 300 effective tags to return in a single
142
+ # page. If unspecified, the server will use 100 as the default.
143
+ # @!attribute [rw] page_token
144
+ # @return [::String]
145
+ # Optional. A pagination token returned from a previous call to
146
+ # `ListEffectiveTags` that indicates from where this listing should continue.
147
+ class ListEffectiveTagsRequest
148
+ include ::Google::Protobuf::MessageExts
149
+ extend ::Google::Protobuf::MessageExts::ClassMethods
150
+ end
151
+
152
+ # The response of ListEffectiveTags.
153
+ # @!attribute [rw] effective_tags
154
+ # @return [::Array<::Google::Cloud::ResourceManager::V3::EffectiveTag>]
155
+ # A possibly paginated list of effective tags for the specified resource.
156
+ # @!attribute [rw] next_page_token
157
+ # @return [::String]
158
+ # Pagination token.
159
+ #
160
+ # If the result set is too large to fit in a single response, this token
161
+ # is returned. It encodes the position of the current result cursor.
162
+ # Feeding this value into a new list request with the `page_token` parameter
163
+ # gives the next page of the results.
164
+ #
165
+ # When `next_page_token` is not filled in, there is no next page and
166
+ # the list returned is the last page in the result set.
167
+ #
168
+ # Pagination tokens have a limited lifetime.
169
+ class ListEffectiveTagsResponse
170
+ include ::Google::Protobuf::MessageExts
171
+ extend ::Google::Protobuf::MessageExts::ClassMethods
172
+ end
173
+
174
+ # An EffectiveTag represents a tag that applies to a resource during policy
175
+ # evaluation. Tags can be either directly bound to a resource or inherited from
176
+ # its ancestor. EffectiveTag contains the name and
177
+ # namespaced_name of the tag value and tag key, with additional fields of
178
+ # `inherited` to indicate the inheritance status of the effective tag.
179
+ # @!attribute [rw] tag_value
180
+ # @return [::String]
181
+ # Resource name for TagValue in the format `tagValues/456`.
182
+ # @!attribute [rw] namespaced_tag_value
183
+ # @return [::String]
184
+ # The namespaced name of the TagValue. Can be in the form
185
+ # `{organization_id}/{tag_key_short_name}/{tag_value_short_name}` or
186
+ # `{project_id}/{tag_key_short_name}/{tag_value_short_name}` or
187
+ # `{project_number}/{tag_key_short_name}/{tag_value_short_name}`.
188
+ # @!attribute [rw] tag_key
189
+ # @return [::String]
190
+ # The name of the TagKey, in the format `tagKeys/{id}`, such as
191
+ # `tagKeys/123`.
192
+ # @!attribute [rw] namespaced_tag_key
193
+ # @return [::String]
194
+ # The namespaced name of the TagKey. Can be in the form
195
+ # `{organization_id}/{tag_key_short_name}` or
196
+ # `{project_id}/{tag_key_short_name}` or
197
+ # `{project_number}/{tag_key_short_name}`.
198
+ # @!attribute [rw] tag_key_parent_name
199
+ # @return [::String]
200
+ # The parent name of the tag key.
201
+ # Must be in the format `organizations/{organization_id}` or
202
+ # `projects/{project_number}`
203
+ # @!attribute [rw] inherited
204
+ # @return [::Boolean]
205
+ # Indicates the inheritance status of a tag value
206
+ # attached to the given resource. If the tag value is inherited from one of
207
+ # the resource's ancestors, inherited will be true. If false, then the tag
208
+ # value is directly attached to the resource, inherited will be false.
209
+ class EffectiveTag
210
+ include ::Google::Protobuf::MessageExts
211
+ extend ::Google::Protobuf::MessageExts::ClassMethods
212
+ end
124
213
  end
125
214
  end
126
215
  end
@@ -0,0 +1,161 @@
1
+ # frozen_string_literal: true
2
+
3
+ # Copyright 2023 Google LLC
4
+ #
5
+ # Licensed under the Apache License, Version 2.0 (the "License");
6
+ # you may not use this file except in compliance with the License.
7
+ # You may obtain a copy of the License at
8
+ #
9
+ # https://www.apache.org/licenses/LICENSE-2.0
10
+ #
11
+ # Unless required by applicable law or agreed to in writing, software
12
+ # distributed under the License is distributed on an "AS IS" BASIS,
13
+ # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14
+ # See the License for the specific language governing permissions and
15
+ # limitations under the License.
16
+
17
+ # Auto-generated by gapic-generator-ruby. DO NOT EDIT!
18
+
19
+
20
+ module Google
21
+ module Cloud
22
+ module ResourceManager
23
+ module V3
24
+ # A TagHold represents the use of a TagValue that is not captured by
25
+ # TagBindings. If a TagValue has any TagHolds, deletion will be blocked.
26
+ # This resource is intended to be created in the same cloud location as the
27
+ # `holder`.
28
+ # @!attribute [r] name
29
+ # @return [::String]
30
+ # Output only. The resource name of a TagHold. This is a String of the form:
31
+ # `tagValues/{tag-value-id}/tagHolds/{tag-hold-id}`
32
+ # (e.g. `tagValues/123/tagHolds/456`). This resource name is generated by
33
+ # the server.
34
+ # @!attribute [rw] holder
35
+ # @return [::String]
36
+ # Required. The name of the resource where the TagValue is being used. Must
37
+ # be less than 200 characters. E.g.
38
+ # `//compute.googleapis.com/compute/projects/myproject/regions/us-east-1/instanceGroupManagers/instance-group`
39
+ # @!attribute [rw] origin
40
+ # @return [::String]
41
+ # Optional. An optional string representing the origin of this request. This
42
+ # field should include human-understandable information to distinguish
43
+ # origins from each other. Must be less than 200 characters. E.g.
44
+ # `migs-35678234`
45
+ # @!attribute [rw] help_link
46
+ # @return [::String]
47
+ # Optional. A URL where an end user can learn more about removing this hold.
48
+ # E.g.
49
+ # `https://cloud.google.com/resource-manager/docs/tags/tags-creating-and-managing`
50
+ # @!attribute [r] create_time
51
+ # @return [::Google::Protobuf::Timestamp]
52
+ # Output only. The time this TagHold was created.
53
+ class TagHold
54
+ include ::Google::Protobuf::MessageExts
55
+ extend ::Google::Protobuf::MessageExts::ClassMethods
56
+ end
57
+
58
+ # The request message to create a TagHold.
59
+ # @!attribute [rw] parent
60
+ # @return [::String]
61
+ # Required. The resource name of the TagHold's parent TagValue. Must be of
62
+ # the form: `tagValues/{tag-value-id}`.
63
+ # @!attribute [rw] tag_hold
64
+ # @return [::Google::Cloud::ResourceManager::V3::TagHold]
65
+ # Required. The TagHold to be created.
66
+ # @!attribute [rw] validate_only
67
+ # @return [::Boolean]
68
+ # Optional. Set to true to perform the validations necessary for creating the
69
+ # resource, but not actually perform the action.
70
+ class CreateTagHoldRequest
71
+ include ::Google::Protobuf::MessageExts
72
+ extend ::Google::Protobuf::MessageExts::ClassMethods
73
+ end
74
+
75
+ # Runtime operation information for creating a TagHold.
76
+ # (-- The metadata is currently empty, but may include information in the
77
+ # future. --)
78
+ class CreateTagHoldMetadata
79
+ include ::Google::Protobuf::MessageExts
80
+ extend ::Google::Protobuf::MessageExts::ClassMethods
81
+ end
82
+
83
+ # The request message to delete a TagHold.
84
+ # @!attribute [rw] name
85
+ # @return [::String]
86
+ # Required. The resource name of the TagHold to delete. Must be of the form:
87
+ # `tagValues/{tag-value-id}/tagHolds/{tag-hold-id}`.
88
+ # @!attribute [rw] validate_only
89
+ # @return [::Boolean]
90
+ # Optional. Set to true to perform the validations necessary for deleting the
91
+ # resource, but not actually perform the action.
92
+ class DeleteTagHoldRequest
93
+ include ::Google::Protobuf::MessageExts
94
+ extend ::Google::Protobuf::MessageExts::ClassMethods
95
+ end
96
+
97
+ # Runtime operation information for deleting a TagHold.
98
+ # (-- The metadata is currently empty, but may include information in the
99
+ # future. --)
100
+ class DeleteTagHoldMetadata
101
+ include ::Google::Protobuf::MessageExts
102
+ extend ::Google::Protobuf::MessageExts::ClassMethods
103
+ end
104
+
105
+ # The request message for listing the TagHolds under a TagValue.
106
+ # @!attribute [rw] parent
107
+ # @return [::String]
108
+ # Required. The resource name of the parent TagValue. Must be of the form:
109
+ # `tagValues/{tag-value-id}`.
110
+ # @!attribute [rw] page_size
111
+ # @return [::Integer]
112
+ # Optional. The maximum number of TagHolds to return in the response. The
113
+ # server allows a maximum of 300 TagHolds to return. If unspecified, the
114
+ # server will use 100 as the default.
115
+ # @!attribute [rw] page_token
116
+ # @return [::String]
117
+ # Optional. A pagination token returned from a previous call to
118
+ # `ListTagHolds` that indicates where this listing should continue from.
119
+ # @!attribute [rw] filter
120
+ # @return [::String]
121
+ # Optional. Criteria used to select a subset of TagHolds parented by the
122
+ # TagValue to return. This field follows the syntax defined by aip.dev/160;
123
+ # the `holder` and `origin` fields are supported for filtering. Currently
124
+ # only `AND` syntax is supported. Some example queries are:
125
+ #
126
+ # * `holder =
127
+ # //compute.googleapis.com/compute/projects/myproject/regions/us-east-1/instanceGroupManagers/instance-group`
128
+ # * `origin = 35678234`
129
+ # * `holder =
130
+ # //compute.googleapis.com/compute/projects/myproject/regions/us-east-1/instanceGroupManagers/instance-group
131
+ # AND origin = 35678234`
132
+ class ListTagHoldsRequest
133
+ include ::Google::Protobuf::MessageExts
134
+ extend ::Google::Protobuf::MessageExts::ClassMethods
135
+ end
136
+
137
+ # The ListTagHolds response.
138
+ # @!attribute [rw] tag_holds
139
+ # @return [::Array<::Google::Cloud::ResourceManager::V3::TagHold>]
140
+ # A possibly paginated list of TagHolds.
141
+ # @!attribute [rw] next_page_token
142
+ # @return [::String]
143
+ # Pagination token.
144
+ #
145
+ # If the result set is too large to fit in a single response, this token
146
+ # is returned. It encodes the position of the current result cursor.
147
+ # Feeding this value into a new list request with the `page_token` parameter
148
+ # gives the next page of the results.
149
+ #
150
+ # When `next_page_token` is not filled in, there is no next page and
151
+ # the list returned is the last page in the result set.
152
+ #
153
+ # Pagination tokens have a limited lifetime.
154
+ class ListTagHoldsResponse
155
+ include ::Google::Protobuf::MessageExts
156
+ extend ::Google::Protobuf::MessageExts::ClassMethods
157
+ end
158
+ end
159
+ end
160
+ end
161
+ end
@@ -29,12 +29,15 @@ module Google
29
29
  # the TagKey.
30
30
  # @!attribute [rw] parent
31
31
  # @return [::String]
32
- # Immutable. The resource name of the new TagKey's parent.
33
- # Must be of the form `organizations/{org_id}`.
32
+ # Immutable. The resource name of the TagKey's parent. A TagKey can be
33
+ # parented by an Organization or a Project. For a TagKey parented by an
34
+ # Organization, its parent must be in the form `organizations/{org_id}`. For
35
+ # a TagKey parented by a Project, its parent can be in the form
36
+ # `projects/{project_id}` or `projects/{project_number}`.
34
37
  # @!attribute [rw] short_name
35
38
  # @return [::String]
36
- # Required. Immutable. The user friendly name for a TagKey. The short name should be
37
- # unique for TagKeys within the same tag namespace.
39
+ # Required. Immutable. The user friendly name for a TagKey. The short name
40
+ # should be unique for TagKeys within the same tag namespace.
38
41
  #
39
42
  # The short name must be 1-63 characters, beginning and ending with
40
43
  # an alphanumeric character ([a-z0-9A-Z]) with dashes (-), underscores (_),
@@ -44,7 +47,8 @@ module Google
44
47
  # Output only. Immutable. Namespaced name of the TagKey.
45
48
  # @!attribute [rw] description
46
49
  # @return [::String]
47
- # Optional. User-assigned description of the TagKey. Must not exceed 256 characters.
50
+ # Optional. User-assigned description of the TagKey. Must not exceed 256
51
+ # characters.
48
52
  #
49
53
  # Read-write.
50
54
  # @!attribute [r] create_time
@@ -55,23 +59,49 @@ module Google
55
59
  # Output only. Update time.
56
60
  # @!attribute [rw] etag
57
61
  # @return [::String]
58
- # Optional. Entity tag which users can pass to prevent race conditions. This field is
59
- # always set in server responses. See UpdateTagKeyRequest for details.
62
+ # Optional. Entity tag which users can pass to prevent race conditions. This
63
+ # field is always set in server responses. See UpdateTagKeyRequest for
64
+ # details.
65
+ # @!attribute [rw] purpose
66
+ # @return [::Google::Cloud::ResourceManager::V3::Purpose]
67
+ # Optional. A purpose denotes that this Tag is intended for use in policies
68
+ # of a specific policy engine, and will involve that policy engine in
69
+ # management operations involving this Tag. A purpose does not grant a
70
+ # policy engine exclusive rights to the Tag, and it may be referenced by
71
+ # other policy engines.
72
+ #
73
+ # A purpose cannot be changed once set.
74
+ # @!attribute [rw] purpose_data
75
+ # @return [::Google::Protobuf::Map{::String => ::String}]
76
+ # Optional. Purpose data corresponds to the policy system that the tag is
77
+ # intended for. See documentation for `Purpose` for formatting of this field.
78
+ #
79
+ # Purpose data cannot be changed once set.
60
80
  class TagKey
61
81
  include ::Google::Protobuf::MessageExts
62
82
  extend ::Google::Protobuf::MessageExts::ClassMethods
83
+
84
+ # @!attribute [rw] key
85
+ # @return [::String]
86
+ # @!attribute [rw] value
87
+ # @return [::String]
88
+ class PurposeDataEntry
89
+ include ::Google::Protobuf::MessageExts
90
+ extend ::Google::Protobuf::MessageExts::ClassMethods
91
+ end
63
92
  end
64
93
 
65
94
  # The request message for listing all TagKeys under a parent resource.
66
95
  # @!attribute [rw] parent
67
96
  # @return [::String]
68
- # Required. The resource name of the new TagKey's parent.
69
- # Must be of the form `folders/{folder_id}` or `organizations/{org_id}`.
97
+ # Required. The resource name of the TagKey's parent.
98
+ # Must be of the form `organizations/{org_id}` or `projects/{project_id}` or
99
+ # `projects/{project_number}`
70
100
  # @!attribute [rw] page_size
71
101
  # @return [::Integer]
72
- # Optional. The maximum number of TagKeys to return in the response. The server allows
73
- # a maximum of 300 TagKeys to return. If unspecified, the server will use 100
74
- # as the default.
102
+ # Optional. The maximum number of TagKeys to return in the response. The
103
+ # server allows a maximum of 300 TagKeys to return. If unspecified, the
104
+ # server will use 100 as the default.
75
105
  # @!attribute [rw] page_token
76
106
  # @return [::String]
77
107
  # Optional. A pagination token returned from a previous call to `ListTagKey`
@@ -104,15 +134,27 @@ module Google
104
134
  extend ::Google::Protobuf::MessageExts::ClassMethods
105
135
  end
106
136
 
137
+ # The request message for getting a TagKey by its namespaced name.
138
+ # @!attribute [rw] name
139
+ # @return [::String]
140
+ # Required. A namespaced tag key name in the format
141
+ # `{parentId}/{tagKeyShort}`, such as `42/foo` for a key with short name
142
+ # "foo" under the organization with ID 42 or `r2-d2/bar` for a key with short
143
+ # name "bar" under the project `r2-d2`.
144
+ class GetNamespacedTagKeyRequest
145
+ include ::Google::Protobuf::MessageExts
146
+ extend ::Google::Protobuf::MessageExts::ClassMethods
147
+ end
148
+
107
149
  # The request message for creating a TagKey.
108
150
  # @!attribute [rw] tag_key
109
151
  # @return [::Google::Cloud::ResourceManager::V3::TagKey]
110
- # Required. The TagKey to be created. Only fields `short_name`, `description`,
111
- # and `parent` are considered during the creation request.
152
+ # Required. The TagKey to be created. Only fields `short_name`,
153
+ # `description`, and `parent` are considered during the creation request.
112
154
  # @!attribute [rw] validate_only
113
155
  # @return [::Boolean]
114
- # Optional. Set to true to perform validations necessary for creating the resource, but
115
- # not actually perform the action.
156
+ # Optional. Set to true to perform validations necessary for creating the
157
+ # resource, but not actually perform the action.
116
158
  class CreateTagKeyRequest
117
159
  include ::Google::Protobuf::MessageExts
118
160
  extend ::Google::Protobuf::MessageExts::ClassMethods
@@ -127,10 +169,10 @@ module Google
127
169
  # The request message for updating a TagKey.
128
170
  # @!attribute [rw] tag_key
129
171
  # @return [::Google::Cloud::ResourceManager::V3::TagKey]
130
- # Required. The new definition of the TagKey. Only the `description` and `etag` fields
131
- # can be updated by this request. If the `etag` field is not empty, it
132
- # must match the `etag` field of the existing tag key. Otherwise,
133
- # `FAILED_PRECONDITION` will be returned.
172
+ # Required. The new definition of the TagKey. Only the `description` and
173
+ # `etag` fields can be updated by this request. If the `etag` field is not
174
+ # empty, it must match the `etag` field of the existing tag key. Otherwise,
175
+ # `ABORTED` will be returned.
134
176
  # @!attribute [rw] update_mask
135
177
  # @return [::Google::Protobuf::FieldMask]
136
178
  # Fields to be updated. The mask may only contain `description` or
@@ -154,17 +196,17 @@ module Google
154
196
  # The request message for deleting a TagKey.
155
197
  # @!attribute [rw] name
156
198
  # @return [::String]
157
- # Required. The resource name of a TagKey to be deleted in the format `tagKeys/123`.
158
- # The TagKey cannot be a parent of any existing TagValues or it will not be
159
- # deleted successfully.
199
+ # Required. The resource name of a TagKey to be deleted in the format
200
+ # `tagKeys/123`. The TagKey cannot be a parent of any existing TagValues or
201
+ # it will not be deleted successfully.
160
202
  # @!attribute [rw] validate_only
161
203
  # @return [::Boolean]
162
- # Optional. Set as true to perform validations necessary for deletion, but not actually
163
- # perform the action.
204
+ # Optional. Set as true to perform validations necessary for deletion, but
205
+ # not actually perform the action.
164
206
  # @!attribute [rw] etag
165
207
  # @return [::String]
166
- # Optional. The etag known to the client for the expected state of the TagKey. This is
167
- # to be used for optimistic concurrency.
208
+ # Optional. The etag known to the client for the expected state of the
209
+ # TagKey. This is to be used for optimistic concurrency.
168
210
  class DeleteTagKeyRequest
169
211
  include ::Google::Protobuf::MessageExts
170
212
  extend ::Google::Protobuf::MessageExts::ClassMethods
@@ -175,6 +217,30 @@ module Google
175
217
  include ::Google::Protobuf::MessageExts
176
218
  extend ::Google::Protobuf::MessageExts::ClassMethods
177
219
  end
220
+
221
+ # A purpose for each policy engine requiring such an integration. A single
222
+ # policy engine may have multiple purposes defined, however a TagKey may only
223
+ # specify a single purpose.
224
+ module Purpose
225
+ # Unspecified purpose.
226
+ PURPOSE_UNSPECIFIED = 0
227
+
228
+ # Purpose for Compute Engine firewalls.
229
+ # A corresponding `purpose_data` should be set for the network the tag is
230
+ # intended for. The key should be `network` and the value should be in
231
+ # either of these two formats:
232
+ #
233
+ # -
234
+ # `https://www.googleapis.com/compute/{compute_version}/projects/{project_id}/global/networks/{network_id}`
235
+ # - `{project_id}/{network_name}`
236
+ #
237
+ # Examples:
238
+ #
239
+ # -
240
+ # `https://www.googleapis.com/compute/staging_v1/projects/fail-closed-load-testing/global/networks/6992953698831725600`
241
+ # - `fail-closed-load-testing/load-testing-network`
242
+ GCE_FIREWALL = 1
243
+ end
178
244
  end
179
245
  end
180
246
  end
@@ -32,16 +32,18 @@ module Google
32
32
  # Must be of the form `tagKeys/{tag_key_id}`.
33
33
  # @!attribute [rw] short_name
34
34
  # @return [::String]
35
- # Required. Immutable. User-assigned short name for TagValue. The short name should be
36
- # unique for TagValues within the same parent TagKey.
35
+ # Required. Immutable. User-assigned short name for TagValue. The short name
36
+ # should be unique for TagValues within the same parent TagKey.
37
37
  #
38
38
  # The short name must be 63 characters or less, beginning and ending with
39
39
  # an alphanumeric character ([a-z0-9A-Z]) with dashes (-), underscores (_),
40
40
  # dots (.), and alphanumerics between.
41
41
  # @!attribute [r] namespaced_name
42
42
  # @return [::String]
43
- # Output only. Namespaced name of the TagValue. Must be in the format
44
- # `{organization_id}/{tag_key_short_name}/{short_name}`.
43
+ # Output only. The namespaced name of the TagValue. Can be in the form
44
+ # `{organization_id}/{tag_key_short_name}/{tag_value_short_name}` or
45
+ # `{project_id}/{tag_key_short_name}/{tag_value_short_name}` or
46
+ # `{project_number}/{tag_key_short_name}/{tag_value_short_name}`.
45
47
  # @!attribute [rw] description
46
48
  # @return [::String]
47
49
  # Optional. User-assigned description of the TagValue.
@@ -56,27 +58,29 @@ module Google
56
58
  # Output only. Update time.
57
59
  # @!attribute [rw] etag
58
60
  # @return [::String]
59
- # Optional. Entity tag which users can pass to prevent race conditions. This field is
60
- # always set in server responses. See UpdateTagValueRequest for details.
61
+ # Optional. Entity tag which users can pass to prevent race conditions. This
62
+ # field is always set in server responses. See UpdateTagValueRequest for
63
+ # details.
61
64
  class TagValue
62
65
  include ::Google::Protobuf::MessageExts
63
66
  extend ::Google::Protobuf::MessageExts::ClassMethods
64
67
  end
65
68
 
66
69
  # The request message for listing TagValues for the specified TagKey.
70
+ # Resource name for TagKey, parent of the TagValues to be listed,
71
+ # in the format `tagKeys/123`.
67
72
  # @!attribute [rw] parent
68
73
  # @return [::String]
69
- # Required. Resource name for TagKey, parent of the TagValues to be listed,
70
- # in the format `tagKeys/123`.
74
+ # Required.
71
75
  # @!attribute [rw] page_size
72
76
  # @return [::Integer]
73
- # Optional. The maximum number of TagValues to return in the response. The server
74
- # allows a maximum of 300 TagValues to return. If unspecified, the server
75
- # will use 100 as the default.
77
+ # Optional. The maximum number of TagValues to return in the response. The
78
+ # server allows a maximum of 300 TagValues to return. If unspecified, the
79
+ # server will use 100 as the default.
76
80
  # @!attribute [rw] page_token
77
81
  # @return [::String]
78
- # Optional. A pagination token returned from a previous call to `ListTagValues`
79
- # that indicates where this listing should continue from.
82
+ # Optional. A pagination token returned from a previous call to
83
+ # `ListTagValues` that indicates where this listing should continue from.
80
84
  class ListTagValuesRequest
81
85
  include ::Google::Protobuf::MessageExts
82
86
  extend ::Google::Protobuf::MessageExts::ClassMethods
@@ -100,21 +104,39 @@ module Google
100
104
  # The request message for getting a TagValue.
101
105
  # @!attribute [rw] name
102
106
  # @return [::String]
103
- # Required. Resource name for TagValue to be fetched in the format `tagValues/456`.
107
+ # Required. Resource name for TagValue to be fetched in the format
108
+ # `tagValues/456`.
104
109
  class GetTagValueRequest
105
110
  include ::Google::Protobuf::MessageExts
106
111
  extend ::Google::Protobuf::MessageExts::ClassMethods
107
112
  end
108
113
 
114
+ # The request message for getting a TagValue by its namespaced name.
115
+ # @!attribute [rw] name
116
+ # @return [::String]
117
+ # Required. A namespaced tag value name in the following format:
118
+ #
119
+ # `{parentId}/{tagKeyShort}/{tagValueShort}`
120
+ #
121
+ # Examples:
122
+ # - `42/foo/abc` for a value with short name "abc" under the key with short
123
+ # name "foo" under the organization with ID 42
124
+ # - `r2-d2/bar/xyz` for a value with short name "xyz" under the key with
125
+ # short name "bar" under the project with ID "r2-d2"
126
+ class GetNamespacedTagValueRequest
127
+ include ::Google::Protobuf::MessageExts
128
+ extend ::Google::Protobuf::MessageExts::ClassMethods
129
+ end
130
+
109
131
  # The request message for creating a TagValue.
110
132
  # @!attribute [rw] tag_value
111
133
  # @return [::Google::Cloud::ResourceManager::V3::TagValue]
112
- # Required. The TagValue to be created. Only fields `short_name`, `description`,
113
- # and `parent` are considered during the creation request.
134
+ # Required. The TagValue to be created. Only fields `short_name`,
135
+ # `description`, and `parent` are considered during the creation request.
114
136
  # @!attribute [rw] validate_only
115
137
  # @return [::Boolean]
116
- # Optional. Set as true to perform the validations necessary for creating the resource,
117
- # but not actually perform the action.
138
+ # Optional. Set as true to perform the validations necessary for creating the
139
+ # resource, but not actually perform the action.
118
140
  class CreateTagValueRequest
119
141
  include ::Google::Protobuf::MessageExts
120
142
  extend ::Google::Protobuf::MessageExts::ClassMethods
@@ -129,17 +151,17 @@ module Google
129
151
  # The request message for updating a TagValue.
130
152
  # @!attribute [rw] tag_value
131
153
  # @return [::Google::Cloud::ResourceManager::V3::TagValue]
132
- # Required. The new definition of the TagValue. Only fields `description` and `etag`
133
- # fields can be updated by this request. If the `etag` field is nonempty, it
134
- # must match the `etag` field of the existing ControlGroup. Otherwise,
135
- # `FAILED_PRECONDITION` will be returned.
154
+ # Required. The new definition of the TagValue. Only fields `description` and
155
+ # `etag` fields can be updated by this request. If the `etag` field is
156
+ # nonempty, it must match the `etag` field of the existing ControlGroup.
157
+ # Otherwise, `ABORTED` will be returned.
136
158
  # @!attribute [rw] update_mask
137
159
  # @return [::Google::Protobuf::FieldMask]
138
160
  # Optional. Fields to be updated.
139
161
  # @!attribute [rw] validate_only
140
162
  # @return [::Boolean]
141
- # Optional. True to perform validations necessary for updating the resource, but not
142
- # actually perform the action.
163
+ # Optional. True to perform validations necessary for updating the resource,
164
+ # but not actually perform the action.
143
165
  class UpdateTagValueRequest
144
166
  include ::Google::Protobuf::MessageExts
145
167
  extend ::Google::Protobuf::MessageExts::ClassMethods
@@ -154,15 +176,16 @@ module Google
154
176
  # The request message for deleting a TagValue.
155
177
  # @!attribute [rw] name
156
178
  # @return [::String]
157
- # Required. Resource name for TagValue to be deleted in the format tagValues/456.
179
+ # Required. Resource name for TagValue to be deleted in the format
180
+ # tagValues/456.
158
181
  # @!attribute [rw] validate_only
159
182
  # @return [::Boolean]
160
- # Optional. Set as true to perform the validations necessary for deletion, but not
161
- # actually perform the action.
183
+ # Optional. Set as true to perform the validations necessary for deletion,
184
+ # but not actually perform the action.
162
185
  # @!attribute [rw] etag
163
186
  # @return [::String]
164
- # Optional. The etag known to the client for the expected state of the TagValue. This
165
- # is to be used for optimistic concurrency.
187
+ # Optional. The etag known to the client for the expected state of the
188
+ # TagValue. This is to be used for optimistic concurrency.
166
189
  class DeleteTagValueRequest
167
190
  include ::Google::Protobuf::MessageExts
168
191
  extend ::Google::Protobuf::MessageExts::ClassMethods