> For the complete documentation index, see [llms.txt](https://cortex-docs.paloaltonetworks.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://cortex-docs.paloaltonetworks.com/application-security/code-security/application-security-scans-management/manage-scans-through-the-tenant-ui/scan-health.md). Agents can also search and read this documentation through its [MCP server](https://cortex-docs.paloaltonetworks.com/~gitbook/mcp).

# Scan health

Scan health shows whether a scan produced complete results, which scanner failed, and how to fix the failure. Every scan record reports a status for each scanner and sub-scanner, with a structured error code for each error.

**Scope**: Scan health reports scan execution only. Scan health does not change what scanners detect, and does not alter findings, issues, or scanner configuration.

### How scan health works

Scanners in one scan succeed or fail independently, so scan health reports two levels of status.

* **Global scan health**: Reports one status for the scan, aggregated from the enabled scanners. Appears in the Scan Health column of the scan table, and the badge in the Scanner Health section header in the side panel
* **Scanner health**: Reports one status per scanner — SCA, IaC, Secrets — plus the SCA sub-scanners. Appears in rows in the **Scanner Health** section of the side panel’s **Overview** tab. The SCA row also lists its sub-scanners

**Note**: Turned-off scanners are ignored, so **Completed** does not mean every scanner ran. A failed scanner reports `0` findings because it did not run.

***

### Prerequisites

* An active VCS data source with onboarded repositories
* Permission to open the Scan Management pages. If you can open Branch Periodic Scans, Pull Request Scans, or CI Code Scans, you can see the scan health of those scans
* For the public API, an API key with a role that can use the scan management APIs

***

## Review the health of a scan

flowchart TD

A\[Open the scan record] --> B{Global scan health}

B -- Completed --> C\[No action]

B -- In progress --> D\[Wait for the scan to complete]

B -- Partial or Failed --> E{Connector Errors banner on the repository asset page?}

E -- Yes --> F\[Fix the data source]

E -- No --> G\[View errors for the failed scanner]

G --> H\[Apply the resolution, or download the report for support]

F --> I\[Rescan]

H --> I

I --> J\[Confirm on the new scan record]

#### Step 1: Check the Scan Health column

1. Select **Modules > Application Security > Scans**, then Branch Periodic Scans, Pull Request Scans, or CI Code Scans.\
   The **Scan Health** column shows one badge per scan:

| **Badge**           | **Meaning**                                                       | **Action**                                                              |
| ------------------- | ----------------------------------------------------------------- | ----------------------------------------------------------------------- |
| **Completed**       | Every enabled scanner completed                                   | None                                                                    |
| **Partial**         | Some enabled scanners completed, and some did not                 | Open the scan to find the failed scanner before you act on the findings |
| **Failed**          | No enabled scanner completed, or the data source blocked the scan | Open the scan. Treat the repository as unscanned for this run           |
| **In** **progress** | The scan is still running                                         | Check again after the scan completes                                    |

#### Step 2: Open the scan

Select a scan row displaying **Partial** or **Failed** scan health. The side panel opens on the **Overview** tab, and the **Scanner Health** section appears below **Scan Details**. Its header shows the same badge as the column.

If the section reads **Unable to load scanner health details**, the details are missing or unreadable. The badge is still correct.

**Note**: You can also access scan health records on a repository asset side page: Navigate to **Inventory > All Assets > Repositories** **>** select a row in the table > select a row in the **Scan Information table** under the **Overview** tab.

#### Step 3: Read the scanner rows

Each scanner row carries a Completed, Partial, Failed, or Disabled badge. A disabled row is dimmed. If the scan failed before any scanner ran, the header shows Scan failed and the step that failed.

The SCA row lists its sub-scanners: Vulnerabilities, Licenses, Malicious Packages, and Package Operational Risk. A green check means the sub-scanner completed, and a red warning triangle means it failed. For example, if SCA is Partial and only Vulnerabilities has a red triangle, the license, malicious package, and operational risk results are usable, but the vulnerability results are not.

To find other scans with the same failed sub-scanner, filter the table by Sub Scanner Statuses. See [#filter-the-scan-management-tables-by-scanner-status](#filter-the-scan-management-tables-by-scanner-status "mention").

IMPORTANT: Sub-scanner isolation applies to platform-orchestrated scans. Do not assume the same isolation for CLI scans.

#### Step 4: View the errors

On a **Partial** or **Failed** scanner row, select **View errors**. The panel shows a list of the scanner's errors. Each error states what went wrong and how to fix it.

| **Column**      | **Contents**                                                                       |
| --------------- | ---------------------------------------------------------------------------------- |
| **Scanner**     | The scanner that emitted the error.                                                |
| **Sub-scanner** | The emitting sub-scanner. Empty for scanner-level errors.                          |
| **Reason**      | What happened? Reads General scan error when no specific text exists.              |
| **Error Code**  | Always populated. Quote the code in support tickets. See Reference B: Error codes. |
| **Resolution**  | The fix, or Contact support for assistance.                                        |
| **Timestamp**   | When the error was recorded.                                                       |

If **Unable to display scan errors** appears, the error details are temporarily unavailable. Refresh later. The statuses remain accurate.

#### Step 5: Fix the failure and rescan

1. For each error, apply the fix given in the **Resolution** column.
2. If the Resolution is Contact support for assistance, or the fix does not work, note the Error Code and select **Back**. In the **Scanner Health** header, select **Download errors report**, and send the report and error code to Cortex support:
   * **Periodic scans:** Choose **Download this repository's report** or **Download periodic scan report**.
   * **Pull request and CI scans:** The button downloads the repository report directly.
   * Reports contain error metadata only. They do not contain secrets, tokens, source code, or file contents.
3. Run the scan again:
   * **Periodic scans:** Select **Rescan**. Rescan requires permission to run periodic scans. AI-assisted scans also require the AI scanner to be available.
   * **Pull request and CI scans:** Re-run the scan from the pull request or pipeline.
4. Verify: Open the **new** scan record and confirm the scanner reports Completed. A scan record does not change when a later scan succeeds.

IMPORTANT: Until a later scan completes the failed scanner, treat the repository as unassessed by that scanner.

## Resolve a data source failure

1. Select **Inventory > All Assets > Repositories**.
2. Filter Repositories by the exact repository name from your file.

   **Note**: If no row is returned, the repository is not discovered. Open **Data Sources & Integrations**, find the data source for that organization, and fix its connection.
3. Select the repository row. The **Overview** tab of the side panel opens.
4. Below the **Scan Information** table, check for one of these banners:
   * **Connector errors** (fix data source errors to complete the scan): Cortex Cloud cannot connect to the repository, so the scanners cannot run.
   * **Connector warnings** (this data source reported warnings. Some results may be incomplete): The connection has problems, so some results may be missing.
5. In the banner, select **Go to Data Source settings**.

   The **Data Sources & Integrations** page opens.
6. Find the data source that serves this repository, open it, and fix the connection error.
7. Run the scan again, as described in **Review the health of a scan**, **Step 5**.
8. Confirm the banner is gone and the new scan is not Failed.

IMPORTANT: Fix the data source before you work on scanner errors in the same scan. The scanner errors are caused by the connection failure.

### Repositories with no scan history

An archived repository shows Archived repository in the Scan Information section, prefixed with No scans executed. To scan the repository, unarchive it in the VCS.

For any other repository with no scan history, confirm the repository is in scan scope and the data source reports no errors.

### Scan errors in pull request, CI, and CLI output

The scan result stays pass or fail. Error detail is added context. If a scan times out, the result is fail when the pull request or pipeline is set to block on scan errors, and pass otherwise.

* **Pull request scans:** In the pull request comment, below the result line.
* **CI scans:** In the CI job log.
* **CLI scans:** In the CLI output, beside the result.

Each error prints the code, reason, and resolution. An error without customer-facing text prints a generic message and the code. Warnings are labeled as warnings and do not fail the scan.

IMPORTANT: A pass on a scan in which a scanner errored is unproven. Re-run the scan after you resolve the error.

### Query scan health through the public API

Use the public API to monitor scan health and alert on failures across repositories. For the API documentation, refer to [Application Security APIs](https://cortex-docs.paloaltonetworks.com/cortex-cloud-api/aspm-cicd-and-application-security/application-security-overview.md).

#### Supported operators

| Operation                   | Method | Endpoint                              |
| --------------------------- | ------ | ------------------------------------- |
| **List periodic scans**     | GET    | /public\_api/appsec/v1/scans/periodic |
| **List pull request scans** | GET    | /public\_api/appsec/v1/scans/pr       |
| **List CI scans**           | GET    | /public\_api/appsec/v1/scans/ci       |

<br>

| Parameter        | Format                      | Accepted values                                                                         |
| ---------------- | --------------------------- | --------------------------------------------------------------------------------------- |
| scanHealth       | Single value                | COMPLETED, PARTIALLY\_COMPLETED, ERROR, IN\_PROGRESS                                    |
| scannerStatus    | SCANNER:status              | SCA, IAC, SECRETS with Completed, Failed, Disabled                                      |
| subScannerStatus | SCANNER:SUB\_SCANNER:status | SCA with CVE, LICENSES, OPERATIONAL\_RISK, MALICIOUS\_PACKAGES, and Completed or Failed |
| days             | Number                      | Default 7                                                                               |
| limit, offset    | Number                      | Pagination                                                                              |

### Filter the Scan Management tables by scanner status

Use filters to find every scan that needs attention, instead of checking scans one at a time.

1. Open **Branch Periodic Scans**, **Pull Request Scans**, or **CI Code Scans**.
2. Select the filter icon, then add one or more of these filters:

   * **Scan Health:** Scans by overall status. For example, select **Failed** and **Partial** to list every scan that needs attention.
   * **Scanner Statuses:** Scans where a specific scanner has a given status.
   * **Sub Scanner Statuses:** Scans where a specific SCA sub-scanner has a given status.

   Scanner Statuses and Sub Scanner Statuses values combine a scanner, an optional sub-scanner, and a status, in lowercase:

   * **Scanner Statuses:** Use `SCANNER:status`.
     * Scanners: `SCA`, `IAC`, or `SECRETS`
     * Statuses: `completed`, `failed`, or `disabled`
     * Example: `SCA:failed`
   * **Sub Scanner Statuses:** Use `SCA:SUB_SCANNER:status`.
     * Sub-scanners: `CVE` (Vulnerabilities), `LICENSES` (Licenses), `MALICIOUS_PACKAGES` (Malicious Packages), or `OPERATIONAL_RISK` (Package Operational Risk)
     * Statuses: `completed` or `failed`
     * Example: `SCA:CVE:failed`

   For example, `SCA:CVE:failed` lists scans whose vulnerability results are missing. `SCA:MALICIOUS_PACKAGES:completed` lists scans with usable malicious package results.
3. Check the result count, for example 49 out of 121 results, then select a scan row to review it.

The table also shows Scanner Statuses and Sub Scanner Statuses columns, so you can compare results without opening each scan.

***

### Reference A: Scan health status values

This appendix maps each status value to the level where it applies.

| State       | Global scan | Scanner | SCA sub-scanner | Scanner-level meaning                                                     |
| ----------- | ----------- | ------- | --------------- | ------------------------------------------------------------------------- |
| Completed   | ✓           | ✓       | ✓               | Finished and produced results.                                            |
| Partial     | ✓           | ✓       | ✗               | Finished, but some work did not complete. Not filterable through the API. |
| Failed      | ✓           | ✓       | ✓               | Produced no usable results.                                               |
| Disabled    | ✗           | ✓       | ✗               | Turned off in scan configuration. Never affects global scan health.       |
| In progress | ✓           | ✗       | ✗               | —                                                                         |

> **Note:** Scan health and scan status are separate signals. Scan health reports whether the scanners ran. Scan status reports the policy verdict for a CI or pull request scan; see «SCAN STATUS PAGE TITLE». A scan can report a **Passed** scan status with «PARTIAL» scan health: the verdict was reached on incomplete evidence.

***

### Reference B: Error codes

This appendix explains the scan error code format.

Error codes use the form APPSEC-{COMPONENT}-{SEQUENCE} — for example, APPSEC-SCA-001, an SCA failure to resolve the dependency tree. A GENERAL suffix, such as APPSEC-SCA-GENERAL, identifies the failing component without a specific cause.

| Sub-scanner              | Code prefix                      |
| ------------------------ | -------------------------------- |
| Vulnerabilities          | APPSEC-SCA\_CVE-                 |
| Licenses                 | APPSEC-SCA\_LICENSES-            |
| Package Operational Risk | APPSEC-SCA\_OPERATIONAL\_RISK-   |
| Malicious Packages       | APPSEC-SCA\_MALICIOUS\_PACKAGES- |

Components cover data source connection, cloning, scan intake and orchestration including pre-scan and post-scan, the SCA, IaC, Secrets, and SAST scanners, AI-assisted scanning, enrichment, persistence, scans management, pull request comments, webhooks, and the CLI.

Error codes are identical across the console, the public API, and pull request, CI, and CLI output.

\ <br>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://cortex-docs.paloaltonetworks.com/application-security/code-security/application-security-scans-management/manage-scans-through-the-tenant-ui/scan-health.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
