get_crawl_issues
Identify URLs with crawl issues on your site to help Bing's crawler access and process pages correctly. This tool retrieves a list of problematic URLs for analysis and resolution.
Instructions
Get a list of URLs with crawl issues for a specific site.
This helps identify pages that Bing's crawler had trouble accessing or processing.
Args: site_url: The URL of the site
Returns: List[UrlWithCrawlIssues]: List of URLs with their associated crawl issues
Raises: BingWebmasterError: If issues cannot be retrieved
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| self | Yes | ||
| site_url | Yes |
Implementation Reference
- The async wrapper function generated by wrap_service_method that serves as the MCP tool handler for get_crawl_issues. It invokes the underlying crawling service's get_crawl_issues method.@mcp.tool() @wraps(original_method) async def wrapper(*args: Any, **kwargs: Any) -> Any: # Filter out any 'self' arguments that might be passed by the MCP client kwargs = {k: v for k, v in kwargs.items() if k != "self"} async with service as s: service_obj = getattr(s, service_attr) # Get the method from the instance method = getattr(service_obj, method_name) # Call the method directly - it's already bound to the instance return await method(*args, **kwargs) # Copy signature and docstring wrapper.__signature__ = new_sig # type: ignore wrapper.__doc__ = original_method.__doc__
- mcp_server_bwt/tools/bing_webmaster.py:148-148 (registration)Specific registration of the get_crawl_issues tool within the add_bing_webmaster_tools function.get_crawl_issues = wrap_service_method(mcp, service, "crawling", "get_crawl_issues") # noqa: F841
- mcp_server_bwt/main.py:16-17 (registration)Invokes the function that registers all Bing Webmaster tools, including get_crawl_issues, to the MCP server.# Add the tools to the MCP server add_bing_webmaster_tools(mcp, bing_service)
- Mapping of service names to classes, used by wrap_service_method to retrieve the original method signature and docstring for get_crawl_issues.# Map service attribute names to their corresponding service classes SERVICE_CLASSES = { "sites": site_management.SiteManagementService, "submission": submission.SubmissionService, "traffic": traffic_analysis.TrafficAnalysisService, "crawling": crawling.CrawlingService, "keywords": keyword_analysis.KeywordAnalysisService, "links": link_analysis.LinkAnalysisService, "content": content_management.ContentManagementService, "blocking": content_blocking.ContentBlockingService, "regional": regional_settings.RegionalSettingsService, "urls": url_management.UrlManagementService, }
- Initialization of the crawling service instance within BingWebmasterService, which provides the get_crawl_issues method.self.traffic = traffic_analysis.TrafficAnalysisService(self.client) self.crawling = crawling.CrawlingService(self.client)