Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,9 @@ import { Steps, Tabs, Callout } from "nextra/components";

# Use Arcade tools with CrewAI

[CrewAI](https://www.crewai.com/) is an agentic framework optimized for building task-oriented multi-agent systems. This guide explains how to integrate Arcade tools into your CrewAI applications.
This guide explains how to integrate Arcade tools into your CrewAI applications.

[CrewAI](https://www.crewai.com/) is an agentic framework optimized for building task-oriented multi-agent systems. You'll learn to retrieve Arcade tools, convert them to CrewAI format, and build an agent that uses Arcade tools for Gmail and Slack integration. This integration enables just-in-time tool authorization and provides a complete solution for CrewAI applications that need external service connectivity.

<GuideOverview>
<GuideOverview.Outcomes>
Expand Down Expand Up @@ -120,21 +122,21 @@ This includes many imports, here's a breakdown:

### Configure the agent

The rest of the code uses these variables to customize the agent and manage the tools. Feel free to configure them to your liking. Here, the `EventListener` class is used to suppress CrewAI's rich panel output, which is useful for debugging but verbose for an interactive session like the one you're building.
The rest of the code uses these variables to customize the agent and manage the tools. Feel free to configure them to your liking. Here, the `EventListener` class suppresses CrewAI's rich panel output, which is useful for debugging but verbose for an interactive session like the one you're building.

```python filename="main.py"
# Load environment variables from the .env file
load_dotenv()

# The Arcade User ID identifies who is authorizing each service.
ARCADE_USER_ID = os.getenv("ARCADE_USER_ID")
# This determines which MCP server is providing the tools, you can customize this to make a Notion agent. All tools from the MCP servers defined in the array will be used.
# This determines which MCP server provides the tools, you can customize this to make a Notion agent. All tools from the MCP servers defined in the array will work.
MCP_SERVERS = ["Slack"]
# This determines individual tools. Useful to pick specific tools when you don't need all of them.
TOOLS = ["Gmail_ListEmails", "Gmail_SendEmail", "Gmail_WhoAmI"]
# This determines the maximum number of tool definitions Arcade will return per MCP server
TOOL_LIMIT = 30
# This determines which LLM model will be used inside the agent
# This determines which LLM model will work inside the agent
MODEL = "openai/gpt-5-mini"
# The individual objective that guides the agent's decision-making
AGENT_GOAL = "Help the user with all their requests"
Expand Down Expand Up @@ -186,7 +188,7 @@ def _build_args_model(tool_def: ToolDefinition) -> type[BaseModel]:

### Write a custom class that extends the CrewAI BaseTool class

Here, you define the `ArcadeTool` class that extends the CrewAI `BaseTool` class to add the following capability:
Here, you define the `ArcadeTool` class that extends the CrewAI `BaseTool` class to add the following feature:

- Authorize the tool with the Arcade client with the `_auth_tool` helper function
- Execute the tool with the Arcade client with the `_run` method
Expand Down Expand Up @@ -245,7 +247,7 @@ class ArcadeTool(BaseTool):

### Retrieve Arcade tools and transform them into CrewAI tools

Here you get the Arcade tools you want the agent to utilize, and transform them into CrewAI tools. The first step is to initialize the Arcade client, and get the tools you want to work with.
Here you get the Arcade tools you want the agent to use, and transform them into CrewAI tools. The first step involves initializing the Arcade client, and getting the tools you want to work with.

Here's a breakdown of what it does for clarity:

Expand Down Expand Up @@ -352,7 +354,7 @@ You should see the agent responding to your prompts like any model, as well as h
## Tips for selecting tools

- **Relevance**: Pick only the tools you need. Avoid using all tools at once.
- **Avoid conflicts**: Be mindful of duplicate or overlapping functionality.
- **Avoid conflicts**: Be mindful of duplicate or overlapping capability.

## Next steps

Expand Down Expand Up @@ -383,13 +385,13 @@ load_dotenv()

# The Arcade User ID identifies who is authorizing each service.
ARCADE_USER_ID = os.getenv("ARCADE_USER_ID")
# This determines which MCP server is providing the tools, you can customize this to make a Notion agent. All tools from the MCP servers defined in the array will be used.
# This determines which MCP server provides the tools, you can customize this to make a Notion agent. All tools from the MCP servers defined in the array will work.
MCP_SERVERS = ["Slack"]
# This determines individual tools. Useful to pick specific tools when you don't need all of them.
TOOLS = ["Gmail_ListEmails", "Gmail_SendEmail", "Gmail_WhoAmI"]
# This determines the maximum number of tool definitions Arcade will return per MCP server
TOOL_LIMIT = 30
# This determines which LLM model will be used inside the agent
# This determines which LLM model will work inside the agent
MODEL = "openai/gpt-5-mini"
# The individual objective that guides the agent's decision-making
AGENT_GOAL = "Help the user with all their requests"
Expand Down Expand Up @@ -549,4 +551,4 @@ if __name__ == "__main__":

```

</details>
</details>
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,8 @@ import { Steps, Tabs, Callout } from "nextra/components";

# Setup Arcade with Google ADK (Python)

Learn how to integrate Arcade tools using Google ADK primitives to build an AI agent.

Google ADK is a modular framework for building and deploying AI agents. It optimizes for Gemini and the Google Ecosystem, but supports any model.

<GuideOverview>
Expand Down Expand Up @@ -145,7 +147,7 @@ This includes multiple imports, here's a breakdown:

### Configure the agent

These variables set the configuration for the rest of the code to customize the agent and manage the tools. Feel free to configure them to your liking. Set the `google_genai.types` logging level to `ERROR` to avoid a lot of noise in the console. Load the environment variables from the `.env` file using `load_dotenv()`.
These variables set the configuration for the rest of the code to customize the agent and manage the tools. Configure them to your liking. Set the `google_genai.types` logging level to `ERROR` to avoid a lot of noise in the console. Load the environment variables from the `.env` file using `load_dotenv()`.

```python filename="main.py"
logging.getLogger("google_genai.types").setLevel(logging.ERROR)
Expand All @@ -154,13 +156,13 @@ load_dotenv()

# The Arcade User ID identifies who is authorizing each service.
ARCADE_USER_ID = os.getenv("ARCADE_USER_ID")
# This determines which MCP server is providing the tools, you can customize this to make a Notion agent. All tools from the MCP servers defined in the array will be used.
# This determines which MCP server is providing the tools, you can customize this to make a Notion agent. All tools from the MCP servers defined in the array will be utilized.
MCP_SERVERS = ["Slack"]
# This determines individual tools. Useful to pick specific tools when you don't need all of them.
TOOLS = ["Gmail_ListEmails", "Gmail_SendEmail", "Gmail_WhoAmI"]
# This prompt defines the behavior of the agent.
MODEL = "gemini-2.5-flash"
# This determines which LLM model will be used inside the agent
# This determines which LLM model will be applied inside the agent
SYSTEM_PROMPT = "You are a helpful assistant that can assist with Gmail and Slack."
# This determines the name of the agent.
AGENT_NAME = "AwesomeAgent"
Expand Down Expand Up @@ -469,7 +471,7 @@ You should see the agent responding to your prompts like any model, as well as h
## Tips for selecting tools

- **Relevance**: Pick only the tools you need. Avoid utilizing all tools at once.
- **User identification**: Always provide a unique and consistent `user_id` for each user. Apply your internal or database user ID, not something entered by the user.
- **User identification**: Always provide a unique and consistent `user_id` for each user. Use your internal or database user ID, not something entered by the user.

## Next steps

Expand Down Expand Up @@ -510,13 +512,13 @@ load_dotenv()

# The Arcade User ID identifies who is authorizing each service.
ARCADE_USER_ID = os.getenv("ARCADE_USER_ID")
# This determines which MCP server is providing the tools, you can customize this to make a Notion agent. All tools from the MCP servers defined in the array will be used.
# This determines which MCP server is providing the tools, you can customize this to make a Notion agent. All tools from the MCP servers defined in the array will be utilized.
MCP_SERVERS = ["Slack"]
# This determines individual tools. Useful to pick specific tools when you don't need all of them.
TOOLS = ["Gmail_ListEmails", "Gmail_SendEmail", "Gmail_WhoAmI"]
# This prompt defines the behavior of the agent.
MODEL = "gemini-2.5-flash"
# This determines which LLM model will be used inside the agent
# This determines which LLM model will be applied inside the agent
SYSTEM_PROMPT = "You are a helpful assistant that can assist with Gmail and Slack."
# This determines the name of the agent.
AGENT_NAME = "AwesomeAgent"
Expand Down Expand Up @@ -759,4 +761,4 @@ if __name__ == '__main__':
asyncio.run(main())
```

</details>
</details>
Loading