Reference documentation and code samples for the Cloud Asset V1 API class Google::Cloud::Asset::V1::IamPolicyAnalysisQuery::IdentitySelector.
Specifies an identity for which to determine resource access, based on
roles assigned either directly to them or to the groups they belong to,
directly or indirectly.
Inherits
Object
Extended By
Google::Protobuf::MessageExts::ClassMethods
Includes
Google::Protobuf::MessageExts
Methods
#identity
defidentity()->::String
Returns
(::String) — Required. The identity appear in the form of principals in
IAM policy
binding.
The examples of supported forms are:
"user:mike@example.com",
"group:admins@example.com",
"domain:google.com",
"serviceAccount:my-project-id@appspot.gserviceaccount.com".
Notice that wildcard characters (such as * and ?) are not supported.
You must give a specific identity.
#identity=
defidentity=(value)->::String
Parameter
value (::String) — Required. The identity appear in the form of principals in
IAM policy
binding.
The examples of supported forms are:
"user:mike@example.com",
"group:admins@example.com",
"domain:google.com",
"serviceAccount:my-project-id@appspot.gserviceaccount.com".
Notice that wildcard characters (such as * and ?) are not supported.
You must give a specific identity.
Returns
(::String) — Required. The identity appear in the form of principals in
IAM policy
binding.
The examples of supported forms are:
"user:mike@example.com",
"group:admins@example.com",
"domain:google.com",
"serviceAccount:my-project-id@appspot.gserviceaccount.com".
Notice that wildcard characters (such as * and ?) are not supported.
You must give a specific identity.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-09-09 UTC."],[],[],null,["# Cloud Asset V1 API - Class Google::Cloud::Asset::V1::IamPolicyAnalysisQuery::IdentitySelector (v1.4.1)\n\nVersion latestkeyboard_arrow_down\n\n- [1.4.1 (latest)](/ruby/docs/reference/google-cloud-asset-v1/latest/Google-Cloud-Asset-V1-IamPolicyAnalysisQuery-IdentitySelector)\n- [1.4.0](/ruby/docs/reference/google-cloud-asset-v1/1.4.0/Google-Cloud-Asset-V1-IamPolicyAnalysisQuery-IdentitySelector)\n- [1.3.1](/ruby/docs/reference/google-cloud-asset-v1/1.3.1/Google-Cloud-Asset-V1-IamPolicyAnalysisQuery-IdentitySelector)\n- [1.2.0](/ruby/docs/reference/google-cloud-asset-v1/1.2.0/Google-Cloud-Asset-V1-IamPolicyAnalysisQuery-IdentitySelector)\n- [1.1.0](/ruby/docs/reference/google-cloud-asset-v1/1.1.0/Google-Cloud-Asset-V1-IamPolicyAnalysisQuery-IdentitySelector)\n- [1.0.2](/ruby/docs/reference/google-cloud-asset-v1/1.0.2/Google-Cloud-Asset-V1-IamPolicyAnalysisQuery-IdentitySelector)\n- [0.32.0](/ruby/docs/reference/google-cloud-asset-v1/0.32.0/Google-Cloud-Asset-V1-IamPolicyAnalysisQuery-IdentitySelector)\n- [0.31.0](/ruby/docs/reference/google-cloud-asset-v1/0.31.0/Google-Cloud-Asset-V1-IamPolicyAnalysisQuery-IdentitySelector)\n- [0.30.0](/ruby/docs/reference/google-cloud-asset-v1/0.30.0/Google-Cloud-Asset-V1-IamPolicyAnalysisQuery-IdentitySelector)\n- [0.29.3](/ruby/docs/reference/google-cloud-asset-v1/0.29.3/Google-Cloud-Asset-V1-IamPolicyAnalysisQuery-IdentitySelector)\n- [0.28.1](/ruby/docs/reference/google-cloud-asset-v1/0.28.1/Google-Cloud-Asset-V1-IamPolicyAnalysisQuery-IdentitySelector)\n- [0.27.0](/ruby/docs/reference/google-cloud-asset-v1/0.27.0/Google-Cloud-Asset-V1-IamPolicyAnalysisQuery-IdentitySelector)\n- [0.26.1](/ruby/docs/reference/google-cloud-asset-v1/0.26.1/Google-Cloud-Asset-V1-IamPolicyAnalysisQuery-IdentitySelector)\n- [0.25.0](/ruby/docs/reference/google-cloud-asset-v1/0.25.0/Google-Cloud-Asset-V1-IamPolicyAnalysisQuery-IdentitySelector)\n- [0.24.0](/ruby/docs/reference/google-cloud-asset-v1/0.24.0/Google-Cloud-Asset-V1-IamPolicyAnalysisQuery-IdentitySelector)\n- [0.23.0](/ruby/docs/reference/google-cloud-asset-v1/0.23.0/Google-Cloud-Asset-V1-IamPolicyAnalysisQuery-IdentitySelector)\n- [0.22.0](/ruby/docs/reference/google-cloud-asset-v1/0.22.0/Google-Cloud-Asset-V1-IamPolicyAnalysisQuery-IdentitySelector)\n- [0.21.1](/ruby/docs/reference/google-cloud-asset-v1/0.21.1/Google-Cloud-Asset-V1-IamPolicyAnalysisQuery-IdentitySelector)\n- [0.20.1](/ruby/docs/reference/google-cloud-asset-v1/0.20.1/Google-Cloud-Asset-V1-IamPolicyAnalysisQuery-IdentitySelector)\n- [0.19.0](/ruby/docs/reference/google-cloud-asset-v1/0.19.0/Google-Cloud-Asset-V1-IamPolicyAnalysisQuery-IdentitySelector)\n- [0.18.0](/ruby/docs/reference/google-cloud-asset-v1/0.18.0/Google-Cloud-Asset-V1-IamPolicyAnalysisQuery-IdentitySelector)\n- [0.17.3](/ruby/docs/reference/google-cloud-asset-v1/0.17.3/Google-Cloud-Asset-V1-IamPolicyAnalysisQuery-IdentitySelector) \nReference documentation and code samples for the Cloud Asset V1 API class Google::Cloud::Asset::V1::IamPolicyAnalysisQuery::IdentitySelector.\n\nSpecifies an identity for which to determine resource access, based on\nroles assigned either directly to them or to the groups they belong to,\ndirectly or indirectly. \n\nInherits\n--------\n\n- Object \n\nExtended By\n-----------\n\n- Google::Protobuf::MessageExts::ClassMethods \n\nIncludes\n--------\n\n- Google::Protobuf::MessageExts\n\nMethods\n-------\n\n### #identity\n\n def identity() -\u003e ::String\n\n**Returns**\n\n- (::String) --- Required. The identity appear in the form of principals in [IAM policy\n binding](https://cloud.google.com/iam/reference/rest/v1/Binding).\n\n\n The examples of supported forms are:\n \"user:mike@example.com\",\n \"group:admins@example.com\",\n \"domain:google.com\",\n \"serviceAccount:my-project-id@appspot.gserviceaccount.com\".\n\n Notice that wildcard characters (such as \\* and ?) are not supported.\n You must give a specific identity.\n\n### #identity=\n\n def identity=(value) -\u003e ::String\n\n**Parameter**\n\n- **value** (::String) --- Required. The identity appear in the form of principals in [IAM policy\n binding](https://cloud.google.com/iam/reference/rest/v1/Binding).\n\n\n The examples of supported forms are:\n \"user:mike@example.com\",\n \"group:admins@example.com\",\n \"domain:google.com\",\n \"serviceAccount:my-project-id@appspot.gserviceaccount.com\".\n\n Notice that wildcard characters (such as \\* and ?) are not supported.\nYou must give a specific identity. \n**Returns**\n\n- (::String) --- Required. The identity appear in the form of principals in [IAM policy\n binding](https://cloud.google.com/iam/reference/rest/v1/Binding).\n\n\n The examples of supported forms are:\n \"user:mike@example.com\",\n \"group:admins@example.com\",\n \"domain:google.com\",\n \"serviceAccount:my-project-id@appspot.gserviceaccount.com\".\n\n Notice that wildcard characters (such as \\* and ?) are not supported.\n You must give a specific identity."]]