let factor = AuthenticationFactor.Email(factorId: "email-test-d5a3b680-e8a3-40c0-b815-ab79986666d0")let response = try await StytchConsumer.user.deleteFactor(factor)
Users
Delete Factor
Deletes an authentication factor from the current user’s account. The endpoint called depends on the type of the [AuthenticationFactor] passed: - [AuthenticationFactor.TOTP] → DELETE /sdk/v1/users/totps/{totp_id} - [AuthenticationFactor.Email] → DELETE /sdk/v1/users/emails/{email_id} - [AuthenticationFactor.OAuth] → DELETE /sdk/v1/users/oauth/{oauth_user_registration_id} - [AuthenticationFactor.WebAuthn] → DELETE /sdk/v1/users/webauthn_registrations/{webauthn_registration_id} - [AuthenticationFactor.Biometric] → DELETE /sdk/v1/users/biometric_registrations/{biometric_registration_id} - [AuthenticationFactor.CryptoWallet] → DELETE /sdk/v1/users/crypto_wallets/{crypto_wallet_id} - [AuthenticationFactor.PhoneNumber] → DELETE /sdk/v1/users/phone_numbers/{phone_id}