Types for Cloud Asset API Client#

class google.cloud.asset_v1beta1.types.Any#
class google.cloud.asset_v1beta1.types.Asset#

Cloud asset. This includes all Google Cloud Platform resources, Cloud IAM policies, and other non-GCP assets.

name#

The full name of the asset. For example: //compute.googleapis.com/projects/my_project_123/zones/zone1/instances/instance1. See https://cloud.google.com/apis/design/resource_names#full_resource_name for more information.

asset_type#

Type of the asset. Example: “google.compute.Disk”.

resource#

Representation of the resource.

iam_policy#

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.

class google.cloud.asset_v1beta1.types.BatchGetAssetsHistoryRequest#

Batch get assets history request.

parent#

Required. The relative name of the root asset. It can only be an organization number (such as “organizations/123”), a project ID (such as “projects/my-project-id”)”, or a project number (such as “projects/12345”).

asset_names#

A list of the full names of the assets. For example: //compu te.googleapis.com/projects/my_project_123/zones/zone1/instance s/instance1. See Resource Names for more info. The request becomes a no-op if the asset name list is empty, and the max size of the asset name list is 100 in one request.

content_type#

Required. The content type.

read_time_window#

Optional. The time window for the asset history. Both start_time and end_time are optional and if set, it must be after 2018-10-02 UTC. If end_time is not set, it is default to current timestamp. If start_time is not set, the snapshot of the assets at end_time will be returned. The returned results contain all temporal assets whose time window overlap with read_time_window.

class google.cloud.asset_v1beta1.types.BatchGetAssetsHistoryResponse#

Batch get assets history response.

assets#

A list of assets with valid time windows.

class google.cloud.asset_v1beta1.types.Binding#

Associates members with a role.

role#

Role that is assigned to members. For example, roles/viewer, roles/editor, or roles/owner. Required

members#

Specifies the identities requesting access for a Cloud Platform resource. members can have the following values: - allUsers: A special identifier that represents anyone who is on the internet; with or without a Google account. - allAuthenticatedUsers: A special identifier that represents anyone who is authenticated with a Google account or a service account. - user:{emailid}: An email address that represents a specific Google account. For example, alice@gmail.com or joe@example.com. - serviceAccount:{emailid}: An email address that represents a service account. For example, my-other- app@appspot.gserviceaccount.com. - group:{emailid}: An email address that represents a Google group. For example, admins@example.com. - domain:{domain}: A Google Apps domain name that represents all the users of that domain. For example, google.com or example.com.

class google.cloud.asset_v1beta1.types.BindingDelta#

One delta entry for Binding. Each individual change (only one member in each entry) to a binding will be a separate entry.

action#

The action that was performed on a Binding. Required

role#

Role that is assigned to members. For example, roles/viewer, roles/editor, or roles/owner. Required

member#

A single identity requesting access for a Cloud Platform resource. Follows the same format of Binding.members. Required

class google.cloud.asset_v1beta1.types.CancelOperationRequest#
class google.cloud.asset_v1beta1.types.CustomHttpPattern#
class google.cloud.asset_v1beta1.types.DeleteOperationRequest#
class google.cloud.asset_v1beta1.types.DescriptorProto#
class ExtensionRange#
class ReservedRange#
class google.cloud.asset_v1beta1.types.Empty#
class google.cloud.asset_v1beta1.types.EnumDescriptorProto#
class EnumReservedRange#
class google.cloud.asset_v1beta1.types.EnumOptions#
class google.cloud.asset_v1beta1.types.EnumValueDescriptorProto#
class google.cloud.asset_v1beta1.types.EnumValueOptions#
class google.cloud.asset_v1beta1.types.ExportAssetsRequest#

Export asset request.

parent#

Required. The relative name of the root asset. This can only be an organization number (such as “organizations/123”), a project ID (such as “projects/my-project-id”), a project number (such as “projects/12345”), or a folder number (such as “folders/123”).

read_time#

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.

asset_types#

A list of asset types of which to take a snapshot for. For example: “google.compute.Disk”. If specified, only matching assets will be returned. See Introduction to Cloud Asset Inventory for all supported asset types.

content_type#

Asset content type. If not specified, no content but the asset name will be returned.

output_config#

Required. Output configuration indicating where the results will be output to. All results will be in newline delimited JSON format.

class google.cloud.asset_v1beta1.types.ExportAssetsResponse#

The export asset response. This message is returned by the [google.longrunning.Operations.GetOperation][google.longrunning.Operations.GetOperation] method in the returned [google.longrunning.Operation.response][google.longrunning.Operation.response] field.

read_time#

Time the snapshot was taken.

output_config#

Output configuration indicating where the results were output to. All results are in JSON format.

