Framework for orchestrating role-playing, autonomous AI agents. By fostering collaborative intelligence, CrewAI empowers agents to work together seamlessly, tackling complex tasks.
feat: expose CrewAI Platform application catalog (#7383)
Vidit Ostwale1f3c4bdd4d3
diff --git a/lib/crewai-core/src/crewai_core/platform_apps.py b/lib/crewai-core/src/crewai_core/platform_apps.pynew file mode 100644index 000000000..5817fb412--- /dev/null+++ b/lib/crewai-core/src/crewai_core/platform_apps.py@@ -0,0 +1,25 @@+"""CrewAI Platform application catalog."""++from typing import Final, Literal, get_args+++PlatformApp = Literal[+ "asana",+ "box",+ "clickup",+ "github",+ "gmail",+ "google_calendar",+ "google_sheets",+ "hubspot",+ "jira",+ "linear",+ "notion",+ "salesforce",+ "shopify",+ "slack",+ "stripe",+ "zendesk",+]++PLATFORM_APPS: Final[tuple[str, ...]] = (*get_args(PlatformApp),)diff --git a/lib/crewai-tools/src/crewai_tools/tools/crewai_platform_tools/__init__.py b/lib/crewai-tools/src/crewai_tools/tools/crewai_platform_tools/__init__.pyindex 4eb9d7d43..89bb29366 100644--- a/lib/crewai-tools/src/crewai_tools/tools/crewai_platform_tools/__init__.py+++ b/lib/crewai-tools/src/crewai_tools/tools/crewai_platform_tools/__init__.py@@ -4,6 +4,8 @@ This module provides tools for integrating with various platform applicationsthrough the CrewAI platform API."""+from crewai_core.platform_apps import PLATFORM_APPS+from crewai_tools.tools.crewai_platform_tools.crewai_platform_action_tool import (CrewAIPlatformActionTool,)@@ -13,6 +15,7 @@ from crewai_tools.tools.crewai_platform_tools.crewai_platform_tools import (__all__ = [+ "PLATFORM_APPS","CrewAIPlatformActionTool","CrewaiPlatformTools",]diff --git a/lib/crewai-tools/tests/tools/crewai_platform_tools/test_constants.py b/lib/crewai-tools/tests/tools/crewai_platform_tools/test_constants.pynew file mode 100644index 000000000..c1080223c--- /dev/null+++ b/lib/crewai-tools/tests/tools/crewai_platform_tools/test_constants.py@@ -0,0 +1,22 @@+from crewai_core.platform_apps import PLATFORM_APPS+++def test_platform_apps_contains_supported_application_catalog() -> None:+ assert PLATFORM_APPS == (+ "asana",+ "box",+ "clickup",+ "github",+ "gmail",+ "google_calendar",+ "google_sheets",+ "hubspot",+ "jira",+ "linear",+ "notion",+ "salesforce",+ "shopify",+ "slack",+ "stripe",+ "zendesk",+ )diff --git a/lib/crewai/src/crewai/agents/agent_builder/base_agent.py b/lib/crewai/src/crewai/agents/agent_builder/base_agent.pyindex 49fad6aac..a4b0e6675 100644--- a/lib/crewai/src/crewai/agents/agent_builder/base_agent.py+++ b/lib/crewai/src/crewai/agents/agent_builder/base_agent.py@@ -9,6 +9,7 @@ import refrom typing import TYPE_CHECKING, Annotated, Any, Final, Literalimport uuid+from crewai_core.platform_apps import PlatformAppfrom pydantic import (UUID4,BaseModel,@@ -180,25 +181,6 @@ _SLUG_RE: Final[re.Pattern[str]] = re.compile()-PlatformApp = Literal[- "asana",- "box",- "clickup",- "github",- "gmail",- "google_calendar",- "google_sheets",- "hubspot",- "jira",- "linear",- "notion",- "salesforce",- "shopify",- "slack",- "stripe",- "zendesk",-]-PlatformAppOrAction = PlatformApp | str