Skip to content

Commit b53f6a4

Browse files
feat(assuredworkloads): update the api
#### assuredworkloads:v1 The following keys were added: - resources.organizations.resources.locations.resources.workloads.methods.enableComplianceUpdates (Total Keys: 11) - resources.organizations.resources.locations.resources.workloads.resources.updates.methods.apply (Total Keys: 12) - resources.organizations.resources.locations.resources.workloads.resources.updates.methods.list (Total Keys: 16) - schemas.GoogleCloudAssuredworkloadsV1ApplyWorkloadUpdateOperationMetadata (Total Keys: 7) - schemas.GoogleCloudAssuredworkloadsV1ApplyWorkloadUpdateRequest (Total Keys: 3) - schemas.GoogleCloudAssuredworkloadsV1ApplyWorkloadUpdateResponse (Total Keys: 3) - schemas.GoogleCloudAssuredworkloadsV1EnableComplianceUpdatesResponse (Total Keys: 2) - schemas.GoogleCloudAssuredworkloadsV1ListWorkloadUpdatesResponse (Total Keys: 5) - schemas.GoogleCloudAssuredworkloadsV1OrgPolicy (Total Keys: 23) - schemas.GoogleCloudAssuredworkloadsV1UpdateDetails (Total Keys: 3) - schemas.GoogleCloudAssuredworkloadsV1WorkloadUpdate (Total Keys: 11)
1 parent 23eadbc commit b53f6a4

5 files changed

+570
-6
lines changed

docs/dyn/assuredworkloads_v1.organizations.locations.workloads.html

Lines changed: 27 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,11 @@
7474

7575
<h1><a href="assuredworkloads_v1.html">Assured Workloads API</a> . <a href="assuredworkloads_v1.organizations.html">organizations</a> . <a href="assuredworkloads_v1.organizations.locations.html">locations</a> . <a href="assuredworkloads_v1.organizations.locations.workloads.html">workloads</a></h1>
7676
<h2>Instance Methods</h2>
77+
<p class="toc_element">
78+
<code><a href="assuredworkloads_v1.organizations.locations.workloads.updates.html">updates()</a></code>
79+
</p>
80+
<p class="firstline">Returns the updates Resource.</p>
81+
7782
<p class="toc_element">
7883
<code><a href="assuredworkloads_v1.organizations.locations.workloads.violations.html">violations()</a></code>
7984
</p>
@@ -94,6 +99,9 @@ <h2>Instance Methods</h2>
9499
<p class="toc_element">
95100
<code><a href="#delete">delete(name, etag=None, x__xgafv=None)</a></code></p>
96101
<p class="firstline">Deletes the workload. Make sure that workload's direct children are already in a deleted state, otherwise the request will fail with a FAILED_PRECONDITION error. In addition to assuredworkloads.workload.delete permission, the user should also have orgpolicy.policy.set permission on the deleted folder to remove Assured Workloads OrgPolicies.</p>
102+
<p class="toc_element">
103+
<code><a href="#enableComplianceUpdates">enableComplianceUpdates(name, x__xgafv=None)</a></code></p>
104+
<p class="firstline">This endpoint enables Assured Workloads service to offer compliance updates for the folder based assured workload. It sets up an Assured Workloads Service Agent, having permissions to read compliance controls (for example: Org Policies) applied on the workload. The caller must have `resourcemanager.folders.getIamPolicy` and `resourcemanager.folders.setIamPolicy` permissions on the assured workload folder.</p>
97105
<p class="toc_element">
98106
<code><a href="#enableResourceMonitoring">enableResourceMonitoring(name, x__xgafv=None)</a></code></p>
99107
<p class="firstline">Enable resource violation monitoring for a workload.</p>
@@ -123,7 +131,7 @@ <h3>Method Details</h3>
123131
Args:
124132
target: string, Required. The resource ID of the folder-based destination workload. This workload is where the source resource will hypothetically be moved to. Specify the workload&#x27;s relative resource name, formatted as: &quot;organizations/{ORGANIZATION_ID}/locations/{LOCATION_ID}/workloads/{WORKLOAD_ID}&quot; For example: &quot;organizations/123/locations/us-east1/workloads/assured-workload-2&quot; (required)
125133
assetTypes: string, Optional. List of asset types to be analyzed, including and under the source resource. If empty, all assets are analyzed. The complete list of asset types is available [here](https://cloud.google.com/asset-inventory/docs/supported-asset-types). (repeated)
126-
pageSize: integer, Optional. Page size. If a value is not specified, the default value of 10 is used.
134+
pageSize: integer, Optional. Page size. If a value is not specified, the default value of 10 is used. The maximum value is 50.
127135
pageToken: string, Optional. The page token from the previous response. It needs to be passed in the second and following requests.
128136
project: string, The source type is a project. Specify the project&#x27;s relative resource name, formatted as either a project number or a project ID: &quot;projects/{PROJECT_NUMBER}&quot; or &quot;projects/{PROJECT_ID}&quot; For example: &quot;projects/951040570662&quot; when specifying a project number, or &quot;projects/my-project-123&quot; when specifying a project ID.
129137
x__xgafv: string, V1 error format.
@@ -313,6 +321,24 @@ <h3>Method Details</h3>
313321
}</pre>
314322
</div>
315323

