Issues with the confusing and misleading pricing structure of Google search grounding

When I tried to use Google Search grounding with the free API tier based on Gemini’s instructions, a 429 error occurred.
According to information circulated so widely that standard consumer AI picks it up, it is easy to get the false impression that Google Search grounding can be used for free with the Google API. In reality, however, free access was only available prior to Gemini 3, and furthermore, versions prior to Gemini 3 are not actually supported in practice. This is extremely confusing and frustrating for users. Please rectify this situation.
For reference, below is the response Gemini provided: "Based on the challenges and requirements of your current physical workflow (full automation, viewing while on the go, accuracy equal to or exceeding ChatGPT search, ¥0 budget), here is the compiled System Requirements Specification and System Architecture Design.

Designed to meet the ¥0 budget constraint while replacing the entire manual workflow of “back-and-forth prompting,” “data formatting,” “manually pasting into programs,” and “execution” with code and cloud infrastructure.


System Requirements Specification

1. Overview

A system designed to fully automate the entire user workflow—from “market information gathering (technical, fundamental, and outlook)” to “data formatting,” “executing custom analysis programs,” “outputting scenarios and graphs,” and “reviewing results”—allowing users to check everything from smartphones or other devices on the go.

2. Functional Requirements

Item Requirement Implementation Method
① Scheduled Automatic Execution Start the process daily at a specified time (e.g., after stock market close) without human intervention. Utilize cloud scheduler functionality.
② Market Info Gathering & Analysis Comprehensively gather and analyze technical, fundamental, and outlook information with accuracy equal to or higher than current ChatGPT search capabilities. Utilize the latest LLM API equipped with web search grounding.
③ Automated Data Formatting Automatically convert the vast amount of collected text into a Python-compatible data format directly readable by custom analysis programs (eliminating manual text editor editing). Implement LLM Structured Outputs (JSON, etc.) or parsing.
④ Custom Program Execution Automatically feed formatted data into two custom analysis programs and execute them. Integrate and execute as modules from within a Python script.
⑤ Result Output & Notification Automatically generate analysis outputs: “scenario candidate text” and “Matplotlib graph images (PNG)”. Output files directly within the script.
⑥ Remote Viewing Allow users to check the latest text and graph images from smartphones or PCs while away. Leverage automatic commits to the repository or free notification services.

3. Non-Functional Requirements

  • Budget: ¥0 (Use completely free tier infrastructure and APIs)
  • Analysis Accuracy: Maintain a level comparable to current ChatGPT search functionality (leveraging Google Search grounding).
  • Maintainability: Reuse the core logic of existing Python analysis programs as-is, wrapping only the pre-processing and post-processing with automation scripts.

System Architecture Design

1. Architecture Diagram & Technology Selection

To satisfy the ¥0 budget and full automation requirements, the following free cloud environments and APIs are adopted.

[GitHub Actions (cron: daily at set time)]
       │ (automated trigger)
       ▼
[Python Runtime Environment (GitHub Actions Runner)]
       ├─ 1. Information gathering: Google AI Studio (Gemini API + Search Grounding)
       ├─ 2. Data formatting: Gemini API (structuring into Python format)
       ├─ 3. Analysis execution: User's custom analysis programs ① & ②
       └─ 4. Save output: Auto-commit to GitHub repository (result text & matplotlib images)
       │
       ▼ (view via browser/app on smartphones, etc.)
[GitHub Repository (Private)]

Key Components and Roles

  • Execution Platform (Free): GitHub Actions

  • Provides scheduled execution (Cron triggers) and a Python runtime environment for free. The monthly free quota easily covers running 1–2 times daily.

  • Information Gathering & Formatting Engine (Free Tier): Google AI Studio (Gemini API)

  • A powerful “Google Search grounding (real-time web search)” feature, rivaling or exceeding current ChatGPT search, can be used on the free tier (API Key).

  • Replaces multiple back-and-forth prompt interactions and manual text editor editing with Python scripts and API integration (a few steps of programmatic processing).

  • Storage & Viewing Interface: GitHub Repository (Private)

  • The daily generated “scenario candidate text (Markdown, etc.)” and “Matplotlib graph images (.png)” are automatically committed (saved) from GitHub Actions to a private repository.

  • While on the go, simply opening the repository via a mobile browser or the official GitHub app allows you to view the latest text and graphs at any time.


2. Detailed Process Flow Design

  1. Trigger Launch (Scheduled Trigger)
  • The workflow triggers automatically at a set time every day based on GitHub Actions’ cron settings.
  1. Information Gathering Phase (Step 1)
  • The Python script calls the Gemini API. At that point, Google Search grounding is enabled to automatically retrieve technical, fundamental, and outlook information in a single query or across optimized multiple requests.
  1. Data Formatting Phase (Step 2)
  • The raw data obtained is fed back to the Gemini API via a prompt to automatically convert and parse it into “a format directly readable by custom programs, such as Python dictionaries or Pandas DataFrames.”
  1. Analysis Program Execution Phase (Step 3)
  • Passes the formatted data to the user’s custom Program ① (scenario candidate text output) and Program ② (Matplotlib rendering), and executes the programs.
  1. Save & Push Artifacts (Step 4)
  • Automatically commits and pushes the generated text files and images (.png) to the GitHub repository using Git commands.

3. Next Steps

Based on this architecture design, you can proceed to create the concrete Python code for actually building the system (the GitHub Actions configuration file .github/workflows/main.py and automation script templates).

I will adapt the scripts to match your current custom program interfaces and data structures (dictionaries, lists, CSVs, etc.), so please let me know if you need further assistance with integrating the code."
Here are the error codes:
When using web search with gemini3.1flash-lite:
Gemini API Call Failed:
429 RESOURCE_EXHAUSTED. {‘error’: {‘code’: 429, ‘message’: 'You exceeded your current quota, please check your plan and billing details. [omitted]}}
When using web search with gemini2.5flash-lite:
Gemini API Call Failed:
404 NOT_FOUND. {‘error’: {‘code’: 404, ‘message’: 'This model models/gemini-2.5-flash is no longer available to new users. Please update your code to use models/gemini-3.8-flash for the latest features and improvements. [omitted] ‘status’: ‘NOT_FOUND’}}