Confluence Cross-Space Search Agent
Search across all Confluence spaces at once. Find relevant pages, read their content, and get organized results with summaries.
The Challenge
Confluence's built-in search returns dozens of results ranked by keyword match, not relevance. When information is spread across Engineering, Product, HR, and IT spaces, finding what you need means clicking through multiple results, reading pages that turn out to be irrelevant, and still not being sure you found everything.
What This Prompt Does
Search All Spaces
Queries every active Confluence space with multiple search variations to catch all relevant content
Read & Verify
Reads the actual page content to confirm relevance instead of relying on title matches alone
Summarize Content
Extracts brief summaries from each page so you know what it covers without opening it
Organize by Space
Groups results by space and ranks by relevance with links for quick navigation
The Prompt
The Prompt
Task
Use @Confluence/List SpacesName it "Confluence/List Spaces" and call it with @Confluence/List Spaces to enumerate all spaces, @Confluence/Search PagesName it "Confluence/Search Pages" and call it with @Confluence/Search Pages to find pages matching a topic across all spaces, @Confluence/Get PageName it "Confluence/Get Page" and call it with @Confluence/Get Page to read page content and verify relevance, and @Confluence/List ChildrenName it "Confluence/List Children" and call it with @Confluence/List Children to discover related child pages. Return a curated list of relevant pages organized by space with content summaries.
Input
The user provides:
- The topic, keyword, or question to search for (e.g., "deployment process", "how to request PTO")
- Maximum number of results to return (optional, defaults to 10)
- Spaces to exclude from search (optional)
Example: "Find everything we have about our deployment process across all Confluence spaces"
Context
Enumerate Available Spaces
- Use @Confluence/List SpacesName it "Confluence/List Spaces" and call it with @Confluence/List Spaces to get a list of all active spaces
- Filter out any spaces the user wants to exclude
- Note space names and keys for organizing results
Search Across Spaces
- Use @Confluence/Search Pages with CQLName it "Confluence/Search Pages with CQL" and call it with @Confluence/Search Pages with CQL to search for pages matching the topic across all spaces
- Search using multiple query variations to catch different phrasings
- Collect page IDs, titles, spaces, and last modified dates
Read and Verify Content
- Use @Confluence/Get PageName it "Confluence/Get Page" and call it with @Confluence/Get Page to read the body of top-matching pages
- Verify that the content is actually relevant to the search topic
- Extract key sections or summaries from each page
- Use @Confluence/List ChildrenName it "Confluence/List Children" and call it with @Confluence/List Children to check if matching pages have related sub-pages
Organize Results
- Group results by space for easy navigation
- Rank pages by relevance based on content analysis
- Include a brief summary of what each page covers
- Note any related child pages that might also be useful
Output
Cross-Space Search Results
Query: [search topic] Spaces Searched: [count] Relevant Pages Found: [count]
Results by Space:
[Space Name 1]
-
[Page Title] (Last updated: [date])
- Summary: [2-3 sentence summary of content]
- Child pages: [count if any]
- URL: [link]
-
[Page Title] (Last updated: [date])
- Summary: [2-3 sentence summary]
- URL: [link]
[Space Name 2]
- [Page Title] (Last updated: [date])
- Summary: [2-3 sentence summary]
- URL: [link]
Most Relevant: [Top 3 pages with brief explanation of why they best answer the query]
Example Usage
Try asking:
- →"Find everything we have about our deployment process across all Confluence spaces"
- →"Search for PTO and time-off policies across HR, Engineering, and Operations spaces"
- →"What do we have documented about our API authentication flow?"