Thanks to visit codestin.com
Credit goes to github.com

Skip to content

gemini-cli-extensions/looker

Gemini CLI Extension - Looker

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.

Why Use the Looker Extension?

  • 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.

Prerequisites

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.

Getting Started

Installation

To install the extension, use the command:

gemini extensions install https://github.com/gemini-cli-extensions/looker

Configuration

You 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 true

Start Gemini CLI

To start the Gemini CLI, use the following command:

gemini

Usage

You can ask questions and give commands such as these:

  1. What models are available in my Looker instance?
  2. What explores are available in model_name?
  3. What measures and dimensions are in explore_name?
  4. Using model_name, what is the total revenue in 2025? Break that down by month and pivot by product category.
  5. What is the sql for that last query?
  6. Visualize that data using a stacked column chart and give me the url to it.
  7. Save that as a Look.
  8. Run the Look titled "Revenue Projection".
  9. Create a dashboard analyzing sales for the year 2025.

Supported Tools

  • get_models: Use this tool to list the LookML models in Looker.
  • get_explores: Use this tool to list the explores in a given model.
  • get_dimensions: Use this tool to list the dimensions in a given explore.
  • get_measures: Use this tool to list the measures in a given explore.
  • get_filters: Use this tool to list the filters in a given explore.
  • get_parameters: Use this tool to list the parameters in a given explore.
  • query: Use this tool to run a query and return the data.
  • query_sql: Use this tool to return the SQL generated by Looker for a query.
  • query_url: Use this tool to return a link to the query in Looker for further exploration.
  • get_looks: Use this tool to return the saved Looks that match a title or description.
  • run_look: Use this tool to run a saved Look and return the data.
  • make_look: Use this tool to create a saved Look in Looker and return the URL.
  • get_dashboards: Use this tool to return the saved dashboards that match a title or description.
  • make_dashboard: Use this tool to create a saved dashboard in Looker and return the URL.
  • add_dashboard_element: Use this tool to add a tile to a dashboard.

Additional Extensions

Find additional extensions to support your entire software development lifecycle at github.com/gemini-cli-extensions.

Troubleshooting

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.

About

No description, website, or topics provided.

Resources

License

Code of conduct

Contributing

Stars

Watchers

Forks

Packages

No packages published

Contributors 9