Google IDX icon

Google IDX

Google IDX

Overview

This node integrates with Google Cloud Workstations via the Google IDX API, enabling management and control of cloud-based development workstations. It supports operations such as resetting cached workstation data, starting/stopping workstations, generating access tokens, retrieving workstation status, running commands remotely, and initializing workstation data caches.

A common use case is automating the lifecycle and monitoring of Google Cloud Workstations within an n8n workflow, for example:

  • Resetting cached workstation information to refresh state.
  • Starting or stopping specific workstations programmatically.
  • Running shell commands on a remote workstation through the Google Cloud CLI inside a Docker container.
  • Fetching live status or metadata about workstations for reporting or alerting.

This node is beneficial for DevOps teams managing multiple cloud workstations, enabling integration into CI/CD pipelines or automated environment setups.

Properties

Name Meaning
Project ID Select or enter your Google Cloud project ID. Supports selecting from a list or entering manually.

Note: The provided properties JSON only includes "Project ID" relevant when the operation is not one of the excluded ones (like reset cache). For the "Reset Cache Workstation" operation specifically, no additional input properties are required.

Output

The node outputs JSON objects representing the result of the selected operation. For the "Reset Cache Workstation" operation, the output is:

{
  "status": "reset-complete"
}

This indicates that the cached workstation data for the current user has been cleared successfully.

For other operations (not requested here), outputs may include detailed workstation data, status codes, command execution results (including stdout, stderr, exit code), or lists of workstations grouped by user and workspace slug.

The node can also output binary data indirectly when running commands inside Docker containers, but this is handled as text in the JSON output fields.

Dependencies

  • Requires an OAuth2 API credential configured for Google IDX API access.
  • Uses Google Cloud Workstations API endpoints.
  • For running commands on workstations, requires:
    • Access to a Docker container running the Google Cloud CLI (gcloud).
    • Properly configured gcloud CLI with authentication.
  • Node uses internal helper methods for OAuth2 requests and concurrency limiting.
  • Environment must allow executing child processes (for running shell commands).

Troubleshooting

  • Missing or invalid Project ID: Some operations require a valid Google Cloud project ID. Ensure it is provided and correct.
  • Authentication errors: The node relies on OAuth2 credentials; expired or misconfigured tokens will cause failures.
  • Command execution failures: When running commands via Docker and gcloud, errors may occur if the Docker container is not running, the CLI is not installed/configured, or the access token is invalid.
  • Invalid input format for manual commands: The "manualWorkstation" operation expects a specific command format. Errors will be thrown if the input does not match the expected pattern.
  • API rate limits or transient errors: The node implements retries for HTTP 503/504 errors, but persistent failures may require checking API quotas or network connectivity.

Common error messages include:

  • "Unsupported operation: <operation>": Indicates the requested operation is not implemented.
  • "Missing or invalid input": Input parameters are missing or malformed.
  • "Failed after X retries": Network or API call failed repeatedly; check connectivity and API status.

Links and References

Discussion