function::get_sa_flags - Linux


function::get_sa_flags is a command used to retrieve the flags associated with a service account (SA). It provides insights into the permissions and capabilities granted to a specific SA within a project.


function::get_sa_flags [PROJECT] [ACCOUNT_EMAIL]


  • PROJECT: (Optional) Google Cloud project ID or project number. Defaults to the current project ID.
  • ACCOUNT_EMAIL: Email address of the service account.




Get SA flags for a specific account in the current project:


Get SA flags for a specific account in a different project:

function::get_sa_flags my-project

Common Issues

  • Error: Service account not found: Ensure that the provided email address is correct and that the service account exists within the specified project.
  • Error: Permission denied: Verify that the user executing the command has sufficient permissions to access the service account’s flags.


function::get_sa_flags can be used in conjunction with other commands for advanced tasks, such as:

  • Check SA permissions: Use the output of function::get_sa_flags as input to function::check_sa_permissions to verify the permissions granted to an SA.
  • Create SA: Combine with function::create_sa to create a new SA and retrieve its flags.

Related Commands

  • function::create_sa
  • function::delete_sa
  • function::check_sa_permissions