# git-cmdserv/2facode architecture

> Architecture diagram of the GitHub repository git-cmdserv/2facode, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-04). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/git-cmdserv/2facode
- Repository: https://github.com/git-cmdserv/2facode

## Overview

2facode is a browser-only TOTP generator. The documented workflow is to provide a Base32 secret or otpauth:// link and receive a time-based code, with configurable hash algorithm and digit count, a refresh countdown, and copy support. The README says secrets are neither sent to a server nor automatically saved. No source excerpts were provided, so this map keeps the implementation as a single page-level component rather than inferring internal modules or relationships.

Main entry points: [`index.html`](https://github.com/git-cmdserv/2facode/blob/main/index.html) (TOTP generator)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_app["Browser app"]
  node_page["TOTP generator<br/>[index.html]"]
end

node_user(("User"))

node_user -->|"enters secret"| node_page
node_page -->|"shows code"| node_user

click node_page "https://github.com/git-cmdserv/2facode/blob/main/index.html"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_page,node_user toneBlue
```

## Components

### Browser app

- [TOTP generator](https://github.com/git-cmdserv/2facode/blob/main/index.html): `index.html`

### Other components

- **User**

## Connections

- User → TOTP generator: enters secret (evidence: `README.md`)
- TOTP generator → User: shows code (evidence: `README.md`)
