360 Secure SkillHub
360 安全技能中心

Polsia R2 Proxy

该 Skill 通过 Polsia 的 Cloudflare R2 代理上传文件:以 POLSIA_API_KEY 鉴权,向上传接口发送 multipart/form-data 请求,返回文件 id、key、url、名称、MIME 类型、大小和创建时间,并规定可上传的图片、视频、音频、文档类型及各类型体积上限;上传需借助 node-fetch 与 form-data 运行代码完成。

agentlevier
agentlevier
热度 8.57
最近更新 2026-07-02 06:30:30
分类:自动化依赖:代码执行 / 第三方 API应用场景:API 集成 / 工作流

安装技能

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

执行命令安装此 skill: npx secure-skills-cli add polsia-r2-proxy
Metadata
name
r2-proxy
description
Upload and manage files through Polsia's Cloudflare R2 proxy with authenticated API requests.

R2 Proxy - File Storage

Upload and manage files using Polsia's R2 storage proxy. Files are stored in Cloudflare R2 with automatic CDN delivery.

Base URL

https://polsia.com/api/proxy/r2

Authentication

All requests require the POLSIA_API_KEY header. Use Authorization: Bearer process.env.POLSIA_API_KEY

Upload a File

Endpoint: POST /upload, Content-Type: multipart/form-data

Use node-fetch (not native fetch) for uploads. Use form-data package and pass formData.getHeaders() to avoid missing boundary errors.

Response Format

Returns: success, file.id, file.key, file.url, file.filename, file.mime_type, file.size, file.created_at

Allowed File Types

Images: jpeg, png, gif, webp. Videos: mp4, webm, mov. Audio: mp3, wav, ogg. Documents: pdf, docx, xlsx, txt, csv.

Size Limits

Images: 20MB, Videos: 1GB, Audio: 500MB, Documents: 50MB.