Skip to main content
Glama

logout

Terminate the active session by invalidating the session ID on the Taiga MCP Bridge, ensuring secure disconnection from the Taiga project management platform.

Instructions

Invalidates the current session_id.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
session_idYes

Implementation Reference

  • The handler function for the 'logout' tool. It invalidates the session by removing the corresponding TaigaClientWrapper from the global active_sessions dictionary and returns a status message.
    @mcp.tool("logout", description="Invalidates the current session_id.") def logout(session_id: str) -> Dict[str, Any]: """Logs out the current session, invalidating the session_id.""" logger.info(f"Executing logout for session {session_id[:8]}...") # Remove from dict, return None if not found client_wrapper = active_sessions.pop(session_id, None) # Use consistent var name if client_wrapper: logger.info(f"Session {session_id[:8]} logged out successfully.") # No specific API logout call needed usually for token-based auth return {"status": "logged_out", "session_id": session_id} else: logger.warning( f"Attempted to log out non-existent session: {session_id}") return {"status": "session_not_found", "session_id": session_id}
  • Global dictionary that stores active sessions mapping session_id to TaigaClientWrapper instances. Used by logout to invalidate sessions.
    active_sessions: Dict[str, TaigaClientWrapper] = {}
  • The @mcp.tool decorator registers the logout function as an MCP tool.
    @mcp.tool("logout", description="Invalidates the current session_id.")

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