> For the complete documentation index, see [llms.txt](https://docs.octoxlabs.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.octoxlabs.com/adapters/z/zscaler-private-access.md).

# Zscaler Private Access

Zscaler Private Access (ZPA) gives users access to private applications. OctoXLabs reads the application servers of your tenant. You can also add App Connectors and Private Service Edges. This page covers only ZPA, not the other Zscaler adapters.

## Use cases

* List all assets collected from ZPA.

```
Adapters = zscaler-private-access
```

## Before you begin

### Network

| Source              | Destination                                                  | Port | Protocol |
| ------------------- | ------------------------------------------------------------ | ---- | -------- |
| OctoXLabs connector | ZPA API portal domain (default `config.private.zscaler.com`) | 443  | HTTPS    |

The API portal domain depends on your cloud. If your organization signs in at `admin.private.zscaler.com`, the domain is `config.private.zscaler.com`. If it signs in at `zpatwo.net`, the domain is `config.zpatwo.net`. Find it on the API Keys page under **Configuration & Control > Public API**.

### Required permissions

| Scope or role            | Permission | Needed for                                                         |
| ------------------------ | ---------- | ------------------------------------------------------------------ |
| Servers                  | Read       | Application servers                                                |
| App Connector Management | Read       | App Connectors (when **Fetch App Connectors** is on)               |
| Private Service Edges    | Read       | Private Service Edges (when **Fetch Private Service Edges** is on) |

## Create credentials in Zscaler Private Access

{% stepper %}
{% step %}

### Open API Keys

Go to **Configuration & Control > Public API > API Keys**.
{% endstep %}

{% step %}

### Add a key

Click **Add**, enter a name and enable its status.
{% endstep %}

{% step %}

### Grant read access

Grant **Read** access to **Servers**. For app connectors and service edges, also grant **Read** to **App Connector Management** and **Private Service Edges**.
{% endstep %}

{% step %}

### Save and copy

Save the key. Copy the Client ID and the Client Secret from the saved key.
{% endstep %}
{% endstepper %}

## Connection parameters

| Parameter                   | Required | Type    | Default                    | Description                          |
| --------------------------- | -------- | ------- | -------------------------- | ------------------------------------ |
| Domain                      | No       | Text    | config.private.zscaler.com | ZPA API portal domain of your cloud. |
| Client ID                   | Yes      | Text    |                            | Client ID of the API key.            |
| Client Secret               | Yes      | Text    |                            | Client secret of the API key.        |
| Customer ID                 | Yes      | Text    |                            | Your ZPA tenant ID.                  |
| Is Secure?                  | No       | Boolean | True                       | Use HTTPS.                           |
| Fetch Private Service Edges | No       | Boolean | False                      | Add Private Service Edges as assets. |
| Fetch App Connectors        | No       | Boolean | False                      | Add App Connectors as assets.        |
| Timeout                     | No       | Integer | 30                         | Seconds to wait for API responses.   |

## Troubleshooting

| Error message                     | Cause                       | Fix                               |
| --------------------------------- | --------------------------- | --------------------------------- |
| Max retries (3) exceeded for URL: | The API kept returning 429. | Wait and run the discovery again. |

If a discovery returns no assets, check the customer ID and that the API key has Read access to Servers.

## Change history

{% hint style="info" %}
Available starting from version 5.5.0.
{% endhint %}
