Skip to main content
Glama
taylorwilsdon

Google Workspace MCP Server - Control Gmail, Calendar, Docs, Sheets, Slides, Chat, Forms & Drive

create_form

Generate a new Google Form with a specified title, description, and document tab title using user's Google email. Returns form ID and edit URL for immediate access.

Instructions

Create a new form using the title given in the provided form message in the request.

Args:
    user_google_email (str): The user's Google email address. Required.
    title (str): The title of the form.
    description (Optional[str]): The description of the form.
    document_title (Optional[str]): The document title (shown in browser tab).

Returns:
    str: Confirmation message with form ID and edit URL.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
descriptionNo
document_titleNo
serviceYes
titleYes
user_google_emailYes

Implementation Reference

  • The handler function for the 'create_form' tool. It is registered via the @server.tool() decorator and implements the logic to create a new Google Form using the Google Forms API, handling title, description, and document_title parameters.
    @server.tool()
    @handle_http_errors("create_form", service_type="forms")
    @require_google_service("forms", "forms")
    async def create_form(
        service,
        user_google_email: str,
        title: str,
        description: Optional[str] = None,
        document_title: Optional[str] = None
    ) -> str:
        """
        Create a new form using the title given in the provided form message in the request.
    
        Args:
            user_google_email (str): The user's Google email address. Required.
            title (str): The title of the form.
            description (Optional[str]): The description of the form.
            document_title (Optional[str]): The document title (shown in browser tab).
    
        Returns:
            str: Confirmation message with form ID and edit URL.
        """
        logger.info(f"[create_form] Invoked. Email: '{user_google_email}', Title: {title}")
    
        form_body: Dict[str, Any] = {
            "info": {
                "title": title
            }
        }
    
        if description:
            form_body["info"]["description"] = description
    
        if document_title:
            form_body["info"]["document_title"] = document_title
    
        created_form = await asyncio.to_thread(
            service.forms().create(body=form_body).execute
        )
    
        form_id = created_form.get("formId")
        edit_url = f"https://docs.google.com/forms/d/{form_id}/edit"
        responder_url = created_form.get("responderUri", f"https://docs.google.com/forms/d/{form_id}/viewform")
    
        confirmation_message = f"Successfully created form '{created_form.get('info', {}).get('title', title)}' for {user_google_email}. Form ID: {form_id}. Edit URL: {edit_url}. Responder URL: {responder_url}"
        logger.info(f"Form created successfully for {user_google_email}. ID: {form_id}")
        return confirmation_message
  • Registration of the 'create_form' tool using the @server.tool() decorator.
    @server.tool()
  • Input schema defined by function parameters with type hints and detailed docstring describing args and return type.
    async def create_form(
        service,
        user_google_email: str,
        title: str,
        description: Optional[str] = None,
        document_title: Optional[str] = None
    ) -> str:
        """
        Create a new form using the title given in the provided form message in the request.
    
        Args:
            user_google_email (str): The user's Google email address. Required.
            title (str): The title of the form.
            description (Optional[str]): The description of the form.
            document_title (Optional[str]): The document title (shown in browser tab).
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 states the tool creates a form and returns a confirmation message with form ID and edit URL, which covers basic behavior. However, it lacks details on permissions needed, whether the form is editable, rate limits, error handling, or other behavioral traits. For a creation tool with zero annotation coverage, this is insufficient.

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

Conciseness4/5

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

The description is appropriately sized and front-loaded with the purpose in the first sentence. The Args and Returns sections are structured clearly. However, the first sentence is somewhat redundant with the tool name, and the parameter descriptions could be more concise.

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

Completeness2/5

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

Given the complexity of a creation tool with 5 parameters, 0% schema coverage, no annotations, and no output schema, the description is incomplete. It lacks details on behavioral traits, omits a required parameter, and doesn't provide sufficient context for safe and effective use. The return value is described but without schema support.

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?

Schema description coverage is 0%, so the description must compensate. It lists and describes 4 parameters (user_google_email, title, description, document_title) out of 5 total parameters, adding meaning beyond the schema. However, it omits the 'service' parameter entirely, which is required. The description partially compensates but leaves a critical parameter undocumented.

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

Purpose4/5

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

The description clearly states the tool's purpose: 'Create a new form using the title given in the provided form message in the request.' This specifies the verb ('Create') and resource ('form'), though it doesn't explicitly differentiate from sibling tools like create_doc or create_sheet. The description is clear but lacks sibling differentiation.

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

Usage Guidelines2/5

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

The description provides no guidance on when to use this tool versus alternatives like create_doc or create_sheet. It doesn't mention prerequisites, context, or exclusions. The only implicit usage is based on the tool name, but no explicit guidelines are provided.

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

Related 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/taylorwilsdon/google_workspace_mcp'

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