Couchdb
CouchDB document database with sync. Use for offline-first apps.From its SKILL.md
npx -y skills add G1Joshi/Agent-Skills --skill couchdbAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
One thing to look at
- 12 stars12 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.
SKILL.md
1.6 KB, 377 tokens by cl100k_base, as published. Nobody here has run it
Apache CouchDB
CouchDB is a database that completely embraces the web. It speaks JSON and HTTP. It is unique for its multi-master replication protocol, making it ideal for "Offline First" apps.
When to Use
- Offline First Apps: PouchDB (in browser) + CouchDB (server) is the gold standard for syncing data.
- Peer-to-Peer: Multiple servers can replicate with each other.
- Reliability: Crash-resistant architecture (Append-only storage).
Quick Start
# Create a document via REST API
curl -X PUT http://admin:[email protected]:5984/my_database/doc1 \
-d '{"key": "value"}'
Core Concepts
Multi-Version Concurrency Control (MVCC)
Documents are versioned (_rev). If you update a doc, you must provide the current _rev. If it has changed on server, you get a conflict (409).
CommonJS MapReduce
Views are written in JavaScript functions (Map/Reduce).
Conflict Resolution
Since replication is multi-master, conflicts happen. CouchDB keeps all conflicting revisions and lets the app execute logic to pick a winner.
Best Practices (2025)
Do:
- Use PouchDB: On the client side. It syncs automatically.
- Use Mango Queries (Find): Easier than writing MapReduce views for simple lookups.
- Compact: The append-only file grows forever. Run compaction regularly.
Don't:
- Don't use as a generic backend: It is specialized for sync. If you don't need sync, Postgres/Mongo is often simpler.
References
What ships with it
Read from the repository
Just SKILL.md. No reference files, no scripts.