Skip to main content
Glama
GodisinHisHeaven

USCardForum MCP Server

get_user_replies

Fetch a user's replies across forum topics to analyze contributions, find shared experiences, and evaluate participation quality with paginated results.

Instructions

Fetch replies/posts made by a user in other topics.

Args:
    username: The user's handle
    offset: Pagination offset (0, 30, 60, ...)

Returns a list of UserAction objects with:
- topic_id: Which topic they replied to
- post_number: Their post number in that topic
- title: Topic title
- excerpt: Preview of their reply
- created_at: When they replied

Use this to:
- See a user's contributions across topics
- Find their data points and experiences
- Evaluate the quality of their participation

Paginate with offset in increments of 30.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
usernameYesThe user's handle
offsetNoPagination offset (0, 30, 60, ...)

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Implementation Reference

  • The core MCP tool handler for 'get_user_replies'. Decorated with @mcp.tool(), defines input schema via Annotated Fields (username: str, offset: int|None), and delegates to the DiscourseClient via get_client() to fetch the user's replies as a list of UserAction objects.
    @mcp.tool()
    def get_user_replies(
        username: Annotated[
            str,
            Field(description="The user's handle"),
        ],
        offset: Annotated[
            int | None,
            Field(default=None, description="Pagination offset (0, 30, 60, ...)"),
        ] = None,
    ) -> list[UserAction]:
        """
        Fetch replies/posts made by a user in other topics.
    
        Args:
            username: The user's handle
            offset: Pagination offset (0, 30, 60, ...)
    
        Returns a list of UserAction objects with:
        - topic_id: Which topic they replied to
        - post_number: Their post number in that topic
        - title: Topic title
        - excerpt: Preview of their reply
        - created_at: When they replied
    
        Use this to:
        - See a user's contributions across topics
        - Find their data points and experiences
        - Evaluate the quality of their participation
    
        Paginate with offset in increments of 30.
        """
        return get_client().get_user_replies(username, offset=offset)
  • Registration via import: Imports the get_user_replies tool function from users.py into the server_tools package namespace, making it available for re-export and use in the MCP server.
    from .users import (
        get_user_summary,
        get_user_topics,
        get_user_replies,
        get_user_actions,
        get_user_badges,
        get_user_following,
        get_user_followers,
        get_user_reactions,
        list_users_with_badge,
    )
  • Re-export of get_user_replies from server_tools in the main server entrypoint, ensuring the tool is available when the MCP server runs.
    from uscardforum.server_tools import (
        analyze_user,
        bookmark_post,
        compare_cards,
        find_data_points,
        get_all_topic_posts,
        get_categories,
        get_current_session,
        get_hot_topics,
        get_new_topics,
        get_notifications,
        get_top_topics,
        get_topic_info,
        get_topic_posts,
        get_user_actions,
        get_user_badges,
        get_user_followers,
        get_user_following,
        get_user_reactions,
        get_user_replies,
        get_user_summary,
        get_user_topics,
        list_users_with_badge,
        login,
        research_topic,
        resource_categories,
        resource_hot_topics,
        resource_new_topics,
        search_forum,
        subscribe_topic,
    )
  • Underlying API helper method in UsersAPI that implements get_user_replies by calling get_user_actions with filter=5 (replies). This is the logic layer called by the client.
    def get_user_replies(
        self,
        username: str,
        offset: int | None = None,
    ) -> list[UserAction]:
        """Fetch user's replies.
    
        Args:
            username: User handle
            offset: Optional pagination offset
    
        Returns:
            List of reply action objects
        """
        return self.get_user_actions(username, filter=5, offset=offset)
  • Client wrapper method in DiscourseClient that delegates get_user_replies to the UsersAPI instance, called by the MCP tool handler.
    def get_user_replies(
        self,
        username: str,
        offset: int | None = None,
    ) -> list[UserAction]:
        """Fetch user's replies.
    
        Args:
            username: User handle
            offset: Optional pagination offset
    
        Returns:
            List of reply action objects
        """
        return self._users.get_user_replies(username, offset=offset)

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.5/5.0
Behavior4/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It effectively describes the tool's behavior: it's a read-only fetch operation (implied by 'Fetch'), returns paginated results with specific increments of 30, and provides detailed information about the return format (UserAction objects with specific fields). The description doesn't mention rate limits, authentication requirements, or error conditions, but provides substantial behavioral context for a read operation.

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 well-structured and appropriately sized. It starts with the core purpose, then provides parameter details, return format, use cases, and pagination guidance. Every sentence adds value: the parameter section clarifies inputs, the return format section explains outputs, and the use cases provide practical guidance. No wasted words or redundant information.

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

Completeness5/5

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

Given that this is a read operation with no annotations, 100% schema coverage, and an output schema (implied by the detailed return format description), the description is complete. It covers purpose, parameters, return values, use cases, and pagination behavior. The output schema information in the description ('Returns a list of UserAction objects with...') compensates for the lack of formal output schema, making this description comprehensive for the tool's complexity.

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 100%, so the schema already fully documents both parameters. The description repeats the parameter information ('Args: username: The user's handle, offset: Pagination offset') without adding significant semantic value beyond what's in the schema. It does add the pagination increment detail ('in increments of 30'), which provides useful context but doesn't fundamentally change parameter understanding.

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 tool's purpose with specific verb ('Fetch') and resource ('replies/posts made by a user in other topics'), distinguishing it from sibling tools like get_user_topics (which likely gets topics created by a user) and get_user_actions (which might include broader actions beyond replies). The description explicitly mentions what makes this tool unique: focusing on user contributions across different topics.

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

Usage Guidelines5/5

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

The description provides explicit guidance on when to use this tool ('Use this to: See a user's contributions across topics, Find their data points and experiences, Evaluate the quality of their participation'). It distinguishes this from tools that might focus on a single topic (like get_topic_posts) or broader user actions (like get_user_actions), giving clear use cases without needing to explicitly list exclusions.

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