# tg-ws-proxy-telegram-socks5

Guides the setup of a local SOCKS5 proxy routing Telegram Desktop traffic to data centers over WebSockets. Useful for bypassing connection blocks without remote servers.

- skill · `type=skill` · Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, OpenCode · 882 installs · ★ 88
- Author: reason-machines
- License: not stated · policy=link-only · description only; the file stays with the author
- Source: https://github.com/reason-machines/trending-skills/tree/HEAD/skills/tg-ws-proxy-telegram-socks5/SKILL.md
- Updated: 2026-10-09
- HTML: https://affpapa.org/en/nevibecode/skills/tg-ws-proxy-telegram-socks5

## What it does

This skill instructs coding agents how to deploy and configure tg-ws-proxy. The proxy defaults to port `1080`. It detects Telegram DC IDs inside MTProto packets and establishes TLS WebSocket tunnels. Direct TCP serves as a fallback whenever a WebSocket connection returns an HTTP 302 status.

The assistant learns commands for building the project with `pip install -e .` or running background systemd services on Linux. Guidance covers CLI flags like `--dc-ip` for datacenter mappings and system tray executables for desktop environments.

If port `1080` is already occupied, the proxy fails until pointed to another port via `--port`. The skill also provides integration snippets for Python scripts using `telethon` or `requests`.

## Install

### Claude Code (native platform)

1. **Skills CLI (Vercel)**
```bash
npx skills add reason-machines/trending-skills --skill tg-ws-proxy-telegram-socks5 -a claude-code
```

2. **Manually: put the files in place**
- File: `~/.claude/skills/tg-ws-proxy-telegram-socks5/SKILL.md` — Copy the whole skill folder; for one project use .claude/skills/tg-ws-proxy-telegram-socks5/

### Codex

1. **Skills CLI (Vercel)**
```bash
npx skills add reason-machines/trending-skills --skill tg-ws-proxy-telegram-socks5 -a codex
```

2. **Manually: put the files in place**
- File: `.agents/skills/tg-ws-proxy-telegram-socks5/SKILL.md` — For all projects use ~/.agents/skills/

### Cursor

1. **Skills CLI (Vercel)**
```bash
npx skills add reason-machines/trending-skills --skill tg-ws-proxy-telegram-socks5 -a cursor
```

2. **Manually: put the files in place**
- File: `.cursor/skills/tg-ws-proxy-telegram-socks5/SKILL.md` — Cursor also reads .agents/skills/ and .claude/skills/

### GitHub Copilot

1. **GitHub CLI**
```bash
gh skill install reason-machines/trending-skills tg-ws-proxy-telegram-socks5
```

2. **Manually: put the files in place**
- File: `.github/skills/tg-ws-proxy-telegram-socks5/SKILL.md`

### Gemini CLI

1. **Skills CLI (Vercel)**
```bash
npx skills add reason-machines/trending-skills --skill tg-ws-proxy-telegram-socks5 -a gemini-cli
```

2. **Platform CLI**
```bash
gemini skills install https://github.com/reason-machines/trending-skills --path skills/tg-ws-proxy-telegram-socks5
```

### Windsurf (Devin Desktop)

**Manually: put the files in place**
- File: `.devin/skills/tg-ws-proxy-telegram-socks5/SKILL.md` — The legacy .windsurf/skills/ path still works

### OpenCode

**Skills CLI (Vercel)**
```bash
npx skills add reason-machines/trending-skills --skill tg-ws-proxy-telegram-socks5 -a opencode
```

### Claude.ai

**Claude.ai**
- Zip the folder and upload it in Settings → Capabilities → Skills

Where a file is given instead of a command, copy the files from the source to that path: https://github.com/reason-machines/trending-skills/tree/HEAD/skills/tg-ws-proxy-telegram-socks5/SKILL.md

## When to use it
- Deploy a local SOCKS5 proxy to route Telegram Desktop traffic
- Tunnel connections to Telegram data centers over WebSockets
- Build and run tg-ws-proxy from source
- Route Telethon and Requests scripts through the local proxy
- Change proxy listener ports during local port conflicts

## Example prompts
- Help me build and start tg-ws-proxy from source for Telegram Desktop
- Telegram cannot connect, configure a local WebSocket tunnel proxy on port 1080
- Show me how to route a Telethon script through the local tg-ws-proxy instance

## Similar
- [access](https://affpapa.org/en/nevibecode/skills/access-2.md) — skill · 3867 installs
- [configure](https://affpapa.org/en/nevibecode/skills/configure-2.md) — skill · 3861 installs
- [claude-to-im](https://affpapa.org/en/nevibecode/skills/claude-to-im.md) — skill · 7100 installs
- [mode-creator](https://affpapa.org/en/nevibecode/skills/mode-creator.md) — skill · 1300 installs
- [chat-sdk](https://affpapa.org/en/nevibecode/skills/vercel-chat-sdk.md) — skill · 5400 installs
- [telegram-mini-app](https://affpapa.org/en/nevibecode/skills/sickn33-telegram-mini-app.md) — skill · 1700 installs

From the same set: [reason-machines/trending-skills](https://affpapa.org/en/nevibecode/by/reason-machines/trending-skills.md) — 139 cards

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
