Features Code Calculator Fine Print Documentation GitHub
v0.2.0 — now with migrations, relationships & caching

Your database is
a bucket now.

Define a Pydantic model. Get a production-shaped REST API — auth, admin panel, pagination, migrations — backed by the cheapest, most durable storage on Earth. Yes, we're serious. (Kind of.)

$ pip install s3verless
// how this works

Three steps. No YAML.
No 3AM pages.

S3verless stores each record as a JSON object in a bucket, keeps indexes in the bucket, and generates the whole API layer for you. Your infra diagram becomes a single rectangle.

STEP 01

Define a model

Plain Pydantic. Add _indexes, _unique_fields, relationships — the stuff your ORM made you suffer for.

STEP 02

Get a full API

create_s3verless_app() hands you CRUD endpoints, JWT auth, filtering, pagination, and an admin GUI at /admin.

STEP 03

Deploy anywhere

It's just FastAPI. Lambda + Mangum, Docker, a VPS, your homelab. The "database" is already deployed — it's a bucket.

// feature list

Features that shouldn't work.
But absolutely do.

Everything below is real, tested, and in the PyPI package today. We checked twice because we didn't believe it either.

S3 as a "Database"

Records as JSON objects, indexes as more JSON objects. Query it like a database. Your DBA is crying. You're laughing.

Auto-Generated APIs

One model in, full REST API out. CRUD, pagination, filtering, sorting — generated on FastAPI, documented by OpenAPI.

JWT Auth in S3

Users? S3. Refresh tokens? S3. Token blacklist? S3. Rate limiting included, because we contain multitudes.

v0.2

Relationships

has_many, has_one, foreign keys, cascade deletes. Foreign key constraints enforced... in a bucket. Science can't explain it.

v0.2

Migrations

Add, remove, rename, transform fields across every object in the bucket. Versioned, runnable, reversible-ish.

v0.2

Caching

In-memory, LRU, and composite backends. Because even we admit that listing a bucket on every request is a lifestyle choice.

v0.2

File Uploads

Presigned upload URLs out of the box. Files go straight to S3 — which, to be fair, is the one thing S3 was actually built for.

Admin Interface

Auto-generated admin panel at /admin. Browse, edit, and delete your JSON files like a professional data engineer.

v0.2

Testing Toolkit

InMemoryS3 and model factories. Unit-test your bucket app without touching a bucket. The irony is not lost on us.

// show me the code

This is the entire backend.
Seriously.

No Docker Compose with 6 services. No connection pool tuning. Just Python and a bucket.

from s3verless import BaseS3Model, create_s3verless_app from pydantic import Field class Product(BaseS3Model): _plural_name = "products" # → /products _indexes = ["category"] # fast lookups (for S3 values of "fast") _unique_fields = ["sku"] # uniqueness enforced. in a bucket. name: str sku: str price: float = Field(gt=0) stock: int = 0 app = create_s3verless_app( title="My S3 Store", model_packages=["models"], enable_admin=True, )
# An actual query API. Filter, sort, paginate. products = await query(Product, s3, bucket).filter( category="electronics", price__lt=1000, ).order_by("-created_at").limit(10).all() # Relationships work too. CASCADE deletes included, # because we fear no god. class Author(BaseS3Model): name: str posts = has_many("Post", foreign_key="author_id", on_delete=OnDelete.CASCADE)
# JWT auth with refresh tokens, token blacklist, # and rate limiting. Users live in the bucket too. class Post(BaseS3Model): _require_ownership = True # users can only touch their own _owner_field = "user_id" user_id: str title: str content: str # Endpoints you get for free: # POST /auth/register POST /auth/login # POST /auth/refresh POST /auth/logout
POST /products # create GET /products # list + filter + paginate GET /products/{id} # read PUT /products/{id} # update DELETE /products/{id} # delete (pour one out) POST /auth/register # JWT auth, in S3 GET /admin # admin GUI GET /docs # OpenAPI, courtesy of FastAPI # Database servers provisioned: 0 # Buckets involved: 1
// interactive evidence

The "wait, that's it?"
cost calculator

Drag the sliders. Watch your database bill approach zero. Actual S3 pricing, no tricks — storage plus request costs.

storage0.2 GB → $0.005
requests (GET+PUT)$0.27
$0.28 /month
vs cheapest managed Postgres: $15.00/month
You save $176/year — that's 35 coffees
// S3 standard: $0.023/GB-mo, GET $0.0004/1k, PUT $0.005/1k
// postgres floor: smallest RDS you can provision without crying
// a fair and balanced comparison

Why would you do this?

Great question. Here's an objective analysis.

With a "real" database

  • Set up PostgreSQL server
  • Configure connection pooling
  • Manage database migrations
  • Monitor query performance
  • Scale read replicas
  • Pray backups work
  • Pay for RDS
  • Wake up at 3AM

With S3verless

  • Create S3 bucket
  • Write Python code
  • Deploy
  • Go to beach
  • Check phone: app still works
  • Pay $0.02/month
  • Sleep peacefully
  • Live your best life
// the fine print

When you should
not use this

We're joking around, but we're not monsters. Here's the honest list:

! thousands of writes/sec

S3 has per-prefix request limits and no transactions. If you're building a high-frequency trading platform, please use a real database. And therapy.

! complex joins & transactions

We fake relationships with indexes and optimism. Multi-row ACID transactions across tables? That's Postgres's whole thing. Let it have it.

! sub-50ms read latency at scale

Our advanced query engine downloads things and filters them in Python. We ship caching to cope. For your MVP's 200 users, it's genuinely fine.

// for MVPs, prototypes, internal tools, and side projects: ship it and thank us later

// social proof*

What people are saying

The community has spoken.

I showed this to our DBA and they had to lie down.

Sarah K.

senior dev, questionable choices

My infrastructure diagram is just a bucket now. My manager thinks I'm not working.

Mike R.

devops engineer (unemployed soon)

I went from 10 AWS services to 1. I don't know what to do with all this free time.

Jessica L.

full stack dev, living her best life

*these are totally real and not made up. trust us.

// join the bucket

Ship it. The bucket
can take it.

Free, open source, MIT licensed. 101 passing tests. Zero database servers were harmed in the making of this framework.

$ pip install s3verless