Add sync conflict detection and resolution system
Implement conflict detection for concurrent reading progress updates from different devices. Adds conflict management endpoints for listing, viewing, and resolving conflicts. - Add ConflictHandler with CRUD endpoints for conflict management - Implement automatic conflict detection in KOReader progress updates - Add WebSocket broadcast for real-time conflict notifications - Add database query for listing user conflicts by status - Add integration tests and Bruno API test collection
This commit is contained in:
@@ -0,0 +1,36 @@
|
||||
meta {
|
||||
name: List Conflicts
|
||||
type: http
|
||||
seq: 1
|
||||
}
|
||||
|
||||
get {
|
||||
url: {{baseUrl}}/api/conflicts?status=unresolved
|
||||
body: none
|
||||
auth: bearer
|
||||
}
|
||||
|
||||
headers: {
|
||||
Authorization: Bearer {{token}}
|
||||
}
|
||||
|
||||
docs: {
|
||||
Lists all sync conflicts for the authenticated user.
|
||||
|
||||
Query Parameters:
|
||||
- status: Filter by resolution status (unresolved, user_resolved, auto_resolved, all)
|
||||
|
||||
Response includes:
|
||||
- conflicts: Array of conflict details
|
||||
- total: Total number of conflicts
|
||||
- unresolved: Number of unresolved conflicts
|
||||
|
||||
Each conflict includes:
|
||||
- id: Conflict UUID
|
||||
- media_item_id: Associated book UUID
|
||||
- media_item_title: Book title
|
||||
- conflict_type: Type of conflict (progress, note, highlight)
|
||||
- conflict_data: Side-by-side comparison of conflicting data
|
||||
- resolution_status: Current status
|
||||
- created_at: When conflict was detected
|
||||
}
|
||||
Reference in New Issue
Block a user