AgentSkillsCN

random-hash

在终端中生成带有盐值的哈希 URL,并附带二维码。当用户希望为标识符附加随机盐值以生成唯一 URL,或需要一个链接至用户个人资料页面的二维码时,可使用此技能。触发条件为 /random-hash 命令。

SKILL.md
--- frontmatter
name: random-hash
description: Generate salted hash URLs with QR codes displayed in terminal. Use when user wants to create a unique URL with a random salt appended to an identifier, or needs a QR code linking to a user profile page. Triggers on /random-hash commands.

Random Hash QR Generator

Generate unique salted URLs and display them as QR codes in the terminal.

Usage

code
/random-hash <identifier>

Example: /random-hash erik-1246 generates a URL like https://example.com/user/erik-1246-@92s_1!

Execution

Run the script with uv:

bash
uv run --with qrcode scripts/generate_qr.py <identifier> [--domain DOMAIN] [--salt-length N]

Arguments:

  • identifier (required): Base identifier for the URL (e.g., erik-1246)
  • --domain: Target domain (default: example.com)
  • --salt-length: Length of random salt suffix (default: 7)

Output

The script displays:

  1. The full salted URL
  2. ASCII QR code in terminal
  3. The salted identifier for reference