RegisterRequest

data class RegisterRequest(account: String, voice: Boolean?, captcha: String?, server: String?) : SignaldRequestBodyV1<Account>

begin the account registration process by requesting a phone number verification code. when the code is received, submit it with a verify request

Constructors

Link copied to clipboard
fun RegisterRequest(account: String, voice: Boolean? = null, captcha: String? = null, server: String? = null)

Functions

Link copied to clipboard
fun submit(socketCommunicator: SocketCommunicator): Account
open override fun submit(socketCommunicator: SocketCommunicator, id: String): Account
Link copied to clipboard
suspend fun submitSuspend(socketCommunicator: SuspendSocketCommunicator): Account
open suspend override fun submitSuspend(socketCommunicator: SuspendSocketCommunicator, id: String): Account

Properties

Link copied to clipboard
val account: String

the e164 phone number to register with

Link copied to clipboard
val captcha: String? = null

See https://signald.org/articles/captcha/

Link copied to clipboard
val id: String

The id to include in the request. This is expected to be present in the response JSON.

Link copied to clipboard
val server: String? = null

The identifier of the server to use. Leave blank for default (usually Signal production servers but configurable at build time)

Link copied to clipboard
val version: String

The version to include in the request. As this class won't be used to deserialize the response, the Required annotation is being used to force this field to be serialized

Link copied to clipboard
val voice: Boolean? = null

set to true to request a voice call instead of an SMS for verification