• Type: Icon: Improvement Improvement
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: None
    • Component/s: None
    • None

      Add support for logging into MongoDB Realm similar to Realm Java:

       

      interface Credentials {  enum class Provider {    ANONYMOUS("anon-user"),
          API_KEY("api-key"),    // same value as API_KEY as per OS specifications
          APPLE("oauth2-apple"),
          CUSTOM_FUNCTION("custom-function"),
          EMAIL_PASSWORD("local-userpass"),
          FACEBOOK("oauth2-facebook"),
          GOOGLE("oauth2-google"),
          JWT("jwt"),
          UNKNOWN("");  }  companion object {
          fun anonymous(): Credentials
          fun apiKey(key: String): Credentials
          fun apple(idToken: String): Credentials
          fun customFunction(args: Document): Credentials
          fun emailPassword(email: String, password: String): Credentials
          fun facebook(accessToken: String): Credentials    fun google(token: String, type: GoogleAuthType): Credentials    fun jwt(jwtToken: String): Credentials
        }  
        val identityProvider: Provider  fun asJson(): String
      }
      
      class io.realm.mongodb.App {
        suspend fun login(credentials: Credentials): User 
      }

            Assignee:
            claus.rorbech@mongodb.com Claus Rørbech (Inactive)
            Reporter:
            brian.munkholm@mongodb.com Brian Munkholm (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated: