register

abstract suspend fun register(registration: DeviceRegistration, installedAt: Instant): Boolean

Registers registration if its address has none. Returns true if it was stored, false if exactly this key is registered already. Throws DeviceRegistrationException.Conflict and changes nothing if another key is registered. Concurrent calls behave as if they ran one after the other: of several different keys for one address, exactly one wins. A new registration has epoch 1 and installedAt as installation time; registering the registered key again changes neither.