← Back to Skills Marketplace
ctz168

AiTun Tunnel

by SamAI.cc · GitHub ↗ · v1.0.0 · MIT-0
cross-platform ✓ Security Clean
24
Downloads
0
Stars
0
Active Installs
1
Versions
Install in OpenClaw
/install aitun-tunnel
Description
Expose local web pages and HTTP services to the public internet via secure tunnels. Perfect for AI agents that build websites locally and need to share them...
README (SKILL.md)

AiTun Tunnel - Expose Local Web Pages to the Public Internet

When to Use

Use this skill when:

  • You've built a web page, dashboard, or web app locally and need to share it publicly
  • You need to test a local HTTP service from an external device
  • You want to demo a locally-running application to someone
  • You need a public webhook endpoint for an external service to call
  • You want to expose a local API for integration testing
  • You built a website for a user and they want to see it in their browser

Do NOT use this skill when:

  • The content only needs to be viewed locally
  • The user asks for a file download (use file sharing instead)

Instructions

Step 1: Install aitun

pip install aitun

Or if already installed, verify:

which aitun || pip show aitun

Step 2: Start the local web service

Ensure the local web service is running on a port. For static HTML files:

# Serve a directory with a built HTML page
python3 -m http.server 8080 --directory /path/to/html/dir

For other frameworks, start their dev server:

  • Next.js: npm run dev -- -p 3000
  • Flask: flask run --port 5000
  • Any HTTP service on any port

Step 3: Create a tunnel

Option A: Free instant tunnel (no sign-up, 24-hour limit)

aitun -s aitun.cc:6639 -l \x3CPORT> --free &
AITUN_PID=$!
sleep 3

The output will contain the public URL, e.g.:

  • https://abc123.t.aitun.cc
  • https://aitun.cc/s/abc123

Option B: Via API (no CLI needed)

curl -s -X POST https://aitun.cc/aitun-api/tunnel/free

Returns JSON with tunnel_key, url, and subdomain_url.

Option C: Custom subdomain (requires Google sign-in at aitun.cc)

# Check availability
curl -s https://aitun.cc/aitun-api/subdomain/check/\x3Cname>

# Register via website: https://aitun.cc
# Then use:
aitun -s aitun.cc:6639 -l \x3CPORT> -sub \x3Cname>

Step 4: Share the public URL

Tell the user their website is now publicly accessible:

Your website is now live at: https://abc123.t.aitun.cc

This free tunnel expires in 24 hours.
For a permanent URL (e.g., myapp.aitun.cc), register at https://aitun.cc

Step 5: Clean up

When done, stop the tunnel:

kill $AITUN_PID 2>/dev/null

API Reference

Check subdomain availability

GET https://aitun.cc/aitun-api/subdomain/check/{name}
Response: { "available": true, "name": "...", "url": "https://name.aitun.cc" }

Create free tunnel

POST https://aitun.cc/aitun-api/tunnel/free
Response: { "tunnel_key": "abc123", "url": "https://aitun.cc/s/abc123", "subdomain_url": "https://abc123.t.aitun.cc" }

Google OAuth login

POST https://aitun.cc/aitun-api/auth/google
Body: { "access_token": "\x3Cgoogle-access-token>" }
Response: { "user": { ..., "token": "\x3Cjwt-token>" } }

Register subdomain (requires auth)

POST https://aitun.cc/aitun-api/subdomain/register
Headers: Authorization: Bearer \x3Ctoken>
Body: { "name": "myapp" }

Notes

  • Free tunnels expire after 24 hours
  • Registered subdomains remain active for 30 days of inactivity; use heartbeat to renew
  • Maximum 5 subdomains per registered user
  • All traffic is encrypted end-to-end
  • The client can optionally serve as a relay node (--relay flag) to improve network performance
  • Reserved subdomains (www, api, admin, test, etc.) cannot be registered \r
Usage Guidance
Install only if you intend to make a local app reachable by others. Before exposing a port, verify what is running there, avoid debug/admin/credential-backed services, and remove the route or stop the service when sharing is done.
Capability Tags
requires-oauth-tokenrequires-sensitive-credentials
Capability Assessment
Purpose & Capability
The stated purpose is to publish a local app as a reachable URL; reverse-proxying a selected localhost port fits that purpose.
Instruction Scope
The instructions involve exposing a local service, but they warn that the URL is public, call out unsafe debug/admin/credential-backed apps, and tell the agent to confirm before exposing.
Install Mechanism
Installation uses a bundled script that downloads a release binary and verifies SHA-256; this is proportionate but users should review the script and release source.
Credentials
Opening a local port to internet users is sensitive and should be limited to non-sensitive, intentionally shared apps.
Persistence & Privilege
Optional user-service persistence and optional sudo system setup are disclosed and require user confirmation; no hidden persistence was identified.
How to Use
  1. Make sure OpenClaw is installed (local or Docker)
  2. Run the install command in chat: /install aitun-tunnel
  3. After installation, invoke the skill by name or use /aitun-tunnel
  4. Provide required inputs per the skill's parameter spec and get structured output
Version History
v1.0.0
Initial release - expose local web pages to the public internet via secure tunnels
Metadata
Slug aitun-tunnel
Version 1.0.0
License MIT-0
All-time Installs 0
Active Installs 0
Total Versions 1
Frequently Asked Questions

What is AiTun Tunnel?

Expose local web pages and HTTP services to the public internet via secure tunnels. Perfect for AI agents that build websites locally and need to share them... It is an AI Agent Skill for Claude Code / OpenClaw, with 24 downloads so far.

How do I install AiTun Tunnel?

Run "/install aitun-tunnel" in the OpenClaw or Claude Code chat to install it in one step — no extra setup required.

Is AiTun Tunnel free?

Yes, AiTun Tunnel is completely free, licensed under MIT-0. You can download, install and use it at no cost.

Which platforms does AiTun Tunnel support?

AiTun Tunnel is cross-platform and runs anywhere OpenClaw / Claude Code is available (cross-platform).

Who created AiTun Tunnel?

It is built and maintained by SamAI.cc (@ctz168); the current version is v1.0.0.

💬 Comments