create_project
Enables AI systems to initiate new project setups by connecting to Taiga. Requires session ID, project name, description, and additional parameters for streamlined project creation.
Instructions
Creates a new project.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| description | Yes | ||
| kwargs | Yes | ||
| name | Yes | ||
| session_id | Yes |
Implementation Reference
- src/server.py:182-204 (handler)The handler function decorated with @mcp.tool that implements the core logic for creating a new Taiga project using the authenticated client.@mcp.tool("create_project", description="Creates a new project.") def create_project(session_id: str, name: str, description: str, **kwargs) -> Dict[str, Any]: """Creates a new project. Requires name and description. Optional args (e.g., is_private) via kwargs.""" logger.info( f"Executing create_project '{name}' for session {session_id[:8]} with data: {kwargs}") taiga_client_wrapper = _get_authenticated_client(session_id) if not name or not description: raise ValueError("Project name and description are required.") try: # Use pytaigaclient syntax: client.projects.create(name=..., description=..., **kwargs) new_project = taiga_client_wrapper.api.projects.create( name=name, description=description, **kwargs ) logger.info(f"Project '{name}' created successfully (ID: {new_project.get('id', 'N/A')}).") return new_project # Return the created project dict except TaigaException as e: logger.error( f"Taiga API error creating project '{name}': {e}", exc_info=False) raise e except Exception as e: logger.error( f"Unexpected error creating project '{name}': {e}", exc_info=True) raise RuntimeError(f"Server error creating project: {e}")