Consent Lifecycle¶
Models the lifecycle of a Customer Consent record — the legal basis under which the business may process a customer's personal data. A consent is captured, remains active until the customer withdraws it or it expires under the applicable retention policy.
Object: consent ·
States: 5 ·
Transitions: 8
State Diagram¶
flowchart LR
%% ── classDef palette ─────────────────────────────────────
classDef stInit fill:#0d9488,stroke:#0f766e,color:#fff,font-weight:bold
classDef stNorm fill:#3b82f6,stroke:#2563eb,color:#fff
classDef stOk fill:#16a34a,stroke:#15803d,color:#fff,font-weight:bold
classDef stFail fill:#dc2626,stroke:#b91c1c,color:#fff,font-weight:bold
classDef stHold fill:#d97706,stroke:#b45309,color:#fff
%% ── nodes ───────────────────────────────────────────────
pending(["Pending"])
active["Active"]
partially_withdrawn["Partially Withdrawn"]
withdrawn[["Withdrawn"]]
expired[["Expired"]]
%% ── transitions ─────────────────────────────────
pending -->|"consent-recorded"| active
pending -->|"consent-declined"| withdrawn
active -->|"consent-updated"| partially_withdrawn
partially_withdrawn -->|"consent-updated"| active
active -->|"consent-withdrawn"| withdrawn
partially_withdrawn -->|"consent-withdrawn"| withdrawn
active -->|"consent-expired"| expired
partially_withdrawn -->|"consent-expired"| expired
%% ── class assignments ───────────────────────────
class pending stInit
class active,partially_withdrawn stNorm
class withdrawn stOk
class expired stFail
States¶
| State | Label | Description | Initial | Terminal |
|---|---|---|---|---|
pending |
Pending | Consent request presented to customer but not yet confirmed. | ✓ | |
active |
Active | Customer has granted consent; data processing is lawful. | ||
partially-withdrawn |
Partially Withdrawn | Customer has withdrawn consent for some channels (e.g. email) but not all (e.g. transactional). | ||
withdrawn |
Withdrawn | Customer has revoked all consent; data processing must cease. | ✓ | |
expired |
Expired | Consent lapsed due to retention policy or inactivity period. | ✓ |
Transitions¶
| From | To | Trigger | Guards |
|---|---|---|---|
pending |
active |
consent-recorded |
Customer has explicitly accepted consent terms; Consent captured with timestamp and version of terms |
pending |
withdrawn |
consent-declined |
Customer explicitly declined |
active |
partially-withdrawn |
consent-updated |
Customer updated preferences, removing at least one consent channel; At least one consent channel remains active |
partially-withdrawn |
active |
consent-updated |
Customer re-granted all previously withdrawn channels |
active |
withdrawn |
consent-withdrawn |
Customer submitted withdrawal request |
partially-withdrawn |
withdrawn |
consent-withdrawn |
Customer revoked remaining consent channels |
active |
expired |
consent-expired |
Retention period elapsed without renewal; No active session or interaction within policy window |
partially-withdrawn |
expired |
consent-expired |
Retention period elapsed on remaining active channels |