Skip to main content
Glama

delete_issue

Remove an issue by its ID from Taiga project management using the Taiga MCP Bridge, ensuring efficient issue management and streamlined workflows.

Instructions

Deletes an issue by its ID.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
issue_idYes
session_idYes

Implementation Reference

  • The handler function that implements the logic for the 'delete_issue' MCP tool. It validates the session, retrieves the Taiga client wrapper, and deletes the specified issue using the Taiga API.
    @mcp.tool("delete_issue", description="Deletes an issue by its ID.") def delete_issue(session_id: str, issue_id: int) -> Dict[str, Any]: """Deletes an issue by ID.""" logger.warning( f"Executing delete_issue ID {issue_id} for session {session_id[:8]}...") taiga_client_wrapper = _get_authenticated_client(session_id) # Use wrapper variable name try: # Use pytaigaclient syntax: client.resource.delete(id=...) taiga_client_wrapper.api.issues.delete(id=issue_id) logger.info(f"Issue {issue_id} deleted successfully.") return {"status": "deleted", "issue_id": issue_id} except TaigaException as e: logger.error( f"Taiga API error deleting issue {issue_id}: {e}", exc_info=False) raise e except Exception as e: logger.error( f"Unexpected error deleting issue {issue_id}: {e}", exc_info=True) raise RuntimeError(f"Server error deleting issue: {e}")
  • Helper function used by delete_issue (and other tools) to retrieve and validate the authenticated Taiga client 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:723-723 (registration)
    The @mcp.tool decorator registers the delete_issue function as an MCP tool.
    @mcp.tool("delete_issue", description="Deletes an issue by its 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