google-api-client 0.9.28 → 0.10.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (138) hide show
  1. checksums.yaml +4 -4
  2. data/.travis.yml +7 -4
  3. data/CHANGELOG.md +10 -0
  4. data/api_names.yaml +36512 -36326
  5. data/generated/google/apis/adexchangebuyer2_v2beta1.rb +1 -1
  6. data/generated/google/apis/adexchangebuyer2_v2beta1/classes.rb +41 -41
  7. data/generated/google/apis/adexchangebuyer2_v2beta1/representations.rb +13 -13
  8. data/generated/google/apis/adexchangebuyer2_v2beta1/service.rb +110 -110
  9. data/generated/google/apis/adsense_v1_4.rb +1 -1
  10. data/generated/google/apis/adsensehost_v4_1.rb +1 -1
  11. data/generated/google/apis/analyticsreporting_v4.rb +3 -3
  12. data/generated/google/apis/analyticsreporting_v4/classes.rb +845 -845
  13. data/generated/google/apis/analyticsreporting_v4/representations.rb +184 -184
  14. data/generated/google/apis/androidenterprise_v1.rb +1 -1
  15. data/generated/google/apis/androidenterprise_v1/classes.rb +5 -5
  16. data/generated/google/apis/androidenterprise_v1/service.rb +3 -1
  17. data/generated/google/apis/appstate_v1.rb +1 -1
  18. data/generated/google/apis/calendar_v3.rb +1 -1
  19. data/generated/google/apis/classroom_v1.rb +22 -25
  20. data/generated/google/apis/classroom_v1/classes.rb +998 -907
  21. data/generated/google/apis/classroom_v1/representations.rb +240 -240
  22. data/generated/google/apis/classroom_v1/service.rb +1269 -1061
  23. data/generated/google/apis/cloudbuild_v1.rb +1 -1
  24. data/generated/google/apis/cloudbuild_v1/classes.rb +322 -322
  25. data/generated/google/apis/cloudbuild_v1/representations.rb +88 -88
  26. data/generated/google/apis/cloudbuild_v1/service.rb +57 -57
  27. data/generated/google/apis/clouddebugger_v2.rb +4 -4
  28. data/generated/google/apis/clouddebugger_v2/classes.rb +311 -311
  29. data/generated/google/apis/clouddebugger_v2/representations.rb +92 -92
  30. data/generated/google/apis/clouddebugger_v2/service.rb +41 -41
  31. data/generated/google/apis/cloudkms_v1beta1.rb +1 -1
  32. data/generated/google/apis/cloudkms_v1beta1/classes.rb +611 -611
  33. data/generated/google/apis/cloudkms_v1beta1/representations.rb +124 -124
  34. data/generated/google/apis/cloudkms_v1beta1/service.rb +254 -248
  35. data/generated/google/apis/cloudresourcemanager_v1.rb +1 -1
  36. data/generated/google/apis/cloudresourcemanager_v1/classes.rb +116 -116
  37. data/generated/google/apis/cloudresourcemanager_v1/representations.rb +28 -28
  38. data/generated/google/apis/cloudresourcemanager_v1/service.rb +257 -257
  39. data/generated/google/apis/cloudresourcemanager_v1beta1.rb +4 -4
  40. data/generated/google/apis/cloudresourcemanager_v1beta1/classes.rb +394 -394
  41. data/generated/google/apis/cloudresourcemanager_v1beta1/representations.rb +79 -79
  42. data/generated/google/apis/cloudresourcemanager_v1beta1/service.rb +269 -269
  43. data/generated/google/apis/cloudtrace_v1.rb +8 -8
  44. data/generated/google/apis/cloudtrace_v1/classes.rb +90 -84
  45. data/generated/google/apis/cloudtrace_v1/representations.rb +22 -22
  46. data/generated/google/apis/cloudtrace_v1/service.rb +40 -35
  47. data/generated/google/apis/compute_beta.rb +1 -1
  48. data/generated/google/apis/compute_beta/classes.rb +406 -31
  49. data/generated/google/apis/compute_beta/representations.rb +154 -0
  50. data/generated/google/apis/compute_beta/service.rb +262 -9
  51. data/generated/google/apis/compute_v1.rb +1 -1
  52. data/generated/google/apis/compute_v1/classes.rb +17 -20
  53. data/generated/google/apis/content_v2.rb +1 -1
  54. data/generated/google/apis/dataflow_v1b3.rb +1 -1
  55. data/generated/google/apis/dataflow_v1b3/classes.rb +3226 -2847
  56. data/generated/google/apis/dataflow_v1b3/representations.rb +825 -677
  57. data/generated/google/apis/dataflow_v1b3/service.rb +175 -175
  58. data/generated/google/apis/dataproc_v1.rb +2 -2
  59. data/generated/google/apis/dataproc_v1/classes.rb +1213 -1136
  60. data/generated/google/apis/dataproc_v1/representations.rb +262 -244
  61. data/generated/google/apis/dataproc_v1/service.rb +298 -243
  62. data/generated/google/apis/datastore_v1.rb +4 -4
  63. data/generated/google/apis/datastore_v1/classes.rb +728 -728
  64. data/generated/google/apis/datastore_v1/representations.rb +167 -167
  65. data/generated/google/apis/datastore_v1/service.rb +68 -68
  66. data/generated/google/apis/doubleclicksearch_v2.rb +1 -1
  67. data/generated/google/apis/drive_v2.rb +1 -1
  68. data/generated/google/apis/drive_v3.rb +1 -1
  69. data/generated/google/apis/games_configuration_v1configuration.rb +1 -1
  70. data/generated/google/apis/games_management_v1management.rb +1 -1
  71. data/generated/google/apis/games_v1.rb +1 -1
  72. data/generated/google/apis/genomics_v1.rb +7 -7
  73. data/generated/google/apis/genomics_v1/classes.rb +932 -932
  74. data/generated/google/apis/genomics_v1/representations.rb +205 -205
  75. data/generated/google/apis/genomics_v1/service.rb +1228 -1228
  76. data/generated/google/apis/gmail_v1.rb +1 -1
  77. data/generated/google/apis/iam_v1/classes.rb +440 -440
  78. data/generated/google/apis/iam_v1/representations.rb +94 -94
  79. data/generated/google/apis/iam_v1/service.rb +60 -60
  80. data/generated/google/apis/identitytoolkit_v3.rb +1 -1
  81. data/generated/google/apis/identitytoolkit_v3/classes.rb +21 -1
  82. data/generated/google/apis/identitytoolkit_v3/representations.rb +3 -0
  83. data/generated/google/apis/kgsearch_v1/classes.rb +6 -6
  84. data/generated/google/apis/kgsearch_v1/representations.rb +1 -1
  85. data/generated/google/apis/kgsearch_v1/service.rb +21 -21
  86. data/generated/google/apis/language_v1beta1.rb +1 -1
  87. data/generated/google/apis/language_v1beta1/classes.rb +232 -232
  88. data/generated/google/apis/language_v1beta1/representations.rb +75 -75
  89. data/generated/google/apis/logging_v2beta1.rb +1 -1
  90. data/generated/google/apis/logging_v2beta1/classes.rb +345 -337
  91. data/generated/google/apis/logging_v2beta1/representations.rb +55 -55
  92. data/generated/google/apis/logging_v2beta1/service.rb +331 -306
  93. data/generated/google/apis/monitoring_v3.rb +1 -1
  94. data/generated/google/apis/monitoring_v3/classes.rb +253 -253
  95. data/generated/google/apis/monitoring_v3/representations.rb +58 -58
  96. data/generated/google/apis/monitoring_v3/service.rb +135 -135
  97. data/generated/google/apis/people_v1.rb +15 -16
  98. data/generated/google/apis/people_v1/classes.rb +985 -855
  99. data/generated/google/apis/people_v1/representations.rb +227 -220
  100. data/generated/google/apis/people_v1/service.rb +58 -52
  101. data/generated/google/apis/plus_domains_v1.rb +1 -1
  102. data/generated/google/apis/plus_v1.rb +1 -1
  103. data/generated/google/apis/pubsub_v1.rb +1 -1
  104. data/generated/google/apis/pubsub_v1/classes.rb +257 -257
  105. data/generated/google/apis/pubsub_v1/representations.rb +83 -83
  106. data/generated/google/apis/pubsub_v1/service.rb +390 -390
  107. data/generated/google/apis/script_v1.rb +17 -17
  108. data/generated/google/apis/script_v1/classes.rb +149 -141
  109. data/generated/google/apis/script_v1/representations.rb +26 -27
  110. data/generated/google/apis/script_v1/service.rb +9 -8
  111. data/generated/google/apis/sheets_v4.rb +1 -1
  112. data/generated/google/apis/sheets_v4/classes.rb +4223 -4188
  113. data/generated/google/apis/sheets_v4/representations.rb +850 -834
  114. data/generated/google/apis/sheets_v4/service.rb +192 -192
  115. data/generated/google/apis/slides_v1.rb +1 -1
  116. data/generated/google/apis/slides_v1/classes.rb +927 -800
  117. data/generated/google/apis/slides_v1/representations.rb +253 -211
  118. data/generated/google/apis/speech_v1beta1.rb +1 -1
  119. data/generated/google/apis/speech_v1beta1/classes.rb +94 -107
  120. data/generated/google/apis/speech_v1beta1/representations.rb +24 -36
  121. data/generated/google/apis/speech_v1beta1/service.rb +51 -54
  122. data/generated/google/apis/storage_v1.rb +1 -1
  123. data/generated/google/apis/vision_v1.rb +1 -1
  124. data/generated/google/apis/vision_v1/classes.rb +888 -885
  125. data/generated/google/apis/vision_v1/representations.rb +139 -139
  126. data/generated/google/apis/youtube_analytics_v1.rb +1 -1
  127. data/generated/google/apis/youtube_analytics_v1/service.rb +5 -1
  128. data/generated/google/apis/youtube_partner_v1.rb +1 -1
  129. data/generated/google/apis/youtubereporting_v1.rb +1 -1
  130. data/generated/google/apis/youtubereporting_v1/classes.rb +80 -80
  131. data/generated/google/apis/youtubereporting_v1/representations.rb +23 -23
  132. data/generated/google/apis/youtubereporting_v1/service.rb +51 -51
  133. data/google-api-client.gemspec +2 -2
  134. data/lib/google/apis/core/api_command.rb +1 -1
  135. data/lib/google/apis/core/json_representation.rb +2 -2
  136. data/lib/google/apis/version.rb +1 -1
  137. data/samples/cli/lib/samples/you_tube.rb +4 -1
  138. metadata +36 -30
