--- title: '`glab service-account get`' stage: AI Clients group: Developer Clients info: To determine the technical writer assigned to the Stage/Group associated with this page, see --- Get a service account. ## Synopsis Get a single service account of a project or a group, by its ID or username. A numeric argument is always treated as an ID. IDs and usernames come from `glab service-account list`. Getting a service account by ID requires GitLab 19.4 or later. ```plaintext glab service-account get [flags] ``` ## Examples ```console # Get service account 42 of the current project glab service-account get 42 # Get a service account by its username glab service-account get service_account_project_123_abc # Get a service account of a specific project glab service-account get 42 --repo user/my-repo # Get a group's service account glab service-account get 42 --group my-group # Print the service account's email address glab service-account get 42 --output json --jq '.email' ``` ## Options ```plaintext -g, --group group Get a service account of a group instead of a project. Accepts a group ID or full path. --jq string Filter JSON output with a jq expression. -F, --output string Format output as: text, json. (default "text") -R, --repo string Select another repository. You can use either OWNER/REPO or GROUP/NAMESPACE/REPO. The full URL or Git URL is also accepted. ``` ## Options inherited from parent commands ```plaintext -h, --help Show help for this command. ```