# Send V2rayn to your agent
Hand the extracted package to your coding agent with a concrete install brief instead of figuring it out manually.
## Fast path
- Download the package from Yavira.
- Extract it into a folder your agent can access.
- Paste one of the prompts below and point your agent at the extracted folder.
## Suggested prompts
### New install

```text
I downloaded a skill package from Yavira. Read SKILL.md from the extracted folder and install it by following the included instructions. Tell me what you changed and call out any manual steps you could not complete.
```
### Upgrade existing

```text
I downloaded an updated skill package from Yavira. Read SKILL.md from the extracted folder, compare it with my current installation, and upgrade it while preserving any custom configuration unless the package docs explicitly say otherwise. Summarize what changed and any follow-up checks I should run.
```
## Machine-readable fields
```json
{
  "schemaVersion": "1.0",
  "item": {
    "slug": "v2rayn",
    "name": "V2rayn",
    "source": "tencent",
    "type": "skill",
    "category": "通讯协作",
    "sourceUrl": "https://clawhub.ai/qiangwang375-wq/v2rayn",
    "canonicalUrl": "https://clawhub.ai/qiangwang375-wq/v2rayn",
    "targetPlatform": "OpenClaw"
  },
  "install": {
    "downloadUrl": "/downloads/v2rayn",
    "sourceDownloadUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=v2rayn",
    "sourcePlatform": "tencent",
    "targetPlatform": "OpenClaw",
    "packageFormat": "ZIP package",
    "primaryDoc": "SKILL.md",
    "includedAssets": [
      "SKILL.md",
      "_meta.json"
    ],
    "downloadMode": "redirect",
    "sourceHealth": {
      "source": "tencent",
      "slug": "v2rayn",
      "status": "healthy",
      "reason": "direct_download_ok",
      "recommendedAction": "download",
      "checkedAt": "2026-05-01T16:03:30.464Z",
      "expiresAt": "2026-05-08T16:03:30.464Z",
      "httpStatus": 200,
      "finalUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=v2rayn",
      "contentType": "application/zip",
      "probeMethod": "head",
      "details": {
        "probeUrl": "https://wry-manatee-359.convex.site/api/v1/download?slug=v2rayn",
        "contentDisposition": "attachment; filename=\"v2rayn-1.0.0.zip\"",
        "redirectLocation": null,
        "bodySnippet": null,
        "slug": "v2rayn"
      },
      "scope": "item",
      "summary": "Item download looks usable.",
      "detail": "Yavira can redirect you to the upstream package for this item.",
      "primaryActionLabel": "Download for OpenClaw",
      "primaryActionHref": "/downloads/v2rayn"
    },
    "validation": {
      "installChecklist": [
        "Use the Yavira download entry.",
        "Review SKILL.md after the package is downloaded.",
        "Confirm the extracted package contains the expected setup assets."
      ],
      "postInstallChecks": [
        "Confirm the extracted package includes the expected docs or setup files.",
        "Validate the skill or prompts are available in your target agent workspace.",
        "Capture any manual follow-up steps the agent could not complete."
      ]
    }
  },
  "links": {
    "detailUrl": "https://openagent3.xyz/skills/v2rayn",
    "downloadUrl": "https://openagent3.xyz/downloads/v2rayn",
    "agentUrl": "https://openagent3.xyz/skills/v2rayn/agent",
    "manifestUrl": "https://openagent3.xyz/skills/v2rayn/agent.json",
    "briefUrl": "https://openagent3.xyz/skills/v2rayn/agent.md"
  }
}
```
## Documentation

### V2RayN Skill

Manage V2RayN proxy client on macOS with auto-failover.

### Overview

V2RayN is a V2Ray client for macOS. This skill helps manage nodes, test connections, auto-check for failures, and update subscriptions.

### Quick Status Check

# Check if V2RayN is running
ps aux | grep -i v2rayN | grep -v grep

# Check listening ports
lsof -i :10808 -i :10809 -i :10810 -i :7890 -i :7891 2>/dev/null

# Test connection
curl -s --max-time 5 https://www.google.com -w "\\nStatus: %{http_code}\\n"

### Auto-Check Node Health (Every 30 min)

This skill automatically:

Check if current node is working
If failed, update subscription
Select a new working node

### Implementation

Create a cron job:

*/30 * * * * /path/to/check_v2rayn.sh

### Check Script

#!/bin/bash
# check_v2rayn.sh - Auto-check and failover for V2RayN

LOG_FILE="$HOME/.openclaw/logs/v2rayn_check.log"
CONFIG_DIR="$HOME/Library/Application Support/v2rayN/guiConfigs"
MAIN_CONFIG="$CONFIG_DIR/guiNConfig.json"

log() {
    echo "[$(date '+%Y-%m-%d %H:%M:%S')] $1" | tee -a "$LOG_FILE"
}

