Thx for the quick response. Looks like the filtering logic I had put to skip the Jira tools was causing the issue. Now I am just passing the entire tools and this seems to be working
from crewai_tools import MCPServerAdapter
from crewai import Agent, Task, Crew, LLM
server_params = {"url": "http://mcp-server:9000/sse"}
#confluence_tools = None
#with MCPServerAdapter(server_params) as all_tools:
# Filter to only get Confluence tools
#confluence_tools = [tool for tool in all_tools if tool.name.startswith('confluence_')]
#print(f"Available Confluence tools: {[tool.name for tool in confluence_tools]}")
confluence_tools = MCPServerAdapter(server_params)
confluence_fetcher = Agent(
role="Confluence Content Retriever",
goal="Fetch and deliver content from specified Confluence pages",
backstory="""I'm a straightforward content retriever that connects to Atlassian MCP server
to fetch Confluence page content. I don't analyze or interpret the content - I simply retrieve
it accurately and deliver it in a clean format.""",
**tools=confluence_tools.tools**,
verbose=False,
memory=False, # Simple fetching doesn't require memory
llm=LLM(
model="openai/aiwb/llama-8b",
temperature=0.1, # Low temperature for consistent, predictable responses
max_tokens=1000,
extra_headers={
"X-TFY-METADATA": '{"tfy_log_request":"true"}'
}
)
)
Below is the Actual output of a run that is able to retrieve the confluence page
🚀 Crew: crew
└── 📋 Task: c368f288-795f-4dbd-a394-8e77c94fbee2
Status: Executing Task...
└── 🤖 Agent: Confluence Content Retriever
Status: In Progress
# Agent: Confluence Content Retriever
## Task:
OBJECTIVE:
Fetch the specified Confluence page and create a clear, concise summary of its contents.
PAGE TO FETCH:
- Page ID: {975512419}
REQUIREMENTS:
1. Retrieve the full content of the specified Confluence page using the page_id and space_key
2. Create a concise summary (300-500 words) highlighting the main points
3. Extract key concepts and terminology
4. Note any important technical details or specifications
5. Format the output in a clear, readable structure
Keep the summary factual and focused on the most important information from the page.
🤖 Agent: Confluence Content Retriever
Status: In Progress
└── 🧠 Thinking...
🤖 Agent: Confluence Content Retriever
Status: In Progress
🤖 Agent: Confluence Content Retriever
Status: In Progress
args ()
kwargs {'page_id': '975512419', 'title': '', 'space_key': '', 'include_metadata': True, 'convert_to_markdown': True}
# Agent: Confluence Content Retriever
## Thought: Thought: To fetch the specified Confluence page and create a summary of its contents, I will first use the `confluence_get_page` tool to retrieve the page content using the provided page ID.
## Using tool: confluence_get_page
## Tool Input:
"{\"page_id\": \"975512419\", \"include_metadata\": true, \"convert_to_markdown\": true}"
## Tool Output:
{
"metadata": {
"id": "975512419",
"title": "AI-Workbench on MKS (HLD/LLD)",
"type": "page",
"created": "",
"updated": "",
"url": "https://confluence.mastercard.int/pages/viewpage.action?pageId=975512419",
"space": {
"key": "ORBT",
"name": "ONE Review Boards: Standard Governance"
},
......
......