Skip to main content
Glama
study-flamingo

D&D MCP Server

create_quest

Generate structured quests for D&D campaigns by defining objectives, rewards, givers, and narrative details to organize adventure content.

Instructions

Create a new quest.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
titleYesQuest title
descriptionYesQuest description
giverNoQuest giver (NPC name)
objectivesNoQuest objectives
rewardNoQuest reward
notesNoAdditional notes

Implementation Reference

  • The main handler function for the 'create_quest' tool. It is registered via the @mcp.tool decorator, defines the input schema using Pydantic's Annotated and Field, creates a Quest model instance, and persists it using the storage layer.
    @mcp.tool
    def create_quest(
        title: Annotated[str, Field(description="Quest title")],
        description: Annotated[str, Field(description="Quest description")],
        giver: Annotated[str | None, Field(description="Quest giver (NPC name)")] = None,
        objectives: Annotated[list[str] | None, Field(description="Quest objectives")] = None,
        reward: Annotated[str | None, Field(description="Quest reward")] = None,
        notes: Annotated[str, Field(description="Additional notes")] = "",
    ) -> str:
        """Create a new quest."""
        quest = Quest(
            title=title,
            description=description,
            giver=giver,
            objectives=objectives or [],
            reward=reward,
            notes=notes
        )
    
        storage.add_quest(quest)
        return f"Created quest '{quest.title}'"

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/study-flamingo/gamemaster-mcp'

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