subscribe_topic
Set notification preferences for USCardForum topics to control when you receive alerts. Choose from muted, normal, tracking, or watching levels to manage forum updates.
Instructions
Set your notification level for a topic. REQUIRES AUTHENTICATION.
Args:
topic_id: The topic ID to subscribe to
level: Notification level:
- 0: Muted (no notifications)
- 1: Normal (only if mentioned)
- 2: Tracking (notify on replies to your posts)
- 3: Watching (notify on all new posts)
Must call login() first.
Returns a SubscriptionResult with:
- success: Whether subscription succeeded
- notification_level: The new notification level
Use to:
- Watch topics for all updates (level=3)
- Mute noisy topics (level=0)
- Track topics you've contributed to (level=2)
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| topic_id | Yes | The topic ID to subscribe to | |
| level | No | Notification level: 0=muted, 1=normal, 2=tracking (default), 3=watching |
Implementation Reference
- MCP tool handler for 'subscribe_topic'. Decorated with @mcp.tool(), defines input schema (topic_id: int, level: int=2), detailed docstring, and delegates execution to get_client().subscribe_topic() returning SubscriptionResult.@mcp.tool() def subscribe_topic( topic_id: Annotated[ int, Field(description="The topic ID to subscribe to"), ], level: Annotated[ int, Field( default=2, description="Notification level: 0=muted, 1=normal, 2=tracking (default), 3=watching", ), ] = 2, ) -> SubscriptionResult: """ Set your notification level for a topic. REQUIRES AUTHENTICATION. Args: topic_id: The topic ID to subscribe to level: Notification level: - 0: Muted (no notifications) - 1: Normal (only if mentioned) - 2: Tracking (notify on replies to your posts) - 3: Watching (notify on all new posts) Must call login() first. Returns a SubscriptionResult with: - success: Whether subscription succeeded - notification_level: The new notification level Use to: - Watch topics for all updates (level=3) - Mute noisy topics (level=0) - Track topics you've contributed to (level=2) """ return get_client().subscribe_topic(topic_id, level=level)
- src/uscardforum/server_tools/__init__.py:52-58 (registration)Re-exports the subscribe_topic tool from .auth module, making it available for import in the server_tools package.from .auth import ( login, get_current_session, get_notifications, bookmark_post, subscribe_topic, )
- src/uscardforum/server.py:43-45 (registration)Imports subscribe_topic from server_tools in the MCP server entrypoint, ensuring the tool is registered when the server runs.search_forum, subscribe_topic, )