> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.tradeguardins.com/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.tradeguardins.com/_mcp/server.

# Reading Compliance Results

> How TradeGuard reports each check on a requirement (required vs found, the outcome, and where on the certificate it was read).

# Reading compliance results

Every requirement on a subcontractor has a **compliance record** with an overall `status`. Behind that status is a list of individual **checks**: one per limit, endorsement and expiration date the requirement asks for. The web app shows the same checks on each subcontractor's Requirements tab.

You get the checks in `checkResult.criteriaResults` from:

* `GET /v1/subcontractors/{subcontractorId}/compliance` (every requirement for the subcontractor)
* `GET /v1/compliance/{complianceRecordId}` (one record, with its check history)

## One check

```json
{
  "key": "limit:each_occurrence",
  "label": "Each Occurrence",
  "field": "general_liability.each_occurrence",
  "rule": "gte",
  "expected": 1000000,
  "actual": 500000,
  "outcome": "fail",
  "passed": false,
  "message": "Each Occurrence: $500,000 is below the required $1,000,000 minimum.",
  "policyType": "general_liability",
  "evidence": { "documentId": "6f1c…" },
  "confidence": 0.94
}
```

| Field                 | Meaning                                                                                                                                                  |
| --------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `label`               | Plain-English name of the check.                                                                                                                         |
| `expected`            | What the requirement asks for.                                                                                                                           |
| `actual`              | What the certificate shows. `null` when it isn't on the certificate.                                                                                     |
| `rule`                | How the two are compared: `gte` (at least), `lte` (at most), `includes`, `not_expired` and others. New rules may be added.                               |
| `outcome`             | The result of the check (see below).                                                                                                                     |
| `passed`              | `true` exactly when `outcome` is `pass` or `waived`. Kept so older integrations keep working.                                                            |
| `message`             | A sentence built from the values above. TradeGuard never writes it with AI.                                                                              |
| `policyType`          | The policy the check is about, e.g. `general_liability`. `null` for a check on the certificate as a whole (certificate holder, insured name, signature). |
| `evidence.documentId` | The certificate the value was read from, when known.                                                                                                     |
| `evidence.page`       | The page of that document the value was read on, when known.                                                                                             |
| `evidence.text`       | The words on the certificate the value was read from, when known.                                                                                        |
| `confidence`          | How sure the certificate reader was of the value, from 0 to 1, when known.                                                                               |

## Outcomes

| `outcome`                | Shown in the web app as                    | What it means                                                                                                                                                                                                                                                                                                                                                          |
| ------------------------ | ------------------------------------------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `pass`                   | Meets                                      | The certificate meets the requirement.                                                                                                                                                                                                                                                                                                                                 |
| `fail`                   | Doesn't meet (for a limit: "Short \$500K") | The certificate clearly doesn't meet the requirement.                                                                                                                                                                                                                                                                                                                  |
| `not_on_certificate`     | Not on the certificate                     | The field is blank on the certificate. TradeGuard never reads a blank as \$0 or "no". Counts as not passing.                                                                                                                                                                                                                                                           |
| `needs_review`           | TradeGuard reviewing                       | TradeGuard couldn't tell what the certificate says: it was read with under 70% confidence, or it's ambiguous. A TradeGuard operator looks at the certificate and decides. A policy whose expiration date is on or before its effective date gets a `policy_dates` check with this outcome: the dates were misread, so the policy is neither passed nor called expired. |
| `waived`                 | Waived                                     | The check is waived for this policy. Counts as passing.                                                                                                                                                                                                                                                                                                                |
| `waiting_on_sub`         | Waiting on the sub                         | The check needs an answer from the subcontractor first. Counts as not passing.                                                                                                                                                                                                                                                                                         |
| `waiting_on_information` | Waiting on information                     | A Secretary of State or license check can't run until information is added to the subcontractor (`checkResult.informationNeeded` lists it). Counts as not passing. See [Secretary of State and License Checks](/getting-started/secretary-of-state-and-license-checks).                                                                                                |

Treat an outcome you don't recognize as not passing. Records written before October 2026 may not have `outcome`, `label` or `field`; use `passed` and `message` for those.

## When a check needs review

If the only checks not passing are `needs_review`, the record's `status` is `under_review` rather than `non_compliant`, and `statusReason` names the check. Nothing is asked of you or the subcontractor.

A TradeGuard operator compares the value against the certificate and records pass or fail. You then get a `compliance.status_changed` webhook with the new status, and the record's `statusReason` starts with "TradeGuard ops review:". That decision holds until a new certificate arrives, which is checked afresh.

## Requirement status

The record's `status` sums up its checks. The web app shows it as:

| `status`                         | Shown in the web app as                                          | What it means                                                                                                                                                                                                                                                                                                                                                                                                                                                                |
| -------------------------------- | ---------------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `compliant`                      | Met                                                              | Every check passes.                                                                                                                                                                                                                                                                                                                                                                                                                                                          |
| `compliant_pending_verification` | Met · confirming with broker                                     | The certificate passes; TradeGuard is confirming the policy with the broker.                                                                                                                                                                                                                                                                                                                                                                                                 |
| `non_compliant`                  | Not met                                                          | At least one check is `fail` or `not_on_certificate`.                                                                                                                                                                                                                                                                                                                                                                                                                        |
| `expired`                        | Expired                                                          | The policy on file has expired. Its limits and endorsements are still checked and listed with the expiry, so you can see everything the renewal certificate must fix.                                                                                                                                                                                                                                                                                                        |
| `under_review`                   | TradeGuard reviewing                                             | The only checks not passing are `needs_review`.                                                                                                                                                                                                                                                                                                                                                                                                                              |
| `pending`                        | Awaiting document, Waiting on the sub, or Waiting on information | No document is on file yet (`checkResult.awaitingDocument` is `true`), the only checks not passing are `waiting_on_sub`, a Secretary of State / license check is waiting on information (`checkResult.informationNeeded`), or the requirement applies only when the sub uses business vehicles and the sub hasn't said whether it does (`checkResult.enforcement.conditionMet` is `null`; the reason reads "Waiting on the sub: confirm whether you use business vehicles"). |
| `not_applicable`                 | Doesn't apply                                                    | A conditional requirement whose condition is off for this subcontractor, for example the sub confirmed it uses no business vehicles.                                                                                                                                                                                                                                                                                                                                         |

## Showing checks by policy

One requirement can have checks on several policies, for example an additional insured endorsement required on both general liability and auto. The web app groups a requirement's checks under each policy, and puts checks on the certificate as a whole in their own group. To do the same, group `criteriaResults` by `policyType`; rows written before October 2026 may not have it, so fall back to the requirement's `policyType`.

## Opening the certificate a value came from

When a check has `evidence.documentId`, get a short-lived download link for that document with `GET /v1/subcontractors/{subcontractorId}/documents/{documentId}` ([Documents](/api-reference/documents)). `$TG` and `$TG_KEY` are set up in the [Quickstart](/getting-started/quickstart):

```bash
curl -s "$TG/v1/subcontractors/$SUB_ID/documents/$DOCUMENT_ID" -H "Authorization: Bearer $TG_KEY" | jq -r .data.downloadUrl
```

Open `data.downloadUrl`. When the check also has `evidence.page`, add `#page=<page>` to the link so PDF viewers open on that page. The web app's "View on certificate" link does exactly this.

## Re-checking after you change a profile

Editing or removing a requirement re-checks every subcontractor on its profile automatically; the edit's response says how many in `meta.runsTriggered`.

After a change to the profile's settings, or whenever you want fresh results, start a re-check yourself:

```bash
curl -s -X POST "$TG/v1/compliance-profiles/$PROFILE_ID/recheck" -H "Authorization: Bearer $TG_KEY"
```

```json
{
  "data": {
    "complianceProfileId": "9b2e…",
    "runsTriggered": 12,
    "message": "Re-checking 12 enrollments. Results will be delivered via webhook."
  }
}
```

It starts one compliance run per enrolled subcontractor (trigger `manual`) and returns `202` straight away. Send `{"subcontractorIds": ["…"]}` to re-check only some of them. Each run reports through the `compliance.run_completed` and `compliance.status_changed` webhooks. To re-check one subcontractor against one profile, use `POST /v1/subcontractors/{subcontractorId}/compliance/check` ([Compliance](/api-reference/compliance)). The web app's "Re-check subs" button on a profile page, and the prompt after you save the profile's settings, call the same endpoint. Requires scope `compliance:write`.