返回顶部
g

github-image-hostingGitHub图床

>

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

github-image-hosting

用于GitHub的图片上传

将图片上传至img402.dev的免费套餐,并将返回的URL嵌入到GitHub Markdown中。

快速参考

bash

上传(多部分表单)


curl -s -X POST https://img402.dev/api/free -F image=@/tmp/screenshot.png

响应

{url:https://i.img402.dev/aBcDeFgHiJ.png,id:aBcDeFgHiJ,contentType:image/png,sizeBytes:182400,expiresAt:2026-02-17T...}

工作流程

  1. 1. 获取图片:使用现有文件,或截取屏幕截图:
bash screencapture -x /tmp/screenshot.png # macOS — 全屏 screencapture -xw /tmp/screenshot.png # macOS — 最前窗口
  1. 2. 验证大小:必须小于1MB。若超出,请调整尺寸:
bash sips -Z 1600 /tmp/screenshot.png # macOS — 将最长边缩放至1600像素
  1. 3. 上传
bash curl -s -X POST https://img402.dev/api/free -F image=@/tmp/screenshot.png
  1. 4. 嵌入返回的url到GitHub Markdown中:
markdown 截图描述

GitHub集成

使用gh CLI将图片嵌入PR和Issue中:

bash

添加到PR描述


gh pr edit --body $(gh pr view --json body -q .body)

截图

添加为PR评论

gh pr comment --body 截图

添加到Issue

gh issue comment 123 --body 截图

限制条件

  • - 最大尺寸:1MB
  • 保留期限:7天 — 适用于PR审查,不适合永久文档
  • 格式支持:PNG、JPEG、GIF、WebP
  • 速率限制:每天1000次免费上传(全局)
  • 无需认证

提示

  • - UI截图建议使用PNG格式(文字清晰)。照片建议使用JPEG格式。
  • 若截图过大,上传前使用sips -Z 1600缩小尺寸。
  • 添加至PR正文或评论时,使用gh pr comment或gh pr edit配合图片Markdown。

付费套餐

如需永久保存图片(1年,最大5MB),可通过x402使用付费接口,费用为0.01 USDC。详情请参阅 https://img402.dev/blog/paying-x402-apis。

标签

skill ai

通过对话安装

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

OpenClaw WorkBuddy QClaw Kimi Claude

方式一:安装 SkillHub 和技能

帮我安装 SkillHub 和 github-image-hosting-1776420048 技能

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

设置 SkillHub 为我的优先技能安装源,然后帮我安装 github-image-hosting-1776420048 技能

通过命令行安装

skillhub install github-image-hosting-1776420048

下载

⬇ 下载 github-image-hosting v1.0.0(免费)

文件大小: 1.87 KB | 发布时间: 2026-4-17 18:25

v1.0.0 最新 2026-4-17 18:25
- Initial release: upload images to img402.dev for easy embedding in GitHub PRs, issues, and comments.
- Supports free uploads under 1MB, with images persisting for 7 days and no authentication required.
- Includes shell workflow for capturing, resizing, uploading images, and embedding returned URLs in markdown.
- Integration examples provided for adding images to GitHub via `gh` CLI.
- Documents constraints: supported formats, upload limits, and retention policy.
- Notes on paid tier for permanent, larger images.

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

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

p2p_official_large
返回顶部