Skip to content

Ollama Web Search

The Ollama Web Search component lets you ask the internet for information directly from your Nappai dashboard. Just type a question or keyword, set how many results you want, and the component will fetch the latest web pages for you. It’s useful for gathering up‑to‑date facts, news, or any data that isn’t already in your own databases.

How it Works

When you run the component, it sends a request to the Ollama Cloud web‑search API. The API looks up the query you provided, pulls the most relevant pages, and returns a list of results. The component then packages those results into two outputs:

  • Data – a structured list of search results that can be used by other components in your workflow.
  • Tool – a ready‑to‑use tool that an AI agent can call to perform the same search on demand.

Because the component talks to an external service, you need to supply an Ollama Cloud API credential. The credential holds your API key, which the component uses to authenticate with Ollama Cloud.

Inputs

Mapping Mode

This component has a special mode called “Mapping Mode”. When you enable this mode using the toggle switch, an additional input called “Mapping Data” is activated, and each input field offers you three different ways to provide data:

  • Fixed: You type the value directly into the field.
  • Mapped: You connect the output of another component to use its result as the value.
  • Javascript: You write Javascript code to dynamically calculate the value.

This flexibility allows you to create more dynamic and connected workflows.

Input Fields

The following fields are available to configure this component. Each field may be visible in different operations:

  • Search Query: The search query to execute.
  • Limit: The number of results to return (between 1 and 10).
  • Mapping Mode: Enable mapping mode to process multiple data records in batch.
  • Tool Name: The name of the tool that will be used when this component is connected as a tool. This name will be displayed to the agent when it selects tools to use.
  • Tool Description: A detailed description of what this tool does. This description will help the agent understand when and how to use this tool effectively.
  • Tools arguments metadata: Defines the arguments metadata for the tools.

Credential – This component requires a credential of type Ollama Cloud API.

  1. Configure the credential in the Nappai credentials section.
  2. Select that credential in the component’s “Credential” field.
    The credential contains your Ollama Cloud API Key, which you can obtain from the Ollama Cloud Console.

Outputs

  • Data – A structured list of search results returned by the Ollama Cloud API.
  • Tool – A tool object that can be passed to an AI agent so it can perform the same search on demand.

Usage Example

  1. Add the component to your workflow.
  2. Set the Search Query to “latest AI trends”.
  3. Set Limit to 5.
  4. Enable Mapping Mode if you want to run the search for many queries at once.
  5. Configure the Credential as described above.
  6. Run the workflow.
    The component will return the top 5 web pages about AI trends in the Data output, and you can also expose the search as a tool for agents via the Tool output.
  • Ollama Cloud Text Generation – Generate natural‑language responses using Ollama Cloud.
  • Ollama Cloud Image Generation – Create images from text prompts with Ollama Cloud.

Tips and Best Practices

  • Keep the Limit low (1‑5) for quick responses; higher values increase API usage and latency.
  • Use Mapping Mode to run the same search across many records without duplicating components.
  • Choose a clear Tool Name (e.g., “WebSearch”) so agents can easily identify it.
  • Store your API key in a credential and never expose it in the workflow UI.

Security Considerations

  • The Ollama Cloud API key is sensitive; store it in a credential and restrict access to the component.
  • Avoid exposing the API key in logs or output fields.
  • Use the component only in trusted workflows to prevent accidental data leaks.