Principal identifiers
Stay organized with collections
Save and categorize content based on your preferences.
When you refer to a principal in an Identity and Access Management (IAM) policy, you need
to use the correct identifier for the principal. The format of the identifier
depends on the type of principal that you want to refer to and
the type of policy that you're writing.
This page lists the identifier formats for each policy type's supported
principal types.
Principal identifiers for allow policies
The following table describes the principal identifiers for allow
policies, which use the IAM v1 API.
Example for all service accounts in a project:principalSet://cloudresourcemanager.googleapis.com/projects/123456789012/type/ServiceAccount
Example for all service accounts in all projects in a folder:principalSet://cloudresourcemanager.googleapis.com/folders/123456789012/type/ServiceAccount
Example for all service accounts in all projects in an organization:principalSet://cloudresourcemanager.googleapis.com/organizations/123456789012/type/ServiceAccount
Example using a group email:principalSet://iam.googleapis.com/locations/global/workforcePools/altostrat-contractors/group/administrators-group@altostrat.com
Example using a group UUID:principalSet://iam.googleapis.com/locations/global/workforcePools/altostrat-contractors/group/abcdefgh-0123-0123-abcdef
All workforce identities with a specific attribute value
All GKE Pods that use a specific Kubernetes service account
By service account name: principal://iam.googleapis.com/projects/PROJECT_NUMBER/locations/global/workloadIdentityPools/PROJECT_ID.svc.id.goog/subject/ns/NAMESPACE/sa/KUBERNETES_SERVICE_ACCOUNT
By service account ID: principal://iam.googleapis.com/projects/PROJECT_NUMBER/locations/global/workloadIdentityPools/PROJECT_ID.svc.id.goog/kubernetes.serviceaccount.uid/SERVICEACCOUNT_ID
Example for all service accounts in a project:principalSet://cloudresourcemanager.googleapis.com/projects/123456789012/type/ServiceAccount
Example for all service accounts in all projects in a folder:principalSet://cloudresourcemanager.googleapis.com/folders/123456789012/type/ServiceAccount
Example for all service accounts in all projects in an organization:principalSet://cloudresourcemanager.googleapis.com/organizations/123456789012/type/ServiceAccount
All service agents associated with a project, folder, or organization
Example for all service agents associated with a project or its descendants:principalSet://cloudresourcemanager.googleapis.com/projects/123456789012/type/ServiceAgent
Example for all service agents associated with a folder or its descendants:principalSet://cloudresourcemanager.googleapis.com/folders/123456789012/type/ServiceAgent
Example for all service agents associated with an organization or its descendants:principalSet://cloudresourcemanager.googleapis.com/organizations/123456789012/type/ServiceAgent
Example using a group email:principalSet://iam.googleapis.com/locations/global/workforcePools/altostrat-contractors/group/administrators-group@altostrat.com
Example using a group UUID:principalSet://iam.googleapis.com/locations/global/workforcePools/altostrat-contractors/group/abcdefgh-0123-0123-abcdef
All workforce identities with a specific attribute value
2 Don't add deleted principals when creating or modifying policies.
Principal identifiers for principal access boundary policy bindings
The following table describes the identifiers for the principal sets that you
can use in principal access boundary (PAB) policy bindings.
Principal access boundary policy bindings use the IAM v3
API.
To learn which principals are included in each of these principal sets, see
Supported principal sets.
The following table describes the principal identifiers that you can use in
access policies. You can use access policies to control access to
Eventarc resources. For more information, see the Eventarc
documentation.
Example for all service accounts in a project:principalSet://cloudresourcemanager.googleapis.com/projects/123456789012/type/ServiceAccount
Example for all service accounts in all projects in a folder:principalSet://cloudresourcemanager.googleapis.com/folders/123456789012/type/ServiceAccount
Example for all service accounts in all projects in an organization:principalSet://cloudresourcemanager.googleapis.com/organizations/123456789012/type/ServiceAccount
[[["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-12-22 UTC."],[],[]]