Command Palette

Search for a command to run...

UnylyUnyly
Назад к скиллам

deepseek-webgui

БесплатноЗапускает вложенные скриптыНе проверен

DeepSeek client via the private chat.deepseek.com API (browser-exported userToken), not the official platform.deepseek.com API. Use for personal webgui…

htlin222от htlin222★ 78 звёзд на GitHub

Об этом скилле

deepseek-webgui

Overview

Drives the private API behind chat.deepseek.com — the same one the React frontend calls. Useful when the user wants to use their existing webgui account (free quotas, browser-based reasoning + search) from a script, TUI, or another tool, and does not want to (or cannot) move to the paid OpenAI-compatible API at platform.deepseek.com.

The hard part is the proof-of-work: every /api/v0/chat/completion call requires an x-ds-pow-response header containing a base64-encoded answer to a server-issued DeepSeekHashV1 challenge. The algorithm is implemented as an SHA3-based WASM solver inside the frontend bundle. This skill ships that WASM and drives it from Python via wasmtime so no Node.js is required at runtime.

When to use this skill

Reach for it when any of the following appears:

  • "use my deepseek web account / cookies / session", "free deepseek", "no API key"
  • "deepseek-tui", "deepseek4free", "wrap chat.deepseek.com"
  • "x-ds-pow-response", "DeepSeekHashV1", "POW challenge", "create_pow_challenge"
  • "parse deepseek SSE", "THINK fragment", "TOOL_SEARCH", "JSON-Patch deepseek"

Prefer the official OpenAI-compatible API at https://api.deepseek.com whenever the user has (or can get) a paid API key. It is faster, supported, and has no anti-bot. This skill exists for the case where that is not an option.

Quick start

# 1) Capture credentials from the browser (one-time)
#    a. Log into https://chat.deepseek.com in any browser.
#    b. DevTools console:  copy(localStorage.userToken)            # paste into auth.json
#    c. Cookie-Editor / EditThisCookie: export *.deepseek.com      # save as cookies.json

# 2) Place credentials next to the prompt or anywhere convenient:
echo '{"token": "<paste userToken here>"}' > auth.json

# 3) Send a prompt.
scripts/run.sh "Summarise the difference between TLS 1.2 and 1.3 in 3 bullets."

# Flags:
#   --thinking           enable reasoning trace (THINK fragments → think_delta events)
#   --search             enable web search (TOOL_SEARCH fragment → tool_search events)
#   --model expert       use the reasoning model (default: "default" = DeepSeek-V3)
#   --raw                emit every parsed StreamEvent as JSON (machine-readable mode)
#   --cookies/--auth     override file paths

run.sh is a thin uv run --with wasmtime --with httpx wrapper. If uv is unavailable, pip install httpx wasmtime and run python3 scripts/client.py directly.

Architecture

prompt
  │
  ▼
DeepSeekClient.completion()
  │
  ├─ 1. POST /api/v0/chat_session/create        →  chat_session.id
  ├─ 2. POST /api/v0/chat/create_pow_challenge  →  challenge {algorithm, challenge, salt, expire_at, difficulty, signature}
  ├─ 3. solve_pow_challenge(...)                →  answer (int)            (scripts/pow.py + sha3.wasm)
  │      base64(JSON(answer + challenge + ...))→  x-ds-pow-response
  │
  └─ 4. POST /api/v0/chat/completion (streaming SSE)
           │
           └─ _parse_sse(...)  →  StreamEvent("delta"|"think_delta"|"tool_search"|"search_results"|"title"|"close"|"raw"|"ready")

Three layers of credentials are required and the API will reject calls missing any one of them:

  • Authorization: Bearer <userToken> from localStorage.userToken.
  • Cookies on *.deepseek.com (aws-waf-token for WAF + ds_session_id for session).
  • A handful of frontend identity headers (x-app-version, x-client-platform, etc.) — the client sets them automatically.

If a request returns {"code":40002,"msg":"Missing Token"} the userToken is missing or expired. If the response is a 202 with x-amzn-waf-action: challenge, the aws-waf-token cookie has expired — the user needs to refresh chat.deepseek.com in the browser and re-export cookies.

Files

  • scripts/client.py — DeepSeekClient, SSE parser, CLI. Public surface:
    • load_cookies(path) -> dict[str,str] — parses Cookie-Editor / EditThisCookie JSON.
    • load_auth_token(path) -> str | None — reads DEEPSEEK_TOKEN env var or {"token": "..."} file.
    • DeepSeekClient(cookies, token=...).completion(prompt, *, thinking, search, model_type, chat_session_id, parent_message_id) -> Iterator[StreamEvent].
    • StreamEvent.kind: "ready" | "delta" | "think_delta" | "tool_search" | "search_results" | "title" | "close" | "raw". The text field on delta / think_delta / title is the human-visible string to print or accumulate.
  • scripts/pow.py — solve_pow_challenge(...). Pure-Python wrapper around the bundled WASM via wasmtime. Includes a self-test against the captured HAR challenge that asserts answer == 49586.
  • scripts/sha3.wasm — the unmodified sha3_wasm_bg.wasm from fe-static.deepseek.com/chat/static/. ~26 KB. Contains wasm_solve which is the iteration kernel.
  • scripts/run.sh — uv-driven launcher.
  • references/api_reference.md — full reverse-engineered API surface: endpoints, error codes, POW field semantics, SSE patch dialect with examples. R
Полный SKILL.md на GitHub

Установить deepseek-webgui в Claude Code и Claude Desktop

Зарегайся, чтобы установить скилл

Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.

  • Открой команду установки в одну строку
  • Сохраняй скиллы в синхронизируемую библиотеку
  • Уведомления, когда скиллы обновляются
Зарегаться бесплатноУ меня уже есть аккаунт

Разрешённые инструменты

Инструменты, которые скиллу разрешено вызывать.

Без ограничений — скилл может использовать любой инструмент.

Вложенные файлы

references/api_reference.mdscripts/client.pyscripts/pow.pyscripts/run.shscripts/sha3.wasm

FAQ

Что делает скилл deepseek-webgui?

DeepSeek client via the private chat.deepseek.com API (browser-exported userToken), not the official platform.deepseek.com API. Use for personal webgui automation, `x-ds-pow-response` / DeepSeekHashV1 POW solving, or SSE THINK/TOOL_SEARCH stream parsing.

Как установить скилл deepseek-webgui?

Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.

Скилл deepseek-webgui запускает скрипты?

Да, скилл несёт исполняемые скрипты. Проверь исходник перед установкой.

Похожие скиллы

Сравнить deepseek-webgui с