add-files

Add secure file upload storage with validation and signed URL delivery.

Updated Apr 30, 2026
One-click install
npx skills add https://github.com/jnlanahan/Product-Agents-and-Skills --skill add-files-jnlanahan
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: add-files
Source: https://github.com/jnlanahan/Product-Agents-and-Skills/tree/main/skills/4-Build-File-Storage
Command: npx skills add https://github.com/jnlanahan/Product-Agents-and-Skills --skill add-files-jnlanahan

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill solves the problem of adding reliable, production-ready file upload and delivery to your app without creating security holes or messy storage logic.

Core Features & Use Cases

  • Secure uploads with ownership: Namespaces files per user and enforces server-side ownership checks on every read/write.
  • Correct storage + delivery: Defaults to private AWS S3 with CloudFront delivery (or extends an existing S3/R2/UploadThing/Firebase Storage integration without migrating).
  • Validation and quotas: Enforces max size, allowed types, and magic-byte MIME verification to prevent spoofing.
  • Practical use cases: Adding image/PDF uploads, enabling private downloads via short-lived signed URLs, and implementing per-user upload limits.

Quick Start

Tell the AI: "Set up secure per-user file uploads for my app using AWS S3 with CloudFront, including server-side size/MIME validation with magic-byte checks and private download URLs."

Frequently Asked Questions about add-files

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I set up secure file uploads with AWS S3 and CloudFront?

Set up secure file uploads by configuring a private AWS S3 bucket for storage and delivering files through CloudFront using short-lived signed URLs. This enforces server-side ownership checks and validation without exposing public access.

Can I add per-user file upload quotas and MIME verification to my app?

Yes, you can enforce per-user upload quotas and validate files using magic-byte MIME verification. This prevents file spoofing by checking the file's actual bytes against allowed types and max size limits on the server.

What is the best way to add private file storage without migrating my existing provider?

The best way to add private file storage without migrating is to detect and extend your existing storage provider. This approach supports current integrations like R2 or Firebase Storage while enforcing secure ownership checks and signed URL delivery.

Does this file upload approach support folders, tags, and image transforms?

Yes, this file upload approach supports practical use cases including folders, tags, image transforms, and versioning. It namespaces files per user to maintain organization while enforcing strict server-side ownership checks on every read and write.

Why do I need magic-byte MIME checks for S3 file uploads?

You need magic-byte MIME checks for S3 file uploads to prevent file spoofing and security vulnerabilities. Validating the actual file bytes server-side ensures the uploaded file matches its declared type, blocking malicious payloads from entering your storage.

Do I need to migrate my files to use CloudFront delivery with my current storage?

No, you do not need to migrate files to use CloudFront delivery. The implementation detects your existing storage setup and extends it to support correct signed URL delivery behavior and private bucket defaults without requiring data migration.