diff --git a/beyondcorp/v1alpha/beyondcorp-api.json b/beyondcorp/v1alpha/beyondcorp-api.json index ec7ee2206c2..0374df65f99 100644 --- a/beyondcorp/v1alpha/beyondcorp-api.json +++ b/beyondcorp/v1alpha/beyondcorp-api.json @@ -123,7 +123,7 @@ ], "parameters": { "parent": { - "description": "Required. The resource name of the PartnerTenant using the form: `organizations/{organization_id}/locations/global`", + "description": "Required. The resource name of the parent organization using the form: `organizations/{organization_id}/locations/global`", "location": "path", "pattern": "^organizations/[^/]+/locations/global$", "required": true, @@ -146,6 +146,36 @@ "https://www.googleapis.com/auth/cloud-platform" ] }, + "delete": { + "description": "Deletes a single PartnerTenant.", + "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/partnerTenants/{partnerTenantsId}", + "httpMethod": "DELETE", + "id": "beyondcorp.organizations.locations.global.partnerTenants.delete", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Name of the resource.", + "location": "path", + "pattern": "^organizations/[^/]+/locations/global/partnerTenants/[^/]+$", + "required": true, + "type": "string" + }, + "requestId": { + "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes after the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + "location": "query", + "type": "string" + } + }, + "path": "v1alpha/{+name}", + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, "get": { "description": "Gets details of a single PartnerTenant.", "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/partnerTenants/{partnerTenantsId}", @@ -170,6 +200,439 @@ "scopes": [ "https://www.googleapis.com/auth/cloud-platform" ] + }, + "getIamPolicy": { + "description": "Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set.", + "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/partnerTenants/{partnerTenantsId}:getIamPolicy", + "httpMethod": "GET", + "id": "beyondcorp.organizations.locations.global.partnerTenants.getIamPolicy", + "parameterOrder": [ + "resource" + ], + "parameters": { + "options.requestedPolicyVersion": { + "description": "Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).", + "format": "int32", + "location": "query", + "type": "integer" + }, + "resource": { + "description": "REQUIRED: The resource for which the policy is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + "location": "path", + "pattern": "^organizations/[^/]+/locations/global/partnerTenants/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+resource}:getIamPolicy", + "response": { + "$ref": "GoogleIamV1Policy" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "list": { + "description": "Lists PartnerTenants in a given organization.", + "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/partnerTenants", + "httpMethod": "GET", + "id": "beyondcorp.organizations.locations.global.partnerTenants.list", + "parameterOrder": [ + "parent" + ], + "parameters": { + "filter": { + "description": "Optional. Filter partnerTenants to be returned. See [List Sub-Collections] (https://cloud.google.com/apis/design/design_patterns#list_sub-collections) for more details. All fields can be used in the filter. Usage: field_filter=\"fieldName1=fieldVal1 AND fieldName2=fieldVal2\". NOTE: Only `AND` conditions are allowed.", + "location": "query", + "type": "string" + }, + "orderBy": { + "description": "Optional. Specifies the ordering of results. Currently, only ordering by the \"name\" and \"create_time\" fields are supported. See [Sorting order](https://cloud.google.com/apis/design/design_patterns#sorting_order) for more information.", + "location": "query", + "type": "string" + }, + "pageSize": { + "description": "Optional. The maximum number of items to return. The service may return fewer than this value. If unspecified, at most 50 items will be returned. The maximum value is 1000; values above 1000 are coerced to 1000. Regardless of the page_size value, the response may include a partial list and a caller should only rely on response's next_page_token to determine if there are more instances left to be queried.", + "format": "int32", + "location": "query", + "type": "integer" + }, + "pageToken": { + "description": "Optional. A token identifying a page of results the server should return.", + "location": "query", + "type": "string" + }, + "parent": { + "description": "Required. The parent organization to which the PartnerTenants belong. Format: `organizations/{organization_id}/locations/global`", + "location": "path", + "pattern": "^organizations/[^/]+/locations/global$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+parent}/partnerTenants", + "response": { + "$ref": "GoogleCloudBeyondcorpPartnerservicesV1alphaListPartnerTenantsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "setIamPolicy": { + "description": "Sets the access control policy on the specified resource. Replaces any existing policy. Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors.", + "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/partnerTenants/{partnerTenantsId}:setIamPolicy", + "httpMethod": "POST", + "id": "beyondcorp.organizations.locations.global.partnerTenants.setIamPolicy", + "parameterOrder": [ + "resource" + ], + "parameters": { + "resource": { + "description": "REQUIRED: The resource for which the policy is being specified. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + "location": "path", + "pattern": "^organizations/[^/]+/locations/global/partnerTenants/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+resource}:setIamPolicy", + "request": { + "$ref": "GoogleIamV1SetIamPolicyRequest" + }, + "response": { + "$ref": "GoogleIamV1Policy" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "testIamPermissions": { + "description": "Returns permissions that a caller has on the specified resource. If the resource does not exist, this will return an empty set of permissions, not a `NOT_FOUND` error. Note: This operation is designed to be used for building permission-aware UIs and command-line tools, not for authorization checking. This operation may \"fail open\" without warning.", + "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/partnerTenants/{partnerTenantsId}:testIamPermissions", + "httpMethod": "POST", + "id": "beyondcorp.organizations.locations.global.partnerTenants.testIamPermissions", + "parameterOrder": [ + "resource" + ], + "parameters": { + "resource": { + "description": "REQUIRED: The resource for which the policy detail is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + "location": "path", + "pattern": "^organizations/[^/]+/locations/global/partnerTenants/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+resource}:testIamPermissions", + "request": { + "$ref": "GoogleIamV1TestIamPermissionsRequest" + }, + "response": { + "$ref": "GoogleIamV1TestIamPermissionsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + }, + "resources": { + "browserDlpRules": { + "methods": { + "create": { + "description": "Creates a new BrowserDlpRule in a given organization and PartnerTenant.", + "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/partnerTenants/{partnerTenantsId}/browserDlpRules", + "httpMethod": "POST", + "id": "beyondcorp.organizations.locations.global.partnerTenants.browserDlpRules.create", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. The resource name of the BrowserDlpRule parent using the form: `organizations/{organization_id}/locations/global/partnerTenants/{partner_tenant_id}`", + "location": "path", + "pattern": "^organizations/[^/]+/locations/global/partnerTenants/[^/]+$", + "required": true, + "type": "string" + }, + "requestId": { + "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + "location": "query", + "type": "string" + } + }, + "path": "v1alpha/{+parent}/browserDlpRules", + "request": { + "$ref": "GoogleCloudBeyondcorpPartnerservicesV1alphaBrowserDlpRule" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "get": { + "description": "Gets details of a single BrowserDlpRule.", + "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/partnerTenants/{partnerTenantsId}/browserDlpRules/{browserDlpRulesId}", + "httpMethod": "GET", + "id": "beyondcorp.organizations.locations.global.partnerTenants.browserDlpRules.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The resource name of the BrowserDlpRule using the form: `organizations/{organization_id}/locations/global/partnerTenants/{partner_tenant_id}/browserDlpRules/{browser_dlp_rule_id}`", + "location": "path", + "pattern": "^organizations/[^/]+/locations/global/partnerTenants/[^/]+/browserDlpRules/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+name}", + "response": { + "$ref": "GoogleCloudBeyondcorpPartnerservicesV1alphaBrowserDlpRule" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "getIamPolicy": { + "description": "Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set.", + "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/partnerTenants/{partnerTenantsId}/browserDlpRules/{browserDlpRulesId}:getIamPolicy", + "httpMethod": "GET", + "id": "beyondcorp.organizations.locations.global.partnerTenants.browserDlpRules.getIamPolicy", + "parameterOrder": [ + "resource" + ], + "parameters": { + "options.requestedPolicyVersion": { + "description": "Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).", + "format": "int32", + "location": "query", + "type": "integer" + }, + "resource": { + "description": "REQUIRED: The resource for which the policy is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + "location": "path", + "pattern": "^organizations/[^/]+/locations/global/partnerTenants/[^/]+/browserDlpRules/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+resource}:getIamPolicy", + "response": { + "$ref": "GoogleIamV1Policy" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "setIamPolicy": { + "description": "Sets the access control policy on the specified resource. Replaces any existing policy. Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors.", + "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/partnerTenants/{partnerTenantsId}/browserDlpRules/{browserDlpRulesId}:setIamPolicy", + "httpMethod": "POST", + "id": "beyondcorp.organizations.locations.global.partnerTenants.browserDlpRules.setIamPolicy", + "parameterOrder": [ + "resource" + ], + "parameters": { + "resource": { + "description": "REQUIRED: The resource for which the policy is being specified. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + "location": "path", + "pattern": "^organizations/[^/]+/locations/global/partnerTenants/[^/]+/browserDlpRules/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+resource}:setIamPolicy", + "request": { + "$ref": "GoogleIamV1SetIamPolicyRequest" + }, + "response": { + "$ref": "GoogleIamV1Policy" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "testIamPermissions": { + "description": "Returns permissions that a caller has on the specified resource. If the resource does not exist, this will return an empty set of permissions, not a `NOT_FOUND` error. Note: This operation is designed to be used for building permission-aware UIs and command-line tools, not for authorization checking. This operation may \"fail open\" without warning.", + "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/partnerTenants/{partnerTenantsId}/browserDlpRules/{browserDlpRulesId}:testIamPermissions", + "httpMethod": "POST", + "id": "beyondcorp.organizations.locations.global.partnerTenants.browserDlpRules.testIamPermissions", + "parameterOrder": [ + "resource" + ], + "parameters": { + "resource": { + "description": "REQUIRED: The resource for which the policy detail is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + "location": "path", + "pattern": "^organizations/[^/]+/locations/global/partnerTenants/[^/]+/browserDlpRules/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+resource}:testIamPermissions", + "request": { + "$ref": "GoogleIamV1TestIamPermissionsRequest" + }, + "response": { + "$ref": "GoogleIamV1TestIamPermissionsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } + }, + "proxyConfigs": { + "methods": { + "create": { + "description": "Creates a new BeyondCorp Enterprise ProxyConfig in a given organization and PartnerTenant. Can only be called by on onboarded Beyondcorp Enterprise partner.", + "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/partnerTenants/{partnerTenantsId}/proxyConfigs", + "httpMethod": "POST", + "id": "beyondcorp.organizations.locations.global.partnerTenants.proxyConfigs.create", + "parameterOrder": [ + "parent" + ], + "parameters": { + "parent": { + "description": "Required. The resource name of the Tenant using the form: `organizations/{organization_id}/locations/global/tenants/{tenant_id}`", + "location": "path", + "pattern": "^organizations/[^/]+/locations/global/partnerTenants/[^/]+$", + "required": true, + "type": "string" + }, + "requestId": { + "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + "location": "query", + "type": "string" + } + }, + "path": "v1alpha/{+parent}/proxyConfigs", + "request": { + "$ref": "GoogleCloudBeyondcorpPartnerservicesV1alphaProxyConfig" + }, + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "get": { + "description": "Gets details of a single ProxyConfig.", + "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/partnerTenants/{partnerTenantsId}/proxyConfigs/{proxyConfigsId}", + "httpMethod": "GET", + "id": "beyondcorp.organizations.locations.global.partnerTenants.proxyConfigs.get", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. The resource name of the ProxyConfig using the form: `organizations/{organization_id}/locations/global/tenants/{tenant_id}/proxyConfigs/{proxy_config_id}`", + "location": "path", + "pattern": "^organizations/[^/]+/locations/global/partnerTenants/[^/]+/proxyConfigs/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+name}", + "response": { + "$ref": "GoogleCloudBeyondcorpPartnerservicesV1alphaProxyConfig" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "getIamPolicy": { + "description": "Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set.", + "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/partnerTenants/{partnerTenantsId}/proxyConfigs/{proxyConfigsId}:getIamPolicy", + "httpMethod": "GET", + "id": "beyondcorp.organizations.locations.global.partnerTenants.proxyConfigs.getIamPolicy", + "parameterOrder": [ + "resource" + ], + "parameters": { + "options.requestedPolicyVersion": { + "description": "Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).", + "format": "int32", + "location": "query", + "type": "integer" + }, + "resource": { + "description": "REQUIRED: The resource for which the policy is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + "location": "path", + "pattern": "^organizations/[^/]+/locations/global/partnerTenants/[^/]+/proxyConfigs/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+resource}:getIamPolicy", + "response": { + "$ref": "GoogleIamV1Policy" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "setIamPolicy": { + "description": "Sets the access control policy on the specified resource. Replaces any existing policy. Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors.", + "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/partnerTenants/{partnerTenantsId}/proxyConfigs/{proxyConfigsId}:setIamPolicy", + "httpMethod": "POST", + "id": "beyondcorp.organizations.locations.global.partnerTenants.proxyConfigs.setIamPolicy", + "parameterOrder": [ + "resource" + ], + "parameters": { + "resource": { + "description": "REQUIRED: The resource for which the policy is being specified. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + "location": "path", + "pattern": "^organizations/[^/]+/locations/global/partnerTenants/[^/]+/proxyConfigs/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+resource}:setIamPolicy", + "request": { + "$ref": "GoogleIamV1SetIamPolicyRequest" + }, + "response": { + "$ref": "GoogleIamV1Policy" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, + "testIamPermissions": { + "description": "Returns permissions that a caller has on the specified resource. If the resource does not exist, this will return an empty set of permissions, not a `NOT_FOUND` error. Note: This operation is designed to be used for building permission-aware UIs and command-line tools, not for authorization checking. This operation may \"fail open\" without warning.", + "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/partnerTenants/{partnerTenantsId}/proxyConfigs/{proxyConfigsId}:testIamPermissions", + "httpMethod": "POST", + "id": "beyondcorp.organizations.locations.global.partnerTenants.proxyConfigs.testIamPermissions", + "parameterOrder": [ + "resource" + ], + "parameters": { + "resource": { + "description": "REQUIRED: The resource for which the policy detail is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + "location": "path", + "pattern": "^organizations/[^/]+/locations/global/partnerTenants/[^/]+/proxyConfigs/[^/]+$", + "required": true, + "type": "string" + } + }, + "path": "v1alpha/{+resource}:testIamPermissions", + "request": { + "$ref": "GoogleIamV1TestIamPermissionsRequest" + }, + "response": { + "$ref": "GoogleIamV1TestIamPermissionsResponse" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + } + } } } }, @@ -208,6 +671,36 @@ "https://www.googleapis.com/auth/cloud-platform" ] }, + "delete": { + "description": "Deletes a single Tenant.", + "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/tenants/{tenantsId}", + "httpMethod": "DELETE", + "id": "beyondcorp.organizations.locations.global.tenants.delete", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Name of the resource.", + "location": "path", + "pattern": "^organizations/[^/]+/locations/global/tenants/[^/]+$", + "required": true, + "type": "string" + }, + "requestId": { + "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes after the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + "location": "query", + "type": "string" + } + }, + "path": "v1alpha/{+name}", + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, "get": { "description": "Gets details of a single Tenant.", "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/tenants/{tenantsId}", @@ -238,7 +731,7 @@ "proxyConfigs": { "methods": { "create": { - "description": "Creates a new BeyondCorp Enterprise ProxyConfiguration in a given organization and PartnerTenant. Can only be called by on onboarded Beyondcorp Enterprise partner.", + "description": "Creates a new BeyondCorp Enterprise ProxyConfig in a given organization and Tenant. Can only be called by on onboarded Beyondcorp Enterprise partner.", "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/tenants/{tenantsId}/proxyConfigs", "httpMethod": "POST", "id": "beyondcorp.organizations.locations.global.tenants.proxyConfigs.create", @@ -247,7 +740,7 @@ ], "parameters": { "parent": { - "description": "Required. The resource name of the ProxyConfig using the form: `organizations/{organization_id}/locations/global/tenants/{tenant_id}`", + "description": "Required. The resource name of the Tenant using the form: `organizations/{organization_id}/locations/global/tenants/{tenant_id}`", "location": "path", "pattern": "^organizations/[^/]+/locations/global/tenants/[^/]+$", "required": true, @@ -270,6 +763,36 @@ "https://www.googleapis.com/auth/cloud-platform" ] }, + "delete": { + "description": "Deletes a single ProxyConfig.", + "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/tenants/{tenantsId}/proxyConfigs/{proxyConfigsId}", + "httpMethod": "DELETE", + "id": "beyondcorp.organizations.locations.global.tenants.proxyConfigs.delete", + "parameterOrder": [ + "name" + ], + "parameters": { + "name": { + "description": "Required. Name of the resource.", + "location": "path", + "pattern": "^organizations/[^/]+/locations/global/tenants/[^/]+/proxyConfigs/[^/]+$", + "required": true, + "type": "string" + }, + "requestId": { + "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes after the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + "location": "query", + "type": "string" + } + }, + "path": "v1alpha/{+name}", + "response": { + "$ref": "GoogleLongrunningOperation" + }, + "scopes": [ + "https://www.googleapis.com/auth/cloud-platform" + ] + }, "get": { "description": "Gets details of a single ProxyConfig.", "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/tenants/{tenantsId}/proxyConfigs/{proxyConfigsId}", @@ -280,7 +803,7 @@ ], "parameters": { "name": { - "description": "Required. The resource name of the Tenant using the form: `organizations/{organization_id}/locations/global/tenants/{tenant_id}/proxyConfigs/{proxy_config_id}`", + "description": "Required. The resource name of the ProxyConfig using the form: `organizations/{organization_id}/locations/global/tenants/{tenant_id}/proxyConfigs/{proxy_config_id}`", "location": "path", "pattern": "^organizations/[^/]+/locations/global/tenants/[^/]+/proxyConfigs/[^/]+$", "required": true, @@ -3264,7 +3787,7 @@ } } }, - "revision": "20230509", + "revision": "20230517", "rootUrl": "https://beyondcorp.googleapis.com/", "schemas": { "AllocatedConnection": { @@ -4893,6 +5416,26 @@ }, "type": "object" }, + "GoogleCloudBeyondcorpPartnerservicesV1alphaBrowserDlpRule": { + "description": "Browser DLP Rule for a PartnerTenant", + "id": "GoogleCloudBeyondcorpPartnerservicesV1alphaBrowserDlpRule", + "properties": { + "group": { + "$ref": "GoogleCloudBeyondcorpPartnerservicesV1alphaGroup", + "description": "Required. The group to which this Rule should be applied to." + }, + "name": { + "description": "Output only. Unique resource name. The name is ignored when creating BrowserDlpRule.", + "readOnly": true, + "type": "string" + }, + "ruleSetting": { + "$ref": "GoogleCloudBeyondcorpPartnerservicesV1alphaRuleSetting", + "description": "Required. The policy settings to apply." + } + }, + "type": "object" + }, "GoogleCloudBeyondcorpPartnerservicesV1alphaEncryptionInfo": { "description": "Message contains the JWT encryption information for the proxy server.", "id": "GoogleCloudBeyondcorpPartnerservicesV1alphaEncryptionInfo", @@ -4908,6 +5451,46 @@ }, "type": "object" }, + "GoogleCloudBeyondcorpPartnerservicesV1alphaGroup": { + "description": "Message to capture group information", + "id": "GoogleCloudBeyondcorpPartnerservicesV1alphaGroup", + "properties": { + "email": { + "description": "The group email id", + "type": "string" + }, + "id": { + "description": "Google group id", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudBeyondcorpPartnerservicesV1alphaListPartnerTenantsResponse": { + "description": "Message for response to listing PartnerTenants.", + "id": "GoogleCloudBeyondcorpPartnerservicesV1alphaListPartnerTenantsResponse", + "properties": { + "nextPageToken": { + "description": "A token which can be sent as `page_token` to retrieve the next page. If this field is omitted, there are no subsequent pages.", + "type": "string" + }, + "partnerTenants": { + "description": "The list of PartnerTenant objects.", + "items": { + "$ref": "GoogleCloudBeyondcorpPartnerservicesV1alphaPartnerTenant" + }, + "type": "array" + }, + "unreachable": { + "description": "Locations that could not be reached.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, "GoogleCloudBeyondcorpPartnerservicesV1alphaPartnerMetadata": { "description": "Metadata associated with PartnerTenant and is provided by the Partner.", "id": "GoogleCloudBeyondcorpPartnerservicesV1alphaPartnerMetadata", @@ -5058,6 +5641,25 @@ }, "type": "object" }, + "GoogleCloudBeyondcorpPartnerservicesV1alphaRuleSetting": { + "description": "Message to capture settings for a BrowserDlpRule", + "id": "GoogleCloudBeyondcorpPartnerservicesV1alphaRuleSetting", + "properties": { + "type": { + "description": "Required. Immutable. The type of the Setting. .", + "type": "string" + }, + "value": { + "additionalProperties": { + "description": "Properties of the object.", + "type": "any" + }, + "description": "Required. The value of the Setting.", + "type": "object" + } + }, + "type": "object" + }, "GoogleCloudBeyondcorpPartnerservicesV1alphaTenant": { "description": "Information about a BeyoncCorp Enterprise Tenant.", "id": "GoogleCloudBeyondcorpPartnerservicesV1alphaTenant", diff --git a/beyondcorp/v1alpha/beyondcorp-gen.go b/beyondcorp/v1alpha/beyondcorp-gen.go index 6acb591bc7c..bd2fc614390 100644 --- a/beyondcorp/v1alpha/beyondcorp-gen.go +++ b/beyondcorp/v1alpha/beyondcorp-gen.go @@ -188,11 +188,35 @@ type OrganizationsLocationsGlobalService struct { func NewOrganizationsLocationsGlobalPartnerTenantsService(s *Service) *OrganizationsLocationsGlobalPartnerTenantsService { rs := &OrganizationsLocationsGlobalPartnerTenantsService{s: s} + rs.BrowserDlpRules = NewOrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesService(s) + rs.ProxyConfigs = NewOrganizationsLocationsGlobalPartnerTenantsProxyConfigsService(s) return rs } type OrganizationsLocationsGlobalPartnerTenantsService struct { s *Service + + BrowserDlpRules *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesService + + ProxyConfigs *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsService +} + +func NewOrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesService(s *Service) *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesService { + rs := &OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesService{s: s} + return rs +} + +type OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesService struct { + s *Service +} + +func NewOrganizationsLocationsGlobalPartnerTenantsProxyConfigsService(s *Service) *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsService { + rs := &OrganizationsLocationsGlobalPartnerTenantsProxyConfigsService{s: s} + return rs +} + +type OrganizationsLocationsGlobalPartnerTenantsProxyConfigsService struct { + s *Service } func NewOrganizationsLocationsGlobalTenantsService(s *Service) *OrganizationsLocationsGlobalTenantsService { @@ -2635,6 +2659,46 @@ func (s *GoogleCloudBeyondcorpAppgatewaysV1AppGatewayOperationMetadata) MarshalJ return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudBeyondcorpPartnerservicesV1alphaBrowserDlpRule: Browser +// DLP Rule for a PartnerTenant +type GoogleCloudBeyondcorpPartnerservicesV1alphaBrowserDlpRule struct { + // Group: Required. The group to which this Rule should be applied to. + Group *GoogleCloudBeyondcorpPartnerservicesV1alphaGroup `json:"group,omitempty"` + + // Name: Output only. Unique resource name. The name is ignored when + // creating BrowserDlpRule. + Name string `json:"name,omitempty"` + + // RuleSetting: Required. The policy settings to apply. + RuleSetting *GoogleCloudBeyondcorpPartnerservicesV1alphaRuleSetting `json:"ruleSetting,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "Group") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Group") to include in API + // requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudBeyondcorpPartnerservicesV1alphaBrowserDlpRule) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudBeyondcorpPartnerservicesV1alphaBrowserDlpRule + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudBeyondcorpPartnerservicesV1alphaEncryptionInfo: Message // contains the JWT encryption information for the proxy server. type GoogleCloudBeyondcorpPartnerservicesV1alphaEncryptionInfo struct { @@ -2668,6 +2732,80 @@ func (s *GoogleCloudBeyondcorpPartnerservicesV1alphaEncryptionInfo) MarshalJSON( return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudBeyondcorpPartnerservicesV1alphaGroup: Message to capture +// group information +type GoogleCloudBeyondcorpPartnerservicesV1alphaGroup struct { + // Email: The group email id + Email string `json:"email,omitempty"` + + // Id: Google group id + Id string `json:"id,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Email") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Email") to include in API + // requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudBeyondcorpPartnerservicesV1alphaGroup) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudBeyondcorpPartnerservicesV1alphaGroup + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudBeyondcorpPartnerservicesV1alphaListPartnerTenantsResponse: +// +// Message for response to listing PartnerTenants. +type GoogleCloudBeyondcorpPartnerservicesV1alphaListPartnerTenantsResponse struct { + // NextPageToken: A token which can be sent as `page_token` to retrieve + // the next page. If this field is omitted, there are no subsequent + // pages. + NextPageToken string `json:"nextPageToken,omitempty"` + + // PartnerTenants: The list of PartnerTenant objects. + PartnerTenants []*GoogleCloudBeyondcorpPartnerservicesV1alphaPartnerTenant `json:"partnerTenants,omitempty"` + + // Unreachable: Locations that could not be reached. + Unreachable []string `json:"unreachable,omitempty"` + + // ServerResponse contains the HTTP response code and headers from the + // server. + googleapi.ServerResponse `json:"-"` + + // ForceSendFields is a list of field names (e.g. "NextPageToken") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "NextPageToken") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudBeyondcorpPartnerservicesV1alphaListPartnerTenantsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudBeyondcorpPartnerservicesV1alphaListPartnerTenantsResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudBeyondcorpPartnerservicesV1alphaPartnerMetadata: Metadata // associated with PartnerTenant and is provided by the Partner. type GoogleCloudBeyondcorpPartnerservicesV1alphaPartnerMetadata struct { @@ -2897,6 +3035,38 @@ func (s *GoogleCloudBeyondcorpPartnerservicesV1alphaRoutingInfo) MarshalJSON() ( return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudBeyondcorpPartnerservicesV1alphaRuleSetting: Message to +// capture settings for a BrowserDlpRule +type GoogleCloudBeyondcorpPartnerservicesV1alphaRuleSetting struct { + // Type: Required. Immutable. The type of the Setting. . + Type string `json:"type,omitempty"` + + // Value: Required. The value of the Setting. + Value googleapi.RawMessage `json:"value,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Type") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Type") to include in API + // requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudBeyondcorpPartnerservicesV1alphaRuleSetting) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudBeyondcorpPartnerservicesV1alphaRuleSetting + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudBeyondcorpPartnerservicesV1alphaTenant: Information about // a BeyoncCorp Enterprise Tenant. type GoogleCloudBeyondcorpPartnerservicesV1alphaTenant struct { @@ -4903,8 +5073,8 @@ type OrganizationsLocationsGlobalPartnerTenantsCreateCall struct { // organization and can only be called by onboarded BeyondCorp // Enterprise partner. // -// - parent: The resource name of the PartnerTenant using the form: -// `organizations/{organization_id}/locations/global`. +// - parent: The resource name of the parent organization using the +// form: `organizations/{organization_id}/locations/global`. func (r *OrganizationsLocationsGlobalPartnerTenantsService) Create(parent string, googlecloudbeyondcorppartnerservicesv1alphapartnertenant *GoogleCloudBeyondcorpPartnerservicesV1alphaPartnerTenant) *OrganizationsLocationsGlobalPartnerTenantsCreateCall { c := &OrganizationsLocationsGlobalPartnerTenantsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.parent = parent @@ -5030,7 +5200,7 @@ func (c *OrganizationsLocationsGlobalPartnerTenantsCreateCall) Do(opts ...google // ], // "parameters": { // "parent": { - // "description": "Required. The resource name of the PartnerTenant using the form: `organizations/{organization_id}/locations/global`", + // "description": "Required. The resource name of the parent organization using the form: `organizations/{organization_id}/locations/global`", // "location": "path", // "pattern": "^organizations/[^/]+/locations/global$", // "required": true, @@ -5056,79 +5226,81 @@ func (c *OrganizationsLocationsGlobalPartnerTenantsCreateCall) Do(opts ...google } -// method id "beyondcorp.organizations.locations.global.partnerTenants.get": +// method id "beyondcorp.organizations.locations.global.partnerTenants.delete": -type OrganizationsLocationsGlobalPartnerTenantsGetCall struct { - s *Service - name string - urlParams_ gensupport.URLParams - ifNoneMatch_ string - ctx_ context.Context - header_ http.Header +type OrganizationsLocationsGlobalPartnerTenantsDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header } -// Get: Gets details of a single PartnerTenant. +// Delete: Deletes a single PartnerTenant. // -// - name: The resource name of the PartnerTenant using the form: -// `organizations/{organization_id}/locations/global/partnerTenants/{pa -// rtner_tenant_id}`. -func (r *OrganizationsLocationsGlobalPartnerTenantsService) Get(name string) *OrganizationsLocationsGlobalPartnerTenantsGetCall { - c := &OrganizationsLocationsGlobalPartnerTenantsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} +// - name: Name of the resource. +func (r *OrganizationsLocationsGlobalPartnerTenantsService) Delete(name string) *OrganizationsLocationsGlobalPartnerTenantsDeleteCall { + c := &OrganizationsLocationsGlobalPartnerTenantsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} c.name = name return c } +// RequestId sets the optional parameter "requestId": An optional +// request ID to identify requests. Specify a unique request ID so that +// if you must retry your request, the server will know to ignore the +// request if it has already been completed. The server will guarantee +// that for at least 60 minutes after the first request. For example, +// consider a situation where you make an initial request and the +// request times out. If you make the request again with the same +// request ID, the server can check if original operation with the same +// request ID was received, and if so, will ignore the second request. +// This prevents clients from accidentally creating duplicate +// commitments. The request ID must be a valid UUID with the exception +// that zero UUID is not supported +// (00000000-0000-0000-0000-000000000000). +func (c *OrganizationsLocationsGlobalPartnerTenantsDeleteCall) RequestId(requestId string) *OrganizationsLocationsGlobalPartnerTenantsDeleteCall { + c.urlParams_.Set("requestId", requestId) + return c +} + // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *OrganizationsLocationsGlobalPartnerTenantsGetCall) Fields(s ...googleapi.Field) *OrganizationsLocationsGlobalPartnerTenantsGetCall { +func (c *OrganizationsLocationsGlobalPartnerTenantsDeleteCall) Fields(s ...googleapi.Field) *OrganizationsLocationsGlobalPartnerTenantsDeleteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } -// IfNoneMatch sets the optional parameter which makes the operation -// fail if the object's ETag matches the given value. This is useful for -// getting updates only after the object has changed since the last -// request. Use googleapi.IsNotModified to check whether the response -// error from Do is the result of In-None-Match. -func (c *OrganizationsLocationsGlobalPartnerTenantsGetCall) IfNoneMatch(entityTag string) *OrganizationsLocationsGlobalPartnerTenantsGetCall { - c.ifNoneMatch_ = entityTag - return c -} - // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *OrganizationsLocationsGlobalPartnerTenantsGetCall) Context(ctx context.Context) *OrganizationsLocationsGlobalPartnerTenantsGetCall { +func (c *OrganizationsLocationsGlobalPartnerTenantsDeleteCall) Context(ctx context.Context) *OrganizationsLocationsGlobalPartnerTenantsDeleteCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *OrganizationsLocationsGlobalPartnerTenantsGetCall) Header() http.Header { +func (c *OrganizationsLocationsGlobalPartnerTenantsDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *OrganizationsLocationsGlobalPartnerTenantsGetCall) doRequest(alt string) (*http.Response, error) { +func (c *OrganizationsLocationsGlobalPartnerTenantsDeleteCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { reqHeaders[k] = v } reqHeaders.Set("User-Agent", c.s.userAgent()) - if c.ifNoneMatch_ != "" { - reqHeaders.Set("If-None-Match", c.ifNoneMatch_) - } var body io.Reader = nil c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("GET", urls, body) + req, err := http.NewRequest("DELETE", urls, body) if err != nil { return nil, err } @@ -5139,17 +5311,14 @@ func (c *OrganizationsLocationsGlobalPartnerTenantsGetCall) doRequest(alt string return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "beyondcorp.organizations.locations.global.partnerTenants.get" call. -// Exactly one of -// *GoogleCloudBeyondcorpPartnerservicesV1alphaPartnerTenant or error -// will be non-nil. Any non-2xx status code is an error. Response -// headers are in either -// *GoogleCloudBeyondcorpPartnerservicesV1alphaPartnerTenant.ServerRespon -// se.Header or (if a response was returned at all) in -// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check -// whether the returned error was because http.StatusNotModified was -// returned. -func (c *OrganizationsLocationsGlobalPartnerTenantsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudBeyondcorpPartnerservicesV1alphaPartnerTenant, error) { +// Do executes the "beyondcorp.organizations.locations.global.partnerTenants.delete" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleLongrunningOperation.ServerResponse.Header or (if a response +// was returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was +// because http.StatusNotModified was returned. +func (c *OrganizationsLocationsGlobalPartnerTenantsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -5168,7 +5337,7 @@ func (c *OrganizationsLocationsGlobalPartnerTenantsGetCall) Do(opts ...googleapi if err := googleapi.CheckResponse(res); err != nil { return nil, gensupport.WrapError(err) } - ret := &GoogleCloudBeyondcorpPartnerservicesV1alphaPartnerTenant{ + ret := &GoogleLongrunningOperation{ ServerResponse: googleapi.ServerResponse{ Header: res.Header, HTTPStatusCode: res.StatusCode, @@ -5180,25 +5349,30 @@ func (c *OrganizationsLocationsGlobalPartnerTenantsGetCall) Do(opts ...googleapi } return ret, nil // { - // "description": "Gets details of a single PartnerTenant.", + // "description": "Deletes a single PartnerTenant.", // "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/partnerTenants/{partnerTenantsId}", - // "httpMethod": "GET", - // "id": "beyondcorp.organizations.locations.global.partnerTenants.get", + // "httpMethod": "DELETE", + // "id": "beyondcorp.organizations.locations.global.partnerTenants.delete", // "parameterOrder": [ // "name" // ], // "parameters": { // "name": { - // "description": "Required. The resource name of the PartnerTenant using the form: `organizations/{organization_id}/locations/global/partnerTenants/{partner_tenant_id}`", + // "description": "Required. Name of the resource.", // "location": "path", // "pattern": "^organizations/[^/]+/locations/global/partnerTenants/[^/]+$", // "required": true, // "type": "string" + // }, + // "requestId": { + // "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes after the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + // "location": "query", + // "type": "string" // } // }, // "path": "v1alpha/{+name}", // "response": { - // "$ref": "GoogleCloudBeyondcorpPartnerservicesV1alphaPartnerTenant" + // "$ref": "GoogleLongrunningOperation" // }, // "scopes": [ // "https://www.googleapis.com/auth/cloud-platform" @@ -5207,43 +5381,2487 @@ func (c *OrganizationsLocationsGlobalPartnerTenantsGetCall) Do(opts ...googleapi } -// method id "beyondcorp.organizations.locations.global.tenants.create": +// method id "beyondcorp.organizations.locations.global.partnerTenants.get": -type OrganizationsLocationsGlobalTenantsCreateCall struct { - s *Service - parent string - googlecloudbeyondcorppartnerservicesv1alphatenant *GoogleCloudBeyondcorpPartnerservicesV1alphaTenant - urlParams_ gensupport.URLParams - ctx_ context.Context - header_ http.Header +type OrganizationsLocationsGlobalPartnerTenantsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header } -// Create: Creates a new BeyondCorp Enterprise tenant in a given -// organization and can only be called by onboarded BeyondCorp -// Enterprise partner. +// Get: Gets details of a single PartnerTenant. // -// - parent: The resource name of the Tenant using the form: -// `organizations/{organization_id}/locations/global`. -func (r *OrganizationsLocationsGlobalTenantsService) Create(parent string, googlecloudbeyondcorppartnerservicesv1alphatenant *GoogleCloudBeyondcorpPartnerservicesV1alphaTenant) *OrganizationsLocationsGlobalTenantsCreateCall { - c := &OrganizationsLocationsGlobalTenantsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} - c.parent = parent - c.googlecloudbeyondcorppartnerservicesv1alphatenant = googlecloudbeyondcorppartnerservicesv1alphatenant +// - name: The resource name of the PartnerTenant using the form: +// `organizations/{organization_id}/locations/global/partnerTenants/{pa +// rtner_tenant_id}`. +func (r *OrganizationsLocationsGlobalPartnerTenantsService) Get(name string) *OrganizationsLocationsGlobalPartnerTenantsGetCall { + c := &OrganizationsLocationsGlobalPartnerTenantsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name return c } -// RequestId sets the optional parameter "requestId": An optional -// request ID to identify requests. Specify a unique request ID so that -// if you must retry your request, the server will know to ignore the -// request if it has already been completed. The server will guarantee -// that for at least 60 minutes since the first request. For example, -// consider a situation where you make an initial request and the -// request times out. If you make the request again with the same -// request ID, the server can check if original operation with the same -// request ID was received, and if so, will ignore the second request. -// This prevents clients from accidentally creating duplicate -// commitments. The request ID must be a valid UUID with the exception -// that zero UUID is not supported -// (00000000-0000-0000-0000-000000000000). +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *OrganizationsLocationsGlobalPartnerTenantsGetCall) Fields(s ...googleapi.Field) *OrganizationsLocationsGlobalPartnerTenantsGetCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets the optional parameter which makes the operation +// fail if the object's ETag matches the given value. This is useful for +// getting updates only after the object has changed since the last +// request. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *OrganizationsLocationsGlobalPartnerTenantsGetCall) IfNoneMatch(entityTag string) *OrganizationsLocationsGlobalPartnerTenantsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *OrganizationsLocationsGlobalPartnerTenantsGetCall) Context(ctx context.Context) *OrganizationsLocationsGlobalPartnerTenantsGetCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *OrganizationsLocationsGlobalPartnerTenantsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *OrganizationsLocationsGlobalPartnerTenantsGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "beyondcorp.organizations.locations.global.partnerTenants.get" call. +// Exactly one of +// *GoogleCloudBeyondcorpPartnerservicesV1alphaPartnerTenant or error +// will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudBeyondcorpPartnerservicesV1alphaPartnerTenant.ServerRespon +// se.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was +// returned. +func (c *OrganizationsLocationsGlobalPartnerTenantsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudBeyondcorpPartnerservicesV1alphaPartnerTenant, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleCloudBeyondcorpPartnerservicesV1alphaPartnerTenant{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Gets details of a single PartnerTenant.", + // "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/partnerTenants/{partnerTenantsId}", + // "httpMethod": "GET", + // "id": "beyondcorp.organizations.locations.global.partnerTenants.get", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. The resource name of the PartnerTenant using the form: `organizations/{organization_id}/locations/global/partnerTenants/{partner_tenant_id}`", + // "location": "path", + // "pattern": "^organizations/[^/]+/locations/global/partnerTenants/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1alpha/{+name}", + // "response": { + // "$ref": "GoogleCloudBeyondcorpPartnerservicesV1alphaPartnerTenant" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "beyondcorp.organizations.locations.global.partnerTenants.getIamPolicy": + +type OrganizationsLocationsGlobalPartnerTenantsGetIamPolicyCall struct { + s *Service + resource string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// GetIamPolicy: Gets the access control policy for a resource. Returns +// an empty policy if the resource exists and does not have a policy +// set. +// +// - resource: REQUIRED: The resource for which the policy is being +// requested. See Resource names +// (https://cloud.google.com/apis/design/resource_names) for the +// appropriate value for this field. +func (r *OrganizationsLocationsGlobalPartnerTenantsService) GetIamPolicy(resource string) *OrganizationsLocationsGlobalPartnerTenantsGetIamPolicyCall { + c := &OrganizationsLocationsGlobalPartnerTenantsGetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.resource = resource + return c +} + +// OptionsRequestedPolicyVersion sets the optional parameter +// "options.requestedPolicyVersion": The maximum policy version that +// will be used to format the policy. Valid values are 0, 1, and 3. +// Requests specifying an invalid value will be rejected. Requests for +// policies with any conditional role bindings must specify version 3. +// Policies with no conditional role bindings may specify any valid +// value or leave the field unset. The policy in the response might use +// the policy version that you specified, or it might use a lower policy +// version. For example, if you specify version 3, but the policy has no +// conditional role bindings, the response uses version 1. To learn +// which resources support conditions in their IAM policies, see the IAM +// documentation +// (https://cloud.google.com/iam/help/conditions/resource-policies). +func (c *OrganizationsLocationsGlobalPartnerTenantsGetIamPolicyCall) OptionsRequestedPolicyVersion(optionsRequestedPolicyVersion int64) *OrganizationsLocationsGlobalPartnerTenantsGetIamPolicyCall { + c.urlParams_.Set("options.requestedPolicyVersion", fmt.Sprint(optionsRequestedPolicyVersion)) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *OrganizationsLocationsGlobalPartnerTenantsGetIamPolicyCall) Fields(s ...googleapi.Field) *OrganizationsLocationsGlobalPartnerTenantsGetIamPolicyCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets the optional parameter which makes the operation +// fail if the object's ETag matches the given value. This is useful for +// getting updates only after the object has changed since the last +// request. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *OrganizationsLocationsGlobalPartnerTenantsGetIamPolicyCall) IfNoneMatch(entityTag string) *OrganizationsLocationsGlobalPartnerTenantsGetIamPolicyCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *OrganizationsLocationsGlobalPartnerTenantsGetIamPolicyCall) Context(ctx context.Context) *OrganizationsLocationsGlobalPartnerTenantsGetIamPolicyCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *OrganizationsLocationsGlobalPartnerTenantsGetIamPolicyCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *OrganizationsLocationsGlobalPartnerTenantsGetIamPolicyCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+resource}:getIamPolicy") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "resource": c.resource, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "beyondcorp.organizations.locations.global.partnerTenants.getIamPolicy" call. +// Exactly one of *GoogleIamV1Policy or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *GoogleIamV1Policy.ServerResponse.Header or (if a response was +// returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was +// because http.StatusNotModified was returned. +func (c *OrganizationsLocationsGlobalPartnerTenantsGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*GoogleIamV1Policy, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleIamV1Policy{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set.", + // "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/partnerTenants/{partnerTenantsId}:getIamPolicy", + // "httpMethod": "GET", + // "id": "beyondcorp.organizations.locations.global.partnerTenants.getIamPolicy", + // "parameterOrder": [ + // "resource" + // ], + // "parameters": { + // "options.requestedPolicyVersion": { + // "description": "Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "resource": { + // "description": "REQUIRED: The resource for which the policy is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + // "location": "path", + // "pattern": "^organizations/[^/]+/locations/global/partnerTenants/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1alpha/{+resource}:getIamPolicy", + // "response": { + // "$ref": "GoogleIamV1Policy" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "beyondcorp.organizations.locations.global.partnerTenants.list": + +type OrganizationsLocationsGlobalPartnerTenantsListCall struct { + s *Service + parent string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// List: Lists PartnerTenants in a given organization. +// +// - parent: The parent organization to which the PartnerTenants belong. +// Format: `organizations/{organization_id}/locations/global`. +func (r *OrganizationsLocationsGlobalPartnerTenantsService) List(parent string) *OrganizationsLocationsGlobalPartnerTenantsListCall { + c := &OrganizationsLocationsGlobalPartnerTenantsListCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + return c +} + +// Filter sets the optional parameter "filter": Filter partnerTenants to +// be returned. See [List Sub-Collections] +// (https://cloud.google.com/apis/design/design_patterns#list_sub-collections) +// for more details. All fields can be used in the filter. Usage: +// field_filter="fieldName1=fieldVal1 AND fieldName2=fieldVal2". NOTE: +// Only `AND` conditions are allowed. +func (c *OrganizationsLocationsGlobalPartnerTenantsListCall) Filter(filter string) *OrganizationsLocationsGlobalPartnerTenantsListCall { + c.urlParams_.Set("filter", filter) + return c +} + +// OrderBy sets the optional parameter "orderBy": Specifies the ordering +// of results. Currently, only ordering by the "name" and "create_time" +// fields are supported. See Sorting order +// (https://cloud.google.com/apis/design/design_patterns#sorting_order) +// for more information. +func (c *OrganizationsLocationsGlobalPartnerTenantsListCall) OrderBy(orderBy string) *OrganizationsLocationsGlobalPartnerTenantsListCall { + c.urlParams_.Set("orderBy", orderBy) + return c +} + +// PageSize sets the optional parameter "pageSize": The maximum number +// of items to return. The service may return fewer than this value. If +// unspecified, at most 50 items will be returned. The maximum value is +// 1000; values above 1000 are coerced to 1000. Regardless of the +// page_size value, the response may include a partial list and a caller +// should only rely on response's next_page_token to determine if there +// are more instances left to be queried. +func (c *OrganizationsLocationsGlobalPartnerTenantsListCall) PageSize(pageSize int64) *OrganizationsLocationsGlobalPartnerTenantsListCall { + c.urlParams_.Set("pageSize", fmt.Sprint(pageSize)) + return c +} + +// PageToken sets the optional parameter "pageToken": A token +// identifying a page of results the server should return. +func (c *OrganizationsLocationsGlobalPartnerTenantsListCall) PageToken(pageToken string) *OrganizationsLocationsGlobalPartnerTenantsListCall { + c.urlParams_.Set("pageToken", pageToken) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *OrganizationsLocationsGlobalPartnerTenantsListCall) Fields(s ...googleapi.Field) *OrganizationsLocationsGlobalPartnerTenantsListCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets the optional parameter which makes the operation +// fail if the object's ETag matches the given value. This is useful for +// getting updates only after the object has changed since the last +// request. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *OrganizationsLocationsGlobalPartnerTenantsListCall) IfNoneMatch(entityTag string) *OrganizationsLocationsGlobalPartnerTenantsListCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *OrganizationsLocationsGlobalPartnerTenantsListCall) Context(ctx context.Context) *OrganizationsLocationsGlobalPartnerTenantsListCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *OrganizationsLocationsGlobalPartnerTenantsListCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *OrganizationsLocationsGlobalPartnerTenantsListCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+parent}/partnerTenants") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "beyondcorp.organizations.locations.global.partnerTenants.list" call. +// Exactly one of +// *GoogleCloudBeyondcorpPartnerservicesV1alphaListPartnerTenantsResponse +// +// or error will be non-nil. Any non-2xx status code is an error. +// +// Response headers are in either +// *GoogleCloudBeyondcorpPartnerservicesV1alphaListPartnerTenantsResponse +// .ServerResponse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was +// returned. +func (c *OrganizationsLocationsGlobalPartnerTenantsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudBeyondcorpPartnerservicesV1alphaListPartnerTenantsResponse, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleCloudBeyondcorpPartnerservicesV1alphaListPartnerTenantsResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Lists PartnerTenants in a given organization.", + // "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/partnerTenants", + // "httpMethod": "GET", + // "id": "beyondcorp.organizations.locations.global.partnerTenants.list", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "filter": { + // "description": "Optional. Filter partnerTenants to be returned. See [List Sub-Collections] (https://cloud.google.com/apis/design/design_patterns#list_sub-collections) for more details. All fields can be used in the filter. Usage: field_filter=\"fieldName1=fieldVal1 AND fieldName2=fieldVal2\". NOTE: Only `AND` conditions are allowed.", + // "location": "query", + // "type": "string" + // }, + // "orderBy": { + // "description": "Optional. Specifies the ordering of results. Currently, only ordering by the \"name\" and \"create_time\" fields are supported. See [Sorting order](https://cloud.google.com/apis/design/design_patterns#sorting_order) for more information.", + // "location": "query", + // "type": "string" + // }, + // "pageSize": { + // "description": "Optional. The maximum number of items to return. The service may return fewer than this value. If unspecified, at most 50 items will be returned. The maximum value is 1000; values above 1000 are coerced to 1000. Regardless of the page_size value, the response may include a partial list and a caller should only rely on response's next_page_token to determine if there are more instances left to be queried.", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "pageToken": { + // "description": "Optional. A token identifying a page of results the server should return.", + // "location": "query", + // "type": "string" + // }, + // "parent": { + // "description": "Required. The parent organization to which the PartnerTenants belong. Format: `organizations/{organization_id}/locations/global`", + // "location": "path", + // "pattern": "^organizations/[^/]+/locations/global$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1alpha/{+parent}/partnerTenants", + // "response": { + // "$ref": "GoogleCloudBeyondcorpPartnerservicesV1alphaListPartnerTenantsResponse" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// Pages invokes f for each page of results. +// A non-nil error returned from f will halt the iteration. +// The provided context supersedes any context provided to the Context method. +func (c *OrganizationsLocationsGlobalPartnerTenantsListCall) Pages(ctx context.Context, f func(*GoogleCloudBeyondcorpPartnerservicesV1alphaListPartnerTenantsResponse) error) error { + c.ctx_ = ctx + defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point + for { + x, err := c.Do() + if err != nil { + return err + } + if err := f(x); err != nil { + return err + } + if x.NextPageToken == "" { + return nil + } + c.PageToken(x.NextPageToken) + } +} + +// method id "beyondcorp.organizations.locations.global.partnerTenants.setIamPolicy": + +type OrganizationsLocationsGlobalPartnerTenantsSetIamPolicyCall struct { + s *Service + resource string + googleiamv1setiampolicyrequest *GoogleIamV1SetIamPolicyRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// SetIamPolicy: Sets the access control policy on the specified +// resource. Replaces any existing policy. Can return `NOT_FOUND`, +// `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors. +// +// - resource: REQUIRED: The resource for which the policy is being +// specified. See Resource names +// (https://cloud.google.com/apis/design/resource_names) for the +// appropriate value for this field. +func (r *OrganizationsLocationsGlobalPartnerTenantsService) SetIamPolicy(resource string, googleiamv1setiampolicyrequest *GoogleIamV1SetIamPolicyRequest) *OrganizationsLocationsGlobalPartnerTenantsSetIamPolicyCall { + c := &OrganizationsLocationsGlobalPartnerTenantsSetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.resource = resource + c.googleiamv1setiampolicyrequest = googleiamv1setiampolicyrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *OrganizationsLocationsGlobalPartnerTenantsSetIamPolicyCall) Fields(s ...googleapi.Field) *OrganizationsLocationsGlobalPartnerTenantsSetIamPolicyCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *OrganizationsLocationsGlobalPartnerTenantsSetIamPolicyCall) Context(ctx context.Context) *OrganizationsLocationsGlobalPartnerTenantsSetIamPolicyCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *OrganizationsLocationsGlobalPartnerTenantsSetIamPolicyCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *OrganizationsLocationsGlobalPartnerTenantsSetIamPolicyCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleiamv1setiampolicyrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+resource}:setIamPolicy") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "resource": c.resource, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "beyondcorp.organizations.locations.global.partnerTenants.setIamPolicy" call. +// Exactly one of *GoogleIamV1Policy or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *GoogleIamV1Policy.ServerResponse.Header or (if a response was +// returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was +// because http.StatusNotModified was returned. +func (c *OrganizationsLocationsGlobalPartnerTenantsSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*GoogleIamV1Policy, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleIamV1Policy{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Sets the access control policy on the specified resource. Replaces any existing policy. Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors.", + // "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/partnerTenants/{partnerTenantsId}:setIamPolicy", + // "httpMethod": "POST", + // "id": "beyondcorp.organizations.locations.global.partnerTenants.setIamPolicy", + // "parameterOrder": [ + // "resource" + // ], + // "parameters": { + // "resource": { + // "description": "REQUIRED: The resource for which the policy is being specified. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + // "location": "path", + // "pattern": "^organizations/[^/]+/locations/global/partnerTenants/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1alpha/{+resource}:setIamPolicy", + // "request": { + // "$ref": "GoogleIamV1SetIamPolicyRequest" + // }, + // "response": { + // "$ref": "GoogleIamV1Policy" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "beyondcorp.organizations.locations.global.partnerTenants.testIamPermissions": + +type OrganizationsLocationsGlobalPartnerTenantsTestIamPermissionsCall struct { + s *Service + resource string + googleiamv1testiampermissionsrequest *GoogleIamV1TestIamPermissionsRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// TestIamPermissions: Returns permissions that a caller has on the +// specified resource. If the resource does not exist, this will return +// an empty set of permissions, not a `NOT_FOUND` error. Note: This +// operation is designed to be used for building permission-aware UIs +// and command-line tools, not for authorization checking. This +// operation may "fail open" without warning. +// +// - resource: REQUIRED: The resource for which the policy detail is +// being requested. See Resource names +// (https://cloud.google.com/apis/design/resource_names) for the +// appropriate value for this field. +func (r *OrganizationsLocationsGlobalPartnerTenantsService) TestIamPermissions(resource string, googleiamv1testiampermissionsrequest *GoogleIamV1TestIamPermissionsRequest) *OrganizationsLocationsGlobalPartnerTenantsTestIamPermissionsCall { + c := &OrganizationsLocationsGlobalPartnerTenantsTestIamPermissionsCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.resource = resource + c.googleiamv1testiampermissionsrequest = googleiamv1testiampermissionsrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *OrganizationsLocationsGlobalPartnerTenantsTestIamPermissionsCall) Fields(s ...googleapi.Field) *OrganizationsLocationsGlobalPartnerTenantsTestIamPermissionsCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *OrganizationsLocationsGlobalPartnerTenantsTestIamPermissionsCall) Context(ctx context.Context) *OrganizationsLocationsGlobalPartnerTenantsTestIamPermissionsCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *OrganizationsLocationsGlobalPartnerTenantsTestIamPermissionsCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *OrganizationsLocationsGlobalPartnerTenantsTestIamPermissionsCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleiamv1testiampermissionsrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+resource}:testIamPermissions") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "resource": c.resource, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "beyondcorp.organizations.locations.global.partnerTenants.testIamPermissions" call. +// Exactly one of *GoogleIamV1TestIamPermissionsResponse or error will +// be non-nil. Any non-2xx status code is an error. Response headers are +// in either +// *GoogleIamV1TestIamPermissionsResponse.ServerResponse.Header or (if a +// response was returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was +// because http.StatusNotModified was returned. +func (c *OrganizationsLocationsGlobalPartnerTenantsTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*GoogleIamV1TestIamPermissionsResponse, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleIamV1TestIamPermissionsResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Returns permissions that a caller has on the specified resource. If the resource does not exist, this will return an empty set of permissions, not a `NOT_FOUND` error. Note: This operation is designed to be used for building permission-aware UIs and command-line tools, not for authorization checking. This operation may \"fail open\" without warning.", + // "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/partnerTenants/{partnerTenantsId}:testIamPermissions", + // "httpMethod": "POST", + // "id": "beyondcorp.organizations.locations.global.partnerTenants.testIamPermissions", + // "parameterOrder": [ + // "resource" + // ], + // "parameters": { + // "resource": { + // "description": "REQUIRED: The resource for which the policy detail is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + // "location": "path", + // "pattern": "^organizations/[^/]+/locations/global/partnerTenants/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1alpha/{+resource}:testIamPermissions", + // "request": { + // "$ref": "GoogleIamV1TestIamPermissionsRequest" + // }, + // "response": { + // "$ref": "GoogleIamV1TestIamPermissionsResponse" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "beyondcorp.organizations.locations.global.partnerTenants.browserDlpRules.create": + +type OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesCreateCall struct { + s *Service + parent string + googlecloudbeyondcorppartnerservicesv1alphabrowserdlprule *GoogleCloudBeyondcorpPartnerservicesV1alphaBrowserDlpRule + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Create: Creates a new BrowserDlpRule in a given organization and +// PartnerTenant. +// +// - parent: The resource name of the BrowserDlpRule parent using the +// form: +// `organizations/{organization_id}/locations/global/partnerTenants/{pa +// rtner_tenant_id}`. +func (r *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesService) Create(parent string, googlecloudbeyondcorppartnerservicesv1alphabrowserdlprule *GoogleCloudBeyondcorpPartnerservicesV1alphaBrowserDlpRule) *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesCreateCall { + c := &OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googlecloudbeyondcorppartnerservicesv1alphabrowserdlprule = googlecloudbeyondcorppartnerservicesv1alphabrowserdlprule + return c +} + +// RequestId sets the optional parameter "requestId": An optional +// request ID to identify requests. Specify a unique request ID so that +// if you must retry your request, the server will know to ignore the +// request if it has already been completed. The server will guarantee +// that for at least 60 minutes since the first request. For example, +// consider a situation where you make an initial request and the +// request times out. If you make the request again with the same +// request ID, the server can check if original operation with the same +// request ID was received, and if so, will ignore the second request. +// This prevents clients from accidentally creating duplicate +// commitments. The request ID must be a valid UUID with the exception +// that zero UUID is not supported +// (00000000-0000-0000-0000-000000000000). +func (c *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesCreateCall) RequestId(requestId string) *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesCreateCall { + c.urlParams_.Set("requestId", requestId) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesCreateCall) Fields(s ...googleapi.Field) *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesCreateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesCreateCall) Context(ctx context.Context) *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesCreateCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesCreateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesCreateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudbeyondcorppartnerservicesv1alphabrowserdlprule) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+parent}/browserDlpRules") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "beyondcorp.organizations.locations.global.partnerTenants.browserDlpRules.create" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleLongrunningOperation.ServerResponse.Header or (if a response +// was returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was +// because http.StatusNotModified was returned. +func (c *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Creates a new BrowserDlpRule in a given organization and PartnerTenant.", + // "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/partnerTenants/{partnerTenantsId}/browserDlpRules", + // "httpMethod": "POST", + // "id": "beyondcorp.organizations.locations.global.partnerTenants.browserDlpRules.create", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "parent": { + // "description": "Required. The resource name of the BrowserDlpRule parent using the form: `organizations/{organization_id}/locations/global/partnerTenants/{partner_tenant_id}`", + // "location": "path", + // "pattern": "^organizations/[^/]+/locations/global/partnerTenants/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "requestId": { + // "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1alpha/{+parent}/browserDlpRules", + // "request": { + // "$ref": "GoogleCloudBeyondcorpPartnerservicesV1alphaBrowserDlpRule" + // }, + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "beyondcorp.organizations.locations.global.partnerTenants.browserDlpRules.get": + +type OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets details of a single BrowserDlpRule. +// +// - name: The resource name of the BrowserDlpRule using the form: +// `organizations/{organization_id}/locations/global/partnerTenants/{pa +// rtner_tenant_id}/browserDlpRules/{browser_dlp_rule_id}`. +func (r *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesService) Get(name string) *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesGetCall { + c := &OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesGetCall) Fields(s ...googleapi.Field) *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesGetCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets the optional parameter which makes the operation +// fail if the object's ETag matches the given value. This is useful for +// getting updates only after the object has changed since the last +// request. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesGetCall) IfNoneMatch(entityTag string) *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesGetCall) Context(ctx context.Context) *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesGetCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "beyondcorp.organizations.locations.global.partnerTenants.browserDlpRules.get" call. +// Exactly one of +// *GoogleCloudBeyondcorpPartnerservicesV1alphaBrowserDlpRule or error +// will be non-nil. Any non-2xx status code is an error. Response +// headers are in either +// *GoogleCloudBeyondcorpPartnerservicesV1alphaBrowserDlpRule.ServerRespo +// nse.Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was +// returned. +func (c *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudBeyondcorpPartnerservicesV1alphaBrowserDlpRule, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleCloudBeyondcorpPartnerservicesV1alphaBrowserDlpRule{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Gets details of a single BrowserDlpRule.", + // "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/partnerTenants/{partnerTenantsId}/browserDlpRules/{browserDlpRulesId}", + // "httpMethod": "GET", + // "id": "beyondcorp.organizations.locations.global.partnerTenants.browserDlpRules.get", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. The resource name of the BrowserDlpRule using the form: `organizations/{organization_id}/locations/global/partnerTenants/{partner_tenant_id}/browserDlpRules/{browser_dlp_rule_id}`", + // "location": "path", + // "pattern": "^organizations/[^/]+/locations/global/partnerTenants/[^/]+/browserDlpRules/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1alpha/{+name}", + // "response": { + // "$ref": "GoogleCloudBeyondcorpPartnerservicesV1alphaBrowserDlpRule" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "beyondcorp.organizations.locations.global.partnerTenants.browserDlpRules.getIamPolicy": + +type OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesGetIamPolicyCall struct { + s *Service + resource string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// GetIamPolicy: Gets the access control policy for a resource. Returns +// an empty policy if the resource exists and does not have a policy +// set. +// +// - resource: REQUIRED: The resource for which the policy is being +// requested. See Resource names +// (https://cloud.google.com/apis/design/resource_names) for the +// appropriate value for this field. +func (r *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesService) GetIamPolicy(resource string) *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesGetIamPolicyCall { + c := &OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesGetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.resource = resource + return c +} + +// OptionsRequestedPolicyVersion sets the optional parameter +// "options.requestedPolicyVersion": The maximum policy version that +// will be used to format the policy. Valid values are 0, 1, and 3. +// Requests specifying an invalid value will be rejected. Requests for +// policies with any conditional role bindings must specify version 3. +// Policies with no conditional role bindings may specify any valid +// value or leave the field unset. The policy in the response might use +// the policy version that you specified, or it might use a lower policy +// version. For example, if you specify version 3, but the policy has no +// conditional role bindings, the response uses version 1. To learn +// which resources support conditions in their IAM policies, see the IAM +// documentation +// (https://cloud.google.com/iam/help/conditions/resource-policies). +func (c *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesGetIamPolicyCall) OptionsRequestedPolicyVersion(optionsRequestedPolicyVersion int64) *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesGetIamPolicyCall { + c.urlParams_.Set("options.requestedPolicyVersion", fmt.Sprint(optionsRequestedPolicyVersion)) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesGetIamPolicyCall) Fields(s ...googleapi.Field) *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesGetIamPolicyCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets the optional parameter which makes the operation +// fail if the object's ETag matches the given value. This is useful for +// getting updates only after the object has changed since the last +// request. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesGetIamPolicyCall) IfNoneMatch(entityTag string) *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesGetIamPolicyCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesGetIamPolicyCall) Context(ctx context.Context) *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesGetIamPolicyCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesGetIamPolicyCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesGetIamPolicyCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+resource}:getIamPolicy") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "resource": c.resource, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "beyondcorp.organizations.locations.global.partnerTenants.browserDlpRules.getIamPolicy" call. +// Exactly one of *GoogleIamV1Policy or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *GoogleIamV1Policy.ServerResponse.Header or (if a response was +// returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was +// because http.StatusNotModified was returned. +func (c *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*GoogleIamV1Policy, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleIamV1Policy{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set.", + // "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/partnerTenants/{partnerTenantsId}/browserDlpRules/{browserDlpRulesId}:getIamPolicy", + // "httpMethod": "GET", + // "id": "beyondcorp.organizations.locations.global.partnerTenants.browserDlpRules.getIamPolicy", + // "parameterOrder": [ + // "resource" + // ], + // "parameters": { + // "options.requestedPolicyVersion": { + // "description": "Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "resource": { + // "description": "REQUIRED: The resource for which the policy is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + // "location": "path", + // "pattern": "^organizations/[^/]+/locations/global/partnerTenants/[^/]+/browserDlpRules/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1alpha/{+resource}:getIamPolicy", + // "response": { + // "$ref": "GoogleIamV1Policy" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "beyondcorp.organizations.locations.global.partnerTenants.browserDlpRules.setIamPolicy": + +type OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesSetIamPolicyCall struct { + s *Service + resource string + googleiamv1setiampolicyrequest *GoogleIamV1SetIamPolicyRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// SetIamPolicy: Sets the access control policy on the specified +// resource. Replaces any existing policy. Can return `NOT_FOUND`, +// `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors. +// +// - resource: REQUIRED: The resource for which the policy is being +// specified. See Resource names +// (https://cloud.google.com/apis/design/resource_names) for the +// appropriate value for this field. +func (r *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesService) SetIamPolicy(resource string, googleiamv1setiampolicyrequest *GoogleIamV1SetIamPolicyRequest) *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesSetIamPolicyCall { + c := &OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesSetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.resource = resource + c.googleiamv1setiampolicyrequest = googleiamv1setiampolicyrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesSetIamPolicyCall) Fields(s ...googleapi.Field) *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesSetIamPolicyCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesSetIamPolicyCall) Context(ctx context.Context) *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesSetIamPolicyCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesSetIamPolicyCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesSetIamPolicyCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleiamv1setiampolicyrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+resource}:setIamPolicy") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "resource": c.resource, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "beyondcorp.organizations.locations.global.partnerTenants.browserDlpRules.setIamPolicy" call. +// Exactly one of *GoogleIamV1Policy or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *GoogleIamV1Policy.ServerResponse.Header or (if a response was +// returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was +// because http.StatusNotModified was returned. +func (c *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*GoogleIamV1Policy, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleIamV1Policy{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Sets the access control policy on the specified resource. Replaces any existing policy. Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors.", + // "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/partnerTenants/{partnerTenantsId}/browserDlpRules/{browserDlpRulesId}:setIamPolicy", + // "httpMethod": "POST", + // "id": "beyondcorp.organizations.locations.global.partnerTenants.browserDlpRules.setIamPolicy", + // "parameterOrder": [ + // "resource" + // ], + // "parameters": { + // "resource": { + // "description": "REQUIRED: The resource for which the policy is being specified. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + // "location": "path", + // "pattern": "^organizations/[^/]+/locations/global/partnerTenants/[^/]+/browserDlpRules/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1alpha/{+resource}:setIamPolicy", + // "request": { + // "$ref": "GoogleIamV1SetIamPolicyRequest" + // }, + // "response": { + // "$ref": "GoogleIamV1Policy" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "beyondcorp.organizations.locations.global.partnerTenants.browserDlpRules.testIamPermissions": + +type OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesTestIamPermissionsCall struct { + s *Service + resource string + googleiamv1testiampermissionsrequest *GoogleIamV1TestIamPermissionsRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// TestIamPermissions: Returns permissions that a caller has on the +// specified resource. If the resource does not exist, this will return +// an empty set of permissions, not a `NOT_FOUND` error. Note: This +// operation is designed to be used for building permission-aware UIs +// and command-line tools, not for authorization checking. This +// operation may "fail open" without warning. +// +// - resource: REQUIRED: The resource for which the policy detail is +// being requested. See Resource names +// (https://cloud.google.com/apis/design/resource_names) for the +// appropriate value for this field. +func (r *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesService) TestIamPermissions(resource string, googleiamv1testiampermissionsrequest *GoogleIamV1TestIamPermissionsRequest) *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesTestIamPermissionsCall { + c := &OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesTestIamPermissionsCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.resource = resource + c.googleiamv1testiampermissionsrequest = googleiamv1testiampermissionsrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesTestIamPermissionsCall) Fields(s ...googleapi.Field) *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesTestIamPermissionsCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesTestIamPermissionsCall) Context(ctx context.Context) *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesTestIamPermissionsCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesTestIamPermissionsCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesTestIamPermissionsCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleiamv1testiampermissionsrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+resource}:testIamPermissions") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "resource": c.resource, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "beyondcorp.organizations.locations.global.partnerTenants.browserDlpRules.testIamPermissions" call. +// Exactly one of *GoogleIamV1TestIamPermissionsResponse or error will +// be non-nil. Any non-2xx status code is an error. Response headers are +// in either +// *GoogleIamV1TestIamPermissionsResponse.ServerResponse.Header or (if a +// response was returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was +// because http.StatusNotModified was returned. +func (c *OrganizationsLocationsGlobalPartnerTenantsBrowserDlpRulesTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*GoogleIamV1TestIamPermissionsResponse, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleIamV1TestIamPermissionsResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Returns permissions that a caller has on the specified resource. If the resource does not exist, this will return an empty set of permissions, not a `NOT_FOUND` error. Note: This operation is designed to be used for building permission-aware UIs and command-line tools, not for authorization checking. This operation may \"fail open\" without warning.", + // "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/partnerTenants/{partnerTenantsId}/browserDlpRules/{browserDlpRulesId}:testIamPermissions", + // "httpMethod": "POST", + // "id": "beyondcorp.organizations.locations.global.partnerTenants.browserDlpRules.testIamPermissions", + // "parameterOrder": [ + // "resource" + // ], + // "parameters": { + // "resource": { + // "description": "REQUIRED: The resource for which the policy detail is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + // "location": "path", + // "pattern": "^organizations/[^/]+/locations/global/partnerTenants/[^/]+/browserDlpRules/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1alpha/{+resource}:testIamPermissions", + // "request": { + // "$ref": "GoogleIamV1TestIamPermissionsRequest" + // }, + // "response": { + // "$ref": "GoogleIamV1TestIamPermissionsResponse" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "beyondcorp.organizations.locations.global.partnerTenants.proxyConfigs.create": + +type OrganizationsLocationsGlobalPartnerTenantsProxyConfigsCreateCall struct { + s *Service + parent string + googlecloudbeyondcorppartnerservicesv1alphaproxyconfig *GoogleCloudBeyondcorpPartnerservicesV1alphaProxyConfig + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Create: Creates a new BeyondCorp Enterprise ProxyConfig in a given +// organization and PartnerTenant. Can only be called by on onboarded +// Beyondcorp Enterprise partner. +// +// - parent: The resource name of the Tenant using the form: +// `organizations/{organization_id}/locations/global/tenants/{tenant_id +// }`. +func (r *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsService) Create(parent string, googlecloudbeyondcorppartnerservicesv1alphaproxyconfig *GoogleCloudBeyondcorpPartnerservicesV1alphaProxyConfig) *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsCreateCall { + c := &OrganizationsLocationsGlobalPartnerTenantsProxyConfigsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googlecloudbeyondcorppartnerservicesv1alphaproxyconfig = googlecloudbeyondcorppartnerservicesv1alphaproxyconfig + return c +} + +// RequestId sets the optional parameter "requestId": An optional +// request ID to identify requests. Specify a unique request ID so that +// if you must retry your request, the server will know to ignore the +// request if it has already been completed. The server will guarantee +// that for at least 60 minutes since the first request. For example, +// consider a situation where you make an initial request and the +// request times out. If you make the request again with the same +// request ID, the server can check if original operation with the same +// request ID was received, and if so, will ignore the second request. +// This prevents clients from accidentally creating duplicate +// commitments. The request ID must be a valid UUID with the exception +// that zero UUID is not supported +// (00000000-0000-0000-0000-000000000000). +func (c *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsCreateCall) RequestId(requestId string) *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsCreateCall { + c.urlParams_.Set("requestId", requestId) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsCreateCall) Fields(s ...googleapi.Field) *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsCreateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsCreateCall) Context(ctx context.Context) *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsCreateCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsCreateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsCreateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudbeyondcorppartnerservicesv1alphaproxyconfig) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+parent}/proxyConfigs") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "beyondcorp.organizations.locations.global.partnerTenants.proxyConfigs.create" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleLongrunningOperation.ServerResponse.Header or (if a response +// was returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was +// because http.StatusNotModified was returned. +func (c *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Creates a new BeyondCorp Enterprise ProxyConfig in a given organization and PartnerTenant. Can only be called by on onboarded Beyondcorp Enterprise partner.", + // "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/partnerTenants/{partnerTenantsId}/proxyConfigs", + // "httpMethod": "POST", + // "id": "beyondcorp.organizations.locations.global.partnerTenants.proxyConfigs.create", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "parent": { + // "description": "Required. The resource name of the Tenant using the form: `organizations/{organization_id}/locations/global/tenants/{tenant_id}`", + // "location": "path", + // "pattern": "^organizations/[^/]+/locations/global/partnerTenants/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "requestId": { + // "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1alpha/{+parent}/proxyConfigs", + // "request": { + // "$ref": "GoogleCloudBeyondcorpPartnerservicesV1alphaProxyConfig" + // }, + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "beyondcorp.organizations.locations.global.partnerTenants.proxyConfigs.get": + +type OrganizationsLocationsGlobalPartnerTenantsProxyConfigsGetCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// Get: Gets details of a single ProxyConfig. +// +// - name: The resource name of the ProxyConfig using the form: +// `organizations/{organization_id}/locations/global/tenants/{tenant_id +// }/proxyConfigs/{proxy_config_id}`. +func (r *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsService) Get(name string) *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsGetCall { + c := &OrganizationsLocationsGlobalPartnerTenantsProxyConfigsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsGetCall) Fields(s ...googleapi.Field) *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsGetCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets the optional parameter which makes the operation +// fail if the object's ETag matches the given value. This is useful for +// getting updates only after the object has changed since the last +// request. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsGetCall) IfNoneMatch(entityTag string) *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsGetCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsGetCall) Context(ctx context.Context) *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsGetCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsGetCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsGetCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "beyondcorp.organizations.locations.global.partnerTenants.proxyConfigs.get" call. +// Exactly one of +// *GoogleCloudBeyondcorpPartnerservicesV1alphaProxyConfig or error will +// be non-nil. Any non-2xx status code is an error. Response headers are +// in either +// *GoogleCloudBeyondcorpPartnerservicesV1alphaProxyConfig.ServerResponse +// .Header or (if a response was returned at all) in +// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check +// whether the returned error was because http.StatusNotModified was +// returned. +func (c *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudBeyondcorpPartnerservicesV1alphaProxyConfig, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleCloudBeyondcorpPartnerservicesV1alphaProxyConfig{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Gets details of a single ProxyConfig.", + // "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/partnerTenants/{partnerTenantsId}/proxyConfigs/{proxyConfigsId}", + // "httpMethod": "GET", + // "id": "beyondcorp.organizations.locations.global.partnerTenants.proxyConfigs.get", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. The resource name of the ProxyConfig using the form: `organizations/{organization_id}/locations/global/tenants/{tenant_id}/proxyConfigs/{proxy_config_id}`", + // "location": "path", + // "pattern": "^organizations/[^/]+/locations/global/partnerTenants/[^/]+/proxyConfigs/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1alpha/{+name}", + // "response": { + // "$ref": "GoogleCloudBeyondcorpPartnerservicesV1alphaProxyConfig" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "beyondcorp.organizations.locations.global.partnerTenants.proxyConfigs.getIamPolicy": + +type OrganizationsLocationsGlobalPartnerTenantsProxyConfigsGetIamPolicyCall struct { + s *Service + resource string + urlParams_ gensupport.URLParams + ifNoneMatch_ string + ctx_ context.Context + header_ http.Header +} + +// GetIamPolicy: Gets the access control policy for a resource. Returns +// an empty policy if the resource exists and does not have a policy +// set. +// +// - resource: REQUIRED: The resource for which the policy is being +// requested. See Resource names +// (https://cloud.google.com/apis/design/resource_names) for the +// appropriate value for this field. +func (r *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsService) GetIamPolicy(resource string) *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsGetIamPolicyCall { + c := &OrganizationsLocationsGlobalPartnerTenantsProxyConfigsGetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.resource = resource + return c +} + +// OptionsRequestedPolicyVersion sets the optional parameter +// "options.requestedPolicyVersion": The maximum policy version that +// will be used to format the policy. Valid values are 0, 1, and 3. +// Requests specifying an invalid value will be rejected. Requests for +// policies with any conditional role bindings must specify version 3. +// Policies with no conditional role bindings may specify any valid +// value or leave the field unset. The policy in the response might use +// the policy version that you specified, or it might use a lower policy +// version. For example, if you specify version 3, but the policy has no +// conditional role bindings, the response uses version 1. To learn +// which resources support conditions in their IAM policies, see the IAM +// documentation +// (https://cloud.google.com/iam/help/conditions/resource-policies). +func (c *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsGetIamPolicyCall) OptionsRequestedPolicyVersion(optionsRequestedPolicyVersion int64) *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsGetIamPolicyCall { + c.urlParams_.Set("options.requestedPolicyVersion", fmt.Sprint(optionsRequestedPolicyVersion)) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsGetIamPolicyCall) Fields(s ...googleapi.Field) *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsGetIamPolicyCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// IfNoneMatch sets the optional parameter which makes the operation +// fail if the object's ETag matches the given value. This is useful for +// getting updates only after the object has changed since the last +// request. Use googleapi.IsNotModified to check whether the response +// error from Do is the result of In-None-Match. +func (c *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsGetIamPolicyCall) IfNoneMatch(entityTag string) *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsGetIamPolicyCall { + c.ifNoneMatch_ = entityTag + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsGetIamPolicyCall) Context(ctx context.Context) *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsGetIamPolicyCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsGetIamPolicyCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsGetIamPolicyCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + if c.ifNoneMatch_ != "" { + reqHeaders.Set("If-None-Match", c.ifNoneMatch_) + } + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+resource}:getIamPolicy") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("GET", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "resource": c.resource, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "beyondcorp.organizations.locations.global.partnerTenants.proxyConfigs.getIamPolicy" call. +// Exactly one of *GoogleIamV1Policy or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *GoogleIamV1Policy.ServerResponse.Header or (if a response was +// returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was +// because http.StatusNotModified was returned. +func (c *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*GoogleIamV1Policy, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleIamV1Policy{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set.", + // "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/partnerTenants/{partnerTenantsId}/proxyConfigs/{proxyConfigsId}:getIamPolicy", + // "httpMethod": "GET", + // "id": "beyondcorp.organizations.locations.global.partnerTenants.proxyConfigs.getIamPolicy", + // "parameterOrder": [ + // "resource" + // ], + // "parameters": { + // "options.requestedPolicyVersion": { + // "description": "Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).", + // "format": "int32", + // "location": "query", + // "type": "integer" + // }, + // "resource": { + // "description": "REQUIRED: The resource for which the policy is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + // "location": "path", + // "pattern": "^organizations/[^/]+/locations/global/partnerTenants/[^/]+/proxyConfigs/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1alpha/{+resource}:getIamPolicy", + // "response": { + // "$ref": "GoogleIamV1Policy" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "beyondcorp.organizations.locations.global.partnerTenants.proxyConfigs.setIamPolicy": + +type OrganizationsLocationsGlobalPartnerTenantsProxyConfigsSetIamPolicyCall struct { + s *Service + resource string + googleiamv1setiampolicyrequest *GoogleIamV1SetIamPolicyRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// SetIamPolicy: Sets the access control policy on the specified +// resource. Replaces any existing policy. Can return `NOT_FOUND`, +// `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors. +// +// - resource: REQUIRED: The resource for which the policy is being +// specified. See Resource names +// (https://cloud.google.com/apis/design/resource_names) for the +// appropriate value for this field. +func (r *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsService) SetIamPolicy(resource string, googleiamv1setiampolicyrequest *GoogleIamV1SetIamPolicyRequest) *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsSetIamPolicyCall { + c := &OrganizationsLocationsGlobalPartnerTenantsProxyConfigsSetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.resource = resource + c.googleiamv1setiampolicyrequest = googleiamv1setiampolicyrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsSetIamPolicyCall) Fields(s ...googleapi.Field) *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsSetIamPolicyCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsSetIamPolicyCall) Context(ctx context.Context) *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsSetIamPolicyCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsSetIamPolicyCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsSetIamPolicyCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleiamv1setiampolicyrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+resource}:setIamPolicy") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "resource": c.resource, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "beyondcorp.organizations.locations.global.partnerTenants.proxyConfigs.setIamPolicy" call. +// Exactly one of *GoogleIamV1Policy or error will be non-nil. Any +// non-2xx status code is an error. Response headers are in either +// *GoogleIamV1Policy.ServerResponse.Header or (if a response was +// returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was +// because http.StatusNotModified was returned. +func (c *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*GoogleIamV1Policy, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleIamV1Policy{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Sets the access control policy on the specified resource. Replaces any existing policy. Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors.", + // "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/partnerTenants/{partnerTenantsId}/proxyConfigs/{proxyConfigsId}:setIamPolicy", + // "httpMethod": "POST", + // "id": "beyondcorp.organizations.locations.global.partnerTenants.proxyConfigs.setIamPolicy", + // "parameterOrder": [ + // "resource" + // ], + // "parameters": { + // "resource": { + // "description": "REQUIRED: The resource for which the policy is being specified. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + // "location": "path", + // "pattern": "^organizations/[^/]+/locations/global/partnerTenants/[^/]+/proxyConfigs/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1alpha/{+resource}:setIamPolicy", + // "request": { + // "$ref": "GoogleIamV1SetIamPolicyRequest" + // }, + // "response": { + // "$ref": "GoogleIamV1Policy" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "beyondcorp.organizations.locations.global.partnerTenants.proxyConfigs.testIamPermissions": + +type OrganizationsLocationsGlobalPartnerTenantsProxyConfigsTestIamPermissionsCall struct { + s *Service + resource string + googleiamv1testiampermissionsrequest *GoogleIamV1TestIamPermissionsRequest + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// TestIamPermissions: Returns permissions that a caller has on the +// specified resource. If the resource does not exist, this will return +// an empty set of permissions, not a `NOT_FOUND` error. Note: This +// operation is designed to be used for building permission-aware UIs +// and command-line tools, not for authorization checking. This +// operation may "fail open" without warning. +// +// - resource: REQUIRED: The resource for which the policy detail is +// being requested. See Resource names +// (https://cloud.google.com/apis/design/resource_names) for the +// appropriate value for this field. +func (r *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsService) TestIamPermissions(resource string, googleiamv1testiampermissionsrequest *GoogleIamV1TestIamPermissionsRequest) *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsTestIamPermissionsCall { + c := &OrganizationsLocationsGlobalPartnerTenantsProxyConfigsTestIamPermissionsCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.resource = resource + c.googleiamv1testiampermissionsrequest = googleiamv1testiampermissionsrequest + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsTestIamPermissionsCall) Fields(s ...googleapi.Field) *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsTestIamPermissionsCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsTestIamPermissionsCall) Context(ctx context.Context) *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsTestIamPermissionsCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsTestIamPermissionsCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsTestIamPermissionsCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleiamv1testiampermissionsrequest) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+resource}:testIamPermissions") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "resource": c.resource, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "beyondcorp.organizations.locations.global.partnerTenants.proxyConfigs.testIamPermissions" call. +// Exactly one of *GoogleIamV1TestIamPermissionsResponse or error will +// be non-nil. Any non-2xx status code is an error. Response headers are +// in either +// *GoogleIamV1TestIamPermissionsResponse.ServerResponse.Header or (if a +// response was returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was +// because http.StatusNotModified was returned. +func (c *OrganizationsLocationsGlobalPartnerTenantsProxyConfigsTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*GoogleIamV1TestIamPermissionsResponse, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleIamV1TestIamPermissionsResponse{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Returns permissions that a caller has on the specified resource. If the resource does not exist, this will return an empty set of permissions, not a `NOT_FOUND` error. Note: This operation is designed to be used for building permission-aware UIs and command-line tools, not for authorization checking. This operation may \"fail open\" without warning.", + // "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/partnerTenants/{partnerTenantsId}/proxyConfigs/{proxyConfigsId}:testIamPermissions", + // "httpMethod": "POST", + // "id": "beyondcorp.organizations.locations.global.partnerTenants.proxyConfigs.testIamPermissions", + // "parameterOrder": [ + // "resource" + // ], + // "parameters": { + // "resource": { + // "description": "REQUIRED: The resource for which the policy detail is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.", + // "location": "path", + // "pattern": "^organizations/[^/]+/locations/global/partnerTenants/[^/]+/proxyConfigs/[^/]+$", + // "required": true, + // "type": "string" + // } + // }, + // "path": "v1alpha/{+resource}:testIamPermissions", + // "request": { + // "$ref": "GoogleIamV1TestIamPermissionsRequest" + // }, + // "response": { + // "$ref": "GoogleIamV1TestIamPermissionsResponse" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "beyondcorp.organizations.locations.global.tenants.create": + +type OrganizationsLocationsGlobalTenantsCreateCall struct { + s *Service + parent string + googlecloudbeyondcorppartnerservicesv1alphatenant *GoogleCloudBeyondcorpPartnerservicesV1alphaTenant + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Create: Creates a new BeyondCorp Enterprise tenant in a given +// organization and can only be called by onboarded BeyondCorp +// Enterprise partner. +// +// - parent: The resource name of the Tenant using the form: +// `organizations/{organization_id}/locations/global`. +func (r *OrganizationsLocationsGlobalTenantsService) Create(parent string, googlecloudbeyondcorppartnerservicesv1alphatenant *GoogleCloudBeyondcorpPartnerservicesV1alphaTenant) *OrganizationsLocationsGlobalTenantsCreateCall { + c := &OrganizationsLocationsGlobalTenantsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.parent = parent + c.googlecloudbeyondcorppartnerservicesv1alphatenant = googlecloudbeyondcorppartnerservicesv1alphatenant + return c +} + +// RequestId sets the optional parameter "requestId": An optional +// request ID to identify requests. Specify a unique request ID so that +// if you must retry your request, the server will know to ignore the +// request if it has already been completed. The server will guarantee +// that for at least 60 minutes since the first request. For example, +// consider a situation where you make an initial request and the +// request times out. If you make the request again with the same +// request ID, the server can check if original operation with the same +// request ID was received, and if so, will ignore the second request. +// This prevents clients from accidentally creating duplicate +// commitments. The request ID must be a valid UUID with the exception +// that zero UUID is not supported +// (00000000-0000-0000-0000-000000000000). func (c *OrganizationsLocationsGlobalTenantsCreateCall) RequestId(requestId string) *OrganizationsLocationsGlobalTenantsCreateCall { c.urlParams_.Set("requestId", requestId) return c @@ -5252,7 +7870,170 @@ func (c *OrganizationsLocationsGlobalTenantsCreateCall) RequestId(requestId stri // Fields allows partial responses to be retrieved. See // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse // for more information. -func (c *OrganizationsLocationsGlobalTenantsCreateCall) Fields(s ...googleapi.Field) *OrganizationsLocationsGlobalTenantsCreateCall { +func (c *OrganizationsLocationsGlobalTenantsCreateCall) Fields(s ...googleapi.Field) *OrganizationsLocationsGlobalTenantsCreateCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *OrganizationsLocationsGlobalTenantsCreateCall) Context(ctx context.Context) *OrganizationsLocationsGlobalTenantsCreateCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *OrganizationsLocationsGlobalTenantsCreateCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *OrganizationsLocationsGlobalTenantsCreateCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudbeyondcorppartnerservicesv1alphatenant) + if err != nil { + return nil, err + } + reqHeaders.Set("Content-Type", "application/json") + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+parent}/tenants") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("POST", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "parent": c.parent, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "beyondcorp.organizations.locations.global.tenants.create" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleLongrunningOperation.ServerResponse.Header or (if a response +// was returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was +// because http.StatusNotModified was returned. +func (c *OrganizationsLocationsGlobalTenantsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Creates a new BeyondCorp Enterprise tenant in a given organization and can only be called by onboarded BeyondCorp Enterprise partner.", + // "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/tenants", + // "httpMethod": "POST", + // "id": "beyondcorp.organizations.locations.global.tenants.create", + // "parameterOrder": [ + // "parent" + // ], + // "parameters": { + // "parent": { + // "description": "Required. The resource name of the Tenant using the form: `organizations/{organization_id}/locations/global`", + // "location": "path", + // "pattern": "^organizations/[^/]+/locations/global$", + // "required": true, + // "type": "string" + // }, + // "requestId": { + // "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1alpha/{+parent}/tenants", + // "request": { + // "$ref": "GoogleCloudBeyondcorpPartnerservicesV1alphaTenant" + // }, + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + +// method id "beyondcorp.organizations.locations.global.tenants.delete": + +type OrganizationsLocationsGlobalTenantsDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Delete: Deletes a single Tenant. +// +// - name: Name of the resource. +func (r *OrganizationsLocationsGlobalTenantsService) Delete(name string) *OrganizationsLocationsGlobalTenantsDeleteCall { + c := &OrganizationsLocationsGlobalTenantsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// RequestId sets the optional parameter "requestId": An optional +// request ID to identify requests. Specify a unique request ID so that +// if you must retry your request, the server will know to ignore the +// request if it has already been completed. The server will guarantee +// that for at least 60 minutes after the first request. For example, +// consider a situation where you make an initial request and the +// request times out. If you make the request again with the same +// request ID, the server can check if original operation with the same +// request ID was received, and if so, will ignore the second request. +// This prevents clients from accidentally creating duplicate +// commitments. The request ID must be a valid UUID with the exception +// that zero UUID is not supported +// (00000000-0000-0000-0000-000000000000). +func (c *OrganizationsLocationsGlobalTenantsDeleteCall) RequestId(requestId string) *OrganizationsLocationsGlobalTenantsDeleteCall { + c.urlParams_.Set("requestId", requestId) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *OrganizationsLocationsGlobalTenantsDeleteCall) Fields(s ...googleapi.Field) *OrganizationsLocationsGlobalTenantsDeleteCall { c.urlParams_.Set("fields", googleapi.CombineFields(s)) return c } @@ -5260,21 +8041,21 @@ func (c *OrganizationsLocationsGlobalTenantsCreateCall) Fields(s ...googleapi.Fi // Context sets the context to be used in this call's Do method. Any // pending HTTP request will be aborted if the provided context is // canceled. -func (c *OrganizationsLocationsGlobalTenantsCreateCall) Context(ctx context.Context) *OrganizationsLocationsGlobalTenantsCreateCall { +func (c *OrganizationsLocationsGlobalTenantsDeleteCall) Context(ctx context.Context) *OrganizationsLocationsGlobalTenantsDeleteCall { c.ctx_ = ctx return c } // Header returns an http.Header that can be modified by the caller to // add HTTP headers to the request. -func (c *OrganizationsLocationsGlobalTenantsCreateCall) Header() http.Header { +func (c *OrganizationsLocationsGlobalTenantsDeleteCall) Header() http.Header { if c.header_ == nil { c.header_ = make(http.Header) } return c.header_ } -func (c *OrganizationsLocationsGlobalTenantsCreateCall) doRequest(alt string) (*http.Response, error) { +func (c *OrganizationsLocationsGlobalTenantsDeleteCall) doRequest(alt string) (*http.Response, error) { reqHeaders := make(http.Header) reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) for k, v := range c.header_ { @@ -5282,34 +8063,29 @@ func (c *OrganizationsLocationsGlobalTenantsCreateCall) doRequest(alt string) (* } reqHeaders.Set("User-Agent", c.s.userAgent()) var body io.Reader = nil - body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudbeyondcorppartnerservicesv1alphatenant) - if err != nil { - return nil, err - } - reqHeaders.Set("Content-Type", "application/json") c.urlParams_.Set("alt", alt) c.urlParams_.Set("prettyPrint", "false") - urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+parent}/tenants") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}") urls += "?" + c.urlParams_.Encode() - req, err := http.NewRequest("POST", urls, body) + req, err := http.NewRequest("DELETE", urls, body) if err != nil { return nil, err } req.Header = reqHeaders googleapi.Expand(req.URL, map[string]string{ - "parent": c.parent, + "name": c.name, }) return gensupport.SendRequest(c.ctx_, c.s.client, req) } -// Do executes the "beyondcorp.organizations.locations.global.tenants.create" call. +// Do executes the "beyondcorp.organizations.locations.global.tenants.delete" call. // Exactly one of *GoogleLongrunningOperation or error will be non-nil. // Any non-2xx status code is an error. Response headers are in either // *GoogleLongrunningOperation.ServerResponse.Header or (if a response // was returned at all) in error.(*googleapi.Error).Header. Use // googleapi.IsNotModified to check whether the returned error was // because http.StatusNotModified was returned. -func (c *OrganizationsLocationsGlobalTenantsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { +func (c *OrganizationsLocationsGlobalTenantsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { gensupport.SetOptions(c.urlParams_, opts...) res, err := c.doRequest("json") if res != nil && res.StatusCode == http.StatusNotModified { @@ -5340,31 +8116,28 @@ func (c *OrganizationsLocationsGlobalTenantsCreateCall) Do(opts ...googleapi.Cal } return ret, nil // { - // "description": "Creates a new BeyondCorp Enterprise tenant in a given organization and can only be called by onboarded BeyondCorp Enterprise partner.", - // "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/tenants", - // "httpMethod": "POST", - // "id": "beyondcorp.organizations.locations.global.tenants.create", + // "description": "Deletes a single Tenant.", + // "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/tenants/{tenantsId}", + // "httpMethod": "DELETE", + // "id": "beyondcorp.organizations.locations.global.tenants.delete", // "parameterOrder": [ - // "parent" + // "name" // ], // "parameters": { - // "parent": { - // "description": "Required. The resource name of the Tenant using the form: `organizations/{organization_id}/locations/global`", + // "name": { + // "description": "Required. Name of the resource.", // "location": "path", - // "pattern": "^organizations/[^/]+/locations/global$", + // "pattern": "^organizations/[^/]+/locations/global/tenants/[^/]+$", // "required": true, // "type": "string" // }, // "requestId": { - // "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes since the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + // "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes after the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", // "location": "query", // "type": "string" // } // }, - // "path": "v1alpha/{+parent}/tenants", - // "request": { - // "$ref": "GoogleCloudBeyondcorpPartnerservicesV1alphaTenant" - // }, + // "path": "v1alpha/{+name}", // "response": { // "$ref": "GoogleLongrunningOperation" // }, @@ -5536,11 +8309,11 @@ type OrganizationsLocationsGlobalTenantsProxyConfigsCreateCall struct { header_ http.Header } -// Create: Creates a new BeyondCorp Enterprise ProxyConfiguration in a -// given organization and PartnerTenant. Can only be called by on -// onboarded Beyondcorp Enterprise partner. +// Create: Creates a new BeyondCorp Enterprise ProxyConfig in a given +// organization and Tenant. Can only be called by on onboarded +// Beyondcorp Enterprise partner. // -// - parent: The resource name of the ProxyConfig using the form: +// - parent: The resource name of the Tenant using the form: // `organizations/{organization_id}/locations/global/tenants/{tenant_id // }`. func (r *OrganizationsLocationsGlobalTenantsProxyConfigsService) Create(parent string, googlecloudbeyondcorppartnerservicesv1alphaproxyconfig *GoogleCloudBeyondcorpPartnerservicesV1alphaProxyConfig) *OrganizationsLocationsGlobalTenantsProxyConfigsCreateCall { @@ -5659,7 +8432,7 @@ func (c *OrganizationsLocationsGlobalTenantsProxyConfigsCreateCall) Do(opts ...g } return ret, nil // { - // "description": "Creates a new BeyondCorp Enterprise ProxyConfiguration in a given organization and PartnerTenant. Can only be called by on onboarded Beyondcorp Enterprise partner.", + // "description": "Creates a new BeyondCorp Enterprise ProxyConfig in a given organization and Tenant. Can only be called by on onboarded Beyondcorp Enterprise partner.", // "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/tenants/{tenantsId}/proxyConfigs", // "httpMethod": "POST", // "id": "beyondcorp.organizations.locations.global.tenants.proxyConfigs.create", @@ -5668,7 +8441,7 @@ func (c *OrganizationsLocationsGlobalTenantsProxyConfigsCreateCall) Do(opts ...g // ], // "parameters": { // "parent": { - // "description": "Required. The resource name of the ProxyConfig using the form: `organizations/{organization_id}/locations/global/tenants/{tenant_id}`", + // "description": "Required. The resource name of the Tenant using the form: `organizations/{organization_id}/locations/global/tenants/{tenant_id}`", // "location": "path", // "pattern": "^organizations/[^/]+/locations/global/tenants/[^/]+$", // "required": true, @@ -5694,6 +8467,161 @@ func (c *OrganizationsLocationsGlobalTenantsProxyConfigsCreateCall) Do(opts ...g } +// method id "beyondcorp.organizations.locations.global.tenants.proxyConfigs.delete": + +type OrganizationsLocationsGlobalTenantsProxyConfigsDeleteCall struct { + s *Service + name string + urlParams_ gensupport.URLParams + ctx_ context.Context + header_ http.Header +} + +// Delete: Deletes a single ProxyConfig. +// +// - name: Name of the resource. +func (r *OrganizationsLocationsGlobalTenantsProxyConfigsService) Delete(name string) *OrganizationsLocationsGlobalTenantsProxyConfigsDeleteCall { + c := &OrganizationsLocationsGlobalTenantsProxyConfigsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)} + c.name = name + return c +} + +// RequestId sets the optional parameter "requestId": An optional +// request ID to identify requests. Specify a unique request ID so that +// if you must retry your request, the server will know to ignore the +// request if it has already been completed. The server will guarantee +// that for at least 60 minutes after the first request. For example, +// consider a situation where you make an initial request and the +// request times out. If you make the request again with the same +// request ID, the server can check if original operation with the same +// request ID was received, and if so, will ignore the second request. +// This prevents clients from accidentally creating duplicate +// commitments. The request ID must be a valid UUID with the exception +// that zero UUID is not supported +// (00000000-0000-0000-0000-000000000000). +func (c *OrganizationsLocationsGlobalTenantsProxyConfigsDeleteCall) RequestId(requestId string) *OrganizationsLocationsGlobalTenantsProxyConfigsDeleteCall { + c.urlParams_.Set("requestId", requestId) + return c +} + +// Fields allows partial responses to be retrieved. See +// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse +// for more information. +func (c *OrganizationsLocationsGlobalTenantsProxyConfigsDeleteCall) Fields(s ...googleapi.Field) *OrganizationsLocationsGlobalTenantsProxyConfigsDeleteCall { + c.urlParams_.Set("fields", googleapi.CombineFields(s)) + return c +} + +// Context sets the context to be used in this call's Do method. Any +// pending HTTP request will be aborted if the provided context is +// canceled. +func (c *OrganizationsLocationsGlobalTenantsProxyConfigsDeleteCall) Context(ctx context.Context) *OrganizationsLocationsGlobalTenantsProxyConfigsDeleteCall { + c.ctx_ = ctx + return c +} + +// Header returns an http.Header that can be modified by the caller to +// add HTTP headers to the request. +func (c *OrganizationsLocationsGlobalTenantsProxyConfigsDeleteCall) Header() http.Header { + if c.header_ == nil { + c.header_ = make(http.Header) + } + return c.header_ +} + +func (c *OrganizationsLocationsGlobalTenantsProxyConfigsDeleteCall) doRequest(alt string) (*http.Response, error) { + reqHeaders := make(http.Header) + reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version) + for k, v := range c.header_ { + reqHeaders[k] = v + } + reqHeaders.Set("User-Agent", c.s.userAgent()) + var body io.Reader = nil + c.urlParams_.Set("alt", alt) + c.urlParams_.Set("prettyPrint", "false") + urls := googleapi.ResolveRelative(c.s.BasePath, "v1alpha/{+name}") + urls += "?" + c.urlParams_.Encode() + req, err := http.NewRequest("DELETE", urls, body) + if err != nil { + return nil, err + } + req.Header = reqHeaders + googleapi.Expand(req.URL, map[string]string{ + "name": c.name, + }) + return gensupport.SendRequest(c.ctx_, c.s.client, req) +} + +// Do executes the "beyondcorp.organizations.locations.global.tenants.proxyConfigs.delete" call. +// Exactly one of *GoogleLongrunningOperation or error will be non-nil. +// Any non-2xx status code is an error. Response headers are in either +// *GoogleLongrunningOperation.ServerResponse.Header or (if a response +// was returned at all) in error.(*googleapi.Error).Header. Use +// googleapi.IsNotModified to check whether the returned error was +// because http.StatusNotModified was returned. +func (c *OrganizationsLocationsGlobalTenantsProxyConfigsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) { + gensupport.SetOptions(c.urlParams_, opts...) + res, err := c.doRequest("json") + if res != nil && res.StatusCode == http.StatusNotModified { + if res.Body != nil { + res.Body.Close() + } + return nil, gensupport.WrapError(&googleapi.Error{ + Code: res.StatusCode, + Header: res.Header, + }) + } + if err != nil { + return nil, err + } + defer googleapi.CloseBody(res) + if err := googleapi.CheckResponse(res); err != nil { + return nil, gensupport.WrapError(err) + } + ret := &GoogleLongrunningOperation{ + ServerResponse: googleapi.ServerResponse{ + Header: res.Header, + HTTPStatusCode: res.StatusCode, + }, + } + target := &ret + if err := gensupport.DecodeResponse(target, res); err != nil { + return nil, err + } + return ret, nil + // { + // "description": "Deletes a single ProxyConfig.", + // "flatPath": "v1alpha/organizations/{organizationsId}/locations/global/tenants/{tenantsId}/proxyConfigs/{proxyConfigsId}", + // "httpMethod": "DELETE", + // "id": "beyondcorp.organizations.locations.global.tenants.proxyConfigs.delete", + // "parameterOrder": [ + // "name" + // ], + // "parameters": { + // "name": { + // "description": "Required. Name of the resource.", + // "location": "path", + // "pattern": "^organizations/[^/]+/locations/global/tenants/[^/]+/proxyConfigs/[^/]+$", + // "required": true, + // "type": "string" + // }, + // "requestId": { + // "description": "Optional. An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. The server will guarantee that for at least 60 minutes after the first request. For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000).", + // "location": "query", + // "type": "string" + // } + // }, + // "path": "v1alpha/{+name}", + // "response": { + // "$ref": "GoogleLongrunningOperation" + // }, + // "scopes": [ + // "https://www.googleapis.com/auth/cloud-platform" + // ] + // } + +} + // method id "beyondcorp.organizations.locations.global.tenants.proxyConfigs.get": type OrganizationsLocationsGlobalTenantsProxyConfigsGetCall struct { @@ -5707,7 +8635,7 @@ type OrganizationsLocationsGlobalTenantsProxyConfigsGetCall struct { // Get: Gets details of a single ProxyConfig. // -// - name: The resource name of the Tenant using the form: +// - name: The resource name of the ProxyConfig using the form: // `organizations/{organization_id}/locations/global/tenants/{tenant_id // }/proxyConfigs/{proxy_config_id}`. func (r *OrganizationsLocationsGlobalTenantsProxyConfigsService) Get(name string) *OrganizationsLocationsGlobalTenantsProxyConfigsGetCall { @@ -5827,7 +8755,7 @@ func (c *OrganizationsLocationsGlobalTenantsProxyConfigsGetCall) Do(opts ...goog // ], // "parameters": { // "name": { - // "description": "Required. The resource name of the Tenant using the form: `organizations/{organization_id}/locations/global/tenants/{tenant_id}/proxyConfigs/{proxy_config_id}`", + // "description": "Required. The resource name of the ProxyConfig using the form: `organizations/{organization_id}/locations/global/tenants/{tenant_id}/proxyConfigs/{proxy_config_id}`", // "location": "path", // "pattern": "^organizations/[^/]+/locations/global/tenants/[^/]+/proxyConfigs/[^/]+$", // "required": true, diff --git a/bigquery/v2/bigquery-api.json b/bigquery/v2/bigquery-api.json index 59e7563dd03..01680312728 100644 --- a/bigquery/v2/bigquery-api.json +++ b/bigquery/v2/bigquery-api.json @@ -1011,7 +1011,7 @@ "type": "string" }, "filter": { - "description": "If set, then only the Routines matching this filter are returned. The current supported form is either \"routine_type:\" or \"routineType:\", where is a RoutineType enum. Example: \"routineType:SCALAR_FUNCTION\".", + "description": "If set, then only the Routines matching this filter are returned. The supported format is `routineType:{RoutineType}`, where `{RoutineType}` is a RoutineType enum. For example: `routineType:SCALAR_FUNCTION`.", "location": "query", "type": "string" }, @@ -1710,7 +1710,7 @@ } } }, - "revision": "20230422", + "revision": "20230520", "rootUrl": "https://bigquery.googleapis.com/", "schemas": { "AggregateClassificationMetrics": { @@ -3105,7 +3105,7 @@ "id": "EncryptionConfiguration", "properties": { "kmsKeyName": { - "description": "[Optional] Describes the Cloud KMS encryption key that will be used to protect destination BigQuery table. The BigQuery Service Account associated with your project requires access to this encryption key.", + "description": "Optional. Describes the Cloud KMS encryption key that will be used to protect destination BigQuery table. The BigQuery Service Account associated with your project requires access to this encryption key.", "type": "string" } }, @@ -3445,6 +3445,10 @@ "description": "[Optional] Indicates if BigQuery should allow extra values that are not represented in the table schema. If true, the extra values are ignored. If false, records with extra columns are treated as bad records, and if there are too many bad records, an invalid error is returned in the job result. The default value is false. The sourceFormat property determines what BigQuery treats as an extra value: CSV: Trailing columns JSON: Named values that don't match any column names Google Cloud Bigtable: This setting is ignored. Google Cloud Datastore backups: This setting is ignored. Avro: This setting is ignored.", "type": "boolean" }, + "jsonOptions": { + "$ref": "JsonOptions", + "description": "Additional properties to set if `sourceFormat` is set to `NEWLINE_DELIMITED_JSON`." + }, "maxBadRecords": { "description": "[Optional] The maximum number of bad records that BigQuery can ignore when reading data. If the number of bad records exceeds this value, an invalid error is returned in the job result. This is only valid for CSV, JSON, and Google Sheets. The default value is 0, which requires that all records are valid. This setting is ignored for Google Cloud Bigtable, Google Cloud Datastore backups and Avro formats.", "format": "int32", @@ -4913,6 +4917,16 @@ "id": "JsonObject", "type": "object" }, + "JsonOptions": { + "id": "JsonOptions", + "properties": { + "encoding": { + "description": "[Optional] The character encoding of the data. The supported values are UTF-8, UTF-16BE, UTF-16LE, UTF-32BE, and UTF-32LE. The default value is UTF-8.", + "type": "string" + } + }, + "type": "object" + }, "JsonValue": { "id": "JsonValue", "type": "any" @@ -5173,8 +5187,8 @@ "Autoencoder model.", "New name for the ARIMA model.", "ARIMA with external regressors.", - "Random Forest regressor model.", - "Random Forest classifier model.", + "Random forest regressor model.", + "Random forest classifier model.", "An imported TensorFlow Lite model.", "An imported ONNX model." ], @@ -5240,15 +5254,15 @@ "id": "ModelReference", "properties": { "datasetId": { - "description": "[Required] The ID of the dataset containing this model.", + "description": "Required. The ID of the dataset containing this model.", "type": "string" }, "modelId": { - "description": "[Required] The ID of the model. The ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum length is 1,024 characters.", + "description": "Required. The ID of the model. The ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum length is 1,024 characters.", "type": "string" }, "projectId": { - "description": "[Required] The ID of the project containing this model.", + "description": "Required. The ID of the project containing this model.", "type": "string" } }, @@ -5944,13 +5958,15 @@ "ROUTINE_TYPE_UNSPECIFIED", "SCALAR_FUNCTION", "PROCEDURE", - "TABLE_VALUED_FUNCTION" + "TABLE_VALUED_FUNCTION", + "AGGREGATE_FUNCTION" ], "enumDescriptions": [ "", - "Non-builtin permanent scalar function.", + "Non-built-in persistent scalar function.", "Stored procedure.", - "Non-builtin permanent TVF." + "Non-built-in persistent TVF.", + "Non-built-in persistent aggregate function." ], "type": "string" }, @@ -5969,15 +5985,15 @@ "id": "RoutineReference", "properties": { "datasetId": { - "description": "[Required] The ID of the dataset containing this routine.", + "description": "Required. The ID of the dataset containing this routine.", "type": "string" }, "projectId": { - "description": "[Required] The ID of the project containing this routine.", + "description": "Required. The ID of the project containing this routine.", "type": "string" }, "routineId": { - "description": "[Required] The ID of the routine. The ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum length is 256 characters.", + "description": "Required. The ID of the routine. The ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum length is 256 characters.", "type": "string" } }, @@ -6037,19 +6053,19 @@ "id": "RowAccessPolicyReference", "properties": { "datasetId": { - "description": "[Required] The ID of the dataset containing this row access policy.", + "description": "Required. The ID of the dataset containing this row access policy.", "type": "string" }, "policyId": { - "description": "[Required] The ID of the row access policy. The ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum length is 256 characters.", + "description": "Required. The ID of the row access policy. The ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum length is 256 characters.", "type": "string" }, "projectId": { - "description": "[Required] The ID of the project containing this row access policy.", + "description": "Required. The ID of the project containing this row access policy.", "type": "string" }, "tableId": { - "description": "[Required] The ID of the table containing this row access policy.", + "description": "Required. The ID of the table containing this row access policy.", "type": "string" } }, @@ -6495,62 +6511,62 @@ "$ref": "ModelDefinition", "description": "[Output-only, Beta] Present iff this table represents a ML model. Describes the training information for the model, and it is required to run 'PREDICT' queries." }, - "numBytes": { - "description": "[Output-only] The size of this table in bytes, excluding any data in the streaming buffer.", + "numActiveLogicalBytes": { + "description": "[Output-only] Number of logical bytes that are less than 90 days old.", "format": "int64", "type": "string" }, - "numLongTermBytes": { - "description": "[Output-only] The number of bytes in the table that are considered \"long-term storage\".", + "numActivePhysicalBytes": { + "description": "[Output-only] Number of physical bytes less than 90 days old. This data is not kept in real time, and might be delayed by a few seconds to a few minutes.", "format": "int64", "type": "string" }, - "numPhysicalBytes": { - "description": "[Output-only] [TrustedTester] The physical size of this table in bytes, excluding any data in the streaming buffer. This includes compression and storage used for time travel.", + "numBytes": { + "description": "[Output-only] The size of this table in bytes, excluding any data in the streaming buffer.", "format": "int64", "type": "string" }, - "numRows": { - "description": "[Output-only] The number of rows of data in this table, excluding any data in the streaming buffer.", - "format": "uint64", + "numLongTermBytes": { + "description": "[Output-only] The number of bytes in the table that are considered \"long-term storage\".", + "format": "int64", "type": "string" }, - "num_active_logical_bytes": { - "description": "[Output-only] Number of logical bytes that are less than 90 days old.", + "numLongTermLogicalBytes": { + "description": "[Output-only] Number of logical bytes that are more than 90 days old.", "format": "int64", "type": "string" }, - "num_active_physical_bytes": { - "description": "[Output-only] Number of physical bytes less than 90 days old. This data is not kept in real time, and might be delayed by a few seconds to a few minutes.", + "numLongTermPhysicalBytes": { + "description": "[Output-only] Number of physical bytes more than 90 days old. This data is not kept in real time, and might be delayed by a few seconds to a few minutes.", "format": "int64", "type": "string" }, - "num_long_term_logical_bytes": { - "description": "[Output-only] Number of logical bytes that are more than 90 days old.", + "numPartitions": { + "description": "[Output-only] The number of partitions present in the table or materialized view. This data is not kept in real time, and might be delayed by a few seconds to a few minutes.", "format": "int64", "type": "string" }, - "num_long_term_physical_bytes": { - "description": "[Output-only] Number of physical bytes more than 90 days old. This data is not kept in real time, and might be delayed by a few seconds to a few minutes.", + "numPhysicalBytes": { + "description": "[Output-only] [TrustedTester] The physical size of this table in bytes, excluding any data in the streaming buffer. This includes compression and storage used for time travel.", "format": "int64", "type": "string" }, - "num_partitions": { - "description": "[Output-only] The number of partitions present in the table or materialized view. This data is not kept in real time, and might be delayed by a few seconds to a few minutes.", - "format": "int64", + "numRows": { + "description": "[Output-only] The number of rows of data in this table, excluding any data in the streaming buffer.", + "format": "uint64", "type": "string" }, - "num_time_travel_physical_bytes": { + "numTimeTravelPhysicalBytes": { "description": "[Output-only] Number of physical bytes used by time travel storage (deleted or changed data). This data is not kept in real time, and might be delayed by a few seconds to a few minutes.", "format": "int64", "type": "string" }, - "num_total_logical_bytes": { + "numTotalLogicalBytes": { "description": "[Output-only] Total number of logical bytes in the table or materialized view.", "format": "int64", "type": "string" }, - "num_total_physical_bytes": { + "numTotalPhysicalBytes": { "description": "[Output-only] The physical size of this table in bytes. This also includes storage used for time travel. This data is not kept in real time, and might be delayed by a few seconds to a few minutes.", "format": "int64", "type": "string" @@ -6580,6 +6596,10 @@ "$ref": "Streamingbuffer", "description": "[Output-only] Contains information regarding this table's streaming buffer, if one is present. This field will be absent if the table is not being streamed to or if there is no data in the streaming buffer." }, + "tableConstraints": { + "$ref": "TableConstraints", + "description": "[Optional] The table constraints on the table." + }, "tableReference": { "$ref": "TableReference", "description": "[Required] Reference describing the ID of this table." @@ -6608,6 +6628,64 @@ }, "type": "object" }, + "TableConstraints": { + "id": "TableConstraints", + "properties": { + "foreignKeys": { + "description": "[Optional] The foreign keys of the tables.", + "items": { + "properties": { + "columnReferences": { + "items": { + "properties": { + "referencedColumn": { + "type": "string" + }, + "referencingColumn": { + "type": "string" + } + }, + "type": "object" + }, + "type": "array" + }, + "name": { + "type": "string" + }, + "referencedTable": { + "properties": { + "datasetId": { + "type": "string" + }, + "projectId": { + "type": "string" + }, + "tableId": { + "type": "string" + } + }, + "type": "object" + } + }, + "type": "object" + }, + "type": "array" + }, + "primaryKey": { + "description": "[Optional] The primary key of the table.", + "properties": { + "columns": { + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + } + }, + "type": "object" + }, "TableDataInsertAllRequest": { "id": "TableDataInsertAllRequest", "properties": { @@ -7002,6 +7080,10 @@ "description": "If true, detect step changes and make data adjustment in the input time series.", "type": "boolean" }, + "approxGlobalFeatureContrib": { + "description": "Whether to use approximate feature contribution method in XGBoost model explanation for global explain.", + "type": "boolean" + }, "autoArima": { "description": "Whether to enable auto ARIMA or not.", "type": "boolean" diff --git a/bigquery/v2/bigquery-gen.go b/bigquery/v2/bigquery-gen.go index fb05224fde0..6d6b03f8950 100644 --- a/bigquery/v2/bigquery-gen.go +++ b/bigquery/v2/bigquery-gen.go @@ -2763,7 +2763,7 @@ func (s *DoubleRange) UnmarshalJSON(data []byte) error { } type EncryptionConfiguration struct { - // KmsKeyName: [Optional] Describes the Cloud KMS encryption key that + // KmsKeyName: Optional. Describes the Cloud KMS encryption key that // will be used to protect destination BigQuery table. The BigQuery // Service Account associated with your project requires access to this // encryption key. @@ -3282,6 +3282,10 @@ type ExternalDataConfiguration struct { // Avro: This setting is ignored. IgnoreUnknownValues bool `json:"ignoreUnknownValues,omitempty"` + // JsonOptions: Additional properties to set if `sourceFormat` is set to + // `NEWLINE_DELIMITED_JSON`. + JsonOptions *JsonOptions `json:"jsonOptions,omitempty"` + // MaxBadRecords: [Optional] The maximum number of bad records that // BigQuery can ignore when reading data. If the number of bad records // exceeds this value, an invalid error is returned in the job result. @@ -5548,6 +5552,35 @@ func (s *JobStatus) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +type JsonOptions struct { + // Encoding: [Optional] The character encoding of the data. The + // supported values are UTF-8, UTF-16BE, UTF-16LE, UTF-32BE, and + // UTF-32LE. The default value is UTF-8. + Encoding string `json:"encoding,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Encoding") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Encoding") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *JsonOptions) MarshalJSON() ([]byte, error) { + type NoMethod JsonOptions + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + type JsonValue interface{} type ListModelsResponse struct { @@ -5880,8 +5913,8 @@ type Model struct { // "AUTOENCODER" - Autoencoder model. // "ARIMA_PLUS" - New name for the ARIMA model. // "ARIMA_PLUS_XREG" - ARIMA with external regressors. - // "RANDOM_FOREST_REGRESSOR" - Random Forest regressor model. - // "RANDOM_FOREST_CLASSIFIER" - Random Forest classifier model. + // "RANDOM_FOREST_REGRESSOR" - Random forest regressor model. + // "RANDOM_FOREST_CLASSIFIER" - Random forest classifier model. // "TENSORFLOW_LITE" - An imported TensorFlow Lite model. // "ONNX" - An imported ONNX model. ModelType string `json:"modelType,omitempty"` @@ -6001,15 +6034,15 @@ func (s *ModelDefinitionModelOptions) MarshalJSON() ([]byte, error) { } type ModelReference struct { - // DatasetId: [Required] The ID of the dataset containing this model. + // DatasetId: Required. The ID of the dataset containing this model. DatasetId string `json:"datasetId,omitempty"` - // ModelId: [Required] The ID of the model. The ID must contain only + // ModelId: Required. The ID of the model. The ID must contain only // letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum // length is 1,024 characters. ModelId string `json:"modelId,omitempty"` - // ProjectId: [Required] The ID of the project containing this model. + // ProjectId: Required. The ID of the project containing this model. ProjectId string `json:"projectId,omitempty"` // ForceSendFields is a list of field names (e.g. "DatasetId") to @@ -7206,9 +7239,10 @@ type Routine struct { // // Possible values: // "ROUTINE_TYPE_UNSPECIFIED" - // "SCALAR_FUNCTION" - Non-builtin permanent scalar function. + // "SCALAR_FUNCTION" - Non-built-in persistent scalar function. // "PROCEDURE" - Stored procedure. - // "TABLE_VALUED_FUNCTION" - Non-builtin permanent TVF. + // "TABLE_VALUED_FUNCTION" - Non-built-in persistent TVF. + // "AGGREGATE_FUNCTION" - Non-built-in persistent aggregate function. RoutineType string `json:"routineType,omitempty"` // SparkOptions: Optional. Spark specific options. @@ -7250,13 +7284,13 @@ func (s *Routine) MarshalJSON() ([]byte, error) { } type RoutineReference struct { - // DatasetId: [Required] The ID of the dataset containing this routine. + // DatasetId: Required. The ID of the dataset containing this routine. DatasetId string `json:"datasetId,omitempty"` - // ProjectId: [Required] The ID of the project containing this routine. + // ProjectId: Required. The ID of the project containing this routine. ProjectId string `json:"projectId,omitempty"` - // RoutineId: [Required] The ID of the routine. The ID must contain only + // RoutineId: Required. The ID of the routine. The ID must contain only // letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum // length is 256 characters. RoutineId string `json:"routineId,omitempty"` @@ -7366,20 +7400,20 @@ func (s *RowAccessPolicy) MarshalJSON() ([]byte, error) { } type RowAccessPolicyReference struct { - // DatasetId: [Required] The ID of the dataset containing this row - // access policy. + // DatasetId: Required. The ID of the dataset containing this row access + // policy. DatasetId string `json:"datasetId,omitempty"` - // PolicyId: [Required] The ID of the row access policy. The ID must + // PolicyId: Required. The ID of the row access policy. The ID must // contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). // The maximum length is 256 characters. PolicyId string `json:"policyId,omitempty"` - // ProjectId: [Required] The ID of the project containing this row - // access policy. + // ProjectId: Required. The ID of the project containing this row access + // policy. ProjectId string `json:"projectId,omitempty"` - // TableId: [Required] The ID of the table containing this row access + // TableId: Required. The ID of the table containing this row access // policy. TableId string `json:"tableId,omitempty"` @@ -8103,6 +8137,15 @@ type Table struct { // required to run 'PREDICT' queries. Model *ModelDefinition `json:"model,omitempty"` + // NumActiveLogicalBytes: [Output-only] Number of logical bytes that are + // less than 90 days old. + NumActiveLogicalBytes int64 `json:"numActiveLogicalBytes,omitempty,string"` + + // NumActivePhysicalBytes: [Output-only] Number of physical bytes less + // than 90 days old. This data is not kept in real time, and might be + // delayed by a few seconds to a few minutes. + NumActivePhysicalBytes int64 `json:"numActivePhysicalBytes,omitempty,string"` + // NumBytes: [Output-only] The size of this table in bytes, excluding // any data in the streaming buffer. NumBytes int64 `json:"numBytes,omitempty,string"` @@ -8111,53 +8154,44 @@ type Table struct { // are considered "long-term storage". NumLongTermBytes int64 `json:"numLongTermBytes,omitempty,string"` - // NumPhysicalBytes: [Output-only] [TrustedTester] The physical size of - // this table in bytes, excluding any data in the streaming buffer. This - // includes compression and storage used for time travel. - NumPhysicalBytes int64 `json:"numPhysicalBytes,omitempty,string"` - - // NumRows: [Output-only] The number of rows of data in this table, - // excluding any data in the streaming buffer. - NumRows uint64 `json:"numRows,omitempty,string"` - - // NumActiveLogicalBytes: [Output-only] Number of logical bytes that are - // less than 90 days old. - NumActiveLogicalBytes int64 `json:"num_active_logical_bytes,omitempty,string"` - - // NumActivePhysicalBytes: [Output-only] Number of physical bytes less - // than 90 days old. This data is not kept in real time, and might be - // delayed by a few seconds to a few minutes. - NumActivePhysicalBytes int64 `json:"num_active_physical_bytes,omitempty,string"` - // NumLongTermLogicalBytes: [Output-only] Number of logical bytes that // are more than 90 days old. - NumLongTermLogicalBytes int64 `json:"num_long_term_logical_bytes,omitempty,string"` + NumLongTermLogicalBytes int64 `json:"numLongTermLogicalBytes,omitempty,string"` // NumLongTermPhysicalBytes: [Output-only] Number of physical bytes more // than 90 days old. This data is not kept in real time, and might be // delayed by a few seconds to a few minutes. - NumLongTermPhysicalBytes int64 `json:"num_long_term_physical_bytes,omitempty,string"` + NumLongTermPhysicalBytes int64 `json:"numLongTermPhysicalBytes,omitempty,string"` // NumPartitions: [Output-only] The number of partitions present in the // table or materialized view. This data is not kept in real time, and // might be delayed by a few seconds to a few minutes. - NumPartitions int64 `json:"num_partitions,omitempty,string"` + NumPartitions int64 `json:"numPartitions,omitempty,string"` + + // NumPhysicalBytes: [Output-only] [TrustedTester] The physical size of + // this table in bytes, excluding any data in the streaming buffer. This + // includes compression and storage used for time travel. + NumPhysicalBytes int64 `json:"numPhysicalBytes,omitempty,string"` + + // NumRows: [Output-only] The number of rows of data in this table, + // excluding any data in the streaming buffer. + NumRows uint64 `json:"numRows,omitempty,string"` // NumTimeTravelPhysicalBytes: [Output-only] Number of physical bytes // used by time travel storage (deleted or changed data). This data is // not kept in real time, and might be delayed by a few seconds to a few // minutes. - NumTimeTravelPhysicalBytes int64 `json:"num_time_travel_physical_bytes,omitempty,string"` + NumTimeTravelPhysicalBytes int64 `json:"numTimeTravelPhysicalBytes,omitempty,string"` // NumTotalLogicalBytes: [Output-only] Total number of logical bytes in // the table or materialized view. - NumTotalLogicalBytes int64 `json:"num_total_logical_bytes,omitempty,string"` + NumTotalLogicalBytes int64 `json:"numTotalLogicalBytes,omitempty,string"` // NumTotalPhysicalBytes: [Output-only] The physical size of this table // in bytes. This also includes storage used for time travel. This data // is not kept in real time, and might be delayed by a few seconds to a // few minutes. - NumTotalPhysicalBytes int64 `json:"num_total_physical_bytes,omitempty,string"` + NumTotalPhysicalBytes int64 `json:"numTotalPhysicalBytes,omitempty,string"` // RangePartitioning: [TrustedTester] Range partitioning specification // for this table. Only one of timePartitioning and rangePartitioning @@ -8185,6 +8219,9 @@ type Table struct { // in the streaming buffer. StreamingBuffer *Streamingbuffer `json:"streamingBuffer,omitempty"` + // TableConstraints: [Optional] The table constraints on the table. + TableConstraints *TableConstraints `json:"tableConstraints,omitempty"` + // TableReference: [Required] Reference describing the ID of this table. TableReference *TableReference `json:"tableReference,omitempty"` @@ -8259,6 +8296,153 @@ func (s *TableCell) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +type TableConstraints struct { + // ForeignKeys: [Optional] The foreign keys of the tables. + ForeignKeys []*TableConstraintsForeignKeys `json:"foreignKeys,omitempty"` + + // PrimaryKey: [Optional] The primary key of the table. + PrimaryKey *TableConstraintsPrimaryKey `json:"primaryKey,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ForeignKeys") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "ForeignKeys") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *TableConstraints) MarshalJSON() ([]byte, error) { + type NoMethod TableConstraints + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +type TableConstraintsForeignKeys struct { + ColumnReferences []*TableConstraintsForeignKeysColumnReferences `json:"columnReferences,omitempty"` + + Name string `json:"name,omitempty"` + + ReferencedTable *TableConstraintsForeignKeysReferencedTable `json:"referencedTable,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ColumnReferences") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "ColumnReferences") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *TableConstraintsForeignKeys) MarshalJSON() ([]byte, error) { + type NoMethod TableConstraintsForeignKeys + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +type TableConstraintsForeignKeysColumnReferences struct { + ReferencedColumn string `json:"referencedColumn,omitempty"` + + ReferencingColumn string `json:"referencingColumn,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ReferencedColumn") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "ReferencedColumn") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *TableConstraintsForeignKeysColumnReferences) MarshalJSON() ([]byte, error) { + type NoMethod TableConstraintsForeignKeysColumnReferences + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +type TableConstraintsForeignKeysReferencedTable struct { + DatasetId string `json:"datasetId,omitempty"` + + ProjectId string `json:"projectId,omitempty"` + + TableId string `json:"tableId,omitempty"` + + // ForceSendFields is a list of field names (e.g. "DatasetId") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "DatasetId") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *TableConstraintsForeignKeysReferencedTable) MarshalJSON() ([]byte, error) { + type NoMethod TableConstraintsForeignKeysReferencedTable + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// TableConstraintsPrimaryKey: [Optional] The primary key of the table. +type TableConstraintsPrimaryKey struct { + Columns []string `json:"columns,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Columns") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Columns") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *TableConstraintsPrimaryKey) MarshalJSON() ([]byte, error) { + type NoMethod TableConstraintsPrimaryKey + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + type TableDataInsertAllRequest struct { // IgnoreUnknownValues: [Optional] Accept rows that contain values that // do not match the schema. The unknown values are ignored. Default is @@ -8966,6 +9150,10 @@ type TrainingOptions struct { // adjustment in the input time series. AdjustStepChanges bool `json:"adjustStepChanges,omitempty"` + // ApproxGlobalFeatureContrib: Whether to use approximate feature + // contribution method in XGBoost model explanation for global explain. + ApproxGlobalFeatureContrib bool `json:"approxGlobalFeatureContrib,omitempty"` + // AutoArima: Whether to enable auto ARIMA or not. AutoArima bool `json:"autoArima,omitempty"` @@ -13522,9 +13710,9 @@ func (r *RoutinesService) List(projectId string, datasetId string) *RoutinesList } // Filter sets the optional parameter "filter": If set, then only the -// Routines matching this filter are returned. The current supported -// form is either "routine_type:" or "routineType:", where is a -// RoutineType enum. Example: "routineType:SCALAR_FUNCTION". +// Routines matching this filter are returned. The supported format is +// `routineType:{RoutineType}`, where `{RoutineType}` is a RoutineType +// enum. For example: `routineType:SCALAR_FUNCTION`. func (c *RoutinesListCall) Filter(filter string) *RoutinesListCall { c.urlParams_.Set("filter", filter) return c @@ -13673,7 +13861,7 @@ func (c *RoutinesListCall) Do(opts ...googleapi.CallOption) (*ListRoutinesRespon // "type": "string" // }, // "filter": { - // "description": "If set, then only the Routines matching this filter are returned. The current supported form is either \"routine_type:\" or \"routineType:\", where is a RoutineType enum. Example: \"routineType:SCALAR_FUNCTION\".", + // "description": "If set, then only the Routines matching this filter are returned. The supported format is `routineType:{RoutineType}`, where `{RoutineType}` is a RoutineType enum. For example: `routineType:SCALAR_FUNCTION`.", // "location": "query", // "type": "string" // }, diff --git a/bigqueryreservation/v1/bigqueryreservation-api.json b/bigqueryreservation/v1/bigqueryreservation-api.json index 5ffff878eb4..6b55598db4e 100644 --- a/bigqueryreservation/v1/bigqueryreservation-api.json +++ b/bigqueryreservation/v1/bigqueryreservation-api.json @@ -824,7 +824,7 @@ } } }, - "revision": "20230428", + "revision": "20230521", "rootUrl": "https://bigqueryreservation.googleapis.com/", "schemas": { "Assignment": { @@ -960,6 +960,11 @@ "description": "Output only. For FAILED commitment plan, provides the reason of failure.", "readOnly": true }, + "isFlatRate": { + "description": "Output only. If true, the commitment is a flat-rate commitment, otherwise, it's an edition commitment.", + "readOnly": true, + "type": "boolean" + }, "multiRegionAuxiliary": { "description": "Applicable only for commitments located within one of the BigQuery multi-regions (US or EU). If set to true, this commitment is placed in the organization's secondary region which is designated for disaster recovery purposes. If false, this commitment is placed in the organization's default region. NOTE: this is a preview feature. Project must be allow-listed in order to set this field.", "type": "boolean" diff --git a/bigqueryreservation/v1/bigqueryreservation-gen.go b/bigqueryreservation/v1/bigqueryreservation-gen.go index 1fcd5325ca6..1ad3dc9511a 100644 --- a/bigqueryreservation/v1/bigqueryreservation-gen.go +++ b/bigqueryreservation/v1/bigqueryreservation-gen.go @@ -373,6 +373,10 @@ type CapacityCommitment struct { // reason of failure. FailureStatus *Status `json:"failureStatus,omitempty"` + // IsFlatRate: Output only. If true, the commitment is a flat-rate + // commitment, otherwise, it's an edition commitment. + IsFlatRate bool `json:"isFlatRate,omitempty"` + // MultiRegionAuxiliary: Applicable only for commitments located within // one of the BigQuery multi-regions (US or EU). If set to true, this // commitment is placed in the organization's secondary region which is diff --git a/container/v1beta1/container-api.json b/container/v1beta1/container-api.json index 91c8bb320ce..aea60be9353 100644 --- a/container/v1beta1/container-api.json +++ b/container/v1beta1/container-api.json @@ -2514,7 +2514,7 @@ } } }, - "revision": "20230501", + "revision": "20230515", "rootUrl": "https://container.googleapis.com/", "schemas": { "AcceleratorConfig": { @@ -4942,6 +4942,38 @@ }, "type": "object" }, + "NodeAffinity": { + "description": "Specifies the NodeAffinity key, values, and affinity operator according to [shared sole tenant node group affinities](https://cloud.google.com/compute/docs/nodes/sole-tenant-nodes#node_affinity_and_anti-affinity).", + "id": "NodeAffinity", + "properties": { + "key": { + "description": "Key for NodeAffinity.", + "type": "string" + }, + "operator": { + "description": "Operator for NodeAffinity.", + "enum": [ + "OPERATOR_UNSPECIFIED", + "IN", + "NOT_IN" + ], + "enumDescriptions": [ + "Invalid or unspecified affinity operator.", + "Affinity operator.", + "Anti-affinity operator." + ], + "type": "string" + }, + "values": { + "description": "Values for NodeAffinity.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, "NodeConfig": { "description": "Parameters that describe the nodes in a cluster. GKE Autopilot clusters do not recognize parameters in `NodeConfig`. Use AutoprovisioningNodePoolDefaults instead.", "id": "NodeConfig", @@ -5079,6 +5111,10 @@ "$ref": "ShieldedInstanceConfig", "description": "Shielded Instance options." }, + "soleTenantConfig": { + "$ref": "SoleTenantConfig", + "description": "Parameters for node pools to be backed by shared sole tenant node groups." + }, "spot": { "description": "Spot flag for enabling Spot VM, which is a rebrand of the existing preemptible flag.", "type": "boolean" @@ -6496,6 +6532,20 @@ }, "type": "object" }, + "SoleTenantConfig": { + "description": "SoleTenantConfig contains the NodeAffinities to specify what shared sole tenant node groups should back the node pool.", + "id": "SoleTenantConfig", + "properties": { + "nodeAffinities": { + "description": "NodeAffinities used to match to a shared sole tenant node group.", + "items": { + "$ref": "NodeAffinity" + }, + "type": "array" + } + }, + "type": "object" + }, "StandardRolloutPolicy": { "description": "Standard rollout policy is the default policy for blue-green.", "id": "StandardRolloutPolicy", diff --git a/container/v1beta1/container-gen.go b/container/v1beta1/container-gen.go index f467b95da4b..829322c096d 100644 --- a/container/v1beta1/container-gen.go +++ b/container/v1beta1/container-gen.go @@ -4447,6 +4447,47 @@ func (s *NetworkTags) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// NodeAffinity: Specifies the NodeAffinity key, values, and affinity +// operator according to shared sole tenant node group affinities +// (https://cloud.google.com/compute/docs/nodes/sole-tenant-nodes#node_affinity_and_anti-affinity). +type NodeAffinity struct { + // Key: Key for NodeAffinity. + Key string `json:"key,omitempty"` + + // Operator: Operator for NodeAffinity. + // + // Possible values: + // "OPERATOR_UNSPECIFIED" - Invalid or unspecified affinity operator. + // "IN" - Affinity operator. + // "NOT_IN" - Anti-affinity operator. + Operator string `json:"operator,omitempty"` + + // Values: Values for NodeAffinity. + Values []string `json:"values,omitempty"` + + // ForceSendFields is a list of field names (e.g. "Key") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "Key") to include in API + // requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *NodeAffinity) MarshalJSON() ([]byte, error) { + type NoMethod NodeAffinity + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // NodeConfig: Parameters that describe the nodes in a cluster. GKE // Autopilot clusters do not recognize parameters in `NodeConfig`. Use // AutoprovisioningNodePoolDefaults instead. @@ -4615,6 +4656,10 @@ type NodeConfig struct { // ShieldedInstanceConfig: Shielded Instance options. ShieldedInstanceConfig *ShieldedInstanceConfig `json:"shieldedInstanceConfig,omitempty"` + // SoleTenantConfig: Parameters for node pools to be backed by shared + // sole tenant node groups. + SoleTenantConfig *SoleTenantConfig `json:"soleTenantConfig,omitempty"` + // Spot: Spot flag for enabling Spot VM, which is a rebrand of the // existing preemptible flag. Spot bool `json:"spot,omitempty"` @@ -7080,6 +7125,38 @@ func (s *ShieldedNodes) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// SoleTenantConfig: SoleTenantConfig contains the NodeAffinities to +// specify what shared sole tenant node groups should back the node +// pool. +type SoleTenantConfig struct { + // NodeAffinities: NodeAffinities used to match to a shared sole tenant + // node group. + NodeAffinities []*NodeAffinity `json:"nodeAffinities,omitempty"` + + // ForceSendFields is a list of field names (e.g. "NodeAffinities") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "NodeAffinities") to + // include in API requests with the JSON null value. By default, fields + // with empty values are omitted from API requests. However, any field + // with an empty value appearing in NullFields will be sent to the + // server as null. It is an error if a field in this list has a + // non-empty value. This may be used to include null fields in Patch + // requests. + NullFields []string `json:"-"` +} + +func (s *SoleTenantConfig) MarshalJSON() ([]byte, error) { + type NoMethod SoleTenantConfig + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // StandardRolloutPolicy: Standard rollout policy is the default policy // for blue-green. type StandardRolloutPolicy struct { diff --git a/datalineage/v1/datalineage-api.json b/datalineage/v1/datalineage-api.json index 2df5ca42679..707991b7b54 100644 --- a/datalineage/v1/datalineage-api.json +++ b/datalineage/v1/datalineage-api.json @@ -761,7 +761,7 @@ } } }, - "revision": "20230307", + "revision": "20230519", "rootUrl": "https://datalineage.googleapis.com/", "schemas": { "GoogleCloudDatacatalogLineageV1BatchSearchLinkProcessesRequest": { @@ -810,7 +810,7 @@ "id": "GoogleCloudDatacatalogLineageV1EntityReference", "properties": { "fullyQualifiedName": { - "description": "Required. Fully Qualified Name of the entity. Useful for referencing entities that aren't represented as Google Cloud resources, for example, tables in Dataproc Metastore API. Examples: * `bigquery:dataset.project_id.dataset_id` * `bigquery:table.project_id.dataset_id.table_id` * `pubsub:project_id.topic_id` * `dataproc_metastore:projectId.locationId.instanceId.databaseId.tableId`", + "description": "Required. [Fully Qualified Name (FQN)](https://cloud.google.com/data-catalog/docs/fully-qualified-names) of the entity.", "type": "string" } }, @@ -963,11 +963,13 @@ "description": "Output only. The type of the operation being performed.", "enum": [ "TYPE_UNSPECIFIED", - "DELETE" + "DELETE", + "CREATE" ], "enumDescriptions": [ "Unused.", - "The resource deletion operation." + "The resource deletion operation.", + "The resource creation operation." ], "readOnly": true, "type": "string" @@ -1009,11 +1011,11 @@ "id": "GoogleCloudDatacatalogLineageV1Origin", "properties": { "name": { - "description": "If the source_type isn't CUSTOM, the value of this field should be a Google Cloud resource name of the system, which reports lineage. The project and location parts of the resource name must match the project and location of the lineage resource being created. Examples: - `{source_type: COMPOSER, name: \"projects/foo/locations/us/environments/bar\"}` - `{source_type: BIGQUERY, name: \"projects/foo/locations/eu\"}` - `{source_type: CUSTOM, name: \"myCustomIntegration\"}`", + "description": "If the source_type isn't CUSTOM, the value of this field should be a GCP resource name of the system, which reports lineage. The project and location parts of the resource name must match the project and location of the lineage resource being created. Examples: - `{source_type: COMPOSER, name: \"projects/foo/locations/us/environments/bar\"}` - `{source_type: BIGQUERY, name: \"projects/foo/locations/eu\"}` - `{source_type: CUSTOM, name: \"myCustomIntegration\"}`", "type": "string" }, "sourceType": { - "description": "Type of the source.", + "description": "Type of the source. Use of a source_type other than `CUSTOM` for process creation or updating is highly discouraged, and may be restricted in the future without notice.", "enum": [ "SOURCE_TYPE_UNSPECIFIED", "CUSTOM", diff --git a/datalineage/v1/datalineage-gen.go b/datalineage/v1/datalineage-gen.go index 7fd2321c00c..a5ae3eeff33 100644 --- a/datalineage/v1/datalineage-gen.go +++ b/datalineage/v1/datalineage-gen.go @@ -293,14 +293,9 @@ func (s *GoogleCloudDatacatalogLineageV1BatchSearchLinkProcessesResponse) Marsha // GoogleCloudDatacatalogLineageV1EntityReference: The soft reference to // everything you can attach a lineage event to. type GoogleCloudDatacatalogLineageV1EntityReference struct { - // FullyQualifiedName: Required. Fully Qualified Name of the entity. - // Useful for referencing entities that aren't represented as Google - // Cloud resources, for example, tables in Dataproc Metastore API. - // Examples: * `bigquery:dataset.project_id.dataset_id` * - // `bigquery:table.project_id.dataset_id.table_id` * - // `pubsub:project_id.topic_id` * - // `dataproc_metastore:projectId.locationId.instanceId.databaseId.tableId - // ` + // FullyQualifiedName: Required. Fully Qualified Name (FQN) + // (https://cloud.google.com/data-catalog/docs/fully-qualified-names) of + // the entity. FullyQualifiedName string `json:"fullyQualifiedName,omitempty"` // ForceSendFields is a list of field names (e.g. "FullyQualifiedName") @@ -590,6 +585,7 @@ type GoogleCloudDatacatalogLineageV1OperationMetadata struct { // Possible values: // "TYPE_UNSPECIFIED" - Unused. // "DELETE" - The resource deletion operation. + // "CREATE" - The resource creation operation. OperationType string `json:"operationType,omitempty"` // Resource: Output only. The [relative name] @@ -637,8 +633,8 @@ func (s *GoogleCloudDatacatalogLineageV1OperationMetadata) MarshalJSON() ([]byte // GoogleCloudDatacatalogLineageV1Origin: Origin of a process. type GoogleCloudDatacatalogLineageV1Origin struct { // Name: If the source_type isn't CUSTOM, the value of this field should - // be a Google Cloud resource name of the system, which reports lineage. - // The project and location parts of the resource name must match the + // be a GCP resource name of the system, which reports lineage. The + // project and location parts of the resource name must match the // project and location of the lineage resource being created. Examples: // - `{source_type: COMPOSER, name: // "projects/foo/locations/us/environments/bar"}` - `{source_type: @@ -646,7 +642,9 @@ type GoogleCloudDatacatalogLineageV1Origin struct { // CUSTOM, name: "myCustomIntegration"}` Name string `json:"name,omitempty"` - // SourceType: Type of the source. + // SourceType: Type of the source. Use of a source_type other than + // `CUSTOM` for process creation or updating is highly discouraged, and + // may be restricted in the future without notice. // // Possible values: // "SOURCE_TYPE_UNSPECIFIED" - Source is Unspecified diff --git a/datastream/v1alpha1/datastream-api.json b/datastream/v1alpha1/datastream-api.json index cd6a2bf3c4d..e4f8b30b129 100644 --- a/datastream/v1alpha1/datastream-api.json +++ b/datastream/v1alpha1/datastream-api.json @@ -215,6 +215,7 @@ }, "resources": { "connectionProfiles": { + "deprecated": true, "methods": { "create": { "deprecated": true, @@ -711,6 +712,7 @@ }, "resources": { "routes": { + "deprecated": true, "methods": { "create": { "deprecated": true, @@ -1096,6 +1098,7 @@ }, "resources": { "objects": { + "deprecated": true, "methods": { "get": { "deprecated": true, @@ -1221,7 +1224,7 @@ } } }, - "revision": "20230425", + "revision": "20230517", "rootUrl": "https://datastream.googleapis.com/", "schemas": { "AvroFileFormat": { diff --git a/deploymentmanager/v2beta/deploymentmanager-api.json b/deploymentmanager/v2beta/deploymentmanager-api.json index a6ab37e19ae..73ff088a0c6 100644 --- a/deploymentmanager/v2beta/deploymentmanager-api.json +++ b/deploymentmanager/v2beta/deploymentmanager-api.json @@ -1552,7 +1552,7 @@ } } }, - "revision": "20230202", + "revision": "20230518", "rootUrl": "https://deploymentmanager.googleapis.com/", "schemas": { "AsyncOptions": { @@ -2316,7 +2316,8 @@ "PARTIAL_SUCCESS", "LARGE_DEPLOYMENT_WARNING", "NEXT_HOP_INSTANCE_HAS_NO_IPV6_INTERFACE", - "INVALID_HEALTH_CHECK_FOR_DYNAMIC_WIEGHTED_LB" + "INVALID_HEALTH_CHECK_FOR_DYNAMIC_WIEGHTED_LB", + "LIST_OVERHEAD_QUOTA_EXCEED" ], "enumDescriptions": [ "A link to a deprecated resource was created.", @@ -2345,7 +2346,8 @@ "Success is reported, but some results may be missing due to errors", "When deploying a deployment with a exceedingly large number of resources", "The route's nextHopInstance URL refers to an instance that does not have an ipv6 interface on the same network as the route.", - "A WEIGHTED_MAGLEV backend service is associated with a health check that is not of type HTTP/HTTPS/HTTP2." + "A WEIGHTED_MAGLEV backend service is associated with a health check that is not of type HTTP/HTTPS/HTTP2.", + "Resource can't be retrieved due to list overhead quota exceed which captures the amount of resources filtered out by user-defined list filter." ], "type": "string" }, @@ -2569,7 +2571,8 @@ "PARTIAL_SUCCESS", "LARGE_DEPLOYMENT_WARNING", "NEXT_HOP_INSTANCE_HAS_NO_IPV6_INTERFACE", - "INVALID_HEALTH_CHECK_FOR_DYNAMIC_WIEGHTED_LB" + "INVALID_HEALTH_CHECK_FOR_DYNAMIC_WIEGHTED_LB", + "LIST_OVERHEAD_QUOTA_EXCEED" ], "enumDescriptions": [ "A link to a deprecated resource was created.", @@ -2598,7 +2601,8 @@ "Success is reported, but some results may be missing due to errors", "When deploying a deployment with a exceedingly large number of resources", "The route's nextHopInstance URL refers to an instance that does not have an ipv6 interface on the same network as the route.", - "A WEIGHTED_MAGLEV backend service is associated with a health check that is not of type HTTP/HTTPS/HTTP2." + "A WEIGHTED_MAGLEV backend service is associated with a health check that is not of type HTTP/HTTPS/HTTP2.", + "Resource can't be retrieved due to list overhead quota exceed which captures the amount of resources filtered out by user-defined list filter." ], "type": "string" }, @@ -2759,7 +2763,8 @@ "PARTIAL_SUCCESS", "LARGE_DEPLOYMENT_WARNING", "NEXT_HOP_INSTANCE_HAS_NO_IPV6_INTERFACE", - "INVALID_HEALTH_CHECK_FOR_DYNAMIC_WIEGHTED_LB" + "INVALID_HEALTH_CHECK_FOR_DYNAMIC_WIEGHTED_LB", + "LIST_OVERHEAD_QUOTA_EXCEED" ], "enumDescriptions": [ "A link to a deprecated resource was created.", @@ -2788,7 +2793,8 @@ "Success is reported, but some results may be missing due to errors", "When deploying a deployment with a exceedingly large number of resources", "The route's nextHopInstance URL refers to an instance that does not have an ipv6 interface on the same network as the route.", - "A WEIGHTED_MAGLEV backend service is associated with a health check that is not of type HTTP/HTTPS/HTTP2." + "A WEIGHTED_MAGLEV backend service is associated with a health check that is not of type HTTP/HTTPS/HTTP2.", + "Resource can't be retrieved due to list overhead quota exceed which captures the amount of resources filtered out by user-defined list filter." ], "type": "string" }, diff --git a/deploymentmanager/v2beta/deploymentmanager-gen.go b/deploymentmanager/v2beta/deploymentmanager-gen.go index 7c4afa8fa19..dccdb3a71ed 100644 --- a/deploymentmanager/v2beta/deploymentmanager-gen.go +++ b/deploymentmanager/v2beta/deploymentmanager-gen.go @@ -1635,6 +1635,9 @@ type OperationWarnings struct { // "INVALID_HEALTH_CHECK_FOR_DYNAMIC_WIEGHTED_LB" - A WEIGHTED_MAGLEV // backend service is associated with a health check that is not of type // HTTP/HTTPS/HTTP2. + // "LIST_OVERHEAD_QUOTA_EXCEED" - Resource can't be retrieved due to + // list overhead quota exceed which captures the amount of resources + // filtered out by user-defined list filter. Code string `json:"code,omitempty"` // Data: [Output Only] Metadata about this warning in key: value format. @@ -2079,6 +2082,9 @@ type ResourceWarnings struct { // "INVALID_HEALTH_CHECK_FOR_DYNAMIC_WIEGHTED_LB" - A WEIGHTED_MAGLEV // backend service is associated with a health check that is not of type // HTTP/HTTPS/HTTP2. + // "LIST_OVERHEAD_QUOTA_EXCEED" - Resource can't be retrieved due to + // list overhead quota exceed which captures the amount of resources + // filtered out by user-defined list filter. Code string `json:"code,omitempty"` // Data: [Output Only] Metadata about this warning in key: value format. @@ -2378,6 +2384,9 @@ type ResourceUpdateWarnings struct { // "INVALID_HEALTH_CHECK_FOR_DYNAMIC_WIEGHTED_LB" - A WEIGHTED_MAGLEV // backend service is associated with a health check that is not of type // HTTP/HTTPS/HTTP2. + // "LIST_OVERHEAD_QUOTA_EXCEED" - Resource can't be retrieved due to + // list overhead quota exceed which captures the amount of resources + // filtered out by user-defined list filter. Code string `json:"code,omitempty"` // Data: [Output Only] Metadata about this warning in key: value format. diff --git a/discoveryengine/v1alpha/discoveryengine-api.json b/discoveryengine/v1alpha/discoveryengine-api.json index 332a89a0c08..428334d9f38 100644 --- a/discoveryengine/v1alpha/discoveryengine-api.json +++ b/discoveryengine/v1alpha/discoveryengine-api.json @@ -1610,7 +1610,7 @@ } } }, - "revision": "20230518", + "revision": "20230525", "rootUrl": "https://discoveryengine.googleapis.com/", "schemas": { "GoogleApiHttpBody": { @@ -1759,6 +1759,200 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1ImportDocumentsMetadata": { + "description": "Metadata related to the progress of the ImportDocuments operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1ImportDocumentsMetadata", + "properties": { + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", + "type": "string" + }, + "failureCount": { + "description": "Count of entries that encountered errors while processing.", + "format": "int64", + "type": "string" + }, + "successCount": { + "description": "Count of entries that were processed successfully.", + "format": "int64", + "type": "string" + }, + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1ImportDocumentsResponse": { + "description": "Response of the ImportDocumentsRequest. If the long running operation is done, then this message is returned by the google.longrunning.Operations.response field if the operation was successful.", + "id": "GoogleCloudDiscoveryengineV1ImportDocumentsResponse", + "properties": { + "errorConfig": { + "$ref": "GoogleCloudDiscoveryengineV1ImportErrorConfig", + "description": "Echoes the destination for the complete errors in the request if set." + }, + "errorSamples": { + "description": "A sample of errors encountered while processing the request.", + "items": { + "$ref": "GoogleRpcStatus" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1ImportErrorConfig": { + "description": "Configuration of destination for Import related errors.", + "id": "GoogleCloudDiscoveryengineV1ImportErrorConfig", + "properties": { + "gcsPrefix": { + "description": "Cloud Storage prefix for import errors. This must be an empty, existing Cloud Storage directory. Import errors will be written to sharded files in this directory, one per line, as a JSON-encoded `google.rpc.Status` message.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1ImportUserEventsMetadata": { + "description": "Metadata related to the progress of the Import operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1ImportUserEventsMetadata", + "properties": { + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", + "type": "string" + }, + "failureCount": { + "description": "Count of entries that encountered errors while processing.", + "format": "int64", + "type": "string" + }, + "successCount": { + "description": "Count of entries that were processed successfully.", + "format": "int64", + "type": "string" + }, + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1ImportUserEventsResponse": { + "description": "Response of the ImportUserEventsRequest. If the long running operation was successful, then this message is returned by the google.longrunning.Operations.response field if the operation was successful.", + "id": "GoogleCloudDiscoveryengineV1ImportUserEventsResponse", + "properties": { + "errorConfig": { + "$ref": "GoogleCloudDiscoveryengineV1ImportErrorConfig", + "description": "Echoes the destination for the complete errors if this field was set in the request." + }, + "errorSamples": { + "description": "A sample of errors encountered while processing the request.", + "items": { + "$ref": "GoogleRpcStatus" + }, + "type": "array" + }, + "joinedEventsCount": { + "description": "Count of user events imported with complete existing Documents.", + "format": "int64", + "type": "string" + }, + "unjoinedEventsCount": { + "description": "Count of user events imported, but with Document information not found in the existing Branch.", + "format": "int64", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata": { + "description": "Metadata related to the progress of the PurgeDocuments operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata", + "properties": { + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", + "type": "string" + }, + "failureCount": { + "description": "Count of entries that encountered errors while processing.", + "format": "int64", + "type": "string" + }, + "successCount": { + "description": "Count of entries that were deleted successfully.", + "format": "int64", + "type": "string" + }, + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1PurgeDocumentsResponse": { + "description": "Response message for DocumentService.PurgeDocuments method. If the long running operation is successfully done, then this message is returned by the google.longrunning.Operations.response field.", + "id": "GoogleCloudDiscoveryengineV1PurgeDocumentsResponse", + "properties": { + "purgeCount": { + "description": "The total count of documents purged as a result of the operation.", + "format": "int64", + "type": "string" + }, + "purgeSample": { + "description": "A sample of document names that will be deleted. Only populated if `force` is set to false. A max of 100 names will be returned and the names are chosen at random.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1Schema": { + "description": "Defines the structure and layout of a type of document data.", + "id": "GoogleCloudDiscoveryengineV1Schema", + "properties": { + "jsonSchema": { + "description": "The JSON representation of the schema.", + "type": "string" + }, + "name": { + "description": "Immutable. The full resource name of the schema, in the format of `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/schemas/{schema}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.", + "type": "string" + }, + "structSchema": { + "additionalProperties": { + "description": "Properties of the object.", + "type": "any" + }, + "description": "The structured representation of the schema.", + "type": "object" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse": { + "description": "Response message for SiteSearchEngineService.BatchCreateTargetSites method.", + "id": "GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse", + "properties": { + "targetSites": { + "description": "TargetSites created.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaTargetSite" + }, + "type": "array" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaBigQuerySource": { "description": "BigQuery source import data from.", "id": "GoogleCloudDiscoveryengineV1alphaBigQuerySource", @@ -1943,6 +2137,10 @@ "description": "Request message for Import methods.", "id": "GoogleCloudDiscoveryengineV1alphaImportDocumentsRequest", "properties": { + "autoGenerateIds": { + "description": "Whether to automatically generate IDs for the documents if absent. If set to `true`, Document.ids are automatically generated based on the hash of the payload, where IDs may not be consistent during multiple imports. In which case ReconciliationMode.FULL is highly recommended to avoid duplicate contents. If unset or set to `false`, Document.ids have to be specified using id_field, otherwises, documents without IDs will fail to be imported. Only set this field when using GcsSource or BigQuerySource, and when GcsSource.data_schema or BigQuerySource.data_schema is `custom`. Otherwise, an INVALID_ARGUMENT error is thrown.", + "type": "boolean" + }, "bigquerySource": { "$ref": "GoogleCloudDiscoveryengineV1alphaBigQuerySource", "description": "BigQuery input source." @@ -1955,6 +2153,10 @@ "$ref": "GoogleCloudDiscoveryengineV1alphaGcsSource", "description": "Cloud Storage location for the input content." }, + "idField": { + "description": "The field in the Cloud Storage and BigQuery sources that indicates the unique IDs of the documents. For GcsSource it is the key of the JSON field. For instance, `my_id` for JSON `{\"my_id\": \"some_uuid\"}`. For BigQuerySource it is the column name of the BigQuery table where the unique ids are stored. The values of the JSON field or the BigQuery column will be used as the Document.ids. The JSON field or the BigQuery column must be of string type, and the values must be set as valid strings conform to [RFC-1034](https://tools.ietf.org/html/rfc1034) with 1-63 characters. Otherwise, documents without valid IDs will fail to be imported. Only set this field when using GcsSource or BigQuerySource, and when GcsSource.data_schema or BigQuerySource.data_schema is `custom`. And only set this field when auto_generate_ids is unset or set as `false`. Otherwise, an INVALID_ARGUMENT error is thrown. If it is unset, a default value `_id` is used when importing from the allowed data sources.", + "type": "string" + }, "inlineSource": { "$ref": "GoogleCloudDiscoveryengineV1alphaImportDocumentsRequestInlineSource", "description": "The Inline source for the input content for documents." @@ -2387,6 +2589,51 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaTargetSite": { + "description": "A target site for the SiteSearchEngine.", + "id": "GoogleCloudDiscoveryengineV1alphaTargetSite", + "properties": { + "exactMatch": { + "description": "Input only. If set to false, an uri_pattern will be generated to include all pages whose address contains the provided_uri_pattern. If set to true, an uri_pattern will be generated to try to be an exact match of the provided_uri_pattern or just the specific page if the provided_uri_pattern is a specific one. provided_uri_pattern will always be normalized to generate the uri pattern to be used by the search engine.", + "type": "boolean" + }, + "generatedUriPattern": { + "description": "Output only. This is system-generated based on the provided_uri_pattern.", + "readOnly": true, + "type": "string" + }, + "name": { + "description": "Output only. The fully qualified resource name of the target site. `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine/targetSites/{target_site}` The `target_site_id` is system-generated.", + "readOnly": true, + "type": "string" + }, + "providedUriPattern": { + "description": "Required. Input only. The user provided uri pattern from which the `generated_uri_pattern` is generated.", + "type": "string" + }, + "type": { + "description": "The type of the target site, e.g. whether the site is to be included or excluded.", + "enum": [ + "TYPE_UNSPECIFIED", + "INCLUDE", + "EXCLUDE" + ], + "enumDescriptions": [ + "This value is unused. In this case, server behavior defaults to Type.INCLUDE.", + "Include the target site.", + "Exclude the target site." + ], + "type": "string" + }, + "updateTime": { + "description": "Output only. The target site's last updated time.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaTransactionInfo": { "description": "A transaction represents the entire purchase transaction.", "id": "GoogleCloudDiscoveryengineV1alphaTransactionInfo", diff --git a/discoveryengine/v1alpha/discoveryengine-gen.go b/discoveryengine/v1alpha/discoveryengine-gen.go index 1d90b89a8fc..379a4ca0eef 100644 --- a/discoveryengine/v1alpha/discoveryengine-gen.go +++ b/discoveryengine/v1alpha/discoveryengine-gen.go @@ -769,6 +769,349 @@ func (s *GoogleCloudDiscoveryengineLoggingSourceLocation) MarshalJSON() ([]byte, return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1ImportDocumentsMetadata: Metadata related +// to the progress of the ImportDocuments operation. This will be +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1ImportDocumentsMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` + + // FailureCount: Count of entries that encountered errors while + // processing. + FailureCount int64 `json:"failureCount,omitempty,string"` + + // SuccessCount: Count of entries that were processed successfully. + SuccessCount int64 `json:"successCount,omitempty,string"` + + // UpdateTime: Operation last update time. If the operation is done, + // this is also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + + // ForceSendFields is a list of field names (e.g. "CreateTime") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "CreateTime") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1ImportDocumentsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1ImportDocumentsMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1ImportDocumentsResponse: Response of the +// ImportDocumentsRequest. If the long running operation is done, then +// this message is returned by the +// google.longrunning.Operations.response field if the operation was +// successful. +type GoogleCloudDiscoveryengineV1ImportDocumentsResponse struct { + // ErrorConfig: Echoes the destination for the complete errors in the + // request if set. + ErrorConfig *GoogleCloudDiscoveryengineV1ImportErrorConfig `json:"errorConfig,omitempty"` + + // ErrorSamples: A sample of errors encountered while processing the + // request. + ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ErrorConfig") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "ErrorConfig") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1ImportDocumentsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1ImportDocumentsResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1ImportErrorConfig: Configuration of +// destination for Import related errors. +type GoogleCloudDiscoveryengineV1ImportErrorConfig struct { + // GcsPrefix: Cloud Storage prefix for import errors. This must be an + // empty, existing Cloud Storage directory. Import errors will be + // written to sharded files in this directory, one per line, as a + // JSON-encoded `google.rpc.Status` message. + GcsPrefix string `json:"gcsPrefix,omitempty"` + + // ForceSendFields is a list of field names (e.g. "GcsPrefix") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "GcsPrefix") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1ImportErrorConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1ImportErrorConfig + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1ImportUserEventsMetadata: Metadata +// related to the progress of the Import operation. This will be +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1ImportUserEventsMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` + + // FailureCount: Count of entries that encountered errors while + // processing. + FailureCount int64 `json:"failureCount,omitempty,string"` + + // SuccessCount: Count of entries that were processed successfully. + SuccessCount int64 `json:"successCount,omitempty,string"` + + // UpdateTime: Operation last update time. If the operation is done, + // this is also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + + // ForceSendFields is a list of field names (e.g. "CreateTime") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "CreateTime") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1ImportUserEventsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1ImportUserEventsMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1ImportUserEventsResponse: Response of the +// ImportUserEventsRequest. If the long running operation was +// successful, then this message is returned by the +// google.longrunning.Operations.response field if the operation was +// successful. +type GoogleCloudDiscoveryengineV1ImportUserEventsResponse struct { + // ErrorConfig: Echoes the destination for the complete errors if this + // field was set in the request. + ErrorConfig *GoogleCloudDiscoveryengineV1ImportErrorConfig `json:"errorConfig,omitempty"` + + // ErrorSamples: A sample of errors encountered while processing the + // request. + ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` + + // JoinedEventsCount: Count of user events imported with complete + // existing Documents. + JoinedEventsCount int64 `json:"joinedEventsCount,omitempty,string"` + + // UnjoinedEventsCount: Count of user events imported, but with Document + // information not found in the existing Branch. + UnjoinedEventsCount int64 `json:"unjoinedEventsCount,omitempty,string"` + + // ForceSendFields is a list of field names (e.g. "ErrorConfig") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "ErrorConfig") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1ImportUserEventsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1ImportUserEventsResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata: Metadata related +// to the progress of the PurgeDocuments operation. This will be +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` + + // FailureCount: Count of entries that encountered errors while + // processing. + FailureCount int64 `json:"failureCount,omitempty,string"` + + // SuccessCount: Count of entries that were deleted successfully. + SuccessCount int64 `json:"successCount,omitempty,string"` + + // UpdateTime: Operation last update time. If the operation is done, + // this is also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + + // ForceSendFields is a list of field names (e.g. "CreateTime") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "CreateTime") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1PurgeDocumentsResponse: Response message +// for DocumentService.PurgeDocuments method. If the long running +// operation is successfully done, then this message is returned by the +// google.longrunning.Operations.response field. +type GoogleCloudDiscoveryengineV1PurgeDocumentsResponse struct { + // PurgeCount: The total count of documents purged as a result of the + // operation. + PurgeCount int64 `json:"purgeCount,omitempty,string"` + + // PurgeSample: A sample of document names that will be deleted. Only + // populated if `force` is set to false. A max of 100 names will be + // returned and the names are chosen at random. + PurgeSample []string `json:"purgeSample,omitempty"` + + // ForceSendFields is a list of field names (e.g. "PurgeCount") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "PurgeCount") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1PurgeDocumentsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1PurgeDocumentsResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1Schema: Defines the structure and layout +// of a type of document data. +type GoogleCloudDiscoveryengineV1Schema struct { + // JsonSchema: The JSON representation of the schema. + JsonSchema string `json:"jsonSchema,omitempty"` + + // Name: Immutable. The full resource name of the schema, in the format + // of + // `projects/{project}/locations/{location}/collections/{collection}/data + // Stores/{data_store}/schemas/{schema}`. This field must be a UTF-8 + // encoded string with a length limit of 1024 characters. + Name string `json:"name,omitempty"` + + // StructSchema: The structured representation of the schema. + StructSchema googleapi.RawMessage `json:"structSchema,omitempty"` + + // ForceSendFields is a list of field names (e.g. "JsonSchema") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "JsonSchema") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1Schema) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1Schema + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse: +// Response message for SiteSearchEngineService.BatchCreateTargetSites +// method. +type GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse struct { + // TargetSites: TargetSites created. + TargetSites []*GoogleCloudDiscoveryengineV1alphaTargetSite `json:"targetSites,omitempty"` + + // ForceSendFields is a list of field names (e.g. "TargetSites") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "TargetSites") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaBigQuerySource: BigQuery source // import data from. type GoogleCloudDiscoveryengineV1alphaBigQuerySource struct { @@ -1123,6 +1466,19 @@ func (s *GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata) MarshalJSON() // GoogleCloudDiscoveryengineV1alphaImportDocumentsRequest: Request // message for Import methods. type GoogleCloudDiscoveryengineV1alphaImportDocumentsRequest struct { + // AutoGenerateIds: Whether to automatically generate IDs for the + // documents if absent. If set to `true`, Document.ids are automatically + // generated based on the hash of the payload, where IDs may not be + // consistent during multiple imports. In which case + // ReconciliationMode.FULL is highly recommended to avoid duplicate + // contents. If unset or set to `false`, Document.ids have to be + // specified using id_field, otherwises, documents without IDs will fail + // to be imported. Only set this field when using GcsSource or + // BigQuerySource, and when GcsSource.data_schema or + // BigQuerySource.data_schema is `custom`. Otherwise, an + // INVALID_ARGUMENT error is thrown. + AutoGenerateIds bool `json:"autoGenerateIds,omitempty"` + // BigquerySource: BigQuery input source. BigquerySource *GoogleCloudDiscoveryengineV1alphaBigQuerySource `json:"bigquerySource,omitempty"` @@ -1133,6 +1489,24 @@ type GoogleCloudDiscoveryengineV1alphaImportDocumentsRequest struct { // GcsSource: Cloud Storage location for the input content. GcsSource *GoogleCloudDiscoveryengineV1alphaGcsSource `json:"gcsSource,omitempty"` + // IdField: The field in the Cloud Storage and BigQuery sources that + // indicates the unique IDs of the documents. For GcsSource it is the + // key of the JSON field. For instance, `my_id` for JSON `{"my_id": + // "some_uuid"}`. For BigQuerySource it is the column name of the + // BigQuery table where the unique ids are stored. The values of the + // JSON field or the BigQuery column will be used as the Document.ids. + // The JSON field or the BigQuery column must be of string type, and the + // values must be set as valid strings conform to RFC-1034 + // (https://tools.ietf.org/html/rfc1034) with 1-63 characters. + // Otherwise, documents without valid IDs will fail to be imported. Only + // set this field when using GcsSource or BigQuerySource, and when + // GcsSource.data_schema or BigQuerySource.data_schema is `custom`. And + // only set this field when auto_generate_ids is unset or set as + // `false`. Otherwise, an INVALID_ARGUMENT error is thrown. If it is + // unset, a default value `_id` is used when importing from the allowed + // data sources. + IdField string `json:"idField,omitempty"` + // InlineSource: The Inline source for the input content for documents. InlineSource *GoogleCloudDiscoveryengineV1alphaImportDocumentsRequestInlineSource `json:"inlineSource,omitempty"` @@ -1149,7 +1523,7 @@ type GoogleCloudDiscoveryengineV1alphaImportDocumentsRequest struct { // source location. ReconciliationMode string `json:"reconciliationMode,omitempty"` - // ForceSendFields is a list of field names (e.g. "BigquerySource") to + // ForceSendFields is a list of field names (e.g. "AutoGenerateIds") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1157,7 +1531,7 @@ type GoogleCloudDiscoveryengineV1alphaImportDocumentsRequest struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "BigquerySource") to + // NullFields is a list of field names (e.g. "AutoGenerateIds") to // include in API requests with the JSON null value. By default, fields // with empty values are omitted from API requests. However, any field // with an empty value appearing in NullFields will be sent to the @@ -2004,6 +2378,69 @@ func (s *GoogleCloudDiscoveryengineV1alphaSearchInfo) MarshalJSON() ([]byte, err return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaTargetSite: A target site for the +// SiteSearchEngine. +type GoogleCloudDiscoveryengineV1alphaTargetSite struct { + // ExactMatch: Input only. If set to false, an uri_pattern will be + // generated to include all pages whose address contains the + // provided_uri_pattern. If set to true, an uri_pattern will be + // generated to try to be an exact match of the provided_uri_pattern or + // just the specific page if the provided_uri_pattern is a specific one. + // provided_uri_pattern will always be normalized to generate the uri + // pattern to be used by the search engine. + ExactMatch bool `json:"exactMatch,omitempty"` + + // GeneratedUriPattern: Output only. This is system-generated based on + // the provided_uri_pattern. + GeneratedUriPattern string `json:"generatedUriPattern,omitempty"` + + // Name: Output only. The fully qualified resource name of the target + // site. + // `projects/{project}/locations/{location}/collections/{collection}/data + // Stores/{data_store}/siteSearchEngine/targetSites/{target_site}` The + // `target_site_id` is system-generated. + Name string `json:"name,omitempty"` + + // ProvidedUriPattern: Required. Input only. The user provided uri + // pattern from which the `generated_uri_pattern` is generated. + ProvidedUriPattern string `json:"providedUriPattern,omitempty"` + + // Type: The type of the target site, e.g. whether the site is to be + // included or excluded. + // + // Possible values: + // "TYPE_UNSPECIFIED" - This value is unused. In this case, server + // behavior defaults to Type.INCLUDE. + // "INCLUDE" - Include the target site. + // "EXCLUDE" - Exclude the target site. + Type string `json:"type,omitempty"` + + // UpdateTime: Output only. The target site's last updated time. + UpdateTime string `json:"updateTime,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ExactMatch") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "ExactMatch") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaTargetSite) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaTargetSite + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaTransactionInfo: A transaction // represents the entire purchase transaction. type GoogleCloudDiscoveryengineV1alphaTransactionInfo struct { diff --git a/discoveryengine/v1beta/discoveryengine-api.json b/discoveryengine/v1beta/discoveryengine-api.json index 5ed52b09b4f..180cf9fb7d8 100644 --- a/discoveryengine/v1beta/discoveryengine-api.json +++ b/discoveryengine/v1beta/discoveryengine-api.json @@ -1610,7 +1610,7 @@ } } }, - "revision": "20230518", + "revision": "20230525", "rootUrl": "https://discoveryengine.googleapis.com/", "schemas": { "GoogleApiHttpBody": { @@ -1759,6 +1759,200 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1ImportDocumentsMetadata": { + "description": "Metadata related to the progress of the ImportDocuments operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1ImportDocumentsMetadata", + "properties": { + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", + "type": "string" + }, + "failureCount": { + "description": "Count of entries that encountered errors while processing.", + "format": "int64", + "type": "string" + }, + "successCount": { + "description": "Count of entries that were processed successfully.", + "format": "int64", + "type": "string" + }, + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1ImportDocumentsResponse": { + "description": "Response of the ImportDocumentsRequest. If the long running operation is done, then this message is returned by the google.longrunning.Operations.response field if the operation was successful.", + "id": "GoogleCloudDiscoveryengineV1ImportDocumentsResponse", + "properties": { + "errorConfig": { + "$ref": "GoogleCloudDiscoveryengineV1ImportErrorConfig", + "description": "Echoes the destination for the complete errors in the request if set." + }, + "errorSamples": { + "description": "A sample of errors encountered while processing the request.", + "items": { + "$ref": "GoogleRpcStatus" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1ImportErrorConfig": { + "description": "Configuration of destination for Import related errors.", + "id": "GoogleCloudDiscoveryengineV1ImportErrorConfig", + "properties": { + "gcsPrefix": { + "description": "Cloud Storage prefix for import errors. This must be an empty, existing Cloud Storage directory. Import errors will be written to sharded files in this directory, one per line, as a JSON-encoded `google.rpc.Status` message.", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1ImportUserEventsMetadata": { + "description": "Metadata related to the progress of the Import operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1ImportUserEventsMetadata", + "properties": { + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", + "type": "string" + }, + "failureCount": { + "description": "Count of entries that encountered errors while processing.", + "format": "int64", + "type": "string" + }, + "successCount": { + "description": "Count of entries that were processed successfully.", + "format": "int64", + "type": "string" + }, + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1ImportUserEventsResponse": { + "description": "Response of the ImportUserEventsRequest. If the long running operation was successful, then this message is returned by the google.longrunning.Operations.response field if the operation was successful.", + "id": "GoogleCloudDiscoveryengineV1ImportUserEventsResponse", + "properties": { + "errorConfig": { + "$ref": "GoogleCloudDiscoveryengineV1ImportErrorConfig", + "description": "Echoes the destination for the complete errors if this field was set in the request." + }, + "errorSamples": { + "description": "A sample of errors encountered while processing the request.", + "items": { + "$ref": "GoogleRpcStatus" + }, + "type": "array" + }, + "joinedEventsCount": { + "description": "Count of user events imported with complete existing Documents.", + "format": "int64", + "type": "string" + }, + "unjoinedEventsCount": { + "description": "Count of user events imported, but with Document information not found in the existing Branch.", + "format": "int64", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata": { + "description": "Metadata related to the progress of the PurgeDocuments operation. This will be returned by the google.longrunning.Operation.metadata field.", + "id": "GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata", + "properties": { + "createTime": { + "description": "Operation create time.", + "format": "google-datetime", + "type": "string" + }, + "failureCount": { + "description": "Count of entries that encountered errors while processing.", + "format": "int64", + "type": "string" + }, + "successCount": { + "description": "Count of entries that were deleted successfully.", + "format": "int64", + "type": "string" + }, + "updateTime": { + "description": "Operation last update time. If the operation is done, this is also the finish time.", + "format": "google-datetime", + "type": "string" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1PurgeDocumentsResponse": { + "description": "Response message for DocumentService.PurgeDocuments method. If the long running operation is successfully done, then this message is returned by the google.longrunning.Operations.response field.", + "id": "GoogleCloudDiscoveryengineV1PurgeDocumentsResponse", + "properties": { + "purgeCount": { + "description": "The total count of documents purged as a result of the operation.", + "format": "int64", + "type": "string" + }, + "purgeSample": { + "description": "A sample of document names that will be deleted. Only populated if `force` is set to false. A max of 100 names will be returned and the names are chosen at random.", + "items": { + "type": "string" + }, + "type": "array" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1Schema": { + "description": "Defines the structure and layout of a type of document data.", + "id": "GoogleCloudDiscoveryengineV1Schema", + "properties": { + "jsonSchema": { + "description": "The JSON representation of the schema.", + "type": "string" + }, + "name": { + "description": "Immutable. The full resource name of the schema, in the format of `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/schemas/{schema}`. This field must be a UTF-8 encoded string with a length limit of 1024 characters.", + "type": "string" + }, + "structSchema": { + "additionalProperties": { + "description": "Properties of the object.", + "type": "any" + }, + "description": "The structured representation of the schema.", + "type": "object" + } + }, + "type": "object" + }, + "GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse": { + "description": "Response message for SiteSearchEngineService.BatchCreateTargetSites method.", + "id": "GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse", + "properties": { + "targetSites": { + "description": "TargetSites created.", + "items": { + "$ref": "GoogleCloudDiscoveryengineV1alphaTargetSite" + }, + "type": "array" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata": { "description": "Metadata related to the progress of the ImportDocuments operation. This will be returned by the google.longrunning.Operation.metadata field.", "id": "GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata", @@ -1939,6 +2133,51 @@ }, "type": "object" }, + "GoogleCloudDiscoveryengineV1alphaTargetSite": { + "description": "A target site for the SiteSearchEngine.", + "id": "GoogleCloudDiscoveryengineV1alphaTargetSite", + "properties": { + "exactMatch": { + "description": "Input only. If set to false, an uri_pattern will be generated to include all pages whose address contains the provided_uri_pattern. If set to true, an uri_pattern will be generated to try to be an exact match of the provided_uri_pattern or just the specific page if the provided_uri_pattern is a specific one. provided_uri_pattern will always be normalized to generate the uri pattern to be used by the search engine.", + "type": "boolean" + }, + "generatedUriPattern": { + "description": "Output only. This is system-generated based on the provided_uri_pattern.", + "readOnly": true, + "type": "string" + }, + "name": { + "description": "Output only. The fully qualified resource name of the target site. `projects/{project}/locations/{location}/collections/{collection}/dataStores/{data_store}/siteSearchEngine/targetSites/{target_site}` The `target_site_id` is system-generated.", + "readOnly": true, + "type": "string" + }, + "providedUriPattern": { + "description": "Required. Input only. The user provided uri pattern from which the `generated_uri_pattern` is generated.", + "type": "string" + }, + "type": { + "description": "The type of the target site, e.g. whether the site is to be included or excluded.", + "enum": [ + "TYPE_UNSPECIFIED", + "INCLUDE", + "EXCLUDE" + ], + "enumDescriptions": [ + "This value is unused. In this case, server behavior defaults to Type.INCLUDE.", + "Include the target site.", + "Exclude the target site." + ], + "type": "string" + }, + "updateTime": { + "description": "Output only. The target site's last updated time.", + "format": "google-datetime", + "readOnly": true, + "type": "string" + } + }, + "type": "object" + }, "GoogleCloudDiscoveryengineV1betaBigQuerySource": { "description": "BigQuery source import data from.", "id": "GoogleCloudDiscoveryengineV1betaBigQuerySource", @@ -2123,6 +2362,10 @@ "description": "Request message for Import methods.", "id": "GoogleCloudDiscoveryengineV1betaImportDocumentsRequest", "properties": { + "autoGenerateIds": { + "description": "Whether to automatically generate IDs for the documents if absent. If set to `true`, Document.ids are automatically generated based on the hash of the payload, where IDs may not be consistent during multiple imports. In which case ReconciliationMode.FULL is highly recommended to avoid duplicate contents. If unset or set to `false`, Document.ids have to be specified using id_field, otherwises, documents without IDs will fail to be imported. Only set this field when using GcsSource or BigQuerySource, and when GcsSource.data_schema or BigQuerySource.data_schema is `custom`. Otherwise, an INVALID_ARGUMENT error is thrown.", + "type": "boolean" + }, "bigquerySource": { "$ref": "GoogleCloudDiscoveryengineV1betaBigQuerySource", "description": "BigQuery input source." @@ -2135,6 +2378,10 @@ "$ref": "GoogleCloudDiscoveryengineV1betaGcsSource", "description": "Cloud Storage location for the input content." }, + "idField": { + "description": "The field in the Cloud Storage and BigQuery sources that indicates the unique IDs of the documents. For GcsSource it is the key of the JSON field. For instance, `my_id` for JSON `{\"my_id\": \"some_uuid\"}`. For BigQuerySource it is the column name of the BigQuery table where the unique ids are stored. The values of the JSON field or the BigQuery column will be used as the Document.ids. The JSON field or the BigQuery column must be of string type, and the values must be set as valid strings conform to [RFC-1034](https://tools.ietf.org/html/rfc1034) with 1-63 characters. Otherwise, documents without valid IDs will fail to be imported. Only set this field when using GcsSource or BigQuerySource, and when GcsSource.data_schema or BigQuerySource.data_schema is `custom`. And only set this field when auto_generate_ids is unset or set as `false`. Otherwise, an INVALID_ARGUMENT error is thrown. If it is unset, a default value `_id` is used when importing from the allowed data sources.", + "type": "string" + }, "inlineSource": { "$ref": "GoogleCloudDiscoveryengineV1betaImportDocumentsRequestInlineSource", "description": "The Inline source for the input content for documents." diff --git a/discoveryengine/v1beta/discoveryengine-gen.go b/discoveryengine/v1beta/discoveryengine-gen.go index 7e6df934a34..937228577cd 100644 --- a/discoveryengine/v1beta/discoveryengine-gen.go +++ b/discoveryengine/v1beta/discoveryengine-gen.go @@ -769,6 +769,349 @@ func (s *GoogleCloudDiscoveryengineLoggingSourceLocation) MarshalJSON() ([]byte, return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1ImportDocumentsMetadata: Metadata related +// to the progress of the ImportDocuments operation. This will be +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1ImportDocumentsMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` + + // FailureCount: Count of entries that encountered errors while + // processing. + FailureCount int64 `json:"failureCount,omitempty,string"` + + // SuccessCount: Count of entries that were processed successfully. + SuccessCount int64 `json:"successCount,omitempty,string"` + + // UpdateTime: Operation last update time. If the operation is done, + // this is also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + + // ForceSendFields is a list of field names (e.g. "CreateTime") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "CreateTime") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1ImportDocumentsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1ImportDocumentsMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1ImportDocumentsResponse: Response of the +// ImportDocumentsRequest. If the long running operation is done, then +// this message is returned by the +// google.longrunning.Operations.response field if the operation was +// successful. +type GoogleCloudDiscoveryengineV1ImportDocumentsResponse struct { + // ErrorConfig: Echoes the destination for the complete errors in the + // request if set. + ErrorConfig *GoogleCloudDiscoveryengineV1ImportErrorConfig `json:"errorConfig,omitempty"` + + // ErrorSamples: A sample of errors encountered while processing the + // request. + ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ErrorConfig") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "ErrorConfig") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1ImportDocumentsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1ImportDocumentsResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1ImportErrorConfig: Configuration of +// destination for Import related errors. +type GoogleCloudDiscoveryengineV1ImportErrorConfig struct { + // GcsPrefix: Cloud Storage prefix for import errors. This must be an + // empty, existing Cloud Storage directory. Import errors will be + // written to sharded files in this directory, one per line, as a + // JSON-encoded `google.rpc.Status` message. + GcsPrefix string `json:"gcsPrefix,omitempty"` + + // ForceSendFields is a list of field names (e.g. "GcsPrefix") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "GcsPrefix") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1ImportErrorConfig) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1ImportErrorConfig + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1ImportUserEventsMetadata: Metadata +// related to the progress of the Import operation. This will be +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1ImportUserEventsMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` + + // FailureCount: Count of entries that encountered errors while + // processing. + FailureCount int64 `json:"failureCount,omitempty,string"` + + // SuccessCount: Count of entries that were processed successfully. + SuccessCount int64 `json:"successCount,omitempty,string"` + + // UpdateTime: Operation last update time. If the operation is done, + // this is also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + + // ForceSendFields is a list of field names (e.g. "CreateTime") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "CreateTime") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1ImportUserEventsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1ImportUserEventsMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1ImportUserEventsResponse: Response of the +// ImportUserEventsRequest. If the long running operation was +// successful, then this message is returned by the +// google.longrunning.Operations.response field if the operation was +// successful. +type GoogleCloudDiscoveryengineV1ImportUserEventsResponse struct { + // ErrorConfig: Echoes the destination for the complete errors if this + // field was set in the request. + ErrorConfig *GoogleCloudDiscoveryengineV1ImportErrorConfig `json:"errorConfig,omitempty"` + + // ErrorSamples: A sample of errors encountered while processing the + // request. + ErrorSamples []*GoogleRpcStatus `json:"errorSamples,omitempty"` + + // JoinedEventsCount: Count of user events imported with complete + // existing Documents. + JoinedEventsCount int64 `json:"joinedEventsCount,omitempty,string"` + + // UnjoinedEventsCount: Count of user events imported, but with Document + // information not found in the existing Branch. + UnjoinedEventsCount int64 `json:"unjoinedEventsCount,omitempty,string"` + + // ForceSendFields is a list of field names (e.g. "ErrorConfig") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "ErrorConfig") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1ImportUserEventsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1ImportUserEventsResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata: Metadata related +// to the progress of the PurgeDocuments operation. This will be +// returned by the google.longrunning.Operation.metadata field. +type GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata struct { + // CreateTime: Operation create time. + CreateTime string `json:"createTime,omitempty"` + + // FailureCount: Count of entries that encountered errors while + // processing. + FailureCount int64 `json:"failureCount,omitempty,string"` + + // SuccessCount: Count of entries that were deleted successfully. + SuccessCount int64 `json:"successCount,omitempty,string"` + + // UpdateTime: Operation last update time. If the operation is done, + // this is also the finish time. + UpdateTime string `json:"updateTime,omitempty"` + + // ForceSendFields is a list of field names (e.g. "CreateTime") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "CreateTime") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1PurgeDocumentsMetadata + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1PurgeDocumentsResponse: Response message +// for DocumentService.PurgeDocuments method. If the long running +// operation is successfully done, then this message is returned by the +// google.longrunning.Operations.response field. +type GoogleCloudDiscoveryengineV1PurgeDocumentsResponse struct { + // PurgeCount: The total count of documents purged as a result of the + // operation. + PurgeCount int64 `json:"purgeCount,omitempty,string"` + + // PurgeSample: A sample of document names that will be deleted. Only + // populated if `force` is set to false. A max of 100 names will be + // returned and the names are chosen at random. + PurgeSample []string `json:"purgeSample,omitempty"` + + // ForceSendFields is a list of field names (e.g. "PurgeCount") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "PurgeCount") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1PurgeDocumentsResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1PurgeDocumentsResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1Schema: Defines the structure and layout +// of a type of document data. +type GoogleCloudDiscoveryengineV1Schema struct { + // JsonSchema: The JSON representation of the schema. + JsonSchema string `json:"jsonSchema,omitempty"` + + // Name: Immutable. The full resource name of the schema, in the format + // of + // `projects/{project}/locations/{location}/collections/{collection}/data + // Stores/{data_store}/schemas/{schema}`. This field must be a UTF-8 + // encoded string with a length limit of 1024 characters. + Name string `json:"name,omitempty"` + + // StructSchema: The structured representation of the schema. + StructSchema googleapi.RawMessage `json:"structSchema,omitempty"` + + // ForceSendFields is a list of field names (e.g. "JsonSchema") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "JsonSchema") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1Schema) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1Schema + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + +// GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse: +// Response message for SiteSearchEngineService.BatchCreateTargetSites +// method. +type GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse struct { + // TargetSites: TargetSites created. + TargetSites []*GoogleCloudDiscoveryengineV1alphaTargetSite `json:"targetSites,omitempty"` + + // ForceSendFields is a list of field names (e.g. "TargetSites") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "TargetSites") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaBatchCreateTargetSitesResponse + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1alphaImportDocumentsMetadata: Metadata // related to the progress of the ImportDocuments operation. This will // be returned by the google.longrunning.Operation.metadata field. @@ -1082,6 +1425,69 @@ func (s *GoogleCloudDiscoveryengineV1alphaSchema) MarshalJSON() ([]byte, error) return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +// GoogleCloudDiscoveryengineV1alphaTargetSite: A target site for the +// SiteSearchEngine. +type GoogleCloudDiscoveryengineV1alphaTargetSite struct { + // ExactMatch: Input only. If set to false, an uri_pattern will be + // generated to include all pages whose address contains the + // provided_uri_pattern. If set to true, an uri_pattern will be + // generated to try to be an exact match of the provided_uri_pattern or + // just the specific page if the provided_uri_pattern is a specific one. + // provided_uri_pattern will always be normalized to generate the uri + // pattern to be used by the search engine. + ExactMatch bool `json:"exactMatch,omitempty"` + + // GeneratedUriPattern: Output only. This is system-generated based on + // the provided_uri_pattern. + GeneratedUriPattern string `json:"generatedUriPattern,omitempty"` + + // Name: Output only. The fully qualified resource name of the target + // site. + // `projects/{project}/locations/{location}/collections/{collection}/data + // Stores/{data_store}/siteSearchEngine/targetSites/{target_site}` The + // `target_site_id` is system-generated. + Name string `json:"name,omitempty"` + + // ProvidedUriPattern: Required. Input only. The user provided uri + // pattern from which the `generated_uri_pattern` is generated. + ProvidedUriPattern string `json:"providedUriPattern,omitempty"` + + // Type: The type of the target site, e.g. whether the site is to be + // included or excluded. + // + // Possible values: + // "TYPE_UNSPECIFIED" - This value is unused. In this case, server + // behavior defaults to Type.INCLUDE. + // "INCLUDE" - Include the target site. + // "EXCLUDE" - Exclude the target site. + Type string `json:"type,omitempty"` + + // UpdateTime: Output only. The target site's last updated time. + UpdateTime string `json:"updateTime,omitempty"` + + // ForceSendFields is a list of field names (e.g. "ExactMatch") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "ExactMatch") to include in + // API requests with the JSON null value. By default, fields with empty + // values are omitted from API requests. However, any field with an + // empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *GoogleCloudDiscoveryengineV1alphaTargetSite) MarshalJSON() ([]byte, error) { + type NoMethod GoogleCloudDiscoveryengineV1alphaTargetSite + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // GoogleCloudDiscoveryengineV1betaBigQuerySource: BigQuery source // import data from. type GoogleCloudDiscoveryengineV1betaBigQuerySource struct { @@ -1436,6 +1842,19 @@ func (s *GoogleCloudDiscoveryengineV1betaImportDocumentsMetadata) MarshalJSON() // GoogleCloudDiscoveryengineV1betaImportDocumentsRequest: Request // message for Import methods. type GoogleCloudDiscoveryengineV1betaImportDocumentsRequest struct { + // AutoGenerateIds: Whether to automatically generate IDs for the + // documents if absent. If set to `true`, Document.ids are automatically + // generated based on the hash of the payload, where IDs may not be + // consistent during multiple imports. In which case + // ReconciliationMode.FULL is highly recommended to avoid duplicate + // contents. If unset or set to `false`, Document.ids have to be + // specified using id_field, otherwises, documents without IDs will fail + // to be imported. Only set this field when using GcsSource or + // BigQuerySource, and when GcsSource.data_schema or + // BigQuerySource.data_schema is `custom`. Otherwise, an + // INVALID_ARGUMENT error is thrown. + AutoGenerateIds bool `json:"autoGenerateIds,omitempty"` + // BigquerySource: BigQuery input source. BigquerySource *GoogleCloudDiscoveryengineV1betaBigQuerySource `json:"bigquerySource,omitempty"` @@ -1446,6 +1865,24 @@ type GoogleCloudDiscoveryengineV1betaImportDocumentsRequest struct { // GcsSource: Cloud Storage location for the input content. GcsSource *GoogleCloudDiscoveryengineV1betaGcsSource `json:"gcsSource,omitempty"` + // IdField: The field in the Cloud Storage and BigQuery sources that + // indicates the unique IDs of the documents. For GcsSource it is the + // key of the JSON field. For instance, `my_id` for JSON `{"my_id": + // "some_uuid"}`. For BigQuerySource it is the column name of the + // BigQuery table where the unique ids are stored. The values of the + // JSON field or the BigQuery column will be used as the Document.ids. + // The JSON field or the BigQuery column must be of string type, and the + // values must be set as valid strings conform to RFC-1034 + // (https://tools.ietf.org/html/rfc1034) with 1-63 characters. + // Otherwise, documents without valid IDs will fail to be imported. Only + // set this field when using GcsSource or BigQuerySource, and when + // GcsSource.data_schema or BigQuerySource.data_schema is `custom`. And + // only set this field when auto_generate_ids is unset or set as + // `false`. Otherwise, an INVALID_ARGUMENT error is thrown. If it is + // unset, a default value `_id` is used when importing from the allowed + // data sources. + IdField string `json:"idField,omitempty"` + // InlineSource: The Inline source for the input content for documents. InlineSource *GoogleCloudDiscoveryengineV1betaImportDocumentsRequestInlineSource `json:"inlineSource,omitempty"` @@ -1462,7 +1899,7 @@ type GoogleCloudDiscoveryengineV1betaImportDocumentsRequest struct { // source location. ReconciliationMode string `json:"reconciliationMode,omitempty"` - // ForceSendFields is a list of field names (e.g. "BigquerySource") to + // ForceSendFields is a list of field names (e.g. "AutoGenerateIds") to // unconditionally include in API requests. By default, fields with // empty or default values are omitted from API requests. However, any // non-pointer, non-interface field appearing in ForceSendFields will be @@ -1470,7 +1907,7 @@ type GoogleCloudDiscoveryengineV1betaImportDocumentsRequest struct { // This may be used to include empty fields in Patch requests. ForceSendFields []string `json:"-"` - // NullFields is a list of field names (e.g. "BigquerySource") to + // NullFields is a list of field names (e.g. "AutoGenerateIds") to // include in API requests with the JSON null value. By default, fields // with empty values are omitted from API requests. However, any field // with an empty value appearing in NullFields will be sent to the diff --git a/ondemandscanning/v1/ondemandscanning-api.json b/ondemandscanning/v1/ondemandscanning-api.json index 5a799153e68..b798b3f66ad 100644 --- a/ondemandscanning/v1/ondemandscanning-api.json +++ b/ondemandscanning/v1/ondemandscanning-api.json @@ -339,7 +339,7 @@ } } }, - "revision": "20230501", + "revision": "20230522", "rootUrl": "https://ondemandscanning.googleapis.com/", "schemas": { "AliasContext": { @@ -506,6 +506,20 @@ }, "type": "object" }, + "BinarySourceInfo": { + "id": "BinarySourceInfo", + "properties": { + "binaryVersion": { + "$ref": "PackageVersion", + "description": "The binary package. This is significant when the source is different than the binary itself. Historically if they've differed, we've stored the name of the source and its version in the package/version fields, but we should also store the binary package info, as that's what's actually installed. See b/175908657#comment15." + }, + "sourceVersion": { + "$ref": "PackageVersion", + "description": "The source package. Similar to the above, this is significant when the source is different than the binary itself. Since the top-level package/version fields are based on an if/else, we need a separate field for both binary and source if we want to know definitively where the data is coming from." + } + }, + "type": "object" + }, "BuildOccurrence": { "description": "Details of a build occurrence.", "id": "BuildOccurrence", @@ -1750,9 +1764,16 @@ "description": "The architecture of the package.", "type": "string" }, + "binarySourceInfo": { + "description": "A bundle containing the binary and source information.", + "items": { + "$ref": "BinarySourceInfo" + }, + "type": "array" + }, "binaryVersion": { "$ref": "PackageVersion", - "description": "The binary package. This is significant when the source is different than the binary itself. Historically if they've differed, we've stored the name of the source and its version in the package/version fields, but we should also store the binary package info, as that's what's actually installed. See b/175908657#comment15." + "description": "DEPRECATED" }, "cpeUri": { "description": "The cpe_uri in [cpe format] (https://cpe.mitre.org/specification/) in which the vulnerability may manifest. Examples include distro or storage location for vulnerable jar.", @@ -1823,7 +1844,7 @@ }, "sourceVersion": { "$ref": "PackageVersion", - "description": "The source package. Similar to the above, this is significant when the source is different than the binary itself. Since the top-level package/version fields are based on an if/else, we need a separate field for both binary and source if we want to know definitively where the data is coming from." + "description": "DEPRECATED" }, "unused": { "type": "string" diff --git a/ondemandscanning/v1/ondemandscanning-gen.go b/ondemandscanning/v1/ondemandscanning-gen.go index 142e8082971..d680f74ffee 100644 --- a/ondemandscanning/v1/ondemandscanning-gen.go +++ b/ondemandscanning/v1/ondemandscanning-gen.go @@ -517,6 +517,44 @@ func (s *AttestationOccurrence) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +type BinarySourceInfo struct { + // BinaryVersion: The binary package. This is significant when the + // source is different than the binary itself. Historically if they've + // differed, we've stored the name of the source and its version in the + // package/version fields, but we should also store the binary package + // info, as that's what's actually installed. See b/175908657#comment15. + BinaryVersion *PackageVersion `json:"binaryVersion,omitempty"` + + // SourceVersion: The source package. Similar to the above, this is + // significant when the source is different than the binary itself. + // Since the top-level package/version fields are based on an if/else, + // we need a separate field for both binary and source if we want to + // know definitively where the data is coming from. + SourceVersion *PackageVersion `json:"sourceVersion,omitempty"` + + // ForceSendFields is a list of field names (e.g. "BinaryVersion") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "BinaryVersion") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *BinarySourceInfo) MarshalJSON() ([]byte, error) { + type NoMethod BinarySourceInfo + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // BuildOccurrence: Details of a build occurrence. type BuildOccurrence struct { // IntotoProvenance: Deprecated. See InTotoStatement for the @@ -2404,11 +2442,11 @@ type PackageData struct { // Architecture: The architecture of the package. Architecture string `json:"architecture,omitempty"` - // BinaryVersion: The binary package. This is significant when the - // source is different than the binary itself. Historically if they've - // differed, we've stored the name of the source and its version in the - // package/version fields, but we should also store the binary package - // info, as that's what's actually installed. See b/175908657#comment15. + // BinarySourceInfo: A bundle containing the binary and source + // information. + BinarySourceInfo []*BinarySourceInfo `json:"binarySourceInfo,omitempty"` + + // BinaryVersion: DEPRECATED BinaryVersion *PackageVersion `json:"binaryVersion,omitempty"` // CpeUri: The cpe_uri in [cpe format] @@ -2461,11 +2499,7 @@ type PackageData struct { // go/drydock-dd-custom-binary-scanning PatchedCve []string `json:"patchedCve,omitempty"` - // SourceVersion: The source package. Similar to the above, this is - // significant when the source is different than the binary itself. - // Since the top-level package/version fields are based on an if/else, - // we need a separate field for both binary and source if we want to - // know definitively where the data is coming from. + // SourceVersion: DEPRECATED SourceVersion *PackageVersion `json:"sourceVersion,omitempty"` Unused string `json:"unused,omitempty"` diff --git a/ondemandscanning/v1beta1/ondemandscanning-api.json b/ondemandscanning/v1beta1/ondemandscanning-api.json index 90c41e85fc1..f28d7e79a87 100644 --- a/ondemandscanning/v1beta1/ondemandscanning-api.json +++ b/ondemandscanning/v1beta1/ondemandscanning-api.json @@ -339,7 +339,7 @@ } } }, - "revision": "20230501", + "revision": "20230522", "rootUrl": "https://ondemandscanning.googleapis.com/", "schemas": { "AliasContext": { @@ -502,6 +502,20 @@ }, "type": "object" }, + "BinarySourceInfo": { + "id": "BinarySourceInfo", + "properties": { + "binaryVersion": { + "$ref": "PackageVersion", + "description": "The binary package. This is significant when the source is different than the binary itself. Historically if they've differed, we've stored the name of the source and its version in the package/version fields, but we should also store the binary package info, as that's what's actually installed. See b/175908657#comment15." + }, + "sourceVersion": { + "$ref": "PackageVersion", + "description": "The source package. Similar to the above, this is significant when the source is different than the binary itself. Since the top-level package/version fields are based on an if/else, we need a separate field for both binary and source if we want to know definitively where the data is coming from." + } + }, + "type": "object" + }, "BuildOccurrence": { "description": "Details of a build occurrence.", "id": "BuildOccurrence", @@ -1746,9 +1760,16 @@ "description": "The architecture of the package.", "type": "string" }, + "binarySourceInfo": { + "description": "A bundle containing the binary and source information.", + "items": { + "$ref": "BinarySourceInfo" + }, + "type": "array" + }, "binaryVersion": { "$ref": "PackageVersion", - "description": "The binary package. This is significant when the source is different than the binary itself. Historically if they've differed, we've stored the name of the source and its version in the package/version fields, but we should also store the binary package info, as that's what's actually installed. See b/175908657#comment15." + "description": "DEPRECATED" }, "cpeUri": { "description": "The cpe_uri in [cpe format] (https://cpe.mitre.org/specification/) in which the vulnerability may manifest. Examples include distro or storage location for vulnerable jar.", @@ -1819,7 +1840,7 @@ }, "sourceVersion": { "$ref": "PackageVersion", - "description": "The source package. Similar to the above, this is significant when the source is different than the binary itself. Since the top-level package/version fields are based on an if/else, we need a separate field for both binary and source if we want to know definitively where the data is coming from." + "description": "DEPRECATED" }, "unused": { "type": "string" diff --git a/ondemandscanning/v1beta1/ondemandscanning-gen.go b/ondemandscanning/v1beta1/ondemandscanning-gen.go index 588f8ed24b0..6189a09e2a2 100644 --- a/ondemandscanning/v1beta1/ondemandscanning-gen.go +++ b/ondemandscanning/v1beta1/ondemandscanning-gen.go @@ -511,6 +511,44 @@ func (s *AttestationOccurrence) MarshalJSON() ([]byte, error) { return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) } +type BinarySourceInfo struct { + // BinaryVersion: The binary package. This is significant when the + // source is different than the binary itself. Historically if they've + // differed, we've stored the name of the source and its version in the + // package/version fields, but we should also store the binary package + // info, as that's what's actually installed. See b/175908657#comment15. + BinaryVersion *PackageVersion `json:"binaryVersion,omitempty"` + + // SourceVersion: The source package. Similar to the above, this is + // significant when the source is different than the binary itself. + // Since the top-level package/version fields are based on an if/else, + // we need a separate field for both binary and source if we want to + // know definitively where the data is coming from. + SourceVersion *PackageVersion `json:"sourceVersion,omitempty"` + + // ForceSendFields is a list of field names (e.g. "BinaryVersion") to + // unconditionally include in API requests. By default, fields with + // empty or default values are omitted from API requests. However, any + // non-pointer, non-interface field appearing in ForceSendFields will be + // sent to the server regardless of whether the field is empty or not. + // This may be used to include empty fields in Patch requests. + ForceSendFields []string `json:"-"` + + // NullFields is a list of field names (e.g. "BinaryVersion") to include + // in API requests with the JSON null value. By default, fields with + // empty values are omitted from API requests. However, any field with + // an empty value appearing in NullFields will be sent to the server as + // null. It is an error if a field in this list has a non-empty value. + // This may be used to include null fields in Patch requests. + NullFields []string `json:"-"` +} + +func (s *BinarySourceInfo) MarshalJSON() ([]byte, error) { + type NoMethod BinarySourceInfo + raw := NoMethod(*s) + return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields) +} + // BuildOccurrence: Details of a build occurrence. type BuildOccurrence struct { // IntotoProvenance: Deprecated. See InTotoStatement for the @@ -2398,11 +2436,11 @@ type PackageData struct { // Architecture: The architecture of the package. Architecture string `json:"architecture,omitempty"` - // BinaryVersion: The binary package. This is significant when the - // source is different than the binary itself. Historically if they've - // differed, we've stored the name of the source and its version in the - // package/version fields, but we should also store the binary package - // info, as that's what's actually installed. See b/175908657#comment15. + // BinarySourceInfo: A bundle containing the binary and source + // information. + BinarySourceInfo []*BinarySourceInfo `json:"binarySourceInfo,omitempty"` + + // BinaryVersion: DEPRECATED BinaryVersion *PackageVersion `json:"binaryVersion,omitempty"` // CpeUri: The cpe_uri in [cpe format] @@ -2455,11 +2493,7 @@ type PackageData struct { // go/drydock-dd-custom-binary-scanning PatchedCve []string `json:"patchedCve,omitempty"` - // SourceVersion: The source package. Similar to the above, this is - // significant when the source is different than the binary itself. - // Since the top-level package/version fields are based on an if/else, - // we need a separate field for both binary and source if we want to - // know definitively where the data is coming from. + // SourceVersion: DEPRECATED SourceVersion *PackageVersion `json:"sourceVersion,omitempty"` Unused string `json:"unused,omitempty"`