class google.cloud.asset_v1beta1.types.ExtensionRangeOptions#
class google.cloud.asset_v1beta1.types.FieldDescriptorProto#
class google.cloud.asset_v1beta1.types.FieldOptions#
class google.cloud.asset_v1beta1.types.FileDescriptorProto#
class google.cloud.asset_v1beta1.types.FileDescriptorSet#
class google.cloud.asset_v1beta1.types.FileOptions#
class google.cloud.asset_v1beta1.types.GcsDestination#

A Cloud Storage location.

object_uri#

Required.

uri#

The uri of the Cloud Storage object. It’s the same uri that is used by gsutil. For example: “gs://bucket_name/object_name”. See Viewing and Editing Object Metadata for more information.

class google.cloud.asset_v1beta1.types.GeneratedCodeInfo#
class Annotation#
class google.cloud.asset_v1beta1.types.GetOperationRequest#
class google.cloud.asset_v1beta1.types.Http#
class google.cloud.asset_v1beta1.types.HttpRule#
class google.cloud.asset_v1beta1.types.ListOperationsRequest#
class google.cloud.asset_v1beta1.types.ListOperationsResponse#
class google.cloud.asset_v1beta1.types.ListValue#
class google.cloud.asset_v1beta1.types.MessageOptions#
class google.cloud.asset_v1beta1.types.MethodDescriptorProto#
class google.cloud.asset_v1beta1.types.MethodOptions#
class google.cloud.asset_v1beta1.types.OneofDescriptorProto#
class google.cloud.asset_v1beta1.types.OneofOptions#
class google.cloud.asset_v1beta1.types.Operation#
class google.cloud.asset_v1beta1.types.OutputConfig#

Output configuration for export assets destination.

destination#

Asset export destination.

gcs_destination#

Destination on Cloud Storage.

class google.cloud.asset_v1beta1.types.Policy#

Defines an Identity and Access Management (IAM) policy. It is used to specify access control policies for Cloud Platform resources.

A Policy consists of a list of bindings. A Binding binds a list of members to a role, where the members can be user accounts, Google groups, Google domains, and service accounts. A role is a named list of permissions defined by IAM.

Example

{
  "bindings": [
    {
      "role": "roles/owner",
      "members": [
        "user:mike@example.com",
        "group:admins@example.com",
        "domain:google.com",
        "serviceAccount:my-other-app@appspot.gserviceaccount.com",
      ]
    },
    {
      "role": "roles/viewer",
      "members": ["user:sean@example.com"]
    }
  ]
}

For a description of IAM and its features, see the IAM developer’s guide.

version#

Version of the Policy. The default version is 0.

bindings#

Associates a list of members to a role. Multiple bindings must not be specified for the same role. bindings with no members will result in an error.

etag#

etag is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the etag in the read-modify-write cycle to perform policy updates in order to avoid race conditions: An etag is returned in the response to getIamPolicy, and systems are expected to put that etag in the request to setIamPolicy to ensure that their change will be applied to the same version of the policy. If no etag is provided in the call to setIamPolicy, then the existing policy is overwritten blindly.

class google.cloud.asset_v1beta1.types.PolicyDelta#

The difference delta between two policies.

binding_deltas#

The delta for Bindings between two policies.

class google.cloud.asset_v1beta1.types.Resource#

Representation of a cloud resource.

version#

The API version. Example: “v1”.

discovery_document_uri#

The URL of the discovery document containing the resource’s JSON schema. For example: "https://www.googleapis.com/discov ery/v1/apis/compute/v1/rest". It will be left unspecified for resources without a discovery-based API, such as Cloud Bigtable.

discovery_name#

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.

resource_url#

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.

parent#

The full name of the immediate parent of this resource. See Resource Names for more information. For GCP assets, it is the parent resource defined in the Cloud IAM policy hierarchy. For example: "//cloudresourcemanager.go ogleapis.com/projects/my_project_123". For third-party assets, it is up to the users to define.

data#

The content of the resource, in which some sensitive fields are scrubbed away and may not be present.

class google.cloud.asset_v1beta1.types.ServiceDescriptorProto#
class google.cloud.asset_v1beta1.types.ServiceOptions#
class google.cloud.asset_v1beta1.types.SourceCodeInfo#
class Location#
class google.cloud.asset_v1beta1.types.Status#
class google.cloud.asset_v1beta1.types.Struct#
class FieldsEntry#
class google.cloud.asset_v1beta1.types.TemporalAsset#

Temporal asset. In addition to the asset, the temporal asset includes the status of the asset and valid from and to time of it.

window#

The time window when the asset data and state was observed.

deleted#

If the asset is deleted or not.

asset#

Asset.

class google.cloud.asset_v1beta1.types.TimeWindow#

A time window of (start_time, end_time].

start_time#

Start time of the time window (exclusive).

end_time#

End time of the time window (inclusive). Current timestamp if not specified.

class google.cloud.asset_v1beta1.types.Timestamp#
class google.cloud.asset_v1beta1.types.UninterpretedOption#
class NamePart#
class google.cloud.asset_v1beta1.types.Value#