arga CLI authenticates your machine and gives scripts or coding agents access to the same core workflows as the web app.
Install
pipx install arga-cli or pip install arga-cli.
Authenticate
arga login starts the device authorization flow and stores a device-scoped credential in ~/.config/arga/config.json. Run arga logout to remove and revoke the current device credential.
Twin Runs
List the available services:google_docs and google_sheets are full twins: each provision exposes its provider-compatible API and an interactive editor UI. When you provision any two or more of google_drive, google_docs, and google_sheets under the same Twin Run ID, they share one run-scoped file state. Creates, edits, renames, permissions, revisions, trash, and deletes stay synchronized across the selected twins. Different Twin Run IDs remain isolated.
google_workspace contains People, Workspace Events, Apps Script, Pub/Sub, and
helper task/push-notification APIs. It does not contain Drive, Docs, Sheets,
Gmail, or Calendar.
When you use gws, cache each provisioned service’s Discovery document. See
Use the Google Workspace CLI with Arga twins
for the complete setup.
Seed the twins from a saved Scenario:
resetrestores the baseline captured when the twins were provisioned.extendchanges the requested TTL within your plan limit.lockrevokes public access while preserving authenticated access.teardownends the run immediately.
Configure a local project
Run the wizard from your project directory:.env to .env.arga-backup, provisions selected twins, and replaces provider endpoints or credentials with twin values. Restore the original file with:
Scenarios
Choose a generation mode
Requiresarga-cli 0.1.20 or later. Upgrade with uv tool upgrade arga-cli.
Use --generation-mode thorough for complex prompt requirements when a longer wait is acceptable. Omit the flag for Fast generation, or pass --generation-mode fast explicitly.
import and update also accept the flag. It overrides generation_mode in the JSON file; without the flag, the file’s value is preserved. To regenerate a saved scenario, provide prompt in the update file and omit seed_config:
arga test-runner scenarios ... and arga previews twins provision accept the same flag.
Test Runs
Start a browser run against a reachable URL:--email and --password together.
Inspect and manage run history:
Saved Tests
Create a Saved Test from a Test Run:--ci when creating a test to make it eligible for that repository’s PR Test Runs.
TestConfig JSON
Saved Tests use agent-editable TestConfig JSON. Validate or normalize a file before importing it:PR Test Runs
Install and configure repository automation:JSON output
Commands that return structured data accept--json:
Git helpers
Create a commit that skips Arga validation for that head commit:[skip arga]. The push wrapper verifies that the current commit already contains it.
Install MCP
Custom API URL
Pass--api-url where supported or set ARGA_API_URL:

