reset
abstract suspend fun reset(request: IB2BPasswordSessionResetParameters): B2BPasswordSessionResetResponse
Resets a member's password using their active session for verification (no existing password required). Calls the POST /sdk/v1/b2b/passwords/session/reset endpoint. Requires an active session.
Kotlin:
StytchB2B.passwords.session.reset(
B2BPasswordSessionResetParameters(password = "newpassword")
)Content copied to clipboard
iOS:
let params = B2BPasswordSessionResetParameters(password: "newpassword")
let response = try await StytchB2B.passwords.session.reset(params)Content copied to clipboard
React Native:
StytchB2B.passwords.session.reset({ password: "newpassword" })Content copied to clipboard
Return
B2BPasswordSessionResetResponse containing the updated member session.
Parameters
request
IB2BPasswordSessionResetParameters
password— The new password to set for the currently authenticated member.
Throws
StytchError
if no active session exists or the password does not meet strength requirements.
if the coroutine is cancelled.