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

# Case detail

> A whole case on one screen: subjects with their verdict, verification, evidence and attachments, compensations, a timeline with internal comments, the SLA in business hours, assignment, status changes, merge and account linking.

## At a glance

| Field | Value |
| - | - |
| Status | **Available** |
| Route | `/{locale}/customer-care/cases/{id}` |
| Menu | Customer care › Customer care › **Cases** › the `CS-` number |
| Role | Customer Compensation Agent (every case action); Supervisor and Manager (read, assign and merge); Technician (read); Customer care Admin, Operator (no merge) and Viewer (read); Administrator |
| Permission | `customer-compensation-case:find-one` to open it; each action needs its own (see **Business rules**) |
| Feature flag | `customer-compensation` |
| Last verified | 2026-11-24 against `develop` (`060621220`) |

## What it is for

It is the work screen of a case: what is claimed, what evidence exists, what the customer was given, what happened
and when it is due. From here you verify, compensate, comment, assign, change the status and merge.

## How to get there

* **Customer care › Cases** → click the case's `CS-` number.
* Customer record › **Compensations** tab → the case.
* When you open a new case, its detail opens by itself.
* The link in the staff notice e-mail (approvals, SLA breached, assignment) opens the case.

## What you see

> [!NOTE]
>
> The screenshots of this screen are added with the manual's first capture (desktop, light theme).

| # | Element | What it does |
| - | - | - |
| 1 | Header | "Back to cases" arrow, the `CS-` number, the status, the priority and the problem; "Duplicate of {code}" with a link when the case was merged |
| 2 | Action buttons | **Assign**, the status changes the case admits, **Merge**, **Link account** and **Request compensation**, depending on the status and your permissions |
| 3 | No-account notice | "This case has no account: link one to request compensations." |
| 4 | **Subjects** | Each subject with its type (Recharge, Machine, Charge…), its short id, the machine and its verdict; **Verify** and **Request compensation** per subject; **Add subject** |
| 5 | **Compensations** | Benefit, status, units, value, tier, contact and date, with **Cancel request**, **Retry** or **Revoke**; below, **Offered options** with the one the customer chose |
| 6 | **Evidence and attachments** | System verifications, technical inspections, notes and attachments with date, author and hash; **Attach file** and **View file** |
| 7 | **Timeline** | **Internal comment** with **Add comment**, and every case event with its author |
| 8 | **SLA** | **Response** (indicator, **Respond by**, **First response**) and **Resolution** (indicator, **Resolve by**) |
| 9 | **Case data** | Channel, cause, customer, paying organization, business unit, machine, assignee, contact data, opening date, whether the customer was present, external reference, description, resolution and reason |

## Step by step

**1. Assign the case to yourself**

**Assign** opens "Assign {code}": choose the person in **Assignee** and press **Assign**, or use **Assign to me**.
You see "Case assigned" · "The assignment is in the case timeline."

**2. Start the investigation**

**Start investigation** moves the case to **Investigating**. Verifying a subject or adding evidence also starts it.

**3. Verify each subject**

In **Subjects**, press **Verify**. The system gathers the evidence (the recharge, its rating, the machine's
components, alerts and connectivity around that time and how many other customers complained) and freezes it:
"Subject verified" · "The evidence was frozen with its hash." The subject's verdict updates.

**4. Add more subjects when needed**

**Add subject** asks for the record's "Identifier ({type})", of the type the problem uses: "Copy the identifier
from the record's page." Each subject is verified and compensated on its own.

**5. Attach what the customer sent**

**Attach file** uploads photos, videos or PDFs: "Up to 10 files of 20 MB: JPG, PNG, HEIC, PDF, MP4 or MOV." Files
are private; **View file** opens them with a temporary link.

**6. Comment**

Type in **Internal comment** and press **Add comment**. The customer never sees comments.

**7. Compensate**

With **Request compensation**, follow [Requesting a compensation](https://docs.bbrands.io/enterprise/customer-care/request-compensation.md).

**8. Wait for the customer when needed**

**Wait for the customer** sets the case to **Waiting for customer**; **Customer answered** returns it to
investigation.

**9. Resolve**

**Resolve** asks for the **Resolution**. A resolved case closes by itself after 7 days; **Close case** closes it
sooner, and **Reopen** (with a reason) returns it to investigation.

### Merging a duplicate

1. On the duplicate case, press **Merge**. When the case opened with a duplicate warning, the dialog already holds
   the other case and the notice "Another open case with the same subject was found when this case opened. Check
   whether it is a duplicate."
2. Type the **Primary case code**; the dialog shows its customer so you can confirm.
3. Optionally type the **Reason**. Press **Merge**.
4. You see "{code} merged" · "The primary case now holds its content." The case becomes **Merged** and shows
   "Duplicate of CS-…".

### Linking an account to a case without one

1. Press **Link account**: "Choose the account of {name}. The link is audited and cannot be changed."
2. Find the account by RUT or name and press **Link**.
3. You see "Account linked" · "You can now request compensations on the case."

## Business rules

| ID | Rule |
| - | - |
| R-01 | Actions per status: New and Assigned admit **Start investigation** and **Dismiss**; Investigating, **Wait for the customer**, **Resolve** and **Dismiss**; Waiting for customer, **Customer answered**, **Resolve** and **Dismiss**; Resolved, **Reopen** and **Close case**. Closed, Dismissed and Merged admit nothing |
| R-02 | Permissions: start, wait for the customer and customer answered, `customer-compensation-case:update`; resolve, `:resolve`; reopen, `:reopen`; close, `:close`; dismiss, `:dismiss`; assign, `:assign`; merge, `:merge`; verify and attach, `customer-compensation-evidence:create`; comment, add a subject and link an account, `customer-compensation-case:update` |
| R-03 | **Resolve** needs a resolution and is refused while a compensation is pending approval or approved but not applied. **Dismiss** and **Reopen** need a reason; dismissing is refused with live compensations (pending, approved or applied) |
| R-04 | A closed case is final: a new complaint, even about the same subject, opens another case |
| R-05 | Evidence is never edited or deleted. Verifying again adds another row with the verifier version and its hash |
| R-06 | Verdict per subject: the latest technical inspection decides (supports → **Confirmed**, contradicts → **Contradicted**); without one, the latest system verification (**Confirmed**, **Probable**, **Not supported** or **Contradicted**). "Sparkling water without CO2" reaches at most **Probable** without an inspection, because the machine does not measure CO₂ |
| R-07 | Machine evidence is read ±30 minutes around the subject and other customers' complaints ±2 hours; other customers appear only as counts, never who they are |
| R-08 | When a case with cause machine gets a **Confirmed** subject, a maintenance alert opens for the machine, or the open one is linked |
| R-09 | Attachments: at most 20 MB per file and 10 files per case (inspection photos count), only JPG, PNG, HEIC, PDF, MP4 or MOV |
| R-10 | First response: set by the first action of someone other than who opened the case (assignment, comment, verification or status change), or by the first status change out of New |
| R-11 | Merge: only an open case into another, different open case of the same customer, or a case without an account. Its subjects, evidence, comments and attachments move to the primary. Refused while the duplicate has compensations pending approval or approved |
| R-12 | **Link account** happens once and is audited; it cannot be changed afterwards |
| R-13 | Adding a subject, linking an account and reassigning keep the case status |

## States and messages

| Situation | What you see |
| - | - |
| Status change done | "{event}: done" · "The change is in the timeline of {code}." |
| Subject added | "Subject added" · "You can now verify it on {code}." |
| Added subject that is on another case with another problem | "Subject added with a warning" and **Merge** opens with that case |
| Subject already there | "The subject was already on the case" |
| File uploaded | "File attached" · "{name} is on the case." |
| No subjects | "The case has no subjects" |
| No evidence | "No evidence yet" |
| No compensations | "No compensations" |

Timeline events: Case opened, Case assigned, Status change, Comment, Subject added, Evidence added, Verdict changed,
Maintenance alert linked, Account linked, Cases merged, Compensation requested, approved, rejected, applied, failed,
retried or revoked, Request cancelled, escalated, expired or refreshed, Fraud flag set or cleared, Case updated and
Data anonymized.

## Errors

| Message | Cause | Backend code | Support action |
| - | - | - | - |
| "This action does not apply in the current status ({detail})." | The case changed status while you had it open | `409 compensation:invalid_transition` | Reload the case |
| "The case has pending or approved compensations not yet applied." | Resolving or merging with live compensations | `409 compensation:case_has_pending_compensation` | Wait for the decision or cancel the request |
| "The case has ended; open a new one." | The case is closed, dismissed or merged | `409 compensation:case_not_open` | Open a new case |
| "The case already has a linked account." | A second link was tried | `409 compensation:account_already_linked` | Nothing |
| "That person cannot be assigned cases." | The assignee is not staff that reads cases | `422 compensation:assignee_not_staff` | Choose someone else or give them a role |
| "The file is not valid: use JPG, PNG, HEIC, PDF, MP4 or MOV up to 20 MB." | Type or size not allowed | `422 compensation:attachment_invalid` | Convert or shrink the file |
| "The case already holds 10 files." | File limit | `422 compensation:attachment_limit` | Open the existing ones; no more can be uploaded |
| "A case cannot be merged into itself." / "No case has that code" | Wrong primary code | — | Check the code |
| "The identifier does not have the expected format." | The subject id is not a valid id | — | Copy it from the record's page |

## Why it works this way

Evidence is frozen with a hash so that what the agent saw when requesting is exactly what the approver sees and what
stays for the audit: nobody can change it later. Each subject has its own verdict because one case may hold
recharges that failed and others that did not. The SLA is stored as fixed dates on opening so a change of hours or a
new holiday does not move commitments already made to the customer.

## Technical detail

| Aspect | Detail |
| - | - |
| Screen | `frontend/horizon-enterprise/app/lib/features/customer-compensation/presentation/components/CaseDetail.tsx`, with `AssignModal`, `MergeCaseModal`, `LinkAccountModal`, `AddSubjectModal` and `ReasonModal` |
| API | `GET /api/v3/compensation/case/{id}`; `POST …/assign`, `…/transition`, `…/merge`, `…/link-account`, `…/comment`, `…/subject`, `…/evidence/verify`, `…/attachment/upload-url`, `…/attachment`; `GET …/attachment/{evidence}` |
| Data | `customer_compensation_case`, `customer_compensation_case_subject`, `customer_compensation_evidence` (`snapshot`, `snapshot_hash` sha256), `customer_compensation_case_event` |
| Files | Private bucket; viewed through a temporary signed link |
| Staff notices | `account.compensation-case.assigned` to the new assignee; `account.compensation-case.sla-breached` to the assignee and the supervisors |
| Texts | `messages/{es,en}.json` › `modules.customerCare.detail`, `.subjects`, `.evidence`, `.timeline`, `.event`, `.transition`, `.assign`, `.merge`, `.linkAccount`, `.addSubject` |

## FAQ and support cases

> [accordion] I do not see the Request compensation button
>
> It only appears when you hold `customer-compensation:create`, the case has a linked account, has not ended and has
> at least one subject.

> [accordion] The "Sparkling water without CO2" verdict stays Probable
>
> Without a CO₂ sensor the system cannot confirm it alone. Ask for a
> [technical inspection](https://docs.bbrands.io/enterprise/customer-care/inspection.md): when it supports the claim, the subject becomes
> Confirmed.

> [accordion] I merged by mistake
>
> A merge cannot be undone. The content is on the primary case: work from there.

> [accordion] The customer sent an iPhone video and it is refused
>
> MOV and MP4 are allowed up to 20 MB. If it is larger, ask for a shorter one or a photo.

## Related and history

* [Requesting a compensation](https://docs.bbrands.io/enterprise/customer-care/request-compensation.md)
* [Revoking a compensation](https://docs.bbrands.io/enterprise/customer-care/revoke.md)
* [Technical inspection](https://docs.bbrands.io/enterprise/customer-care/inspection.md)

| Date | Change |
| - | - |
| 2026-11-24 | First version |


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.