TapeRelay

TapeOut 的中继网关:给开发者的文件存储接口 · 权限靠容器,不靠 API key

A TapeOut relay gateway: file storage for developers · permissions come from containers, not API keys

🔌 接口地址API address

把名字写进容器的发现文件,客户端库就会连这台;接口都在 /v1/ 下,/v1/info 是这台的公开信息。Put a name in your container's discovery file and the client library connects here; the API lives under /v1/, and /v1/info is this server's public info.

📋 这台服务器的规矩This server's policy

🧭 两种做法,你来选Two ways to build

🏢用开发者的容器Your own container
  • 网盘、内容平台:用户不用钱包
  • 文件记在你的容器名下
  • 你的后台用专用钱包逐个请求签名,文件不经过后台
  • Cloud drives, content platforms: users need no wallet
  • Files are recorded under your container
  • Your backend signs each request with a dedicated wallet; files never pass through it
👛用用户的容器Your users' containers
  • DeWEB 视频站:用户用自己的钱包
  • 文件记在用户自己的容器名下
  • 纯静态网站,没有后台;用户授权一把带范围的会话密钥
  • DeWEB video sites: users bring their own wallet
  • Files are recorded under the user's own container
  • A static site with no backend; the user authorizes a scoped session key

🚀 三步接入Three steps

  1. 挑 3 家不同的运营方Pick 3 different operators从运营方名单随机挑(这台可以是其中一家),写进容器的发现文件:一笔链上交易at random from the operator list (this one can be among them), written into the container's discovery file: one on-chain transaction
  2. 签名Sign容器持有人的钱包,或它授权的会话密钥;不用 API keywith the container holder's wallet or a session key it authorized; no API keys
  3. 上传、读取Upload and read客户端库同时传 3 台,2 台存好就算存好;读的时候逐块核对,一台不行换下一台the client library uploads to all 3 and counts a file stored once 2 have it; reads check every chunk and move on if a server fails

🛡️ 为什么可以放心Why you can trust it

🧩改不了你的文件Can't alter your files逐块核对哈希,错一个字节就换下一台Every chunk is hash-checked; one wrong byte and the next server is used
🔑权限靠容器Permissions from containers只认持有人的签名和它授权的范围;释放文件只认钱包Only the holder's signature and the scopes it granted count; releasing files needs the wallet
🔁随时可以换Switch any time身份在链上的容器里,换运营方不换账号Your identity is your on-chain container

💬 常见问题FAQ

💰 要花钱吗?Does it cost anything?

🧯 文件一定不会丢吗?Can files never be lost?

存 3 家不同的运营方只是降低风险:运营方会按自己的规矩删、也会关门,服务器之间不互相复制。缺了的副本由持有人从别的台补回来(客户端库的「核对并补齐」)。

Storing with 3 different operators lowers the risk but cannot remove it: operators delete by their own policy and may close, and servers do not copy to each other. Missing copies are restored by the holder from the other servers (the client library's check and repair).

🗑️ 删了就没了吗?Is a deleted file gone?

不一定:读取不要签名。释放只是从你的容器名下去掉,服务器还会留一段时间再删(没人再用的文件,见上面的「保存期限」),删之前知道哈希的人照样能读到;别人也可能存过同样的内容。要保密的内容先加密再存。

Not necessarily: reading needs no signature. Releasing only removes it from your container; the server keeps the bytes for a while before deleting them (unused files, see Retention above), and until then anyone with the hash can still read it. Others may also have stored the same content. Encrypt anything private before storing it.

👋 运营方不干了怎么办?What if this operator shuts down?

运营方要提前宣布,这一页顶部会写明哪天停。在那之前另挑一家写进发现文件,再从另外两台把副本补过去;容器(账号)不变。

They must announce it in advance, and the date appears at the top of this page. Before then, pick another operator for the discovery file and copy the files over from the other two; the container (your account) stays the same.

🙋 我只是想存文件I just want to store files

用官方前端 relay.hivehubs.app,或这台服务器上的副本(在副本里生成的私钥、文件列表只存在这台服务器的网址下)。

Use the official app at relay.hivehubs.app, or the copy on this server (keys and file lists made there stay under this server's address).

🆘 遇到问题找谁?Who can help?