Skip to main content
Glama

get_recent_wiki_pages

Retrieve recently modified wiki pages from Azure DevOps projects to track documentation updates and team activity.

Instructions

Get recently modified wiki pages based on activity.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
projectYesThe name or ID of the project.
wiki_identifierYesThe name or ID of the wiki.
limitNoMaximum number of pages to return (default: 10).

Implementation Reference

  • The primary handler function that implements the tool logic: retrieves all wiki pages, annotates with latest view activity as a proxy for recency, sorts descending by activity date, and returns the top 'limit' pages.
    def get_recent_wiki_pages(self, project, wiki_identifier, limit=10): """ Get recently modified wiki pages. """ pages = self.list_wiki_pages(project, wiki_identifier) # Sort by view stats if available (proxy for recent activity) pages_with_activity = [] for page in pages: if page.get("view_stats"): latest_activity = max(page["view_stats"], key=lambda x: x["date"]) if page["view_stats"] else None pages_with_activity.append({ **page, "latest_activity": latest_activity }) else: pages_with_activity.append({ **page, "latest_activity": None }) # Sort by latest activity date pages_with_activity.sort( key=lambda x: x["latest_activity"]["date"] if x["latest_activity"] else "1900-01-01", reverse=True ) return pages_with_activity[:limit]
  • Input schema defining parameters: project (required string), wiki_identifier (required string), limit (optional integer, default 10).
    inputSchema={ "type": "object", "properties": { "project": { "type": "string", "description": "The name or ID of the project." }, "wiki_identifier": { "type": "string", "description": "The name or ID of the wiki." }, "limit": { "type": "integer", "description": "Maximum number of pages to return (default: 10)." }, }, "required": ["project", "wiki_identifier"], "additionalProperties": False }
  • Tool registration in the self.tools list, including name, description, and schema. Exposed via list_tools() handler.
    name="get_recent_wiki_pages", description="Get recently modified wiki pages based on activity.", inputSchema={ "type": "object", "properties": { "project": { "type": "string", "description": "The name or ID of the project." }, "wiki_identifier": { "type": "string", "description": "The name or ID of the wiki." }, "limit": { "type": "integer", "description": "Maximum number of pages to return (default: 10)." }, }, "required": ["project", "wiki_identifier"], "additionalProperties": False } ),
  • Dispatch handler in call_tool that proxies arguments to the client method.
    elif name == "get_recent_wiki_pages": return self.client.get_recent_wiki_pages(**arguments)
  • Helper method called by get_recent_wiki_pages to fetch wiki pages with view_stats used for sorting recency.
    def list_wiki_pages(self, project, wiki_identifier): pages_batch_request = WikiPagesBatchRequest( top=100 # Retrieve up to 100 pages ) pages = self.wiki_client.get_pages_batch( project=project, wiki_identifier=wiki_identifier, pages_batch_request=pages_batch_request ) return [ { "path": page.path, "url": getattr(page, 'url', ''), # Handle missing url attribute "view_stats": [ {"date": stat.date.isoformat(), "count": stat.count} for stat in page.view_stats ] if page.view_stats else [] } for page in pages ]

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/xrmghost/mcp-azure-devops'

If you have feedback or need assistance with the MCP directory API, please join our Discord server