Skip to main content
Glama

get_site

Retrieve detailed Webflow site information by ID, including workspace, creation date, display name, and publishing details for site management.

Instructions

Retrieve detailed information about a specific Webflow site by ID, including workspace, creation date, display name, and publishing details

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
siteIdYesThe unique identifier of the Webflow site

Implementation Reference

  • The asynchronous handler function for the 'get_site' tool. It validates input using Zod, fetches the site details from Webflow API, formats the response, and handles specific errors like site not found.
    get_site: async (args: unknown) => {
      const { siteId } = schemas.toolInputs.getSite.parse(args);
    
      try {
        const webflow = new WebflowClient({ accessToken });
        const site = await webflow.sites.get(siteId);
    
        if (!site) {
          throw new Error("Site not found");
        }
    
        const formattedSite = `• Site Details:
              ID: ${site.id}
              Display Name: ${site.displayName}
              Short Name: ${site.shortName}
            
            - Workspace Information:
              Workspace ID: ${site.workspaceId}
            
            - Dates:
              Created On: ${formatDate(site?.createdOn)}
              Last Published: ${formatDate(site?.lastPublished)}
            
            - URLs:
              Preview URL: ${site.previewUrl || "N/A"}`;
    
        return {
          content: [
            {
              type: "text" as const,
              text: formattedSite,
            },
          ],
        };
      } catch (error: unknown) {
        if (isWebflowApiError(error) && error.code === "NOT_FOUND") {
          return {
            content: [
              {
                type: "text" as const,
                text: `Site with ID ${siteId} not found.`,
              },
            ],
          };
        }
        console.error("Error fetching site:", error);
        throw new Error("Failed to fetch site details");
      }
    },
  • src/index.ts:61-75 (registration)
    The tool registration/definition for 'get_site' in the TOOL_DEFINITIONS array, which is returned by the listTools handler. Includes name, description, and JSON input schema.
    {
      name: "get_site",
      description:
        "Retrieve detailed information about a specific Webflow site by ID, including workspace, creation date, display name, and publishing details",
      inputSchema: {
        type: "object",
        properties: {
          siteId: {
            type: "string",
            description: "The unique identifier of the Webflow site",
          },
        },
        required: ["siteId"],
      },
    },
  • Zod schema used for input validation inside the get_site handler.
    getSite: z.object({
      siteId: z.string().min(1, "Site ID is required"),
    }),
  • Helper utility function used to format dates in the site details response.
    function formatDate(date: Date | undefined | null): string {
      if (!date) return "N/A";
      return date.toLocaleString();
    }
  • Helper type guard function used to check for Webflow API errors in the handler.
    function isWebflowApiError(error: unknown): error is WebflowApiError {
      return error !== null && typeof error === "object" && "code" in error;
    }
Behavior2/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden. It describes the tool as a retrieval operation, which implies read-only behavior, but does not disclose other traits such as authentication requirements, rate limits, error handling, or response format. This leaves significant gaps for a tool with no annotation coverage.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single, well-structured sentence that efficiently conveys the tool's purpose and key details without unnecessary words. It is front-loaded with the main action and resource, making it easy to understand quickly.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's complexity (simple retrieval with one parameter), 100% schema coverage, but no output schema and no annotations, the description is adequate but incomplete. It covers the purpose and parameter semantics well, but lacks behavioral details like response format or error handling, which are important for a tool with no structured output information.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The input schema has 100% description coverage, with the parameter 'siteId' documented as 'The unique identifier of the Webflow site'. The description adds value by specifying that the tool retrieves information 'by ID', reinforcing the parameter's purpose, but does not provide additional syntax or format details beyond what the schema already covers.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the verb 'Retrieve' and the resource 'detailed information about a specific Webflow site by ID', with specific details like workspace, creation date, display name, and publishing details. It distinguishes from the sibling tool 'get_sites' by specifying retrieval for a single site rather than multiple sites.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description implies usage when detailed information for a specific site is needed, but does not explicitly state when to use this tool versus the sibling 'get_sites' or other alternatives. It provides clear context for retrieving site details by ID, but lacks explicit exclusions or comparisons.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

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/kapilduraphe/webflow-mcp-server'

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