Retriever GoogleCustomWebSearch

Retriever GoogleCustomWebSearch

Certified

Retrieve web results with Google Custom Search

Uses Google Custom Search (CSE) to fetch web snippets for RAG. Requires API key and CSE ID (csi/cx); maxResults limits returned items (default 3). Requests consume CSE quota.

yaml
type: io.kestra.plugin.ai.retriever.GoogleCustomWebSearch

RAG chat with a web search content retriever (answers grounded in search results)

yaml
id: rag
namespace: company.ai

tasks:
  - id: chat_with_rag_and_websearch_content_retriever
    type: io.kestra.plugin.ai.rag.ChatCompletion
    chatProvider:
      type: io.kestra.plugin.ai.provider.GoogleGemini
      modelName: gemini-3.5-flash-lite
      apiKey: "{{ secret('GEMINI_API_KEY') }}"
    contentRetrievers:
      - type: io.kestra.plugin.ai.retriever.GoogleCustomWebSearch
        apiKey: "{{ secret('GOOGLE_SEARCH_API_KEY') }}"
        csi: "{{ secret('GOOGLE_SEARCH_CSI') }}"
    prompt: What is the latest release of Kestra?
Installation

Our standard Docker images already include this plugin. If you use a -slim image or another setup, install it with the following command:

kestractl plugins get io.kestra.plugin:plugin-ai --compatible-for $KESTRA_VERSION

For kestractl, use your Kestra version with --compatible-for, or specify an exact plugin version.

For Kestra CLI, replace LATEST with a specific version or version range to pin the plugin version.

Properties

API key

Google Custom Search JSON API key. Store it as a Kestra secret rather than inline. No default: this property is required.

Custom Search Engine ID

Identifier of the Programmable Search Engine to query, referred to as cx in Google's documentation. No default: this property is required.

Default3

Maximum results

Number of search results retrieved for each query. Defaults to 3.