Skip to main content
Glama
isiahw1

mcp-server-bing-webmaster

add_page_preview_block

Prevent rich snippets from appearing in search results by adding a page preview block through Bing Webmaster Tools.

Instructions

Add a page preview block to prevent rich snippets.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
site_urlYes
block_urlYes
block_typeNoPage

Implementation Reference

  • The @mcp.tool decorator registers the tool, and the async function implements the handler logic by making a POST request to Bing Webmaster API's AddPagePreviewBlock endpoint to block page previews for the specified URL or pattern.
    @mcp.tool( name="add_page_preview_block", description="Add a page preview block to prevent rich snippets.", ) async def add_page_preview_block( site_url: Annotated[str, "The URL of the site"], block_url: Annotated[str, "URL or pattern to block"], block_type: Annotated[str, "Type of block"] = "Page", ) -> Dict[str, str]: """ Add a page preview block to prevent rich snippets. Args: site_url: The URL of the site block_url: URL or pattern to block block_type: Type of block (default: Page) Returns: Success message """ async with api: await api._make_request( "AddPagePreviewBlock", "POST", {"siteUrl": site_url, "blockUrl": block_url, "blockType": block_type}, ) return {"message": f"Page preview block for {block_url} added successfully"}
  • Registration of the add_page_preview_block tool using the @mcp.tool decorator with name and description.
    @mcp.tool( name="add_page_preview_block", description="Add a page preview block to prevent rich snippets.", )

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/isiahw1/mcp-server-bing-webmaster'

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