324+
<div class="method">
325+
<code class="details" id="enableComplianceUpdates">enableComplianceUpdates(name, x__xgafv=None)</code>
326+
<pre>This endpoint enables Assured Workloads service to offer compliance updates for the folder based assured workload. It sets up an Assured Workloads Service Agent, having permissions to read compliance controls (for example: Org Policies) applied on the workload. The caller must have `resourcemanager.folders.getIamPolicy` and `resourcemanager.folders.setIamPolicy` permissions on the assured workload folder.
327+
328+
Args:
329+
name: string, Required. The `name` field is used to identify the workload. Format: organizations/{org_id}/locations/{location_id}/workloads/{workload_id} (required)
330+
x__xgafv: string, V1 error format.
331+
Allowed values
332+
1 - v1 error format
333+
2 - v2 error format
334+
335+
Returns:
336+
An object of the form:
337+
338+
{ # Response for EnableComplianceUpdates endpoint.
339+
}</pre>
340+
</div>
341+
316342
<div class="method">
317343
<code class="details" id="enableResourceMonitoring">enableResourceMonitoring(name, x__xgafv=None)</code>
318344
<pre>Enable resource violation monitoring for a workload.
Lines changed: 222 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,222 @@
1+
<html><body>
2+
<style>
3+
4+
body, h1, h2, h3, div, span, p, pre, a {
5+
margin: 0;
6+
padding: 0;
7+
border: 0;
8+
font-weight: inherit;
9+
font-style: inherit;
10+
font-size: 100%;
11+
font-family: inherit;
12+
vertical-align: baseline;
13+
}
14+
15+
body {
16+
font-size: 13px;
17+
padding: 1em;
18+
}
19+
20+
h1 {
21+
font-size: 26px;
22+
margin-bottom: 1em;
23+
}
24+
25+
h2 {
26+
font-size: 24px;
27+
margin-bottom: 1em;
28+
}
29+
30+
h3 {
31+
font-size: 20px;
32+
margin-bottom: 1em;
33+
margin-top: 1em;
34+
}
35+
36+
pre, code {
37+
line-height: 1.5;
38+
font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace;
39+
}
40+
41+
pre {
42+
margin-top: 0.5em;
43+
}
44+
45+
h1, h2, h3, p {
46+
font-family: Arial, sans serif;
47+
}
48+
49+
h1, h2, h3 {
50+
border-bottom: solid #CCC 1px;
51+
}
52+
53+
.toc_element {
54+
margin-top: 0.5em;
55+
}
56+
57+
.firstline {
58+
margin-left: 2 em;
59+
}
60+
61+
.method {
62+
margin-top: 1em;
63+
border: solid 1px #CCC;
64+
padding: 1em;
65+
background: #EEE;
66+
}
67+
68+
.details {
69+
font-weight: bold;
70+
font-size: 14px;
71+
}
72+
73+
</style>
74+
75+
<h1><a href="assuredworkloads_v1.html">Assured Workloads API</a> . <a href="assuredworkloads_v1.organizations.html">organizations</a> . <a href="assuredworkloads_v1.organizations.locations.html">locations</a> . <a href="assuredworkloads_v1.organizations.locations.workloads.html">workloads</a> . <a href="assuredworkloads_v1.organizations.locations.workloads.updates.html">updates</a></h1>
76+
<h2>Instance Methods</h2>
77+
<p class="toc_element">
78+
<code><a href="#apply">apply(name, body=None, x__xgafv=None)</a></code></p>
79+
<p class="firstline">This endpoint creates a new operation to apply the given update.</p>
80+
<p class="toc_element">
81+
<code><a href="#close">close()</a></code></p>
82+
<p class="firstline">Close httplib2 connections.</p>
83+
<p class="toc_element">
84+
<code><a href="#list">list(parent, pageSize=None, pageToken=None, x__xgafv=None)</a></code></p>
85+
<p class="firstline">This endpoint lists all updates for the given workload.</p>
86+
<p class="toc_element">
87+
<code><a href="#list_next">list_next()</a></code></p>
88+
<p class="firstline">Retrieves the next page of results.</p>
89+
<h3>Method Details</h3>
90+
<div class="method">
91+
<code class="details" id="apply">apply(name, body=None, x__xgafv=None)</code>
92+
<pre>This endpoint creates a new operation to apply the given update.
93+
94+
Args:
95+
name: string, Required. The resource name of the update. Format: organizations/{org_id}/locations/{location_id}/workloads/{workload_id}/updates/{update_id} (required)
96+
body: object, The request body.
97+
The object takes the form of:
98+
99+
{ # Request to apply update to a workload.
100+
&quot;action&quot;: &quot;A String&quot;, # The action to be performed on the update.
101+
}
102+
103+
x__xgafv: string, V1 error format.
104+
Allowed values
105+
1 - v1 error format
106+
2 - v2 error format
107+
108+
Returns:
109+
An object of the form:
110+
111+
{ # This resource represents a long-running operation that is the result of a network API call.
112+
&quot;done&quot;: True or False, # If the value is `false`, it means the operation is still in progress. If `true`, the operation is completed, and either `error` or `response` is available.
113+
&quot;error&quot;: { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # The error result of the operation in case of failure or cancellation.
114+
&quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
115+
&quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of message types for APIs to use.
116+
{
117+
&quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
118+
},
119+
],
120+
&quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.
121+
},
122+
&quot;metadata&quot;: { # Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any.
123+
&quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
124+
},
125+
&quot;name&quot;: &quot;A String&quot;, # The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should be a resource name ending with `operations/{unique_id}`.
126+
&quot;response&quot;: { # The normal, successful response of the operation. If the original method returns no data on success, such as `Delete`, the response is `google.protobuf.Empty`. If the original method is standard `Get`/`Create`/`Update`, the response should be the resource. For other methods, the response should have the type `XxxResponse`, where `Xxx` is the original method name. For example, if the original method name is `TakeSnapshot()`, the inferred response type is `TakeSnapshotResponse`.
127+
&quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
128+
},
129+
}</pre>
130+
</div>
131+
132+
<div class="method">
133+
<code class="details" id="close">close()</code>
134+
<pre>Close httplib2 connections.</pre>
135+
</div>
136+
137+
<div class="method">
138+
<code class="details" id="list">list(parent, pageSize=None, pageToken=None, x__xgafv=None)</code>
139+
<pre>This endpoint lists all updates for the given workload.
140+
141+
Args:
142+
parent: string, Required. organizations/{org_id}/locations/{location_id}/workloads/{workload_id} (required)
143+
pageSize: integer, Page size. The default value is 20 and the max allowed value is 100.
144+
pageToken: string, Page token returned from previous request.
145+
x__xgafv: string, V1 error format.
146+
Allowed values
147+
1 - v1 error format
148+
2 - v2 error format
149+
150+
Returns:
151+
An object of the form:
152+
153+
{ # Response of listing the compliance updates per workload with pagination.
154+
&quot;nextPageToken&quot;: &quot;A String&quot;, # The next page token. Return empty if reached the last page.
155+
&quot;workloadUpdates&quot;: [ # The list of workload updates for a given workload.
156+
{ # A workload update is a change to the workload&#x27;s compliance configuration.
157+
&quot;createTime&quot;: &quot;A String&quot;, # The time the update was created.
158+
&quot;details&quot;: { # The details of the update. # The details of the update.
159+
&quot;orgPolicyUpdate&quot;: { # Represents an update for an org policy control applied on an Assured Workload resource. The inherited org policy is not considered. # Update to one org policy, e.g. gcp.resourceLocation.
160+
&quot;appliedPolicy&quot;: { # This assured workload service object is used to represent the org policy attached to a resource. It servces the same purpose as the orgpolicy.v2.Policy object but with functionality that is limited to what is supported by Assured Workloads(e.g. only one rule under one OrgPolicy object, no conditions, etc). # The org policy currently applied on the assured workload resource.
161+
&quot;constraint&quot;: &quot;A String&quot;, # The constraint name of the OrgPolicy. e.g. &quot;constraints/gcp.resourceLocations&quot;.
162+
&quot;inherit&quot;: True or False, # If `inherit` is true, policy rules of the lowest ancestor in the resource hierarchy chain are inherited. If it is false, policy rules are not inherited.
163+
&quot;reset&quot;: True or False, # Ignores policies set above this resource and restores to the `constraint_default` value. `reset` can only be true when `rules` is empty and `inherit` is false.
164+
&quot;resource&quot;: &quot;A String&quot;, # Resource that the OrgPolicy attaches to. Format: folders/123&quot; projects/123&quot;.
165+
&quot;rule&quot;: { # A rule used to express this policy. # The rule of the OrgPolicy.
166+
&quot;allowAll&quot;: True or False, # ListPolicy only when all values are allowed.
167+
&quot;denyAll&quot;: True or False, # ListPolicy only when all values are denied.
168+
&quot;enforce&quot;: True or False, # BooleanPolicy only.
169+
&quot;values&quot;: { # The values allowed for a ListPolicy. # ListPolicy only when custom values are specified.
170+
&quot;allowedValues&quot;: [ # List of values allowed at this resource.
171+
&quot;A String&quot;,
172+
],
173+
&quot;deniedValues&quot;: [ # List of values denied at this resource.
174+
&quot;A String&quot;,
175+
],
176+
},
177+
},
178+
},
179+
&quot;suggestedPolicy&quot;: { # This assured workload service object is used to represent the org policy attached to a resource. It servces the same purpose as the orgpolicy.v2.Policy object but with functionality that is limited to what is supported by Assured Workloads(e.g. only one rule under one OrgPolicy object, no conditions, etc). # The suggested org policy that replaces the applied policy.
180+
&quot;constraint&quot;: &quot;A String&quot;, # The constraint name of the OrgPolicy. e.g. &quot;constraints/gcp.resourceLocations&quot;.
181+
&quot;inherit&quot;: True or False, # If `inherit` is true, policy rules of the lowest ancestor in the resource hierarchy chain are inherited. If it is false, policy rules are not inherited.
182+
&quot;reset&quot;: True or False, # Ignores policies set above this resource and restores to the `constraint_default` value. `reset` can only be true when `rules` is empty and `inherit` is false.
183+
&quot;resource&quot;: &quot;A String&quot;, # Resource that the OrgPolicy attaches to. Format: folders/123&quot; projects/123&quot;.
184+
&quot;rule&quot;: { # A rule used to express this policy. # The rule of the OrgPolicy.
185+
&quot;allowAll&quot;: True or False, # ListPolicy only when all values are allowed.
186+
&quot;denyAll&quot;: True or False, # ListPolicy only when all values are denied.
187+
&quot;enforce&quot;: True or False, # BooleanPolicy only.
188+
&quot;values&quot;: { # The values allowed for a ListPolicy. # ListPolicy only when custom values are specified.
189+
&quot;allowedValues&quot;: [ # List of values allowed at this resource.
190+
&quot;A String&quot;,
191+
],
192+
&quot;deniedValues&quot;: [ # List of values denied at this resource.
193+
&quot;A String&quot;,
194+
],
195+
},
196+
},
197+
},
198+
},
199+
},
200+
&quot;name&quot;: &quot;A String&quot;, # Output only. Immutable. Identifier. Resource name of the WorkloadUpdate. Format: organizations/{organization}/locations/{location}/workloads/{workload}/updates/{update}
201+
&quot;state&quot;: &quot;A String&quot;, # Output only. The state of the update.
202+
&quot;updateTime&quot;: &quot;A String&quot;, # The time the update was last updated.
203+
},
204+
],
205+
}</pre>
206+
</div>
207+
208+
<div class="method">
209+
<code class="details" id="list_next">list_next()</code>
210+
<pre>Retrieves the next page of results.
211+
212+
Args:
213+
previous_request: The request for the previous page. (required)
214+
previous_response: The response from the request for the previous page. (required)
215+
216+
Returns:
217+
A request object that you can call &#x27;execute()&#x27; on to request the next
218+
page. Returns None if there are no more items in the collection.
219+
</pre>
220+
</div>
221+
222+
</body></html>

