CrewAI Tools (original) (raw)

Last Updated : 1 May, 2026

CrewAI provides agents with specialized tools to perform specific tasks like web scraping, file management, database interaction and image generation. These tools enable agents to collect and process data from websites, manage files efficiently, interact with databases and generate visual content. By integrating these tools, CrewAI agents can perform task-specific actions autonomously while maintaining context within collaborative workflows.

To begin, we need to install the crewai_tools package by running the following command:

pip install crewai_tools

Listing Available Tools

We can list all the tools available in crewai_tools by running the following code:

Python `

from crewai_tools import tools

for i in dir(tools): print(i)

`

**Output:

AIMindTool
ApifyActorsTool
ArxivPaperTool
BraveSearchTool
BrightDataDatasetTool
BrightDataSearchTool
BrightDataWebUnlockerTool
...............

Tool Documentation and Usage

Each tool in CrewAI has detailed documentation. To explore the usage of any specific tool, such as ScrapeWebsiteTool, we can use the help() function in Python to view the tool’s description and available parameters. Here's an example of how to use it:

Python `

from crewai_tools import ScrapeWebsiteTool

help(ScrapeWebsiteTool)

`

**Output:

Help on class ScrapeWebsiteTool in module crewai_tools.tools.scrape_website_tool.scrape_website_tool:

class ScrapeWebsiteTool(crewai.tools.base_tool.BaseTool)
| ScrapeWebsiteTool(website_url: Optional[str] = None, cookies: Optional[dir......

Below are some popular tools in CrewAI, commonly used for tasks like web scraping, file management, database interaction and more.

1. RAG Tool (Retrieval-Augmented Generation)

is designed to combine retrieval and generation models. It first retrieves relevant documents from external sources and then generates meaningful responses by combining the retrieved data with the agent's built-in knowledge. This is useful when we need the agent to provide responses based on both prior knowledge and new data retrieved dynamically.

import os os.environ['OPENAI_API_KEY'] ="Your_API_Key"

from crewai_tools import RagTool

rag_tool = RagTool( name='Knowledge base', description='A knowledge base that can be used to answer questions.', result_as_answer=True,
summarize=True,
verbose=True )

response= rag_tool.run("What are the latest AI advancements?") print(response)

`

**Output:

Using Tool: Knowledge base
Relevant Content:
Recent advancements in AI have focused on several key areas..........

2. ScrapeWebsiteTool

Allows agents to extract and scrape content from websites. It works by scraping the raw HTML content of a page, extracting meaningful data from it.

import os os.environ['OPENAI_API_KEY'] ="Your_API_Key"

from crewai_tools import ScrapeWebsiteTool

scraper = ScrapeWebsiteTool(website_url="https://geeksforgeeks.org") response = scraper.run() print(response)

`

**Output:

Using Tool: Read website content
GeeksforGeeks | Your All-in-One Learning Portal Tutorials Courses Go Premium Data......

3. SerperDevTool

Helps agents retrieve relevant search results from the web. Unlike traditional scraping, it interacts directly with search engines (like Google) to pull search results in a structured format

from crewai_tools import SerperDevTool import os os.environ["SERPER_API_KEY"]="Your_SERPER_API_KEY" os.environ['OPENAI_API_KEY'] ="Your_API_Key"

serper_tool = SerperDevTool( name="Web Search Tool", description="A tool to perform web searches and retrieve search results.", verbose=True )

search_results = serper_tool.run(query="What are the latest AI advancements?")

print("Search Results:") print(search_results)

`

**Output:

Using Tool: Web Search Tool
Search Results:
{'searchParameters': {'q': 'What are the latest AI advancements?', 'type': 'sear...........

4. File Read Tool

The File Read Tool allow agents to read files which is useful when dealing with persistent storage or managing local files. These tools help agents interact with file systems for data extraction and creation.

import os os.environ['OPENAI_API_KEY'] ="Your_API_Key"

from crewai_tools import FileReadTool

file_reader = FileReadTool(file_path="/content/data.txt")

output = file_reader.run() print(output)

`

**Output:

Using Tool: Read a file's content
Hello Geeks!

5. DaLLE Tool

The DaLLE Tool is used to generate images based on textual descriptions. It integrates with OpenAI’s DALL-E model, allowing the agent to create unique and high-quality images from user-provided prompts.

import os os.environ['OPENAI_API_KEY'] ="Your_API_Key"

from crewai_tools import DallETool

dalle_tool = DallETool()

image_url = dalle_tool.run(image_description="A futuristic city skyline") print(image_url)

`

**Output:

Using Tool: Dall-E Tool
{"image_url": "https://oaidalleapiprodscus.blob.core.windows.net/priv..................