# Test connection
test_connection() {
    curl -s --max-time 5 -x socks5://127.0.0.1:10808 https://www.google.com -o /dev/null -w "%{http_code}" 2>/dev/null
}

# Get current node info
get_current_node() {
    python3 -c "
import json
with open('$MAIN_CONFIG') as f:
    d = json.load(f)
    idx = d.get('currentServerIndex')
    if idx is not None:
        servers = d.get('vmess',[]) + d.get('vless',[]) + d.get('trojan',[])
        if idx < len(servers):
            print(servers[idx].get('remarks', 'Unknown'))
        else:
            print('Invalid index')
    else:
        print('No server selected')
" 2>/dev/null
}

# Main check
log "=== Starting V2RayN health check ==="

# Test current connection
RESULT=$(test_connection)
log "Connection test result: $RESULT"

if [ "$RESULT" = "200" ]; then
    log "✅ Node is working: $(get_current_node)"
    exit 0
else
    log "❌ Node failed! Trying to recover..."
    
    # Try to update subscription
    log "Updating subscription..."
    # Note: V2RayN CLI is limited, manual or external script needed
    
    log "Please manually:"
    log "1. Open V2RayN"
    log "2. Update subscription"
    log "3. Select a new node"
    
    # Notify user
    echo "⚠️ V2RayN node failed! Please check manually."
    exit 1
fi

### 1. Check Node Status

# Test all common proxy ports
for port in 10808 10809 10810 7890 7891; do
    result=$(curl -s --max-time 3 -x socks5://127.0.0.1:$port https://www.google.com -w "%{http_code}" 2>/dev/null)
    echo "Port $port: $result"
done

### 2. List All Nodes

cat ~/Library/Application\\ Support/v2rayN/guiConfigs/guiNConfig.json | python3 -c "
import json,sys
d=json.load(sys.stdin)
servers = d.get('vmess',[]) + d.get('vless',[]) + d.get('trojan',[]) + d.get('shadowsocks',[])
print(f'Total nodes: {len(servers)}')
for i, s in enumerate(servers):
    print(f'{i+1}. {s.get(\\"remarks\\", s.get(\\"name\\", \\"Unnamed\\"))}')
"

### 3. Get Current Node

python3 -c "
import json
with open('$HOME/Library/Application Support/v2rayN/guiConfigs/guiNConfig.json') as f:
    d = json.load(f)
    idx = d.get('currentServerIndex')
    if idx:
        servers = d.get('vmess',[]) + d.get('vless',[]) + d.get('trojan',[])
        if idx < len(servers):
            s = servers[idx]
            print(f'Current: {s.get(\\"remarks\\", \\"Unknown\\")}')
            print(f'Protocol: {s.get(\\"protocol\\", \\"trojan\\")}')
"

### 4. Test Specific Node

# Test current node
curl -s --max-time 5 -x socks5://127.0.0.1:10808 https://www.google.com

# Test direct
curl -s --max-time 5 https://www.google.com

### 5. View Logs

ls -la ~/Library/Application\\ Support/v2rayN/guiLogs/
tail -50 ~/Library/Application\\ Support/v2rayN/guiLogs/*.log 2>/dev/null | tail -30

### 6. Restart V2RayN

# Kill and restart
pkill -f v2rayN
open /Applications/v2rayN.app

### 7. Force Update Subscription

Note: V2RayN doesn't have a CLI for subscription update. You'll need to:

Open V2RayN GUI
Click "Update" on your subscription

### Configuration Files

FileDescriptionguiNConfig.jsonMain GUI config (nodes, settings)config.jsonV2Ray/Xray runtime configconfigPre.jsonSing-box config (if using TUN mode)

### Node Not Working

Check logs: tail -50 ~/Library/Application Support/v2rayN/guiLogs/*.log
Test port: lsof -i :10808
Try different node in GUI
Update subscription

### All Nodes Invalid

Import new subscription
Or add nodes manually in GUI

### TUN Mode Not Working

Check if TUN interface exists: ifconfig | grep -i tun
Check configPre.json for TUN settings
## Trust
- Source: tencent
- Verification: Indexed source record
- Publisher: qiangwang375-wq
- Version: 1.0.0
## Source health
- Status: healthy
- Item download looks usable.
- Yavira can redirect you to the upstream package for this item.
- Health scope: item
- Reason: direct_download_ok
- Checked at: 2026-05-01T16:03:30.464Z
- Expires at: 2026-05-08T16:03:30.464Z
- Recommended action: Download for OpenClaw
## Links
- [Detail page](https://openagent3.xyz/skills/v2rayn)
- [Send to Agent page](https://openagent3.xyz/skills/v2rayn/agent)
- [JSON manifest](https://openagent3.xyz/skills/v2rayn/agent.json)
- [Markdown brief](https://openagent3.xyz/skills/v2rayn/agent.md)
- [Download page](https://openagent3.xyz/downloads/v2rayn)