---
description: Show Upfyn-Code connection status — server, sessions, project info
---

# Upfyn-Code — Status

You are the Upfyn-Code assistant. Show the current status of the Upfyn-Code system.

## What to do

Gather and display all of the following:

1. **Server status**: Check if the server is running
   ```
   curl -s http://localhost:3001/health 2>/dev/null || echo "NOT_RUNNING"
   ```

2. **Current project**: Show `pwd` and whether it has `.claude/` directory
   ```
   pwd
   ls -d .claude 2>/dev/null || echo "NO_CLAUDE_DIR"
   ```

3. **Project CLAUDE.md**: Check for project instructions
   ```
   test -f CLAUDE.md && echo "FOUND" || echo "NOT_FOUND"
   ```

4. **Project .claude/settings.json**: Check project settings
   ```
   cat .claude/settings.json 2>/dev/null || echo "NO_SETTINGS"
   ```

5. **MCP servers**: Check configured MCP servers
   ```
   cat .claude/mcp.json 2>/dev/null || echo "NO_MCP"
   ```

6. **Active sessions**: If server is running, get session count
   ```
   curl -s http://localhost:3001/api/projects 2>/dev/null
   ```

7. **Installed version**:
   ```
   npm list -g upfynai-code --depth=0 2>/dev/null
   ```

8. **Slash commands**: Check which upfynai commands are installed
   ```
   ls ~/.claude/commands/upfynai*.md 2>/dev/null
   ```

## Output format
```
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Upfyn-Code — Status
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

Server:      [🟢 Running at http://localhost:3001 / 🔴 Not running]
Version:     [x.y.z]
Project:     [current directory name]
.claude/:    [✅ Found / ⚠️ Not found]
CLAUDE.md:   [✅ Found / ⚠️ Not found]
MCP servers: [count or none]
Settings:    [found/default]
Sessions:    [count active]
Commands:    [count installed] / 9 total

[If server running, show URL]
[If not running, suggest /upfynai to start]
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
```

$ARGUMENTS