@@ -47,8 +47,9 @@ module Google
47
47
  super('https://cloudresourcemanager.googleapis.com/', '')
48
48
  end
49
49
 
50
- # Returns the IAM access control policy for the specified Project.
51
- # Permission is denied if the policy or the resource does not exist.
50
+ # Gets the access control policy for an Organization resource. May be empty
51
+ # if no such policy or resource exists. The `resource` field should be the
52
+ # organization's resource name, e.g. "organizations/123".
52
53
  # @param [String] resource
53
54
  # REQUIRED: The resource for which the policy is being requested.
54
55
  # `resource` is usually specified as a path. For example, a Project
@@ -71,8 +72,8 @@ module Google
71
72
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
72
73
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
73
74
  # @raise [Google::Apis::AuthorizationError] Authorization is required
74
- def get_project_iam_policy(resource, get_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
75
- command = make_simple_command(:post, 'v1/projects/{resource}:getIamPolicy', options)
75
+ def get_organization_iam_policy(resource, get_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
76
+ command = make_simple_command(:post, 'v1/{+resource}:getIamPolicy', options)
76
77
  command.request_representation = Google::Apis::CloudresourcemanagerV1::GetIamPolicyRequest::Representation
77
78
  command.request_object = get_iam_policy_request_object
78
79
  command.response_representation = Google::Apis::CloudresourcemanagerV1::Policy::Representation
@@ -83,51 +84,11 @@ module Google
83
84
  execute_or_queue_command(command, &block)
84
85
  end
85
86
 
86
- # Restores the Project identified by the specified
87
- # `project_id` (for example, `my-project-123`).
88
- # You can only use this method for a Project that has a lifecycle state of
89
- # DELETE_REQUESTED.
90
- # After deletion starts, the Project cannot be restored.
91
- # The caller must have modify permissions for this Project.
92
- # @param [String] project_id
93
- # The project ID (for example, `foo-bar-123`).
94
- # Required.
95
- # @param [Google::Apis::CloudresourcemanagerV1::UndeleteProjectRequest] undelete_project_request_object
96
- # @param [String] fields
97
- # Selector specifying which fields to include in a partial response.
98
- # @param [String] quota_user
99
- # Available to use for quota purposes for server-side applications. Can be any
100
- # arbitrary string assigned to a user, but should not exceed 40 characters.
101
- # @param [Google::Apis::RequestOptions] options
102
- # Request-specific options
103
- #
104
- # @yield [result, err] Result & error if block supplied
105
- # @yieldparam result [Google::Apis::CloudresourcemanagerV1::Empty] parsed result object
106
- # @yieldparam err [StandardError] error object if request failed
107
- #
108
- # @return [Google::Apis::CloudresourcemanagerV1::Empty]
109
- #
110
- # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
111
- # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
112
- # @raise [Google::Apis::AuthorizationError] Authorization is required
113
- def undelete_project(project_id, undelete_project_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
114
- command = make_simple_command(:post, 'v1/projects/{projectId}:undelete', options)
115
- command.request_representation = Google::Apis::CloudresourcemanagerV1::UndeleteProjectRequest::Representation
116
- command.request_object = undelete_project_request_object
117
- command.response_representation = Google::Apis::CloudresourcemanagerV1::Empty::Representation
118
- command.response_class = Google::Apis::CloudresourcemanagerV1::Empty
119
- command.params['projectId'] = project_id unless project_id.nil?
120
- command.query['fields'] = fields unless fields.nil?
121
- command.query['quotaUser'] = quota_user unless quota_user.nil?
122
- execute_or_queue_command(command, &block)
123
- end
124
-
125
- # Retrieves the Project identified by the specified
126
- # `project_id` (for example, `my-project-123`).
127
- # The caller must have read permissions for this Project.
128
- # @param [String] project_id
129
- # The Project ID (for example, `my-project-123`).
130
- # Required.
87
+ # Searches Organization resources that are visible to the user and satisfy
88
+ # the specified filter. This method returns Organizations in an unspecified
89
+ # order. New Organizations do not necessarily appear at the end of the
90
+ # results.
91
+ # @param [Google::Apis::CloudresourcemanagerV1::SearchOrganizationsRequest] search_organizations_request_object
131
92
  # @param [String] fields
132
93
  # Selector specifying which fields to include in a partial response.
133
94
  # @param [String] quota_user
@@ -137,31 +98,28 @@ module Google
137
98
  # Request-specific options
138
99
  #
139
100
  # @yield [result, err] Result & error if block supplied
140
- # @yieldparam result [Google::Apis::CloudresourcemanagerV1::Project] parsed result object
101
+ # @yieldparam result [Google::Apis::CloudresourcemanagerV1::SearchOrganizationsResponse] parsed result object
141
102
  # @yieldparam err [StandardError] error object if request failed
142
103
  #
143
- # @return [Google::Apis::CloudresourcemanagerV1::Project]
104
+ # @return [Google::Apis::CloudresourcemanagerV1::SearchOrganizationsResponse]
144
105
  #
145
106
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
146
107
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
147
108
  # @raise [Google::Apis::AuthorizationError] Authorization is required
148
- def get_project(project_id, fields: nil, quota_user: nil, options: nil, &block)
149
- command = make_simple_command(:get, 'v1/projects/{projectId}', options)
150
- command.response_representation = Google::Apis::CloudresourcemanagerV1::Project::Representation
151
- command.response_class = Google::Apis::CloudresourcemanagerV1::Project
152
- command.params['projectId'] = project_id unless project_id.nil?
109
+ def search_organizations(search_organizations_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
110
+ command = make_simple_command(:post, 'v1/organizations:search', options)
111
+ command.request_representation = Google::Apis::CloudresourcemanagerV1::SearchOrganizationsRequest::Representation
112
+ command.request_object = search_organizations_request_object
113
+ command.response_representation = Google::Apis::CloudresourcemanagerV1::SearchOrganizationsResponse::Representation
114
+ command.response_class = Google::Apis::CloudresourcemanagerV1::SearchOrganizationsResponse
153
115
  command.query['fields'] = fields unless fields.nil?
154
116
  command.query['quotaUser'] = quota_user unless quota_user.nil?
155
117
  execute_or_queue_command(command, &block)
156
118
  end
157
119
 
158
- # Gets a list of ancestors in the resource hierarchy for the Project
159
- # identified by the specified `project_id` (for example, `my-project-123`).
160
- # The caller must have read permissions for this Project.
161
- # @param [String] project_id
162
- # The Project ID (for example, `my-project-123`).
163
- # Required.
164
- # @param [Google::Apis::CloudresourcemanagerV1::GetAncestryRequest] get_ancestry_request_object
120
+ # Fetches an Organization resource identified by the specified resource name.
121
+ # @param [String] name
122
+ # The resource name of the Organization to fetch, e.g. "organizations/1234".
165
123
  # @param [String] fields
166
124
  # Selector specifying which fields to include in a partial response.
167
125
  # @param [String] quota_user
@@ -171,33 +129,32 @@ module Google
171
129
  # Request-specific options
172
130
  #
173
131
  # @yield [result, err] Result & error if block supplied
174
- # @yieldparam result [Google::Apis::CloudresourcemanagerV1::GetAncestryResponse] parsed result object
132
+ # @yieldparam result [Google::Apis::CloudresourcemanagerV1::Organization] parsed result object
175
133
  # @yieldparam err [StandardError] error object if request failed
176
134
  #
177
- # @return [Google::Apis::CloudresourcemanagerV1::GetAncestryResponse]
135
+ # @return [Google::Apis::CloudresourcemanagerV1::Organization]
178
136
  #
179
137
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
180
138
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
181
139
  # @raise [Google::Apis::AuthorizationError] Authorization is required
182
- def get_project_ancestry(project_id, get_ancestry_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
183
- command = make_simple_command(:post, 'v1/projects/{projectId}:getAncestry', options)
184
- command.request_representation = Google::Apis::CloudresourcemanagerV1::GetAncestryRequest::Representation
185
- command.request_object = get_ancestry_request_object
186
- command.response_representation = Google::Apis::CloudresourcemanagerV1::GetAncestryResponse::Representation
187
- command.response_class = Google::Apis::CloudresourcemanagerV1::GetAncestryResponse
188
- command.params['projectId'] = project_id unless project_id.nil?
140
+ def get_organization(name, fields: nil, quota_user: nil, options: nil, &block)
141
+ command = make_simple_command(:get, 'v1/{+name}', options)
142
+ command.response_representation = Google::Apis::CloudresourcemanagerV1::Organization::Representation
143
+ command.response_class = Google::Apis::CloudresourcemanagerV1::Organization
144
+ command.params['name'] = name unless name.nil?
189
145
  command.query['fields'] = fields unless fields.nil?
190
146
  command.query['quotaUser'] = quota_user unless quota_user.nil?
191
147
  execute_or_queue_command(command, &block)
192
148
  end
193
149
 
194
- # Updates the attributes of the Project identified by the specified
195
- # `project_id` (for example, `my-project-123`).
196
- # The caller must have modify permissions for this Project.
197
- # @param [String] project_id
198
- # The project ID (for example, `my-project-123`).
199
- # Required.
200
- # @param [Google::Apis::CloudresourcemanagerV1::Project] project_object
150
+ # Sets the access control policy on an Organization resource. Replaces any
151
+ # existing policy. The `resource` field should be the organization's resource
152
+ # name, e.g. "organizations/123".
153
+ # @param [String] resource
154
+ # REQUIRED: The resource for which the policy is being specified.
155
+ # `resource` is usually specified as a path. For example, a Project
156
+ # resource is specified as `projects/`project``.
157
+ # @param [Google::Apis::CloudresourcemanagerV1::SetIamPolicyRequest] set_iam_policy_request_object
201
158
  # @param [String] fields
202
159
  # Selector specifying which fields to include in a partial response.
203
160
  # @param [String] quota_user
@@ -207,27 +164,29 @@ module Google
207
164
  # Request-specific options
208
165
  #
209
166
  # @yield [result, err] Result & error if block supplied
210
- # @yieldparam result [Google::Apis::CloudresourcemanagerV1::Project] parsed result object
167
+ # @yieldparam result [Google::Apis::CloudresourcemanagerV1::Policy] parsed result object
211
168
  # @yieldparam err [StandardError] error object if request failed
212
169
  #
213
- # @return [Google::Apis::CloudresourcemanagerV1::Project]
170
+ # @return [Google::Apis::CloudresourcemanagerV1::Policy]
214
171
  #
215
172
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
216
173
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
217
174
  # @raise [Google::Apis::AuthorizationError] Authorization is required
218
- def update_project(project_id, project_object = nil, fields: nil, quota_user: nil, options: nil, &block)
219
- command = make_simple_command(:put, 'v1/projects/{projectId}', options)
220
- command.request_representation = Google::Apis::CloudresourcemanagerV1::Project::Representation
221
- command.request_object = project_object
222
- command.response_representation = Google::Apis::CloudresourcemanagerV1::Project::Representation
223
- command.response_class = Google::Apis::CloudresourcemanagerV1::Project
224
- command.params['projectId'] = project_id unless project_id.nil?
175
+ def set_organization_iam_policy(resource, set_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
176
+ command = make_simple_command(:post, 'v1/{+resource}:setIamPolicy', options)
177
+ command.request_representation = Google::Apis::CloudresourcemanagerV1::SetIamPolicyRequest::Representation
178
+ command.request_object = set_iam_policy_request_object
179
+ command.response_representation = Google::Apis::CloudresourcemanagerV1::Policy::Representation
180
+ command.response_class = Google::Apis::CloudresourcemanagerV1::Policy
181
+ command.params['resource'] = resource unless resource.nil?
225
182
  command.query['fields'] = fields unless fields.nil?
226
183
  command.query['quotaUser'] = quota_user unless quota_user.nil?
227
184
  execute_or_queue_command(command, &block)
228
185
  end
229
186
 
230
- # Returns permissions that a caller has on the specified Project.
187
+ # Returns permissions that a caller has on the specified Organization.
188
+ # The `resource` field should be the organization's resource name,
189
+ # e.g. "organizations/123".
231
190
  # @param [String] resource
232
191
  # REQUIRED: The resource for which the policy detail is being requested.
233
192
  # `resource` is usually specified as a path. For example, a Project
@@ -250,8 +209,8 @@ module Google
250
209
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
251
210
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
252
211
  # @raise [Google::Apis::AuthorizationError] Authorization is required
253
- def test_project_iam_permissions(resource, test_iam_permissions_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
254
- command = make_simple_command(:post, 'v1/projects/{resource}:testIamPermissions', options)
212
+ def test_organization_iam_permissions(resource, test_iam_permissions_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
213
+ command = make_simple_command(:post, 'v1/{+resource}:testIamPermissions', options)
255
214
  command.request_representation = Google::Apis::CloudresourcemanagerV1::TestIamPermissionsRequest::Representation
256
215
  command.request_object = test_iam_permissions_request_object
257
216
  command.response_representation = Google::Apis::CloudresourcemanagerV1::TestIamPermissionsResponse::Representation
@@ -262,85 +221,11 @@ module Google
262
221
  execute_or_queue_command(command, &block)
263
222
  end
264
223
 
265
- # Marks the Project identified by the specified
266
- # `project_id` (for example, `my-project-123`) for deletion.
267
- # This method will only affect the Project if the following criteria are met:
268
- # + The Project does not have a billing account associated with it.
269
- # + The Project has a lifecycle state of
270
- # ACTIVE.
271
- # This method changes the Project's lifecycle state from
272
- # ACTIVE
273
- # to DELETE_REQUESTED.
274
- # The deletion starts at an unspecified time,
275
- # at which point the Project is no longer accessible.
276
- # Until the deletion completes, you can check the lifecycle state
277
- # checked by retrieving the Project with GetProject,
278
- # and the Project remains visible to ListProjects.
279
- # However, you cannot update the project.
280
- # After the deletion completes, the Project is not retrievable by
281
- # the GetProject and
282
- # ListProjects methods.
283
- # The caller must have modify permissions for this Project.
284
- # @param [String] project_id
285
- # The Project ID (for example, `foo-bar-123`).
286
- # Required.
287
- # @param [String] fields
288
- # Selector specifying which fields to include in a partial response.
289
- # @param [String] quota_user
290
- # Available to use for quota purposes for server-side applications. Can be any
291
- # arbitrary string assigned to a user, but should not exceed 40 characters.
292
- # @param [Google::Apis::RequestOptions] options
293
- # Request-specific options
294
- #
295
- # @yield [result, err] Result & error if block supplied
296
- # @yieldparam result [Google::Apis::CloudresourcemanagerV1::Empty] parsed result object
297
- # @yieldparam err [StandardError] error object if request failed
298
- #
299
- # @return [Google::Apis::CloudresourcemanagerV1::Empty]
300
- #
301
- # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
302
- # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
303
- # @raise [Google::Apis::AuthorizationError] Authorization is required
304
- def delete_project(project_id, fields: nil, quota_user: nil, options: nil, &block)
305
- command = make_simple_command(:delete, 'v1/projects/{projectId}', options)
306
- command.response_representation = Google::Apis::CloudresourcemanagerV1::Empty::Representation
307
- command.response_class = Google::Apis::CloudresourcemanagerV1::Empty
308
- command.params['projectId'] = project_id unless project_id.nil?
309
- command.query['fields'] = fields unless fields.nil?
310
- command.query['quotaUser'] = quota_user unless quota_user.nil?
311
- execute_or_queue_command(command, &block)
312
- end
313
-
314
- # Lists Projects that are visible to the user and satisfy the
315
- # specified filter. This method returns Projects in an unspecified order.
316
- # New Projects do not necessarily appear at the end of the list.
317
- # @param [Fixnum] page_size
318
- # The maximum number of Projects to return in the response.
319
- # The server can return fewer Projects than requested.
320
- # If unspecified, server picks an appropriate default.
321
- # Optional.
322
- # @param [String] filter
323
- # An expression for filtering the results of the request. Filter rules are
324
- # case insensitive. The fields eligible for filtering are:
325
- # + `name`
326
- # + `id`
327
- # + <code>labels.<em>key</em></code> where *key* is the name of a label
328
- # Some examples of using labels as filters:
329
- # |Filter|Description|
330
- # |------|-----------|
331
- # |name:*|The project has a name.|
332
- # |name:Howl|The project's name is `Howl` or `howl`.|
333
- # |name:HOWL|Equivalent to above.|
334
- # |NAME:howl|Equivalent to above.|
335
- # |labels.color:*|The project has the label `color`.|
336
- # |labels.color:red|The project's label `color` has the value `red`.|
337
- # |labels.color:red&nbsp;label.size:big|The project's label `color` has the
338
- # value `red` and its label `size` has the value `big`.
339
- # Optional.
340
- # @param [String] page_token
341
- # A pagination token returned from a previous call to ListProjects
342
- # that indicates from where listing should continue.
343
- # Optional.
224
+ # Gets the latest state of a long-running operation. Clients can use this
225
+ # method to poll the operation result at intervals as recommended by the API
226
+ # service.
227
+ # @param [String] name
228
+ # The name of the operation resource.
344
229
  # @param [String] fields
345
230
  # Selector specifying which fields to include in a partial response.
346
231
  # @param [String] quota_user
@@ -350,21 +235,19 @@ module Google
350
235
  # Request-specific options
351
236
  #
352
237
  # @yield [result, err] Result & error if block supplied
353
- # @yieldparam result [Google::Apis::CloudresourcemanagerV1::ListProjectsResponse] parsed result object
238
+ # @yieldparam result [Google::Apis::CloudresourcemanagerV1::Operation] parsed result object
354
239
  # @yieldparam err [StandardError] error object if request failed
355
240
  #
356
- # @return [Google::Apis::CloudresourcemanagerV1::ListProjectsResponse]
241
+ # @return [Google::Apis::CloudresourcemanagerV1::Operation]
357
242
  #
358
243
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
359
244
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
360
245
  # @raise [Google::Apis::AuthorizationError] Authorization is required
361
- def list_projects(page_size: nil, filter: nil, page_token: nil, fields: nil, quota_user: nil, options: nil, &block)
362
- command = make_simple_command(:get, 'v1/projects', options)
363
- command.response_representation = Google::Apis::CloudresourcemanagerV1::ListProjectsResponse::Representation
364
- command.response_class = Google::Apis::CloudresourcemanagerV1::ListProjectsResponse
365
- command.query['pageSize'] = page_size unless page_size.nil?
366
- command.query['filter'] = filter unless filter.nil?
367
- command.query['pageToken'] = page_token unless page_token.nil?
246
+ def get_operation(name, fields: nil, quota_user: nil, options: nil, &block)
247
+ command = make_simple_command(:get, 'v1/{+name}', options)
248
+ command.response_representation = Google::Apis::CloudresourcemanagerV1::Operation::Representation
249
+ command.response_class = Google::Apis::CloudresourcemanagerV1::Operation
250
+ command.params['name'] = name unless name.nil?
368
251
  command.query['fields'] = fields unless fields.nil?
369
252
  command.query['quotaUser'] = quota_user unless quota_user.nil?
370
253
  execute_or_queue_command(command, &block)
@@ -468,14 +351,13 @@ module Google
468
351
  execute_or_queue_command(command, &block)
469
352
  end
470
353
 
471
- # Returns permissions that a caller has on the specified Organization.
472
- # The `resource` field should be the organization's resource name,
473
- # e.g. "organizations/123".
354
+ # Returns the IAM access control policy for the specified Project.
355
+ # Permission is denied if the policy or the resource does not exist.
474
356
  # @param [String] resource
475
- # REQUIRED: The resource for which the policy detail is being requested.
357
+ # REQUIRED: The resource for which the policy is being requested.
476
358
  # `resource` is usually specified as a path. For example, a Project
477
359
  # resource is specified as `projects/`project``.
478
- # @param [Google::Apis::CloudresourcemanagerV1::TestIamPermissionsRequest] test_iam_permissions_request_object
360
+ # @param [Google::Apis::CloudresourcemanagerV1::GetIamPolicyRequest] get_iam_policy_request_object
479
361
  # @param [String] fields
480
362
  # Selector specifying which fields to include in a partial response.
481
363
  # @param [String] quota_user
@@ -485,34 +367,32 @@ module Google
485
367
  # Request-specific options
486
368
  #
487
369
  # @yield [result, err] Result & error if block supplied
488
- # @yieldparam result [Google::Apis::CloudresourcemanagerV1::TestIamPermissionsResponse] parsed result object
370
+ # @yieldparam result [Google::Apis::CloudresourcemanagerV1::Policy] parsed result object
489
371
  # @yieldparam err [StandardError] error object if request failed
490
372
  #
491
- # @return [Google::Apis::CloudresourcemanagerV1::TestIamPermissionsResponse]
373
+ # @return [Google::Apis::CloudresourcemanagerV1::Policy]
492
374
  #
493
375
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
494
376
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
495
377
  # @raise [Google::Apis::AuthorizationError] Authorization is required
496
- def test_organization_iam_permissions(resource, test_iam_permissions_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
497
- command = make_simple_command(:post, 'v1/{+resource}:testIamPermissions', options)
498
- command.request_representation = Google::Apis::CloudresourcemanagerV1::TestIamPermissionsRequest::Representation
499
- command.request_object = test_iam_permissions_request_object
500
- command.response_representation = Google::Apis::CloudresourcemanagerV1::TestIamPermissionsResponse::Representation
501
- command.response_class = Google::Apis::CloudresourcemanagerV1::TestIamPermissionsResponse
378
+ def get_project_iam_policy(resource, get_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
379
+ command = make_simple_command(:post, 'v1/projects/{resource}:getIamPolicy', options)
380
+ command.request_representation = Google::Apis::CloudresourcemanagerV1::GetIamPolicyRequest::Representation
381
+ command.request_object = get_iam_policy_request_object
382
+ command.response_representation = Google::Apis::CloudresourcemanagerV1::Policy::Representation
383
+ command.response_class = Google::Apis::CloudresourcemanagerV1::Policy
502
384
  command.params['resource'] = resource unless resource.nil?
503
385
  command.query['fields'] = fields unless fields.nil?
504
386
  command.query['quotaUser'] = quota_user unless quota_user.nil?
505
387
  execute_or_queue_command(command, &block)
506
388
  end
507
389
 
508
- # Gets the access control policy for an Organization resource. May be empty
509
- # if no such policy or resource exists. The `resource` field should be the
510
- # organization's resource name, e.g. "organizations/123".
511
- # @param [String] resource
512
- # REQUIRED: The resource for which the policy is being requested.
513
- # `resource` is usually specified as a path. For example, a Project
514
- # resource is specified as `projects/`project``.
515
- # @param [Google::Apis::CloudresourcemanagerV1::GetIamPolicyRequest] get_iam_policy_request_object
390
+ # Retrieves the Project identified by the specified
391
+ # `project_id` (for example, `my-project-123`).
392
+ # The caller must have read permissions for this Project.
393
+ # @param [String] project_id
394
+ # The Project ID (for example, `my-project-123`).
395
+ # Required.
516
396
  # @param [String] fields
517
397
  # Selector specifying which fields to include in a partial response.
518
398
  # @param [String] quota_user
@@ -522,31 +402,34 @@ module Google
522
402
  # Request-specific options
523
403
  #
524
404
  # @yield [result, err] Result & error if block supplied
525
- # @yieldparam result [Google::Apis::CloudresourcemanagerV1::Policy] parsed result object
405
+ # @yieldparam result [Google::Apis::CloudresourcemanagerV1::Project] parsed result object
526
406
  # @yieldparam err [StandardError] error object if request failed
527
407
  #
528
- # @return [Google::Apis::CloudresourcemanagerV1::Policy]
408
+ # @return [Google::Apis::CloudresourcemanagerV1::Project]
529
409
  #
530
410
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
531
411
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
532
412
  # @raise [Google::Apis::AuthorizationError] Authorization is required
533
- def get_organization_iam_policy(resource, get_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
534
- command = make_simple_command(:post, 'v1/{+resource}:getIamPolicy', options)
535
- command.request_representation = Google::Apis::CloudresourcemanagerV1::GetIamPolicyRequest::Representation
536
- command.request_object = get_iam_policy_request_object
537
- command.response_representation = Google::Apis::CloudresourcemanagerV1::Policy::Representation
538
- command.response_class = Google::Apis::CloudresourcemanagerV1::Policy
539
- command.params['resource'] = resource unless resource.nil?
413
+ def get_project(project_id, fields: nil, quota_user: nil, options: nil, &block)
414
+ command = make_simple_command(:get, 'v1/projects/{projectId}', options)
415
+ command.response_representation = Google::Apis::CloudresourcemanagerV1::Project::Representation
416
+ command.response_class = Google::Apis::CloudresourcemanagerV1::Project
417
+ command.params['projectId'] = project_id unless project_id.nil?
540
418
  command.query['fields'] = fields unless fields.nil?
541
419
  command.query['quotaUser'] = quota_user unless quota_user.nil?
542
420
  execute_or_queue_command(command, &block)
543
421
  end
544
422
 
545
- # Searches Organization resources that are visible to the user and satisfy
546
- # the specified filter. This method returns Organizations in an unspecified
547
- # order. New Organizations do not necessarily appear at the end of the
548
- # results.
549
- # @param [Google::Apis::CloudresourcemanagerV1::SearchOrganizationsRequest] search_organizations_request_object
423
+ # Restores the Project identified by the specified
424
+ # `project_id` (for example, `my-project-123`).
425
+ # You can only use this method for a Project that has a lifecycle state of
426
+ # DELETE_REQUESTED.
427
+ # After deletion starts, the Project cannot be restored.
428
+ # The caller must have modify permissions for this Project.
429
+ # @param [String] project_id
430
+ # The project ID (for example, `foo-bar-123`).
431
+ # Required.
432
+ # @param [Google::Apis::CloudresourcemanagerV1::UndeleteProjectRequest] undelete_project_request_object
550
433
  # @param [String] fields
551
434
  # Selector specifying which fields to include in a partial response.
552
435
  # @param [String] quota_user
@@ -556,28 +439,33 @@ module Google
556
439
  # Request-specific options
557
440
  #
558
441
  # @yield [result, err] Result & error if block supplied
559
- # @yieldparam result [Google::Apis::CloudresourcemanagerV1::SearchOrganizationsResponse] parsed result object
442
+ # @yieldparam result [Google::Apis::CloudresourcemanagerV1::Empty] parsed result object
560
443
  # @yieldparam err [StandardError] error object if request failed
561
444
  #
562
- # @return [Google::Apis::CloudresourcemanagerV1::SearchOrganizationsResponse]
445
+ # @return [Google::Apis::CloudresourcemanagerV1::Empty]
563
446
  #
564
447
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
565
448
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
566
449
  # @raise [Google::Apis::AuthorizationError] Authorization is required
567
- def search_organizations(search_organizations_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
568
- command = make_simple_command(:post, 'v1/organizations:search', options)
569
- command.request_representation = Google::Apis::CloudresourcemanagerV1::SearchOrganizationsRequest::Representation
570
- command.request_object = search_organizations_request_object
571
- command.response_representation = Google::Apis::CloudresourcemanagerV1::SearchOrganizationsResponse::Representation
572
- command.response_class = Google::Apis::CloudresourcemanagerV1::SearchOrganizationsResponse
450
+ def undelete_project(project_id, undelete_project_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
451
+ command = make_simple_command(:post, 'v1/projects/{projectId}:undelete', options)
452
+ command.request_representation = Google::Apis::CloudresourcemanagerV1::UndeleteProjectRequest::Representation
453
+ command.request_object = undelete_project_request_object
454
+ command.response_representation = Google::Apis::CloudresourcemanagerV1::Empty::Representation
455
+ command.response_class = Google::Apis::CloudresourcemanagerV1::Empty
456
+ command.params['projectId'] = project_id unless project_id.nil?
573
457
  command.query['fields'] = fields unless fields.nil?
574
458
  command.query['quotaUser'] = quota_user unless quota_user.nil?
575
459
  execute_or_queue_command(command, &block)
576
460
  end
577
461
 
578
- # Fetches an Organization resource identified by the specified resource name.
579
- # @param [String] name
580
- # The resource name of the Organization to fetch, e.g. "organizations/1234".
462
+ # Gets a list of ancestors in the resource hierarchy for the Project
463
+ # identified by the specified `project_id` (for example, `my-project-123`).
464
+ # The caller must have read permissions for this Project.
465
+ # @param [String] project_id
466
+ # The Project ID (for example, `my-project-123`).
467
+ # Required.
468
+ # @param [Google::Apis::CloudresourcemanagerV1::GetAncestryRequest] get_ancestry_request_object
581
469
  # @param [String] fields
582
470
  # Selector specifying which fields to include in a partial response.
583
471
  # @param [String] quota_user
@@ -587,32 +475,68 @@ module Google
587
475
  # Request-specific options
588
476
  #
589
477
  # @yield [result, err] Result & error if block supplied
590
- # @yieldparam result [Google::Apis::CloudresourcemanagerV1::Organization] parsed result object
478
+ # @yieldparam result [Google::Apis::CloudresourcemanagerV1::GetAncestryResponse] parsed result object
591
479
  # @yieldparam err [StandardError] error object if request failed
592
480
  #
593
- # @return [Google::Apis::CloudresourcemanagerV1::Organization]
481
+ # @return [Google::Apis::CloudresourcemanagerV1::GetAncestryResponse]
594
482
  #
595
483
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
596
484
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
597
485
  # @raise [Google::Apis::AuthorizationError] Authorization is required
598
- def get_organization(name, fields: nil, quota_user: nil, options: nil, &block)
599
- command = make_simple_command(:get, 'v1/{+name}', options)
600
- command.response_representation = Google::Apis::CloudresourcemanagerV1::Organization::Representation
601
- command.response_class = Google::Apis::CloudresourcemanagerV1::Organization
602
- command.params['name'] = name unless name.nil?
486
+ def get_project_ancestry(project_id, get_ancestry_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
487
+ command = make_simple_command(:post, 'v1/projects/{projectId}:getAncestry', options)
488
+ command.request_representation = Google::Apis::CloudresourcemanagerV1::GetAncestryRequest::Representation
489
+ command.request_object = get_ancestry_request_object
490
+ command.response_representation = Google::Apis::CloudresourcemanagerV1::GetAncestryResponse::Representation
491
+ command.response_class = Google::Apis::CloudresourcemanagerV1::GetAncestryResponse
492
+ command.params['projectId'] = project_id unless project_id.nil?
603
493
  command.query['fields'] = fields unless fields.nil?
604
494
  command.query['quotaUser'] = quota_user unless quota_user.nil?
605
495
  execute_or_queue_command(command, &block)
606
496
  end
607
497
 
608
- # Sets the access control policy on an Organization resource. Replaces any
609
- # existing policy. The `resource` field should be the organization's resource
610
- # name, e.g. "organizations/123".
498
+ # Updates the attributes of the Project identified by the specified
499
+ # `project_id` (for example, `my-project-123`).
500
+ # The caller must have modify permissions for this Project.
501
+ # @param [String] project_id
502
+ # The project ID (for example, `my-project-123`).
503
+ # Required.
504
+ # @param [Google::Apis::CloudresourcemanagerV1::Project] project_object
505
+ # @param [String] fields
506
+ # Selector specifying which fields to include in a partial response.
507
+ # @param [String] quota_user
508
+ # Available to use for quota purposes for server-side applications. Can be any
509
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
510
+ # @param [Google::Apis::RequestOptions] options
511
+ # Request-specific options
512
+ #
513
+ # @yield [result, err] Result & error if block supplied
514
+ # @yieldparam result [Google::Apis::CloudresourcemanagerV1::Project] parsed result object
515
+ # @yieldparam err [StandardError] error object if request failed
516
+ #
517
+ # @return [Google::Apis::CloudresourcemanagerV1::Project]
518
+ #
519
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
520
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
521
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
522
+ def update_project(project_id, project_object = nil, fields: nil, quota_user: nil, options: nil, &block)
523
+ command = make_simple_command(:put, 'v1/projects/{projectId}', options)
524
+ command.request_representation = Google::Apis::CloudresourcemanagerV1::Project::Representation
525
+ command.request_object = project_object
526
+ command.response_representation = Google::Apis::CloudresourcemanagerV1::Project::Representation
527
+ command.response_class = Google::Apis::CloudresourcemanagerV1::Project
528
+ command.params['projectId'] = project_id unless project_id.nil?
529
+ command.query['fields'] = fields unless fields.nil?
530
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
531
+ execute_or_queue_command(command, &block)
532
+ end
533
+
534
+ # Returns permissions that a caller has on the specified Project.
611
535
  # @param [String] resource
612
- # REQUIRED: The resource for which the policy is being specified.
536
+ # REQUIRED: The resource for which the policy detail is being requested.
613
537
  # `resource` is usually specified as a path. For example, a Project
614
538
  # resource is specified as `projects/`project``.
615
- # @param [Google::Apis::CloudresourcemanagerV1::SetIamPolicyRequest] set_iam_policy_request_object
539
+ # @param [Google::Apis::CloudresourcemanagerV1::TestIamPermissionsRequest] test_iam_permissions_request_object
616
540
  # @param [String] fields
617
541
  # Selector specifying which fields to include in a partial response.
618
542
  # @param [String] quota_user
@@ -622,31 +546,48 @@ module Google
622
546
  # Request-specific options
623
547
  #
624
548
  # @yield [result, err] Result & error if block supplied
625
- # @yieldparam result [Google::Apis::CloudresourcemanagerV1::Policy] parsed result object
549
+ # @yieldparam result [Google::Apis::CloudresourcemanagerV1::TestIamPermissionsResponse] parsed result object
626
550
  # @yieldparam err [StandardError] error object if request failed
627
551
  #
628
- # @return [Google::Apis::CloudresourcemanagerV1::Policy]
552
+ # @return [Google::Apis::CloudresourcemanagerV1::TestIamPermissionsResponse]
629
553
  #
630
554
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
631
555
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
632
556
  # @raise [Google::Apis::AuthorizationError] Authorization is required
633
- def set_organization_iam_policy(resource, set_iam_policy_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
634
- command = make_simple_command(:post, 'v1/{+resource}:setIamPolicy', options)
635
- command.request_representation = Google::Apis::CloudresourcemanagerV1::SetIamPolicyRequest::Representation
636
- command.request_object = set_iam_policy_request_object
637
- command.response_representation = Google::Apis::CloudresourcemanagerV1::Policy::Representation
638
- command.response_class = Google::Apis::CloudresourcemanagerV1::Policy
557
+ def test_project_iam_permissions(resource, test_iam_permissions_request_object = nil, fields: nil, quota_user: nil, options: nil, &block)
558
+ command = make_simple_command(:post, 'v1/projects/{resource}:testIamPermissions', options)
559
+ command.request_representation = Google::Apis::CloudresourcemanagerV1::TestIamPermissionsRequest::Representation
560
+ command.request_object = test_iam_permissions_request_object
561
+ command.response_representation = Google::Apis::CloudresourcemanagerV1::TestIamPermissionsResponse::Representation
562
+ command.response_class = Google::Apis::CloudresourcemanagerV1::TestIamPermissionsResponse
639
563
  command.params['resource'] = resource unless resource.nil?
640
564
  command.query['fields'] = fields unless fields.nil?
641
565
  command.query['quotaUser'] = quota_user unless quota_user.nil?
642
566
  execute_or_queue_command(command, &block)
643
567
  end
644
568
 
645
- # Gets the latest state of a long-running operation. Clients can use this
646
- # method to poll the operation result at intervals as recommended by the API
647
- # service.
648
- # @param [String] name
649
- # The name of the operation resource.
569
+ # Marks the Project identified by the specified
570
+ # `project_id` (for example, `my-project-123`) for deletion.
571
+ # This method will only affect the Project if the following criteria are met:
572
+ # + The Project does not have a billing account associated with it.
573
+ # + The Project has a lifecycle state of
574
+ # ACTIVE.
575
+ # This method changes the Project's lifecycle state from
576
+ # ACTIVE
577
+ # to DELETE_REQUESTED.
578
+ # The deletion starts at an unspecified time,
579
+ # at which point the Project is no longer accessible.
580
+ # Until the deletion completes, you can check the lifecycle state
581
+ # checked by retrieving the Project with GetProject,
582
+ # and the Project remains visible to ListProjects.
583
+ # However, you cannot update the project.
584
+ # After the deletion completes, the Project is not retrievable by
585
+ # the GetProject and
586
+ # ListProjects methods.
587
+ # The caller must have modify permissions for this Project.
588
+ # @param [String] project_id
589
+ # The Project ID (for example, `foo-bar-123`).
590
+ # Required.
650
591
  # @param [String] fields
651
592
  # Selector specifying which fields to include in a partial response.
652
593
  # @param [String] quota_user
@@ -656,19 +597,78 @@ module Google
656
597
  # Request-specific options
657
598
  #
658
599
  # @yield [result, err] Result & error if block supplied
659
- # @yieldparam result [Google::Apis::CloudresourcemanagerV1::Operation] parsed result object
600
+ # @yieldparam result [Google::Apis::CloudresourcemanagerV1::Empty] parsed result object
660
601
  # @yieldparam err [StandardError] error object if request failed
661
602
  #
662
- # @return [Google::Apis::CloudresourcemanagerV1::Operation]
603
+ # @return [Google::Apis::CloudresourcemanagerV1::Empty]
663
604
  #
664
605
  # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
665
606
  # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
666
607
  # @raise [Google::Apis::AuthorizationError] Authorization is required
667
- def get_operation(name, fields: nil, quota_user: nil, options: nil, &block)
668
- command = make_simple_command(:get, 'v1/{+name}', options)
669
- command.response_representation = Google::Apis::CloudresourcemanagerV1::Operation::Representation
670
- command.response_class = Google::Apis::CloudresourcemanagerV1::Operation
671
- command.params['name'] = name unless name.nil?
608
+ def delete_project(project_id, fields: nil, quota_user: nil, options: nil, &block)
609
+ command = make_simple_command(:delete, 'v1/projects/{projectId}', options)
610
+ command.response_representation = Google::Apis::CloudresourcemanagerV1::Empty::Representation
611
+ command.response_class = Google::Apis::CloudresourcemanagerV1::Empty
612
+ command.params['projectId'] = project_id unless project_id.nil?
613
+ command.query['fields'] = fields unless fields.nil?
614
+ command.query['quotaUser'] = quota_user unless quota_user.nil?
615
+ execute_or_queue_command(command, &block)
616
+ end
617
+
618
+ # Lists Projects that are visible to the user and satisfy the
619
+ # specified filter. This method returns Projects in an unspecified order.
620
+ # New Projects do not necessarily appear at the end of the list.
621
+ # @param [String] filter
622
+ # An expression for filtering the results of the request. Filter rules are
623
+ # case insensitive. The fields eligible for filtering are:
624
+ # + `name`
625
+ # + `id`
626
+ # + <code>labels.<em>key</em></code> where *key* is the name of a label
627
+ # Some examples of using labels as filters:
628
+ # |Filter|Description|
629
+ # |------|-----------|
630
+ # |name:*|The project has a name.|
631
+ # |name:Howl|The project's name is `Howl` or `howl`.|
632
+ # |name:HOWL|Equivalent to above.|
633
+ # |NAME:howl|Equivalent to above.|
634
+ # |labels.color:*|The project has the label `color`.|
635
+ # |labels.color:red|The project's label `color` has the value `red`.|
636
+ # |labels.color:red&nbsp;label.size:big|The project's label `color` has the
637
+ # value `red` and its label `size` has the value `big`.
638
+ # Optional.
639
+ # @param [String] page_token
640
+ # A pagination token returned from a previous call to ListProjects
641
+ # that indicates from where listing should continue.
642
+ # Optional.
643
+ # @param [Fixnum] page_size
644
+ # The maximum number of Projects to return in the response.
645
+ # The server can return fewer Projects than requested.
646
+ # If unspecified, server picks an appropriate default.
647
+ # Optional.
648
+ # @param [String] fields
649
+ # Selector specifying which fields to include in a partial response.
650
+ # @param [String] quota_user
651
+ # Available to use for quota purposes for server-side applications. Can be any
652
+ # arbitrary string assigned to a user, but should not exceed 40 characters.
653
+ # @param [Google::Apis::RequestOptions] options
654
+ # Request-specific options
655
+ #
656
+ # @yield [result, err] Result & error if block supplied
657
+ # @yieldparam result [Google::Apis::CloudresourcemanagerV1::ListProjectsResponse] parsed result object
658
+ # @yieldparam err [StandardError] error object if request failed
659
+ #
660
+ # @return [Google::Apis::CloudresourcemanagerV1::ListProjectsResponse]
661
+ #
662
+ # @raise [Google::Apis::ServerError] An error occurred on the server and the request can be retried
663
+ # @raise [Google::Apis::ClientError] The request is invalid and should not be retried without modification
664
+ # @raise [Google::Apis::AuthorizationError] Authorization is required
665
+ def list_projects(filter: nil, page_token: nil, page_size: nil, fields: nil, quota_user: nil, options: nil, &block)
666
+ command = make_simple_command(:get, 'v1/projects', options)
667
+ command.response_representation = Google::Apis::CloudresourcemanagerV1::ListProjectsResponse::Representation
668
+ command.response_class = Google::Apis::CloudresourcemanagerV1::ListProjectsResponse
669
+ command.query['filter'] = filter unless filter.nil?
670
+ command.query['pageToken'] = page_token unless page_token.nil?
671
+ command.query['pageSize'] = page_size unless page_size.nil?
672
672
  command.query['fields'] = fields unless fields.nil?
673
673
  command.query['quotaUser'] = quota_user unless quota_user.nil?
674
674
  execute_or_queue_command(command, &block)