360 Secure SkillHub
360 安全技能中心

stratos-storage

该 Skill 提供上传与下载两个 bash 脚本,结合 SPFS 网关和本地 SDS 节点配置,把指定文件上传到 Stratos 去中心化存储并返回文件哈希,或按文件哈希或 CID 将文件下载到指定路径;操作前需确认文件路径与节点可用性。

notboxqsn
notboxqsn
热度 68.70
最近更新 2026-05-17 11:56:32
分类:自动化依赖:代码执行 / 读写文件 / 第三方 API应用场景:工作流 / 自动化脚本

安装技能

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

执行命令安装此 skill: npx secure-skills-cli add stratos-storage
Metadata
name
stratos-storage
description
Upload and download files to/from Stratos Decentralized Storage (SDS) network. Use when the user wants to store files on Stratos, retrieve files from Stratos, upload to decentralized storage, or download from SDS.
version
1.0.0
metadata
{"openclaw":{"requires":{"env":["STRATOS_SPFS_GATEWAY","STRATOS_NODE_DIR"],"bins":["curl"]},"primaryEnv":"STRATOS_SPFS_GATEWAY"}}

Stratos Decentralized Storage

When to use

  • User wants to upload a file to Stratos SDS network
  • User wants to download a file from Stratos SDS using file hash or share link
  • User mentions "Stratos", "SDS", "SPFS", or "decentralized storage upload/download"

Steps

Upload a file

  1. Verify ppd or SPFS gateway is available
  2. Run the upload script: bash $SKILL_DIR/scripts/upload.sh <file_path>
  3. Return the file hash (CID) to the user

Download a file

  1. Verify ppd or SPFS gateway is available
  2. Run the download script: bash $SKILL_DIR/scripts/download.sh <file_hash_or_cid> <output_path>
  3. Confirm download success

Examples

Upload: "Upload /tmp/report.pdf to Stratos" → Run: bash scripts/upload.sh /tmp/report.pdf → Output: File uploaded. CID: Qm...xxx

Download: "Download file Qm...xxx from Stratos to ~/Downloads/" → Run: bash scripts/download.sh Qm...xxx ~/Downloads/report.pdf → Output: File downloaded to ~/Downloads/report.pdf

Constraints

  • Always confirm file path with user before uploading
  • Never overwrite existing files without user confirmation
  • Verify SDS node is running before operations
  • Large files may take significant time; inform user of progress