Skip to content

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Repository files navigation

Clawk iOS

Personal iOS app for chatting with OpenClaw agents. Built with SwiftUI, powered by Tailscale + Railway.

Architecture

┌─────────────┐     Tailscale      ┌──────────────┐
│   iPhone    │◄──────────────────►│   Railway    │
│  (Clawk)    │   (WireGuard VPN)  │   (Relay)    │
└─────────────┘                    └──────────────┘
                                          │
                                          ▼
                                   ┌──────────────┐
                                   │  OpenClaw    │
                                   │   Gateway    │
                                   └──────────────┘

Structure

├── backend/           # Node.js relay (deploy to Railway)
│   ├── server.js
│   └── package.json
├── Clawk/             # SwiftUI iOS app
│   └── ...
└── README.md

Setup

1. Backend (Railway)

cd backend
railway login
railway init
railway up

Get your public URL: railway domain

2. iOS App

Open Clawk/Clawk.xcodeproj in Xcode.

Update Config.swift with your Railway URL.

3. Pair Device

On first launch, the app shows a QR code. Scan with any device to pair.

Or manually POST to /pair:

curl -X POST https://your-app.railway.app/pair \
  -H "Content-Type: application/json" \
  -d '{"deviceToken": "your-device-token", "deviceName": "Kish iPhone"}'

4. Send Messages

From OpenClaw (or any HTTP client):

curl -X POST https://your-app.railway.app/message \
  -H "Content-Type: application/json" \
  -H "x-device-token: your-device-token" \
  -d '{
    "message": "Approve this clip for upload?",
    "actions": ["Approve", "Reject", "Later"]
  }'

Message Types

Card (default)

{
  "type": "card",
  "message": "Your message here",
  "actions": ["Button 1", "Button 2"]
}

Input

{
  "type": "input",
  "message": "What's your ETA?",
  "inputType": "text"
}

List

{
  "type": "list",
  "message": "Choose a clip:",
  "actions": ["Clip 1", "Clip 2", "Clip 3"]
}

Local Development

Backend

cd backend
npm install
npm start

iOS App

Open in Xcode, run on device or simulator.

Tailscale Notes

  • Install Tailscale on your iPhone
  • Install Tailscale on Railway (use Tailscale SSH or subnet routes)
  • Or: Keep Railway public but use token auth (what we do here)

For fully private setup:

  1. Run relay on your Tailscale network (home machine or VPS with Tailscale)
  2. Point iOS app to Tailscale IP
  3. No public internet needed

About

No description, website, or topics provided.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages