---
title: "Enable MFA"
method: POST
path: "/v1/users/{id}/mfa/enable"
tags: ["MFA API"]
---

# Enable MFA

`POST /v1/users/{id}/mfa/enable`

Use this endpoint to enable MFA for a user after the passcode has been verified. A valid recovery code is required to confirm the action.

## Path parameters

- `id` string, required

## Request body

- MFAEnableInput — Information required to enable MFA after passcode verification.
  - `secret` string — The TOTP secret (required for app-based MFA).
  - `recoveryCode` string, required — A valid recovery code obtained during MFA setup.
  - `mfaType` 'app' | 'email' | 'sms', required — The type of MFA to enable.

## Response `200`

MFA enabled successfully for the user.

- object
  - `enabled` boolean

## Other responses

- `400`
- `404`
- `500`

---

[API](https://skmtc.net/lerian/apis/identity-plugin.md) · [All operations](https://skmtc.net/lerian/apis/identity-plugin/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/lerian/identity-plugin/versions/25daba385532/schema)
