feat: added support for ListAssets API Beta.
Added support for google.cloud.asset.v1p5beta1.AssetService.ListAssets. PiperOrigin-RevId: 315725603
This commit is contained in:
parent
3e7056405a
commit
49e84e1dfc
|
|
@ -0,0 +1,375 @@
|
|||
# This file was automatically generated by BuildFileGenerator
|
||||
|
||||
# This is an API workspace, having public visibility by default makes perfect sense.
|
||||
package(default_visibility = ["//visibility:public"])
|
||||
|
||||
##############################################################################
|
||||
# Common
|
||||
##############################################################################
|
||||
load("@rules_proto//proto:defs.bzl", "proto_library")
|
||||
load("@com_google_googleapis_imports//:imports.bzl", "proto_library_with_info")
|
||||
|
||||
proto_library(
|
||||
name = "asset_proto",
|
||||
srcs = [
|
||||
"asset_service.proto",
|
||||
"assets.proto",
|
||||
],
|
||||
deps = [
|
||||
"//google/api:annotations_proto",
|
||||
"//google/api:client_proto",
|
||||
"//google/api:field_behavior_proto",
|
||||
"//google/api:resource_proto",
|
||||
"//google/cloud/orgpolicy/v1:orgpolicy_proto",
|
||||
"//google/iam/v1:policy_proto",
|
||||
"//google/identity/accesscontextmanager/v1:accesscontextmanager_proto",
|
||||
"@com_google_protobuf//:any_proto",
|
||||
"@com_google_protobuf//:struct_proto",
|
||||
"@com_google_protobuf//:timestamp_proto",
|
||||
],
|
||||
)
|
||||
|
||||
proto_library_with_info(
|
||||
name = "asset_proto_with_info",
|
||||
deps = [
|
||||
":asset_proto",
|
||||
"//google/cloud:common_resources_proto",
|
||||
],
|
||||
)
|
||||
|
||||
##############################################################################
|
||||
# Java
|
||||
##############################################################################
|
||||
load(
|
||||
"@com_google_googleapis_imports//:imports.bzl",
|
||||
"java_gapic_assembly_gradle_pkg",
|
||||
"java_gapic_library",
|
||||
"java_gapic_test",
|
||||
"java_grpc_library",
|
||||
"java_proto_library",
|
||||
)
|
||||
|
||||
java_proto_library(
|
||||
name = "asset_java_proto",
|
||||
deps = [":asset_proto"],
|
||||
)
|
||||
|
||||
java_grpc_library(
|
||||
name = "asset_java_grpc",
|
||||
srcs = [":asset_proto"],
|
||||
deps = [":asset_java_proto"],
|
||||
)
|
||||
|
||||
java_gapic_library(
|
||||
name = "asset_java_gapic",
|
||||
src = ":asset_proto_with_info",
|
||||
gapic_yaml = "cloudasset_gapic.yaml",
|
||||
package = "google.cloud.asset.v1p5beta1",
|
||||
service_yaml = "cloudasset_v1p5beta1.yaml",
|
||||
test_deps = [
|
||||
":asset_java_grpc",
|
||||
"//google/iam/v1:iam_java_grpc",
|
||||
],
|
||||
deps = [
|
||||
":asset_java_proto",
|
||||
"//google/iam/v1:iam_java_proto",
|
||||
],
|
||||
)
|
||||
|
||||
java_gapic_test(
|
||||
name = "asset_java_gapic_test_suite",
|
||||
test_classes = [
|
||||
"com.google.cloud.asset.v1p5beta1.AssetServiceClientTest",
|
||||
],
|
||||
runtime_deps = [":asset_java_gapic_test"],
|
||||
)
|
||||
|
||||
# Open Source Packages
|
||||
java_gapic_assembly_gradle_pkg(
|
||||
name = "google-cloud-asset-v1p5beta1-java",
|
||||
deps = [
|
||||
":asset_java_gapic",
|
||||
":asset_java_grpc",
|
||||
":asset_java_proto",
|
||||
":asset_proto",
|
||||
],
|
||||
)
|
||||
|
||||
##############################################################################
|
||||
# Go
|
||||
##############################################################################
|
||||
load(
|
||||
"@com_google_googleapis_imports//:imports.bzl",
|
||||
"go_gapic_assembly_pkg",
|
||||
"go_gapic_library",
|
||||
"go_proto_library",
|
||||
"go_test",
|
||||
)
|
||||
|
||||
go_proto_library(
|
||||
name = "asset_go_proto",
|
||||
compilers = ["@io_bazel_rules_go//proto:go_grpc"],
|
||||
importpath = "google.golang.org/genproto/googleapis/cloud/asset/v1p5beta1",
|
||||
protos = [":asset_proto"],
|
||||
deps = [
|
||||
"//google/api:annotations_go_proto",
|
||||
"//google/cloud/orgpolicy/v1:orgpolicy_go_proto",
|
||||
"//google/iam/v1:iam_go_proto",
|
||||
"//google/identity/accesscontextmanager/v1:accesscontextmanager_go_proto",
|
||||
],
|
||||
)
|
||||
|
||||
go_gapic_library(
|
||||
name = "asset_go_gapic",
|
||||
srcs = [":asset_proto_with_info"],
|
||||
grpc_service_config = "cloudasset_grpc_service_config.json",
|
||||
importpath = "cloud.google.com/go/asset/apiv1p5beta1;asset",
|
||||
service_yaml = "cloudasset_v1p5beta1.yaml",
|
||||
deps = [
|
||||
":asset_go_proto",
|
||||
"//google/iam/v1:iam_go_proto",
|
||||
],
|
||||
)
|
||||
|
||||
go_test(
|
||||
name = "asset_go_gapic_test",
|
||||
srcs = [":asset_go_gapic_srcjar_test"],
|
||||
embed = [":asset_go_gapic"],
|
||||
importpath = "cloud.google.com/go/asset/apiv1p5beta1",
|
||||
)
|
||||
|
||||
# Open Source Packages
|
||||
go_gapic_assembly_pkg(
|
||||
name = "gapi-cloud-asset-v1p5beta1-go",
|
||||
deps = [
|
||||
":asset_go_gapic",
|
||||
":asset_go_gapic_srcjar-test.srcjar",
|
||||
":asset_go_proto",
|
||||
],
|
||||
)
|
||||
|
||||
##############################################################################
|
||||
# Python
|
||||
##############################################################################
|
||||
load(
|
||||
"@com_google_googleapis_imports//:imports.bzl",
|
||||
"moved_proto_library",
|
||||
"py_gapic_assembly_pkg",
|
||||
"py_gapic_library",
|
||||
"py_grpc_library",
|
||||
"py_proto_library",
|
||||
)
|
||||
|
||||
moved_proto_library(
|
||||
name = "asset_moved_proto",
|
||||
srcs = [":asset_proto"],
|
||||
deps = [
|
||||
"//google/api:annotations_proto",
|
||||
"//google/api:client_proto",
|
||||
"//google/api:field_behavior_proto",
|
||||
"//google/api:resource_proto",
|
||||
"//google/cloud/orgpolicy/v1:orgpolicy_proto",
|
||||
"//google/iam/v1:policy_proto",
|
||||
"//google/identity/accesscontextmanager/v1:accesscontextmanager_proto",
|
||||
"@com_google_protobuf//:any_proto",
|
||||
"@com_google_protobuf//:struct_proto",
|
||||
"@com_google_protobuf//:timestamp_proto",
|
||||
],
|
||||
)
|
||||
|
||||
py_proto_library(
|
||||
name = "asset_py_proto",
|
||||
plugin = "@protoc_docs_plugin//:docs_plugin",
|
||||
deps = [":asset_moved_proto"],
|
||||
)
|
||||
|
||||
py_grpc_library(
|
||||
name = "asset_py_grpc",
|
||||
srcs = [":asset_moved_proto"],
|
||||
deps = [":asset_py_proto"],
|
||||
)
|
||||
|
||||
py_gapic_library(
|
||||
name = "asset_py_gapic",
|
||||
src = ":asset_proto_with_info",
|
||||
gapic_yaml = "cloudasset_gapic.yaml",
|
||||
package = "google.cloud.asset.v1p5beta1",
|
||||
service_yaml = "cloudasset_v1p5beta1.yaml",
|
||||
deps = [
|
||||
":asset_py_grpc",
|
||||
":asset_py_proto",
|
||||
],
|
||||
)
|
||||
|
||||
# Open Source Packages
|
||||
py_gapic_assembly_pkg(
|
||||
name = "asset-v1p5beta1-py",
|
||||
deps = [
|
||||
":asset_py_gapic",
|
||||
":asset_py_grpc",
|
||||
":asset_py_proto",
|
||||
],
|
||||
)
|
||||
|
||||
##############################################################################
|
||||
# PHP
|
||||
##############################################################################
|
||||
load(
|
||||
"@com_google_googleapis_imports//:imports.bzl",
|
||||
"php_gapic_assembly_pkg",
|
||||
"php_gapic_library",
|
||||
"php_grpc_library",
|
||||
"php_proto_library",
|
||||
)
|
||||
|
||||
php_proto_library(
|
||||
name = "asset_php_proto",
|
||||
deps = [":asset_proto"],
|
||||
)
|
||||
|
||||
php_grpc_library(
|
||||
name = "asset_php_grpc",
|
||||
srcs = [":asset_proto"],
|
||||
deps = [":asset_php_proto"],
|
||||
)
|
||||
|
||||
php_gapic_library(
|
||||
name = "asset_php_gapic",
|
||||
src = ":asset_proto_with_info",
|
||||
gapic_yaml = "cloudasset_gapic.yaml",
|
||||
package = "google.cloud.asset.v1p5beta1",
|
||||
service_yaml = "cloudasset_v1p5beta1.yaml",
|
||||
deps = [
|
||||
":asset_php_grpc",
|
||||
":asset_php_proto",
|
||||
],
|
||||
)
|
||||
|
||||
# Open Source Packages
|
||||
php_gapic_assembly_pkg(
|
||||
name = "google-cloud-asset-v1p5beta1-php",
|
||||
deps = [
|
||||
":asset_php_gapic",
|
||||
":asset_php_grpc",
|
||||
":asset_php_proto",
|
||||
],
|
||||
)
|
||||
|
||||
##############################################################################
|
||||
# Node.js
|
||||
##############################################################################
|
||||
load(
|
||||
"@com_google_googleapis_imports//:imports.bzl",
|
||||
"nodejs_gapic_assembly_pkg",
|
||||
"nodejs_gapic_library",
|
||||
)
|
||||
|
||||
nodejs_gapic_library(
|
||||
name = "asset_nodejs_gapic",
|
||||
src = ":asset_proto_with_info",
|
||||
gapic_yaml = "cloudasset_gapic.yaml",
|
||||
package = "google.cloud.asset.v1p5beta1",
|
||||
service_yaml = "cloudasset_v1p5beta1.yaml",
|
||||
deps = [],
|
||||
)
|
||||
|
||||
nodejs_gapic_assembly_pkg(
|
||||
name = "asset-v1p5beta1-nodejs",
|
||||
deps = [
|
||||
":asset_nodejs_gapic",
|
||||
":asset_proto",
|
||||
],
|
||||
)
|
||||
|
||||
##############################################################################
|
||||
# Ruby
|
||||
##############################################################################
|
||||
load(
|
||||
"@com_google_googleapis_imports//:imports.bzl",
|
||||
"ruby_gapic_assembly_pkg",
|
||||
"ruby_gapic_library",
|
||||
"ruby_grpc_library",
|
||||
"ruby_proto_library",
|
||||
)
|
||||
|
||||
ruby_proto_library(
|
||||
name = "asset_ruby_proto",
|
||||
deps = [":asset_proto"],
|
||||
)
|
||||
|
||||
ruby_grpc_library(
|
||||
name = "asset_ruby_grpc",
|
||||
srcs = [":asset_proto"],
|
||||
deps = [":asset_ruby_proto"],
|
||||
)
|
||||
|
||||
ruby_gapic_library(
|
||||
name = "asset_ruby_gapic",
|
||||
src = ":asset_proto_with_info",
|
||||
gapic_yaml = "cloudasset_gapic.yaml",
|
||||
package = "google.cloud.asset.v1p5beta1",
|
||||
service_yaml = "cloudasset_v1p5beta1.yaml",
|
||||
deps = [
|
||||
":asset_ruby_grpc",
|
||||
":asset_ruby_proto",
|
||||
],
|
||||
)
|
||||
|
||||
# Open Source Packages
|
||||
ruby_gapic_assembly_pkg(
|
||||
name = "google-cloud-asset-v1p5beta1-ruby",
|
||||
deps = [
|
||||
":asset_ruby_gapic",
|
||||
":asset_ruby_grpc",
|
||||
":asset_ruby_proto",
|
||||
],
|
||||
)
|
||||
|
||||
##############################################################################
|
||||
# C#
|
||||
##############################################################################
|
||||
load(
|
||||
"@com_google_googleapis_imports//:imports.bzl",
|
||||
"csharp_gapic_assembly_pkg",
|
||||
"csharp_gapic_library",
|
||||
"csharp_grpc_library",
|
||||
"csharp_proto_library",
|
||||
)
|
||||
|
||||
csharp_proto_library(
|
||||
name = "asset_csharp_proto",
|
||||
deps = [":asset_proto"],
|
||||
)
|
||||
|
||||
csharp_grpc_library(
|
||||
name = "asset_csharp_grpc",
|
||||
srcs = [":asset_proto"],
|
||||
deps = [":asset_csharp_proto"],
|
||||
)
|
||||
|
||||
csharp_gapic_library(
|
||||
name = "asset_csharp_gapic",
|
||||
src = ":asset_proto_with_info",
|
||||
gapic_yaml = "cloudasset_gapic.yaml",
|
||||
package = "google.cloud.asset.v1p5beta1",
|
||||
service_yaml = "cloudasset_v1p5beta1.yaml",
|
||||
deps = [
|
||||
":asset_csharp_grpc",
|
||||
":asset_csharp_proto",
|
||||
],
|
||||
)
|
||||
|
||||
# Open Source Packages
|
||||
csharp_gapic_assembly_pkg(
|
||||
name = "google-cloud-asset-v1p5beta1-csharp",
|
||||
deps = [
|
||||
":asset_csharp_gapic",
|
||||
":asset_csharp_grpc",
|
||||
":asset_csharp_proto",
|
||||
],
|
||||
)
|
||||
|
||||
##############################################################################
|
||||
# C++
|
||||
##############################################################################
|
||||
# Put your C++ rules here
|
||||
|
|
@ -0,0 +1,112 @@
|
|||
// Copyright 2020 Google LLC
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
syntax = "proto3";
|
||||
|
||||
package google.cloud.asset.v1p5beta1;
|
||||
|
||||
import "google/api/annotations.proto";
|
||||
import "google/api/client.proto";
|
||||
import "google/api/field_behavior.proto";
|
||||
import "google/cloud/asset/v1p5beta1/assets.proto";
|
||||
import "google/protobuf/timestamp.proto";
|
||||
|
||||
option csharp_namespace = "Google.Cloud.Asset.V1P5Beta1";
|
||||
option go_package = "google.golang.org/genproto/googleapis/cloud/asset/v1p5beta1;asset";
|
||||
option java_multiple_files = true;
|
||||
option java_outer_classname = "AssetServiceProto";
|
||||
option java_package = "com.google.cloud.asset.v1p5beta1";
|
||||
option php_namespace = "Google\\Cloud\\Asset\\V1p5beta1";
|
||||
|
||||
// Asset service definition.
|
||||
service AssetService {
|
||||
option (google.api.default_host) = "cloudasset.googleapis.com";
|
||||
option (google.api.oauth_scopes) =
|
||||
"https://www.googleapis.com/auth/cloud-platform";
|
||||
|
||||
// Lists assets with time and resource types and returns paged results in
|
||||
// response.
|
||||
rpc ListAssets(ListAssetsRequest) returns (ListAssetsResponse) {
|
||||
option (google.api.http) = {
|
||||
get: "/v1p5beta1/{parent=*/*}/assets"
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
// ListAssets request.
|
||||
message ListAssetsRequest {
|
||||
// Required. Name of the organization or project the assets belong to. Format:
|
||||
// "organizations/[organization-number]" (such as "organizations/123"),
|
||||
// "projects/[project-number]" (such as "projects/my-project-id"), or
|
||||
// "projects/[project-id]" (such as "projects/12345").
|
||||
string parent = 1 [(google.api.field_behavior) = REQUIRED];
|
||||
|
||||
// Timestamp to take an asset snapshot. This can only be set to a timestamp
|
||||
// between 2018-10-02 UTC (inclusive) and the current time. If not specified,
|
||||
// the current time will be used. Due to delays in resource data collection
|
||||
// and indexing, there is a volatile window during which running the same
|
||||
// query may get different results.
|
||||
google.protobuf.Timestamp read_time = 2;
|
||||
|
||||
// A list of asset types of which to take a snapshot for. For example:
|
||||
// "compute.googleapis.com/Disk". If specified, only matching assets will be
|
||||
// returned. See [Introduction to Cloud Asset
|
||||
// Inventory](https://cloud.google.com/resource-manager/docs/cloud-asset-inventory/overview)
|
||||
// for all supported asset types.
|
||||
repeated string asset_types = 3;
|
||||
|
||||
// Asset content type. If not specified, no content but the asset name will
|
||||
// be returned.
|
||||
ContentType content_type = 4;
|
||||
|
||||
// The maximum number of assets to be returned in a single response. Default
|
||||
// is 100, minimum is 1, and maximum is 1000.
|
||||
int32 page_size = 5;
|
||||
|
||||
// The `next_page_token` returned from the previous `ListAssetsResponse`, or
|
||||
// unspecified for the first `ListAssetsRequest`. It is a continuation of a
|
||||
// prior `ListAssets` call, and the API should return the next page of assets.
|
||||
string page_token = 6;
|
||||
}
|
||||
|
||||
// Asset content type.
|
||||
enum ContentType {
|
||||
// Unspecified content type.
|
||||
CONTENT_TYPE_UNSPECIFIED = 0;
|
||||
|
||||
// Resource metadata.
|
||||
RESOURCE = 1;
|
||||
|
||||
// The actual IAM policy set on a resource.
|
||||
IAM_POLICY = 2;
|
||||
|
||||
// The Cloud Organization Policy set on an asset.
|
||||
ORG_POLICY = 4;
|
||||
|
||||
// The Cloud Access context mananger Policy set on an asset.
|
||||
ACCESS_POLICY = 5;
|
||||
}
|
||||
|
||||
// ListAssets response.
|
||||
message ListAssetsResponse {
|
||||
// Time the snapshot was taken.
|
||||
google.protobuf.Timestamp read_time = 1;
|
||||
|
||||
// Assets.
|
||||
repeated Asset assets = 2;
|
||||
|
||||
// Token to retrieve the next page of results. Set to empty if there are no
|
||||
// remaining results.
|
||||
string next_page_token = 3;
|
||||
}
|
||||
|
|
@ -0,0 +1,127 @@
|
|||
// Copyright 2020 Google LLC
|
||||
//
|
||||
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||
// you may not use this file except in compliance with the License.
|
||||
// You may obtain a copy of the License at
|
||||
//
|
||||
// http://www.apache.org/licenses/LICENSE-2.0
|
||||
//
|
||||
// Unless required by applicable law or agreed to in writing, software
|
||||
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
// See the License for the specific language governing permissions and
|
||||
// limitations under the License.
|
||||
|
||||
syntax = "proto3";
|
||||
|
||||
package google.cloud.asset.v1p5beta1;
|
||||
|
||||
import "google/api/annotations.proto";
|
||||
import "google/api/resource.proto";
|
||||
import "google/cloud/orgpolicy/v1/orgpolicy.proto";
|
||||
import "google/iam/v1/policy.proto";
|
||||
import "google/identity/accesscontextmanager/v1/access_level.proto";
|
||||
import "google/identity/accesscontextmanager/v1/access_policy.proto";
|
||||
import "google/identity/accesscontextmanager/v1/service_perimeter.proto";
|
||||
import "google/protobuf/any.proto";
|
||||
import "google/protobuf/struct.proto";
|
||||
import "google/protobuf/timestamp.proto";
|
||||
|
||||
option cc_enable_arenas = true;
|
||||
option csharp_namespace = "Google.Cloud.Asset.V1p5Beta1";
|
||||
option go_package = "google.golang.org/genproto/googleapis/cloud/asset/v1p5beta1;asset";
|
||||
option java_multiple_files = true;
|
||||
option java_outer_classname = "AssetProto";
|
||||
option java_package = "com.google.cloud.asset.v1p5beta1";
|
||||
option php_namespace = "Google\\Cloud\\Asset\\V1p5beta1";
|
||||
|
||||
// Cloud asset. This includes all Google Cloud Platform resources,
|
||||
// Cloud IAM policies, and other non-GCP assets.
|
||||
message Asset {
|
||||
option (google.api.resource) = {
|
||||
type: "cloudasset.googleapis.com/Asset"
|
||||
pattern: "*"
|
||||
};
|
||||
|
||||
// The full name of the asset. For example:
|
||||
// `//compute.googleapis.com/projects/my_project_123/zones/zone1/instances/instance1`.
|
||||
// See [Resource
|
||||
// Names](https://cloud.google.com/apis/design/resource_names#full_resource_name)
|
||||
// for more information.
|
||||
string name = 1;
|
||||
|
||||
// Type of the asset. Example: "compute.googleapis.com/Disk".
|
||||
string asset_type = 2;
|
||||
|
||||
// Representation of the resource.
|
||||
Resource resource = 3;
|
||||
|
||||
// Representation of the actual Cloud IAM policy set on a cloud resource. For
|
||||
// each resource, there must be at most one Cloud IAM policy set on it.
|
||||
google.iam.v1.Policy iam_policy = 4;
|
||||
|
||||
// Representation of the Cloud Organization Policy set on an asset. For each
|
||||
// asset, there could be multiple Organization policies with different
|
||||
// constraints.
|
||||
repeated google.cloud.orgpolicy.v1.Policy org_policy = 6;
|
||||
|
||||
// Representation of the Cloud Organization access policy.
|
||||
oneof access_context_policy {
|
||||
google.identity.accesscontextmanager.v1.AccessPolicy access_policy = 7;
|
||||
|
||||
google.identity.accesscontextmanager.v1.AccessLevel access_level = 8;
|
||||
|
||||
google.identity.accesscontextmanager.v1.ServicePerimeter service_perimeter =
|
||||
9;
|
||||
}
|
||||
|
||||
// Asset's ancestry path in Cloud Resource Manager (CRM) hierarchy,
|
||||
// represented as a list of relative resource names. Ancestry path starts with
|
||||
// the closest CRM ancestor and ends at root. If the asset is a CRM
|
||||
// project/folder/organization, this starts from the asset itself.
|
||||
//
|
||||
// Example: ["projects/123456789", "folders/5432", "organizations/1234"]
|
||||
repeated string ancestors = 10;
|
||||
}
|
||||
|
||||
// Representation of a cloud resource.
|
||||
message Resource {
|
||||
// The API version. Example: "v1".
|
||||
string version = 1;
|
||||
|
||||
// The URL of the discovery document containing the resource's JSON schema.
|
||||
// For example:
|
||||
// `"https://www.googleapis.com/discovery/v1/apis/compute/v1/rest"`.
|
||||
// It will be left unspecified for resources without a discovery-based API,
|
||||
// such as Cloud Bigtable.
|
||||
string discovery_document_uri = 2;
|
||||
|
||||
// The JSON schema name listed in the discovery document.
|
||||
// Example: "Project". It will be left unspecified for resources (such as
|
||||
// Cloud Bigtable) without a discovery-based API.
|
||||
string discovery_name = 3;
|
||||
|
||||
// The REST URL for accessing the resource. An HTTP GET operation using this
|
||||
// URL returns the resource itself.
|
||||
// Example:
|
||||
// `https://cloudresourcemanager.googleapis.com/v1/projects/my-project-123`.
|
||||
// It will be left unspecified for resources without a REST API.
|
||||
string resource_url = 4;
|
||||
|
||||
// The full name of the immediate parent of this resource. See
|
||||
// [Resource
|
||||
// Names](https://cloud.google.com/apis/design/resource_names#full_resource_name)
|
||||
// for more information.
|
||||
//
|
||||
// For GCP assets, it is the parent resource defined in the [Cloud IAM policy
|
||||
// hierarchy](https://cloud.google.com/iam/docs/overview#policy_hierarchy).
|
||||
// For example:
|
||||
// `"//cloudresourcemanager.googleapis.com/projects/my_project_123"`.
|
||||
//
|
||||
// For third-party assets, it is up to the users to define.
|
||||
string parent = 5;
|
||||
|
||||
// The content of the resource, in which some sensitive fields are scrubbed
|
||||
// away and may not be present.
|
||||
google.protobuf.Struct data = 6;
|
||||
}
|
||||
|
|
@ -0,0 +1,21 @@
|
|||
type: com.google.api.codegen.ConfigProto
|
||||
config_schema_version: 2.0.0
|
||||
# The settings of generated code in a specific language.
|
||||
language_settings:
|
||||
java:
|
||||
package_name: com.google.cloud.asset.v1p5beta1
|
||||
python:
|
||||
package_name: google.cloud.asset_v1p5beta1.gapic
|
||||
go:
|
||||
package_name: cloud.google.com/go/asset/apiv1p5beta1
|
||||
csharp:
|
||||
package_name: Google.Cloud.Asset.V1p5beta1
|
||||
ruby:
|
||||
package_name: Google::Cloud::Asset::V1p5beta1
|
||||
php:
|
||||
package_name: Google\Cloud\Asset\V1p5beta1
|
||||
nodejs:
|
||||
package_name: asset.v1p5beta1
|
||||
domain_layer_location: google-cloud
|
||||
interfaces:
|
||||
- name: google.cloud.asset.v1p5beta1.AssetService
|
||||
|
|
@ -0,0 +1,22 @@
|
|||
{
|
||||
"methodConfig": [
|
||||
{
|
||||
"name": [
|
||||
{
|
||||
"service": "google.cloud.asset.v1p5beta1.AssetService",
|
||||
"method": "ListAssets"
|
||||
}
|
||||
],
|
||||
"timeout": "60s",
|
||||
"retryPolicy": {
|
||||
"initialBackoff": "0.100s",
|
||||
"maxBackoff": "60s",
|
||||
"backoffMultiplier": 1.3,
|
||||
"retryableStatusCodes": [
|
||||
"DEADLINE_EXCEEDED",
|
||||
"UNAVAILABLE"
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
@ -0,0 +1,32 @@
|
|||
type: google.api.Service
|
||||
config_version: 3
|
||||
name: cloudasset.googleapis.com
|
||||
title: Cloud Asset API
|
||||
|
||||
apis:
|
||||
- name: google.cloud.asset.v1p5beta1.AssetService
|
||||
|
||||
documentation:
|
||||
summary: The cloud asset API manages the history and inventory of cloud resources.
|
||||
overview: |-
|
||||
# Cloud Asset API
|
||||
|
||||
The Cloud Asset API keeps a history of Google Cloud Platform (GCP) asset
|
||||
metadata, and allows GCP users to download a dump of all asset metadata
|
||||
for the resource types listed below within an organization or a project at
|
||||
a given timestamp.
|
||||
|
||||
Read more documents here:
|
||||
https://cloud.google.com/asset-inventory/docs
|
||||
|
||||
backend:
|
||||
rules:
|
||||
- selector: google.cloud.asset.v1p5beta1.AssetService.ListAssets
|
||||
deadline: 600.0
|
||||
|
||||
authentication:
|
||||
rules:
|
||||
- selector: google.cloud.asset.v1p5beta1.AssetService.ListAssets
|
||||
oauth:
|
||||
canonical_scopes: |-
|
||||
https://www.googleapis.com/auth/cloud-platform
|
||||
Loading…
Reference in New Issue