Kotlin: Create a new user

Creates a new user.

Examples

Sign up with email

val user = supabase.gotrue.signUpWith(Email) {
    email = "example@email.com"
    password = "example-password"
}

Sign up with a phone number

val user = supabase.gotrue.signUpWith(Phone) {
    phoneNumber = "+4912345679"
    password = "example-password"
}

Sign up with additional user metadata

val user = supabase.gotrue.signUpWith(Email) {
    email = "example@email.com"
    password = "example-password"
    data = buildJsonObject {
       put("first_name", "John")
       put("age", 24)
    }
}

Sign up with a redirect URL

val user = supabase.gotrue.signUpWith(Email, redirectUrl = "https://example.com") {
    email = "example@email.com"
    password = "example-password"
}