SyncResponse

@Serializable
data class SyncResponse<Change>(val syncVersion: Int, val mode: String, val applied: List<SyncAppliedRecord> = emptyList(), val serverChanges: List<Change> = emptyList(), val cursor: String? = null, val hasMore: Boolean = false, val fullResyncRequired: Boolean = false, val metadataExtra: Map<String, String> = emptyMap())

Wire response envelope for one sync pass against a single resource.

Constructors

Link copied to clipboard
constructor(syncVersion: Int, mode: String, applied: List<SyncAppliedRecord> = emptyList(), serverChanges: List<Change> = emptyList(), cursor: String? = null, hasMore: Boolean = false, fullResyncRequired: Boolean = false, metadataExtra: Map<String, String> = emptyMap())

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard
@SerialName(value = "applied")
val applied: List<SyncAppliedRecord>
Link copied to clipboard
@SerialName(value = "cursor")
val cursor: String?
Link copied to clipboard
@SerialName(value = "fullResyncRequired")
val fullResyncRequired: Boolean
Link copied to clipboard
@SerialName(value = "hasMore")
val hasMore: Boolean
Link copied to clipboard
@SerialName(value = "metadataExtra")
val metadataExtra: Map<String, String>

Free-form pass-through metadata (e.g. quota/subscription-tier hints) that the engine itself never reads. Apps can stash product-specific fields here and read them back out of SyncCursorStore without the generic engine needing to know they exist.

Link copied to clipboard
@SerialName(value = "mode")
val mode: String
Link copied to clipboard
@SerialName(value = "serverChanges")
val serverChanges: List<Change>
Link copied to clipboard
@SerialName(value = "syncVersion")
val syncVersion: Int