How to reset MongoDB User password in Kotlin using Realm?

Hello I am using MongoDB for my Android app I am developing with Compose and I need to add Reset Password function in my App.

mongoDB.getApp().emailPasswordAuth.resetPassword(password, tokenId, token) this is what I found but I have no idea how to get token and tokenId .

I have also tried mongoDB.getApp().emailPasswordAuth.sendResetPasswordEmail("email@gmail.com") but this causes an error which says:

io.realm.kotlin.mongodb.exceptions.BadRequestException: [Service][BadRequest(48)] please use reset password via function.