返回顶部
m

mdshare-agentMDShare代理

Create, read, unlock, update, and delete temporary Markdown shares through the MDShare service. Use when an agent needs to publish Markdown as a short-lived share link, fetch shared Markdown, access password-protected or burn-after-read content, continue editing with a manage or edit token, or hand back public/edit/manage links for collaboration. Triggers include “share this markdown”, “generate a temporary link”, “publish notes”, “read an MDShare link”, “update an existing share”, and “delete a

作者: admin | 来源: ClawHub
源自
ClawHub
版本
V 1.0.0
安全检测
已通过
219
下载量
免费
免费
0
收藏
概述
安装方式
版本历史

mdshare-agent

MDShare Agent

将MDShare用作轻量级匿名Markdown发布后端。

服务

  • - 默认基础URL:https://share.yekyos.com
  • 如果调用方提供了其他部署地址,则使用该地址。
  • 将公开链接和含令牌链接分开:
- 公开链接:/s/{slug} - 编辑/管理页面:/e/{slug}#edit={token} 或 /e/{slug}#manage={token}
  • - 除非用户明确需要,否则绝不暴露ownerToken或editorToken。

核心工作流

创建分享

发送POST /api/shares,附带JSON:

json
{
markdownContent: # 标题\n\n正文,
expiresInHours: 24,
password: ,
burnMode: OFF,
editableMode: READ_ONLY
}

规则:

  • - expiresInHours通常应为1、24、168、720之一。
  • burnMode取值:
- OFF - AFTERFIRSTVIEW_GRACE - AFTERFIRSTVIEW_INSTANT
  • - editableMode取值:
- READ_ONLY - EDIT_LINK

向用户返回以下链接:

  • - 公开:{baseUrl}/s/{slug}
  • 管理:{baseUrl}/e/{slug}#manage={ownerToken}
  • 编辑:仅当editorToken存在时,{baseUrl}/e/{slug}#edit={editorToken}

使用默认部署的示例:

  • - 公开:https://share.yekyos.com/s/abc123xy
  • 管理:https://share.yekyos.com/e/abc123xy#manage=
  • 编辑:https://share.yekyos.com/e/abc123xy#edit=

读取公开分享

调用GET /api/shares/{slug}/public。

可能的状态:

  • - available:返回内容
  • gated:需要密码和/或确认查看
  • expired
  • burned
  • deleted
  • not_found

如果状态为gated,仅在需要时询问密码,并在确认访问前解释阅后即焚。

解锁受限分享

发送POST /api/shares/{slug}/public,附带JSON:

json
{
password: 可选密码,
confirmView: true
}

当服务提示需要焚毁确认时,使用confirmView: true。

通过令牌读取或编辑

使用请求头:

text
x-share-token:

调用GET /api/shares/{slug}/manage查看当前分享和角色。

保存内容

发送PATCH /api/shares/{slug}/manage,附带请求头x-share-token和JSON:

json
{
markdownContent: # 已更新\n\n内容,
lastKnownUpdatedAt: 2026-03-12T00:00:00.000Z,
force: false
}

如果API返回409且conflict: true,不要静默覆盖。总结冲突并询问是否强制保存。

更新设置

仅限所有者令牌。发送PATCH /api/shares/{slug}/settings,附带JSON:

json
{
expiresInHours: 168,
password: ,
burnMode: OFF,
editableMode: READ_ONLY
}

如果响应包含新的editorToken,则重新生成编辑链接。

删除分享

仅限所有者令牌。调用DELETE /api/shares/{slug}/manage,附带x-share-token。

行为指导

  • - 优先使用简单默认值:
- expiresInHours: 168 - burnMode: OFF - editableMode: READ_ONLY
  • - 将密码视为可选。空字符串表示无密码。
  • 除非用户明确要求格式化或清理,否则精确保留其Markdown内容。
  • 当用户仅需要格式预览时,除非用户要求,否则不要创建分享链接。
  • 对于敏感内容,提醒用户任何拥有管理链接的人都可以修改或删除该分享。

参考

标签

skill ai

通过对话安装

该技能支持在以下平台通过对话安装:

OpenClaw WorkBuddy QClaw Kimi Claude

方式一:安装 SkillHub 和技能

帮我安装 SkillHub 和 mdshare-agent-1776123074 技能

方式二:设置 SkillHub 为优先技能安装源

设置 SkillHub 为我的优先技能安装源,然后帮我安装 mdshare-agent-1776123074 技能

通过命令行安装

skillhub install mdshare-agent-1776123074

下载

⬇ 下载 mdshare-agent v1.0.0(免费)

文件大小: 6.2 KB | 发布时间: 2026-4-15 13:22

v1.0.0 最新 2026-4-15 13:22
Initial release of mdshare-agent.

- Enables creating, reading, updating, unlocking, and deleting temporary Markdown shares via the MDShare service.
- Supports generating public, edit, and manage links—public and token-bearing links handled separately for privacy.
- Handles password-protected and burn-after-read shares, confirming before revealing sensitive content.
- Provides workflows for collaborative Markdown sharing and editing with short-lived links.
- Default base URL is https://share.yekyos.com, with support for custom deployments.

Archiver·手机版·闲社网·闲社论坛·羊毛社区· 多链控股集团有限公司 · 苏ICP备2025199260号-1

Powered by Discuz! X5.0   © 2024-2025 闲社网·线报更新论坛·羊毛分享社区·http://xianshe.com

p2p_official_large
返回顶部