---
title: "Screen an email you already have"
method: POST
path: "/api/v1/comprehend"
tags: ["comprehend"]
---

# Screen an email you already have

`POST /api/v1/comprehend`

## Request

- Base URL: `https://postfleet.ai`
- URL: `https://postfleet.ai/api/v1/comprehend`
- Auth: HTTP bearer

BYO inbound: submit subject/text/html, get a trust report. Does not provision a mailbox and does not evaluate malware. Paid LLM injection scan runs when quota admits (metered as extractions). Extraction runs only when extraction_schema_id is also supplied. Quota miss is deterministic sanitization + heuristic scan (unmetered). virus_risk is always null.

## Request body

- ComprehendRequest
  - `subject` string
  - `text` string
  - `html` string
  - `attachment_text` string
  - `authentication_results` string: Raw Authentication-Results header. Restores the SPF/DKIM/DMARC prior. Omit if you do not have it.
  - `from` string: Echo-only sender string. Invisible characters are stripped; it is not part of the screened surface.
  - `extraction_schema_id` string: Account-owned schema. Optional: runs extract on the same extractions reservation as the LLM scan. Omit to scan without extract. Quota miss is deterministic sanitization + heuristic (unmetered) either way.

## Response `200`

Trust report.

- ComprehendResult
  - `subject_clean` string, nullable, required
  - `body_clean` string, required
  - `truncated` boolean, required
  - `sanitization` object[], required
    - `kind` string, required
    - `detail` string, required
    - `stripped` string, required
  - `status` 'complete' | 'partial' | 'skipped_injection_risk' | 'skipped_spam' | 'skipped_virus', required
  - `classification` string, nullable, required
  - `extraction` unknown, required
  - `extraction_error` string, nullable, required
  - `confidence` number, nullable, required
  - `model` string, nullable, required
  - `scan_risk` 'low' | 'high' | 'error', nullable, required
  - `heuristic_risk` 'low' | 'high', required
  - `spam_risk` 'low' | 'high' | 'error', nullable, required
  - `virus_risk` unknown, required
  - `not_evaluated` string[], required
  - `spam_evaluated` 'none' | 'content' | 'auth_and_content', required
  - `from` string, nullable, required
  - `auth_results` object, nullable, required
    - `spf` 'pass' | 'fail' | 'softfail' | 'neutral' | 'none' | 'temperror' | 'permerror', required
    - `dkim` 'pass' | 'fail' | 'softfail' | 'neutral' | 'none' | 'temperror' | 'permerror', required
    - `dmarc` 'pass' | 'fail' | 'softfail' | 'neutral' | 'none' | 'temperror' | 'permerror', required

## Other responses

- `400`: Neither text nor html, or invalid body.
- `401`: Missing or invalid bearer token, or a key whose scope is not permitted for this endpoint.
- `403`: Bootstrap key (`scope` not permitted). Mailbox-bound keys are allowed.
- `404`: extraction_schema_id not found on this account.
- `413`: Combined payload over 1,048,576 characters.
- `429`: Per-account hourly cap.

---

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