# Laravel Forge MCP for AI Agents AI Agent Connect

> Laravel Forge MCP lets you manage your Laravel Forge infrastructure directly through your AI client. You can trigger site deployments, check server health, query databases, and manage queue workers without switching tabs. It connects your Forge account to your agent so you can handle devops tasks via chat.

## Overview
- **Category:** ship-it
- **Price:** Free
- **Endpoint:** https://edge.vinkius.com/vk_preview_jzfomuWEBzKK0YLd7YZ2kG9qG8ViIw2W2udigts6/ai-agent-connect
- **Tags:** server-management, deployment, php, automation, database-management, web-hosting

## Description

Imagine you're in the middle of a deployment and realize a worker isn't picking up jobs. Instead of hunting through the Forge dashboard, you just ask your agent to check the status. This Connector puts your entire Laravel Forge environment into the hands of your AI client. You can ask it to list every server in your fleet, find specific site layouts, or pull the details on a specific droplet. It handles the heavy lifting of navigating menus and clicking buttons. Because it's hosted on Vinkius, you get a reliable way to bridge your developer account with your agent's capabilities. Whether you're auditing SSH keys across your network or dispatching a deployment script to a staging site, the agent does the manual work for you. You get to stay in your coding environment while the agent handles the infrastructure.

## Tools

### list_recipes
Retrieve available custom shell recipes within your organizational team limits. See what automation is ready.

### list_servers
Retrieve the master list of all connected Forge servers. This gives you a full fleet overview.

### list_sites
List websites mounted to a specific server. Use this to see all sites hosted on a single droplet.

### list_workers
Retrieve queue worker configurations executing on a tracked site. Check if your jobs are actually being processed.

### get_site
Look up specifics for an exact site layout on a server. This helps you quickly verify site configurations.

### list_databases
List active databases mounted on a Forge server. Use this to check your DB cluster connections.

### list_ssh_keys
Retrieve active physical access keys inserted on the root server. This is great for security audits.

### deploy_site
Command a deployment script queue to execute on a repository site. Trigger your updates directly from chat.

### get_server
Retrieve detailed data on a specific server droplet. Get the exact specs for a single node.

## Prompt Examples

**Prompt:** 
```
Show me all the servers I have connected to Forge.
```

**Response:** 
```
I've pulled your server list from Laravel Forge. Here is what's currently connected:

| Server Name | ID | Status |
| :--- | :--- | :--- |
| **Production Web** | 10293 | Online |
| **Staging Loadbalancer** | 44921 | Online |

Would you like me to check the site layouts for either of these?
```

**Prompt:** 
```
Deploy the latest code to my staging site.
```

**Response:** 
```
### 🚀 Deployment Started

I've initiated the deployment for your staging site. 

**Details:**
- **Action:** Repository Deployment
- **Target:** Staging Site
- **Status:** Queued

I'll monitor the output and let you know as soon as the validation flag returns.
```

**Prompt:** 
```
Are the queue workers running on the production server active?
```

**Response:** 
```
I checked the worker configurations for your Production Server. 

**Worker Status:**
- ✅ **Queue Worker 1:** Active (Handling Redis payloads)
- ✅ **Queue Worker 2:** Active (Handling Redis payloads)

Both workers are currently running and healthy.
```

## Capabilities

### Trigger site deployments
Command your deployment scripts to run on a specific repository site via chat.

### List all connected servers
Get a full inventory of every Forge server linked to your account.

### Query active database clusters
Retrieve a list of databases mounted on your Forge servers.

### Inspect queue worker configurations
See which workers are executing on your tracked sites.

### Audit root server SSH keys
Pull active physical access keys from your root server for security checks.

### Retrieve site-specific details
Look up the exact layout and specs for any site on your servers.

### List available shell recipes
See the custom shell scripts available within your team limits.

## Use Cases

### Checking a hanging worker
A developer notices a background job is stuck. They ask the agent to use list_workers on the production site to see if the daemon is still running.

### Inventorying a droplet
An admin needs to know how many sites are on a specific server. They use list_sites to get a full list of websites on that droplet.

### Hotfix deployment
A lead dev needs to push a quick fix to staging. They tell the agent to run deploy_site for the staging repository to push the latest commits.

### Security audit
A security lead wants to see which physical keys are active. They use list_ssh_keys to pull the current access list from the root server.

## Benefits

- Stop tab-switching between your editor and Forge by using list_servers to see your fleet in your chat window.
- Run site updates instantly with deploy_site instead of manually triggering scripts in the web dashboard.
- Quickly find database info with list_databases so you don't have to hunt for cluster links.
- Monitor your background tasks by using list_workers to see active queue configurations in seconds.
- Audit your security posture by pulling active physical access keys with list_ssh_keys on demand.

## How It Works

The bottom line is you get a chat-based interface for your entire Laravel Forge infrastructure.

1. Subscribe to the endpoint and provide your Laravel Forge API token.
2. Connect the Connector to your preferred client like Claude or Cursor.
3. Ask your agent to perform tasks like 'deploy site 5210' or 'list my servers'.

## Frequently Asked Questions

**Can I use Laravel Forge MCP to manage my production servers?**
Yes, it connects directly to your Laravel Forge account. You can manage production environments, check server health, and run deployments through your chat interface.

**Does Laravel Forge MCP support site deployments?**
Yes, it can trigger deployment scripts for your repository sites. This allows you to push updates to staging or production using simple chat commands.

**How do I connect Laravel Forge MCP to my AI agent?**
You just need to subscribe to the endpoint and provide your Laravel Forge API token. Once connected to your client like Claude or Cursor, you can start asking questions.

**Can I check my database clusters with Laravel Forge MCP?**
Yes, the Connector can list all active databases mounted on your Forge servers, making it easy to verify your database configurations without leaving your chat.

**Is Laravel Forge MCP safe for my SSH keys?**
Yes, it retrieves the keys from your existing Forge account. It's a secure way to audit which physical access keys are active on your root servers.

**How do I get started?**
Subscribe, copy your active API Token (which you generate inside **Forge Dashboard → API**), and connect it. The integration expects standard connections so you can trigger real build routines natively without intricate pipelines or ssh logic.

**Can my AI automatically trigger site deployments?**
Yes! Give the agent the Server ID and Site ID you're questioning. It utilizes `deploy_site` to physically POST to Forge's pipelines kicking off an automated release. Perfect for hands-free releases right from Cursor.

**What happens when I want to fetch metrics on queued application workers?**
Provide the exact IDs. The tool evaluates endpoint rules (`list_workers`) and unpacks default configurations running PHP queues natively back to the terminal screen.

**Does it list physical server setups efficiently?**
Absolutely. Execute 'list_servers' or probe 'list_ssh_keys'. It aggregates root connection statuses, IPs, and structural records giving immense monitoring peace-of-mind at the keyboard.