==========================================================
 XAPI CLAUDE SETUP — VS Code Extension
 Publish: https://open-vsx.org/
==========================================================

CHỨC NĂNG
  - Nhập API key sk-... (xapi.labpinky.com)
  - Tự ghi ~/.claude/settings.json cho Claude Code
  - Backup file cũ trước khi ghi đè
  - Mở trang usage token, video HD, API docs

CÀI ĐẶT CHO NGƯỜI DÙNG
  1. Cài extension "Claude Code" (Anthropic) trước
  2. Cài "XAPI Claude Setup" từ Open VSX:
     - VSCodium / Cursor: Extensions → tìm "XAPI Claude Setup"
     - Hoặc: https://open-vsx.org/extension/labpinky-xapi/xapi-claude-setup
  3. Extension TỰ MỞ GUI khi bật:
     - Icon "XAPI Claude" trên Activity Bar (sidebar trái)
     - Form nhập API key / Base URL / Model hiện ngay
     - Lần đầu chưa cấu hình → tự mở thêm tab thiết lập
  4. Dán API key → Lưu & chạy
  5. Mở Claude Code → chat

GIAO DIỆN (GUI)
  - Sidebar trái: icon XAPI Claude → panel "Thiết lập API"
  - Form: API Key, Base URL, Model, nút Dán key / Lưu
  - Liên kết: usage, video, API docs, mở settings.json
  - Tắt tự mở: Settings → xapi-claude.autoOpenOnStartup = false

LỆNH (Command Palette)
  - XAPI: Thiết lập Claude API
  - XAPI: Dán API Key từ clipboard
  - XAPI: Mở bảng thiết lập (tab editor)
  - XAPI: Mở sidebar thiết lập
  - XAPI: Xem usage token
  - XAPI: Video hướng dẫn

SETTINGS VS CODE (tuỳ chọn)
  xapi-claude.apiKey      — lưu key (global)
  xapi-claude.baseUrl     — https://xapi.labpinky.com/
  xapi-claude.defaultModel — opus | sonnet | haiku

DEV — CHẠY LOCAL
  1. Mở thư mục XAPI-Claude-Setup trong VS Code
  2. F5 (Run Extension) → cửa sổ Extension Development Host
  3. Trong cửa sổ mới: Ctrl+Shift+P → XAPI commands

DEV — ĐÓNG GÓI .vsix
  cd XAPI-Claude-Setup
  npm install
  npx vsce package
  → ra file xapi-claude-setup-1.0.0.vsix
  → cài thủ công: Extensions → ... → Install from VSIX

PUBLISH LÊN OPEN VSX
  Xem PUBLISH.md

LINKS
  Usage:  https://xapi.labpinky.com/key
  Video:  https://youtu.be/c7eNO0H7WgY
  API:    https://rddvzo1u4x.apidog.io/chat-completions-35087875e0
