Overseas access: www.kdjingpai.com
Bookmark Us
Current Position:fig. beginning " AI Answers

How to install and configure Gemini-CLI-2-API?

2025-08-21 551
Link directMobile View
qrcode

The following steps are required to install and configure Gemini-CLI-2-API:

  1. environmental preparation: First you need to install Node.js (the latest LTS version is recommended). You can verify if the installation was successful by using the node -v and npm -v commands.
  2. Get Code: Use Git to clone your project repository locally:
    git clone https://github.com/justlovemaki/Gemini-CLI-2-API.git
    cd Gemini-CLI-2-API
  3. Installation of dependencies: Run the npm install command in the project directory to install all dependencies.
  4. Configuring Authentication: Two options are available:
    • OAuth authentication: the first time you run the program will automatically guide you to sign in to your Google account in your browser
    • API key: set GOOGLE_API_KEY and GOOGLE_GENAI_USE_VERTEXAI environment variables
  5. Starting services: Started with the command node openai-api-server.js, with customizable ports and keys via the -port and -api-key arguments.

The entire installation process requires attention to a stable network connection, especially OAuth authentication needs to have access to Google servers.

Recommended

Can't find AI tools? Try here!

Just type in the keyword Accessibility Bing SearchYou can quickly find all the AI tools on this site.

Top

en_USEnglish