---
title: "Counts of one customer's mail held by the PHI screen"
method: GET
path: "/accountant/companies/{customerId}/phi-screen/held-messages"
tags: ["Accountant Portal"]
---

# Counts of one customer's mail held by the PHI screen

`GET /accountant/companies/{customerId}/phi-screen/held-messages`

## Request

- Base URL: `https://api.medianfi.com/api/v1`
- URL: `https://api.medianfi.com/api/v1/accountant/companies/{customerId}/phi-screen/held-messages`
- Auth: HTTP bearer

#1122. For a PHI-bounded customer, how many Gmail messages the PHI screen holds now, by held reason and by the UTC week (Monday) each was received over the last eight weeks, and how many a later sync released. Counts only: held rows store no sender, subject or file name. Any other customer answers `bounded: false`. Requires assignment to the customer (403 otherwise). A failed read of the flag or the rows is 503, never an empty answer.

## Response `200`

Held-mail counts

- object
  - `success` boolean, required
  - `data` object, required
    - `bounded` boolean, required: Whether the customer is PHI-bounded now.
    - `held` integer, required: Messages held now.
    - `released` integer, required: Messages held earlier and released by a later sync.
    - `byReason` object[], required: Messages held now by reason, most first. `not_recorded` for rows written before reasons were stored.
      - `reason` string, required
      - `messages` integer, required
    - `byWeek` object[], required: Messages held now by received week, the last eight weeks, oldest first, zero-filled.
      - `weekStart` string, date, required
      - `messages` integer, required

## Other responses

- `401`: Authentication required
- `403`: Insufficient permissions or not a company member
- `503`: Required sandbox provider configuration or service is unavailable

---

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