This document provides instructions for starting and stopping the Multi-Agent Canvas application, which consists of a frontend (Next.js) and a backend (MCP Agent).
Before starting the application, ensure you have the following installed:
- Poetry for Python dependency management
- PNPM for Node.js dependency management
- Node.js (v18 or later)
- Python (v3.10 or later)
You have two options for starting the application:
- Double-click the
start-app.batfile - Two command windows will open - one for the backend and one for the frontend
- Wait for both services to initialize
- Right-click on
start-app.ps1and select "Run with PowerShell" - The script will:
- Check if all prerequisites are installed
- Start the backend and verify it's running
- Start the frontend and verify it's running
- Verify the integration between frontend and backend
- Display the URLs for accessing the application
Once both services are running, you can access:
- Frontend: http://localhost:3000
- Backend API: http://localhost:8123
- Backend Health: http://localhost:8123/health
- API Documentation: http://localhost:8123/docs
You have two options for stopping the application:
- Double-click the
stop-app.batfile - The script will terminate all related processes
- Right-click on
stop-app.ps1and select "Run with PowerShell" - The script will:
- Identify and stop all frontend processes
- Identify and stop all backend processes
- Close any remaining terminal windows
If you encounter issues:
-
Backend fails to start:
- Check if port 8123 is already in use
- Verify that Poetry is installed correctly
- Check the backend terminal for specific error messages
-
Frontend fails to start:
- Check if port 3000 is already in use
- Verify that PNPM is installed correctly
- Check the frontend terminal for specific error messages
-
Connection issues:
- Verify that both services are running
- Check that the frontend's
.envfile containsNEXT_PUBLIC_BACKEND_URL=http://localhost:8123 - Try accessing the backend health endpoint directly: http://localhost:8123/health
- Run the health check script:
scripts/check-app-health.ps1orscripts/check-app-health.bat
If the scripts don't work for any reason, you can start the services manually:
cd agent
poetry install
poetry run custom-servercd frontend
pnpm install
pnpm run devAll utility scripts are now organized in the scripts directory for better maintainability:
- Start Scripts:
scripts/start-app.ps1andscripts/start-app.bat - Stop Scripts:
scripts/stop-app.ps1andscripts/stop-app.bat - Health Check Scripts:
scripts/check-app-health.ps1andscripts/check-app-health.bat
For convenience, shortcut scripts are provided in the root directory:
start-app.ps1andstart-app.batstop-app.ps1andstop-app.batcheck-health.ps1andcheck-health.bat