360 Secure SkillHub
360 安全技能中心

Clawpage

clawpage 用于将 AI Agent 会话记录导出并发布为公开网页。流程为先确认本地项目与站点配置,定位会话文件后用 CLI 解析转换为 YAML,补充标题、参与者、可见性等元数据,人工脱敏敏感信息,在独立 Git 分支上提交;仅在用户明确要求时推送分支、创建 PR 并部署静态站点。支持 OpenClaw 及通用回退 profile。

imyelo
imyelo
热度 59.79
最近更新 2026-05-17 14:44:36
分类:效率依赖:代码执行 / 读写文件 / 第三方 API应用场景:文件转换 / 工作流 / 模板

安装技能

复制下面的话术发给你的 Agent,它会通过 secure-skills 检索并安装该技能。

执行命令安装此 skill: npx secure-skills-cli add clawpage
Metadata
name
clawpage
description
Share AI agent conversations as public web pages. Use when the user wants to share a conversation externally, export conversation history for documentation, or publish a chat session to a public URL.
license
Apache-2.0
metadata
{"openclaw":{"emoji":"💬","homepage":"https://github.com/imyelo/clawpage"}}

clawpage

Share AI agent conversations as public web pages.

Supported Agents

Agent Profile
OpenClaw references/platforms/openclaw.md
(unknown) references/platforms/unknown.md — generic skill-based fallback
(new platform) Add a file following references/platforms/TEMPLATE.md

Core Workflow

1. Setup Check

  • Detect agent type; load project dir + site URL using the agent profile
  • If project not configured locally, ask the user:

2. Locate Session

  • List sessions using agent profile discovery
  • Show candidates → user confirms selection

3. Extract & Convert

Follow the Conversion section in the platform profile detected in Step 1. Save the result to {projectDir}/chats/.tmp/{timestamp}.yaml.

4. Populate Metadata

The CLI auto-fills structural fields. The Skill's job is to fill in the human-facing metadata:

Field CLI default Action
date, sessionId, model, totalMessages, totalTokens, defaultShowProcess Auto-filled Review only
visibility private Update to public
participants Generic role names (user, assistant) Ask user for display names → rename keys; if no name is provided, use Human / Agent for single-speaker or Human 1 / Human 2 … for multi-speaker
title 'Session Export' (generic) Skim generated YAML → suggest → confirm
description (absent) Write one-sentence summary → confirm
channel (absent) Ask user — set to platform name (e.g. discord) if applicable; omit otherwise
cover (absent) Skip (user adds custom OG image URL manually later)
tags (absent) Skip (user adds manually later)

5. Redact

Review the generated YAML and replace sensitive information with [REDACTED]:

  • API keys, tokens, passwords → [REDACTED]
  • File paths with usernames (/Users/xxx → ~)
  • Email addresses, phone numbers → [REDACTED]
  • Internal URLs and private IPs → [REDACTED]

Do not silently remove content — always substitute [REDACTED] so the reader can see that content was present but withheld.

6. Confirm & Save

  • Suggest filename: {YYYYMMDD}-{topic}.yaml
  • Show preview → user confirms or modifies topic/filename
  • Before moving the file, create a dedicated branch (see below — required even if the user does not publish yet):
    cd {projectDir}
    git checkout main
    git pull origin main
    git checkout -b chat/{YYYYMMDD}-{topic}
    
  • Move: {projectDir}/chats/.tmp/{timestamp}.yaml → {projectDir}/chats/{YYYYMMDD}-{topic}.yaml
  • Stage and commit immediately so the file is isolated on its own branch:
    git add chats/{YYYYMMDD}-{topic}.yaml
    git commit -m "docs: add {topic}"
    

Why create a branch here? Saving on the default branch risks mixing unrelated changes into a future PR. Always commit each chat file on its own dedicated branch.


Optional: Publish

Push the branch created in step 6 and open a PR. See references/publish.md. Only proceed after explicit user request.


Edge Cases