docs/dyn/assuredworkloads_v1beta1.organizations.locations.workloads.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ <h3>Method Details</h3>
128128
Args:
129129
target: string, Required. The resource ID of the folder-based destination workload. This workload is where the source resource will hypothetically be moved to. Specify the workload&#x27;s relative resource name, formatted as: &quot;organizations/{ORGANIZATION_ID}/locations/{LOCATION_ID}/workloads/{WORKLOAD_ID}&quot; For example: &quot;organizations/123/locations/us-east1/workloads/assured-workload-2&quot; (required)
130130
assetTypes: string, Optional. List of asset types to be analyzed, including and under the source resource. If empty, all assets are analyzed. The complete list of asset types is available [here](https://cloud.google.com/asset-inventory/docs/supported-asset-types). (repeated)
131-
pageSize: integer, Optional. Page size. If a value is not specified, the default value of 10 is used.
131+
pageSize: integer, Optional. Page size. If a value is not specified, the default value of 10 is used. The maximum value is 50.
132132
pageToken: string, Optional. The page token from the previous response. It needs to be passed in the second and following requests.
133133
project: string, The source type is a project. Specify the project&#x27;s relative resource name, formatted as either a project number or a project ID: &quot;projects/{PROJECT_NUMBER}&quot; or &quot;projects/{PROJECT_ID}&quot; For example: &quot;projects/951040570662&quot; when specifying a project number, or &quot;projects/my-project-123&quot; when specifying a project ID.
134134
x__xgafv: string, V1 error format.

0 commit comments

Comments
 (0)