---
title: "Regenerate 2FA recovery codes for a user."
method: PUT
path: "/api/v1/crm/people/{personUid}/regenerateTwoFactorRecoveryCodes"
tags: ["CRM"]
---

# Regenerate 2FA recovery codes for a user.

`PUT /api/v1/crm/people/{personUid}/regenerateTwoFactorRecoveryCodes`

## Request

- Base URL: `https://go.outseta.com`
- URL: `https://go.outseta.com/api/v1/crm/people/{personUid}/regenerateTwoFactorRecoveryCodes`
- Auth: one of:
  - HTTP bearer
  - API key in header `Authorization`

Use this when a user is locked out of their authenticator. All prior recovery codes are
invalidated. Existing TOTP/Email mechanisms are intentionally left in place — the admin
returns the new codes to the user out of band, the user logs in with one, then re-enrolls
their device. Mirrors the temporary-password flow at SetTemporaryPassword.

## Path parameters

- `personUid` string, nullable, required

## Response `200`

## Other responses

- `400`: Invalid Uid format
- `401`: Unauthorized
- `404`: Entity not found

---

[API](https://skmtc.dev/outseta/apis/outseta-api.md) · [All operations](https://skmtc.dev/outseta/apis/outseta-api/llms.txt) · [OpenAPI document](https://skmtc.dev/outseta/apis/outseta-api/revisions/c362823af82d?raw)
