> ## Documentation Index
> Fetch the complete documentation index at: https://docs.playaos.app/llms.txt
> Use this file to discover all available pages before exploring further.

# Clean up duplicate, stuck, and orphaned accounts in PlayaOS

> Find and resolve account data issues from the Accounts page — merge duplicates, promote stuck profiles to active membership, and invite or remove orphaned placeholder records.

The Accounts page at **Admin → Accounts** is your hub for resolving account data issues that build up over time — especially from bulk imports, abandoned sign-ups, and people who signed up twice by accident.

Use it when the roster feels "off" — duplicate names in search results, admins who can't log in, or imported profiles that never finished onboarding.

<Info>
  The **Members** page focuses on confirmed members with a role. **Accounts** focuses on profiles that aren't yet in a clean, active state.
</Info>

## Opening the Accounts page

Navigate to **Admin → Accounts**. You'll see three tabs, each with a count badge showing how many items need review:

* **Duplicates** — profiles sharing a normalized name
* **Needs Attention** — profiles stuck in a problematic state
* **Orphans** — placeholder records from bulk imports that were never claimed

Tabs with a zero count have no outstanding work.

## Merging duplicate profiles

The Duplicates tab groups profiles that share the same normalized full name (case- and whitespace-insensitive). Each card shows every matching profile with its email, status, role, sign-in state, application count, and camp years.

### When to merge

Merge accounts when two profiles clearly represent the same person — for example, someone who applied under a personal email one year and a work email the next, or a member who started a second account after forgetting they already had one.

If two people legitimately share a name, use **Dismiss** instead. Dismissed pairs are remembered so the group won't reappear.

### Running the merge wizard

<Steps>
  <Step title="Open the wizard">
    On a duplicate group, click **Merge**. The wizard opens in a three-step flow: **Select primary → Review → Done**.
  </Step>

  <Step title="Select the primary account">
    PlayaOS recommends a primary account based on a score that favors active status, higher roles, camp year history, and application count. You can override the recommendation with any account in the group. The **Recommended** badge marks the highest-scoring option.
  </Step>

  <Step title="Review the merge plan">
    The review step shows exactly what will happen, including whether sign-in will be transferred between accounts. Confirm to proceed, or go back to pick a different primary.
  </Step>

  <Step title="Done">
    The duplicate profile is deleted and the merge is written to the audit log.
  </Step>
</Steps>

### What happens during a merge

* The duplicate profile and all its related records are permanently deleted.
* If the duplicate account has signed in but the primary hasn't, sign-in is transferred to the primary so they can keep logging in without disruption.
* If both accounts have signed in, the duplicate's sign-in credentials are removed — the primary keeps its own. Let the person know they should use the primary account's sign-in method going forward.
* Every merge is recorded in the audit trail with who ran it, when, and which emails were involved.

<Warning>
  Merges cannot be undone. Double-check the primary selection before confirming.
</Warning>

## Resolving accounts that need attention

The Needs Attention tab surfaces profiles stuck in problematic states:

| Category               | What it means                                                                                                                                 |
| ---------------------- | --------------------------------------------------------------------------------------------------------------------------------------------- |
| **Registered admin**   | An admin role was assigned but the person never completed onboarding.                                                                         |
| **Registered member**  | A member was imported or added but never activated.                                                                                           |
| **New User signed in** | Someone signed in through authentication but their profile still has the placeholder "New User" name, meaning they never finished onboarding. |

### Promoting profiles to active

Select one or more profiles in the Needs Attention tab and click **Promote to Active**. This:

* Sets status to `active`
* Upgrades `applicant` → `member` (other roles are left as-is)
* Adds the person to the active camp year roster
* Approves any of their draft applications for the active year

<Tip>
  Promote in bulk when reconciling a batch of imports at once — select multiple rows and run the action a single time.
</Tip>

## Handling orphan profiles

The Orphans tab lists placeholder "New User" profiles created by bulk import that were never claimed (no one ever signed in against them). You have two ways to resolve them:

* **Send invite** — marks the profile as invited so the standard invite email goes out. Use this when the person should still join your camp.
* **Delete** — removes the placeholder entirely. Use this for stale imports, test data, or people who are no longer joining.

<Note>
  An orphan profile can only be invited once through this action. If the person never claims it, delete the placeholder and re-add them through **Admin → Members**.
</Note>

## Reviewing the merge audit log

Every merge is recorded with:

* The primary profile that was kept
* The email of the merged profile
* Which admin performed the merge
* A timestamp
* Details about whether sign-in was transferred

Check **Admin → Audit** to review merge activity alongside other system events.
