docs: add comprehensive CouchDB schema documentation for cross-implementation compatibility
- Add complete CouchDB document schema specifications in couchdb-schemas.md - Create example JSON documents for mail and sync metadata structures - Implement Rust schema definitions with full serde support and type safety - Add validation script to ensure schema consistency across implementations - Document field definitions, data types, and validation rules - Provide Rust Cargo.toml with appropriate dependencies for future implementation This establishes a solid foundation for the planned Rust implementation while ensuring 100% compatibility with existing Go implementation databases. Both implementations will use identical document structures, field names, and database naming conventions. Schema Features: - Mail documents with native CouchDB attachment support - Sync metadata for incremental synchronization - Predictable document ID patterns for efficient access - Cross-language type mappings and validation rules - Example documents for testing and reference 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
parent
e280aa0aaa
commit
651d95e98b
10 changed files with 908 additions and 0 deletions
10
examples/sample-sync-metadata.json
Normal file
10
examples/sample-sync-metadata.json
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
{
|
||||
"_id": "sync_metadata_INBOX",
|
||||
"_rev": "2-def456abc789123",
|
||||
"docType": "sync_metadata",
|
||||
"mailbox": "INBOX",
|
||||
"lastSyncTime": "2025-08-02T14:26:08.281094+02:00",
|
||||
"lastMessageUID": 123,
|
||||
"messageCount": 45,
|
||||
"updatedAt": "2025-08-02T14:26:08.281094+02:00"
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue