Our November launch attempt stopped at GLIBC_2.39, before Google Workspace CLI could display its version. Use googleworkspace/cli, invoked as gws, if you need its broad API commands and can own authentication and account routing. Skip it if you need native switching between personal and work accounts without wrappers: users request its restoration in issue #439. For a new agent integration, Google's separate official gwscli is another starting point.
The two names identify different products. Google's Workspace CLI guide identifies gwscli as the official tool and encourages migration from the community-maintained gws. The distinction affects both support expectations and command coverage. The gws README describes a broad Discovery-generated interface, while its migration FAQ describes gwscli as a curated set of commands for agents. Choosing between them starts with the operations and identities your workflow needs.
What people use cli for
gws exposes Drive, Gmail, Calendar and Sheets operations through commands generated from Google's Discovery Service, according to its README. An API is the interface software uses to request data or actions from another service. Here, command arguments describe the request instead of a handwritten HTTP wrapper. The README demonstrates listing files, creating a spreadsheet, previewing a Chat message request and inspecting a method's schema.
The reported workflows focus on credentials as much as service coverage. Several users need personal, work or agent identities in the same automation environment, and their examples put account selection around the underlying commands. Other reports describe recovering API access after authentication appeared to succeed. These are user accounts of particular workflows, with the historical login example kept separate from current profile routing.
| Who used it | What they did | Reported outcome |
|---|---|---|
| jezweb and their team | Read several Workspace mailboxes on shared machines and agent fleets using per-account directories and a gws-as wrapper |
They report that local wrappers work around removed multi-account support. |
| devxoul | Put personal and work credentials in separate subdirectories and selected one with GOOGLE_WORKSPACE_CLI_CONFIG_DIR |
They describe a directory layout and per-command selection. |
| kinowarrior, cleacos and davidiov42 | Used credential workarounds after decryption failed | They report working access, with token-cache warnings continuing for some users. |
| The reporter of issue #187 | Repeated login with an explicit account after Gmail triage failed | They report restored operation on the historical account-support version. |
The historical example belongs to the account-support history. The requester in #439 says multiple accounts were removed in release 0.7.0, while the earlier #187 workaround used an account argument during login. Present-day wrapper examples instead select a configuration directory before invoking gws. That distinction keeps an old successful command from becoming an instruction for a different account model.
What happened when we ran it
Our November 28, 2026 run installed npm package 0.22.5, then gws --version exited 1 with GLIBC_2.39 not found. The run used checkout 8e945eed02a8 and a fresh unprivileged lab-node:22 container, with 2 CPUs, 4 GB RAM, no published ports and no secrets. The task was the README's gws auth setup quick start. The checkout and downloaded npm executable were separate artifacts.
The clone completed in 1 second. The npm installation then recorded @googleworkspace/cli 0.22.5, 18.5 MB installed in 4.6 seconds. Installation therefore completed before the loader failure. The three executable invocations each failed in 0.1 seconds, including help and the actual setup task. Cleanup subsequently completed successfully.
| November 28 command or step | Result | What it tells you |
|---|---|---|
| Clone | Completed in 1 second | The checkout step completed. |
| npm installation | 0.22.5 installed; 18.5 MB in 4.6 seconds | Package installation completed before launch failed. |
gws --version |
Exit 1 in 0.1 seconds: GLIBC_2.39 not found |
The executable failed before displaying its version. |
gws --help |
Exit 1 in 0.1 seconds with the same loader error | Help was also blocked. |
gws auth setup |
Exit 1 in 0.1 seconds with the same loader error | Setup stopped before authentication. |
| Teardown | Completed successfully | Sandbox cleanup finished. |
The decisive message named /lib/x86_64-linux-gnu/libc.so.6 and version GLIBC_2.39. This locates the failure at executable startup in that container, before OAuth or an API request. Repeating a login command would encounter the same startup requirement. The result also separates two acceptance checks: installing the package and launching the program produced different outcomes in our run.
Our November 7 source run used commit cd3697e, 3 CPUs, 8 GB RAM and the lab-node:22 image label. The package test script invoked cargo test; the shell returned sh: 1: cargo: not found, and the command exited 1 after 2 seconds.
| November 7 source-check step | Measured result |
|---|---|
| pnpm dependency install | Succeeded in 5 seconds; 104 dependencies; 36 MB on disk |
| Build | No build script or target found by the harness; skipped |
| Tests | Failed with exit 1 in 2 seconds; sh: 1: cargo: not found |
The test log names @googleworkspace/cli@0.22.5 test and then cargo test. The failure occurred before Rust tests could execute. The harness's build-script scan skipped its build step, while the README separately documents cargo build for development. The checkout scan recorded 222 files, approximately 32,493 source lines, 2.4 MB checked out and 11 CI workflow files, with no Dockerfile or directory named tests detected.
Where people get stuck: login, decryption and account selection
A successful-looking login can precede a 401 API response: issue #198 reports that sequence on gws 0.5.0. The reporter's status displayed a valid token, while Drive requests failed and the account appeared as unknown. Maintainer jpoehnelt attributes fixes to PRs #175 and #223. A later Windows commenter reports the same symptom after a fresh installation, giving the thread both a fix report and a subsequent failure report.
| Reported problem | What the thread says helped | Reported outcome |
|---|---|---|
| Login succeeds but requests return 401 in #198 | Maintainer cites #175 and #223 | A later Windows commenter still reports 401 responses. |
| Credentials fail to decrypt in #360 | Maintainer cites #359 and GOOGLE_WORKSPACE_CLI_KEYRING_BACKEND=file |
Users report working access; some still receive token-cache warnings. |
| OAuth shows "Something went wrong" in #157 | Some users describe adding a test user or changing browsers | Other users report continued failure. |
| Admin Directory appears missing after an upgrade in #430 | A commenter points to #473 and says it remains usable | The discussion points readers to another issue. |
The #157 OAuth discussion includes a failed shorthand-scope recipe: --scopes drive,gmail,calendar produced an error naming invalid gmail, calendar and drive scopes. The reporter also says a read-only attempt did not succeed fully. In #198, a reporter says gws auth login --help initiated OAuth instead of displaying help. These are specific reported command failures, separate from our loader failure.
The Admin Directory upgrade report in #430 says services appeared missing despite enabled API access and scopes. A commenter links #473, while the maintainer acknowledges having written a service-removal PR. For credentials, #360 records Windows, Ubuntu Linux and macOS reports, including working operations accompanied by warning: failed to decrypt token cache (token_cache.json).
Account isolation matters before an agent can write
Select an explicit profile and check the identity serving a normal API request before allowing writes, following the gw README's identity-check advice. The wrapper requires a profile for every operation and assigns each profile a separate gws configuration directory. Its examples put identity before the action, such as gw personal gmail +triage, so the proposed invocation exposes the account choice alongside the requested operation.
In #439, hitripod describes old multi-account state being ignored and reports silent wrong-account operation on v0.22.5. Other commenters describe selecting directories or using wrappers to separate identities. The requester's reason is concrete: an agent account can carry separate permissions, make actions auditable and have its access switched off. Those goals explain why account routing belongs before an agent receives permission to send mail or change files.
A configuration directory selects credential state; the account's Google permissions determine what those credentials authorize. The two controls address different parts of the workflow. The gw README says it removes inherited identity-bearing gws variables before starting its child process and sets GOOGLE_WORKSPACE_CLI_CONFIG_DIR for the chosen profile. Its account metadata is separate from the opaque directory holding gws state.
Credential encryption still leaves a directory to protect
Protect the entire gws configuration directory when it contains both encrypted credentials and their fallback key, the storage arrangement discussed in issue #344. The discussion describes copying both together to another machine. A backup or shared home-directory copy therefore deserves credential handling, even though one file is encrypted. The README also documents an export command that writes unmasked credentials to a JSON file for headless use.
The fallback history explains why simply removing the key file introduced another problem. capi reports that the 0.9.1 cleanup left a Linux container without a working keyring unable to decrypt credentials. Maintainer jpoehnelt acknowledged that the fallback key had been cleaned up in one scenario and advised downgrading and logging in again. In #360, the maintainer says #359 preserves that fallback and adds a file-backend option for Docker, CI and headless environments.
After #359, cross32768 reports building main on macOS and finding no gws-cli entry in Keychain. Their comment distinguishes a durable file fallback from an operating-system keyring entry and describes a local platform-feature change. That distinction is useful when reading the README's encryption description: persistence across invocations and storage in a particular keyring are separate observable outcomes, even when both are discussed under credential encryption.
The README directs future development toward gwscli
The gws README says future development will concentrate on the official CLI, while users can continue using gws. Its migration section recommends gwscli for agent workflows and Google support, while retaining gws as an option for API methods outside gwscli's curated coverage or direct service-account key files. This gives existing scripts a concrete comparison: required methods, authentication route and support expectations.
GitHub metadata records a November 24, 2026 last push, and the README warns of breaking changes before v1.0. Google's official guide also warns that gwscli discovers interfaces dynamically and that commands and output schemas can change without backward compatibility. Moving to the official client therefore changes the product and support relationship; its documentation still tells developers to inspect current commands and schemas rather than assume fixed signatures in static scripts.
Google Workspace CLI vs gogcli, profile wrappers and MCP
gogcli documents explicit multi-account routing, while gw retains gws and adds required profiles with separate configuration directories. Those are different answers to the account-selection problem. A #293 commenter reports choosing gogcli for multi-account authentication; another describes running multiple Workspace MCP instances with substantial glue code and poor reliability. The comparison below separates documented product behavior from those individual reports.
| Choice | Why someone would choose it | Evidence |
|---|---|---|
gws with local profiles |
Keep Discovery-based commands while selecting a directory per call | Users describe directory and wrapper approaches in #439 and #78. |
| gogcli | Route commands among multiple Google accounts | Its README documents account routing, including --account. |
| gw wrapper | Require an explicit profile while retaining gws | Its README documents isolated configuration directories. |
| Multiple Workspace MCP instances | Connect an agent through separate server instances | deep-ink-ventures reports glue code and poor reliability in #293. |
| Official gwscli | Use Google's supported Workspace CLI for agents | Google's official guide identifies the separate client. |
The #293 requester proposes AWS CLI and gcloud named profiles as an account-selection model. These examples concern how users choose credentials, rather than replacing Gmail or Drive operations. CircleCI's CLI/MCP comparison instead discusses interface choice, favoring CLI for local iteration and MCP for external coordination. Account selection and interface choice remain separate decisions in the Workspace workflows described here.
Outdated claims, corrected
gws returns structured JSON in the authentication and error examples recorded in issue #156. CircleCI's CLI/MCP comparison characterizes CLI output as text and treats consistent JSON as an MCP advantage; the gws examples require a narrower distinction. The issue shows JSON login output followed by a JSON error containing code 401 and reason authError. Structured output alone did not make that authentication sequence successful.
The EECS 280 tutorial calls the terminal another name for the CLI, while the terminology evidence distinguishes the terminal application, shell and command interface. Developer DAO Academy also says Homebrew is needed before using the macOS CLI environment. The EECS tutorial explicitly starts with the Terminal application that comes with macOS. Opening that application and installing a Workspace client are separate setup steps; Homebrew is one installation option listed by the gws README.
FAQ
gws builds terminal commands around Google APIs, while account routing determines which credentials those commands use. The questions below come from CLI/API, agent-interface and terminal search questions, with answers focused on this Workspace client. For this review, the practical decisions are whether the executable starts, whether a request works under the intended identity and whether gws or the separate gwscli covers the required operation.
What is the difference between a CLI and an API?
gws is a CLI that constructs requests to Google APIs from terminal commands, according to its README. It reads Discovery documents and builds its command surface dynamically. The API still performs the requested Workspace operation, using the credentials selected for the invocation. That makes successful login and successful API access separate checks, as #198's valid-token status followed by 401 responses illustrates.
Should AI agents use CLI tools or MCP?
For Workspace agents, explicit account selection is a requirement whichever interface you choose: #439 asks for separate agent credentials and permissions. CircleCI describes CLI and MCP as useful for different development contexts. Google's official guide offers gwscli for agents, while gws exposes Discovery-generated operations. Compare the operation, identity and approval requirements before choosing the interface around them.
Is a CLI the same thing as a terminal?
A terminal displays a command session; gws is a program invoked within that session. The terminology guides distinguish the display application from the command interface and shell. In our November 28 launch attempt, the gws executable encountered a missing GLIBC_2.39 requirement before displaying its version. The actionable failure was at program startup, before Google authentication or a Workspace request.
What we have not tested yet
Neither recorded run completed an authenticated Workspace API task: November 7 stopped at missing Cargo, and November 28 stopped at the executable's library requirement. Actual runtime and operating-system versions require the toolchain logs; the image label alone identifies neither. Rust tests can live beside source, so the absence of a tests directory supplies no test count. The npm binary's source revision is also distinct from the cloned checkout identifier.
A compatible binary environment, manual release download, OAuth completion, account isolation, credential export, actual keyring storage, API quotas, concurrent agents and migration to gwscli remain outside these results. The Admin Directory discussion lacks a demonstrated replacement invocation, and the macOS keyring discussion leaves the shipped backend outcome unresolved. There is no side-by-side performance or reliability measurement for gogcli, gw or Workspace MCP, and the issue samples supply no failure rate or production-adoption estimate.
The four YouTube entries have no transcript extracts, and the Bilibili material consists of search listings rather than demonstrations. No Reddit or X deployment account was available for this review. Search demand, rankings and volumes are unknown. The next useful acceptance task is a read-only request under a deliberately selected identity, followed by a controlled account switch and a record of the identity that served each request.


