Happy Server MCP
MCP (Model Context Protocol) server for managing Happy AI sessions. This allows AI agents to interact with Happy sessions programmatically.
Features
List Sessions: Query all your Happy AI sessions with their titles, working directories, and activity status
List Machines: See all registered machines and their online/offline status
List Recent Paths: Get recently used working directories for a machine
Read Messages: Fetch recent messages from any session to see conversation history
Send Messages: Trigger a session to work by sending it a message
Start Sessions: Spawn new AI sessions on any connected machine
Archive Sessions: Stop and archive sessions when done
Wait for Idle: Wait for a session to finish processing
Installation
Prerequisites
You must be authenticated with Happy CLI. Run:
This creates credentials at ~/.happy/access.key that the MCP server uses.
Usage with Claude
Add to your Claude configuration:
Or with npx:
Available Tools
happy_list_sessions
List all Happy AI sessions. Returns session IDs, titles, paths, machines, and activity status.
Parameters:
Name | Type | Required | Default | Description |
| number | No | 50 | Maximum number of sessions to return |
Example:
happy_list_machines
List all machines registered with Happy. Returns machine IDs, hostnames, platforms, and activity status.
Parameters: None
Example:
happy_list_recent_paths
List recently used folder paths for a machine. Useful for starting sessions in familiar locations.
Parameters:
Name | Type | Required | Default | Description |
| string | Yes | - | The machine ID to get recent paths for |
| number | No | 20 | Maximum number of paths to return |
Example:
happy_read_messages
Read recent messages from a Happy AI session. Use this to see the conversation history.
Parameters:
Name | Type | Required | Default | Description |
| string | Yes | - | The session ID to read messages from |
| number | No | 20 | Maximum number of messages to return |
Example:
happy_send_message
Send a message to a Happy AI session to trigger it to work. The message will be sent with bypass permissions mode.
Parameters:
Name | Type | Required | Default | Description |
| string | Yes | - | The session ID to send the message to |
| string | Yes | - | The message text to send |
| boolean | No | false | If true, wait for AI to finish processing before returning |
Example:
happy_start_session
Start a new Happy AI session on a machine. Use happy_list_machines to find available machines first.
Parameters:
Name | Type | Required | Default | Description |
| string | Yes | - | The machine ID to start the session on |
| string | Yes | - | The directory path to run the session in |
| string | No | - | Optional initial message to send to start the session working |
| "claude" | "codex" | No | "claude" | Agent type to use |
| boolean | No | false | If true, wait for AI to finish processing initial message before returning |
Example:
happy_archive_session
Archive (stop) a Happy AI session. The session will be terminated and marked as inactive.
Parameters:
Name | Type | Required | Default | Description |
| string | Yes | - | The session ID to archive |
Example:
happy_wait_for_idle
Wait for a Happy AI session to become idle (finish processing). Useful after sending a message to wait for AI to complete its work.
Parameters:
Name | Type | Required | Default | Description |
| string | Yes | - | The session ID to wait for |
| number | No | 120 | Maximum time to wait in seconds |
Example:
Common Workflows
Start a session and wait for completion
Use
happy_list_machinesto find an online machineUse
happy_list_recent_pathsto find a good working directoryUse
happy_start_sessionwithwait=trueto start and wait for the initial task
Monitor an existing session
Use
happy_list_sessionsto find active sessionsUse
happy_read_messagesto see what the AI is working onUse
happy_send_messageto give it new instructions
Clean up old sessions
Use
happy_list_sessionsto see all sessionsUse
happy_archive_sessionto stop sessions you no longer need
Environment Variables
HAPPY_SERVER_URL: Override the Happy server URL (default:https://happy.engineering)
License
MIT