Skip to main content
Glama

get_project_by_slug

Retrieve detailed project information using a unique slug to access its data in the Taiga project management platform through the MCP Bridge.

Instructions

Gets detailed information about a specific project by its slug.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
session_idYes
slugYes

Implementation Reference

  • The main handler function for the 'get_project_by_slug' tool. It authenticates the session, calls the Taiga API to get the project by slug, and handles errors.
    @mcp.tool("get_project_by_slug", description="Gets detailed information about a specific project by its slug.") def get_project_by_slug(session_id: str, slug: str) -> Dict[str, Any]: """Retrieves project details by slug.""" logger.info( f"Executing get_project_by_slug '{slug}' for session {session_id[:8]}...") taiga_client_wrapper = _get_authenticated_client(session_id) # Use wrapper variable name try: # Use pytaigaclient syntax: client.resource.get(slug=...) project = taiga_client_wrapper.api.projects.get(slug=slug) # return project.to_dict() # Remove .to_dict() return project # Return directly except TaigaException as e: logger.error( f"Taiga API error getting project by slug '{slug}': {e}", exc_info=False) raise e except Exception as e: logger.error( f"Unexpected error getting project by slug '{slug}': {e}", exc_info=True) raise RuntimeError(f"Server error getting project by slug: {e}")
  • Shared helper function used by get_project_by_slug (and other tools) to retrieve the authenticated Taiga client wrapper for the session.
    def _get_authenticated_client(session_id: str) -> TaigaClientWrapper: """ Retrieves the authenticated TaigaClientWrapper for a given session ID. Raises PermissionError if the session is invalid or not found. """ client = active_sessions.get(session_id) # Also check if the client object itself exists and is authenticated if not client or not client.is_authenticated: logger.warning(f"Invalid or expired session ID provided: {session_id}") # Raise PermissionError - FastMCP will map this to an appropriate error response raise PermissionError( f"Invalid or expired session ID: '{session_id}'. Please login again.") logger.debug(f"Retrieved valid client for session ID: {session_id}") return client
  • src/server.py:161-161 (registration)
    The @mcp.tool decorator registers the 'get_project_by_slug' function as an MCP tool.
    @mcp.tool("get_project_by_slug", description="Gets detailed information about a specific project by its slug.")

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/talhaorak/pytaiga-mcp'

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