Note
This extension is currently in beta (pre-v1.0), and may see breaking changes until the first stable release (v1.0).
This Gemini CLI extension provides a set of tools to interact with Looker instances. It allows you to manage your Looks, dashboards, and explores directly from the Gemini CLI, using natural language prompts.
Learn more about Gemini CLI Extensions.
Important
We Want Your Feedback! Please share your thoughts with us by filling out our feedback form. Your input is invaluable and helps us improve the project for everyone.
- Seamless Workflow: Stay in your CLI. No need to constantly switch contexts.
- Connect to Looker: Securely connect to your Looker instances.
- Natural Language Usage: Stop wrestling with complex commands. List models, explores, and dimensions, and run Looks and queries by describing what you want in plain English.
Before you begin, ensure you have the following:
- Gemini CLI installed with version +v0.6.0.
- Setup Gemini CLI Authentication.
- A Looker instance with API access enabled.
To install the extension, use the command:
gemini extensions install https://github.com/gemini-cli-extensions/lookerYou will need a Looker Client Id and Client Secret. These can be obtained by following the directions at Looker API authentication. If you don't have access to the Admin pages of the Looker system, you will need to ask your administrator to get the Id and Secret for you.
Set the following environment variables before starting the Gemini CLI. These variables can be loaded from a .env file.
export LOOKER_BASE_URL="<your-looker-instance-url>" # e.g. `https://looker.example.com`. You may need to add the port, i.e. `:19999`.
export LOOKER_CLIENT_ID="<your-looker-client-id>"
export LOOKER_CLIENT_SECRET="<your-looker-client-secret>"
export LOOKER_VERIFY_SSL="true" # Optional, defaults to true
export LOOKER_SHOW_HIDDEN_MODELS="true" # Optional, defaults to true
export LOOKER_SHOW_HIDDEN_EXPLORES="true" # Optional, defaults to true
export LOOKER_SHOW_HIDDEN_FIELDS="true" # Optional, defaults to trueTo start the Gemini CLI, use the following command:
geminiYou can ask questions and give commands such as these:
- What models are available in my Looker instance?
- What explores are available in model_name?
- What measures and dimensions are in explore_name?
- Using model_name, what is the total revenue in 2025? Break that down by month and pivot by product category.
- What is the sql for that last query?
- Visualize that data using a stacked column chart and give me the url to it.
- Save that as a Look.
- Run the Look titled "Revenue Projection".
- Create a dashboard analyzing sales for the year 2025.
The full tool list is available in the Prebuilt Tools Reference.
The following tools are available to the LLM:
These tools are used to get information about a Looker model and execute queries against that model.
- get_models: list the LookML models in Looker
- get_explores: list the explores in a given model
- get_dimensions: list the dimensions in a given explore
- get_measures: list the measures in a given explore
- get_filters: list the filters in a given explore
- get_parameters: list the parameters in a given explore
- query: Run a query and return the data
- query_sql: Return the SQL generated by Looker for a query
- query_url: Return a link to the query in Looker for further exploration
These tools get saved content (Looks and Dashboards) from a Looker instance and create new saved content.
- get_looks: Return the saved Looks that match a title or description
- run_look: Run a saved Look and return the data
- make_look: Create a saved Look in Looker and return the URL
- get_dashboards: Return the saved dashboards that match a title or description
- make_dashboard: Create a saved dashboard in Looker and return the URL
- add_dashboard_element: Add a tile to a dashboard
These tools offer the same health check algorithms that the popular CLI Henry offers.
- health_pulse: Check the health of a Looker intance
- health_analyze: Analyze the usage of a Looker object
- health_vacuum: Find LookML elements that might be unused
These tools allow enable the caller to write and modify LookML files as well as get the database schema needed to write LookML effectively.
- dev_mode: Activate dev mode.
- get_projects: Get the list of LookML projects
- get_project_files: Get the list of files in a project
- get_project_file: Get the contents of a file in a project
- create_project_file: Create a file in a project
- update_project_file: Update the contents of a file in a project
- delete_project_file: Delete a file in a project
- get_connections: Get the list of connections
- get_connection_schemas: Get the list of schemas for a connection
- get_connection_databases: Get the list of databases for a connection
- get_connection_tables: Get the list of tables for a connection
- get_connection_table_columns: Get the list of columns for a table in a connection
Find additional extensions to support your entire software development lifecycle at github.com/gemini-cli-extensions.
Use gemini --debug to enable debugging.
Common issues:
- "failed to find default credentials: google: could not find default credentials.": Ensure Application Default Credentials are available in your environment. See Set up Application Default Credentials for more information.
- "✖ Error during discovery for server: MCP error -32000: Connection closed": The database connection has not been established. Ensure your configuration is set via environment variables.
- "✖ MCP ERROR: Error: spawn /Users/USER/.gemini/extensions/cloud-sql-sqlserver/toolbox ENOENT": The Toolbox binary did not download correctly. Ensure you are using Gemini CLI v0.6.0+.
- "cannot execute binary file": The Toolbox binary did not download correctly. Ensure the correct binary for your OS/Architecture has been downloaded. See Installing the server for more information.