Skip to main content
Glama

set_goal

Define and track personal objectives with specific timeframes and categories to organize progress and maintain focus on productivity goals.

Instructions

Set a new goal.

Args: goal: The goal description timeframe: When you want to achieve this (e.g., 'this week', 'this month', 'long-term') category: Category of the goal (e.g., 'career', 'health', 'personal', 'general')

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
goalYes
timeframeYes
categoryNogeneral

Implementation Reference

  • The actual implementation of the set_goal tool logic which interacts with the database.
    async def set_goal(goal: str, timeframe: str, category: str = "general") -> str:
        """Set a new goal.
    
        Args:
            goal: The goal description
            timeframe: When you want to achieve this
            category: Category of the goal
    
        Returns:
            Success message
        """
        db = await get_db()
    
        await db.execute(
            "INSERT INTO goals (goal, timeframe, category) VALUES (?, ?, ?)",
            (goal, timeframe, category),
        )
        await db.commit()
    
        return f"✓ Set goal: {goal} ({timeframe}, {category})"
  • Registration of the set_goal tool using @mcp.tool() and delegation to the storage handler.
    @mcp.tool()
    async def set_goal(goal: str, timeframe: str, category: str = "general") -> str:
        """Set a new goal.
    
        Args:
            goal: The goal description
            timeframe: When you want to achieve this (e.g., 'this week', 'this month', 'long-term')
            category: Category of the goal (e.g., 'career', 'health', 'personal', 'general')
        """
        return await storage.set_goal(goal, timeframe, category)

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/94aharris/coach-ai'

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