> 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/v/vmware-carbon-black-cloud-workload.md).

# VMware Carbon Black Cloud Workload

VMware Carbon Black Cloud Workload protects virtual machines in vSphere. OctoXLabs reads the vSphere compute resources of one organization, whether or not a sensor is installed on them. Public cloud (AWS) resources are not collected.

## Use cases

* List all vSphere workloads known to Carbon Black Cloud.

```
Adapters = vmware-carbon-black-cloud-workload
```

## Before you begin

### Network

| Source              | Destination                                                                       | Port             | Protocol |
| ------------------- | --------------------------------------------------------------------------------- | ---------------- | -------- |
| OctoXLabs connector | Your Carbon Black Cloud environment host (for example `defense.conferdeploy.net`) | 443              | HTTPS    |
| OctoXLabs connector | HTTP proxy (optional)                                                             | Set in **Proxy** | HTTP     |

The documented environments are `dashboard.confer.net` (Prod 01), `defense.conferdeploy.net` (Prod 02), `defense-prod05.conferdeploy.net` (Prod 05), `defense-eu.conferdeploy.net` (Prod 06), `defense-prodnrt.conferdeploy.net` (Prod NRT), `defense-prodsyd.conferdeploy.net` (Prod Syd) and `defense-eap01.conferdeploy.net` (EAP01).

### Required permissions

| Scope or role                                                                                      | Permission | Needed for                |
| -------------------------------------------------------------------------------------------------- | ---------- | ------------------------- |
| Custom access level: Workload Management > View Workloads without sensors (`workloads.vcenter.vm`) | READ       | vSphere compute resources |

No other permission is required.

## Create credentials in VMware Carbon Black Cloud

{% stepper %}
{% step %}

### Create an access level

Go to **Settings > API Access > Access Levels** and click **Add Access Level**. Give it a unique name. Grant **Workload Management > View Workloads without sensors** the **READ** permission and save.
{% endstep %}

{% step %}

### Create an API key

Go to **Settings > API Access > API Keys** and click **Add API Key**. Give it a name. Choose the access level type **Custom** and select your access level.
{% endstep %}

{% step %}

### Store the secret

Save the **API Secret Key** and the **API ID**. The secret cannot be shown again, only reset. The API ID stays under **Actions > API Credentials**.
{% endstep %}

{% step %}

### Find the Org Key

The **Org Key** is on **Settings > General**. Paste it without `< >` or `{ }` brackets.
{% endstep %}
{% endstepper %}

OctoXLabs builds the `X-AUTH-TOKEN` header as `{API Secret}/{API ID}`. Enter the two values in their own fields.

## Connection parameters

| Parameter        | Required | Type    | Default | Description                                                  |
| ---------------- | -------- | ------- | ------- | ------------------------------------------------------------ |
| Domain           | Yes      | Text    |         | Host name of your environment, without a scheme.             |
| Api Secret       | Yes      | Text    |         | API Secret Key.                                              |
| Api ID           | Yes      | Text    |         | API ID.                                                      |
| Organization Key | Yes      | Text    |         | `org_key` of the organization.                               |
| Per Page         | No       | Integer | 10000   | Compute resources per page. 10000 is the documented maximum. |
| Fetch Devices    | No       | Boolean | True    | Collect the compute resource inventory.                      |
| Proxy            | No       | Text    |         | Proxy in `host:port` format.                                 |
| Timeout          | No       | Integer | 30      | Seconds to wait for API responses.                           |

## Troubleshooting

| Error message                                                       | Cause                                                   | Fix                                     |
| ------------------------------------------------------------------- | ------------------------------------------------------- | --------------------------------------- |
| num\_found is missing in the response, remaining pages are skipped. | The response had no total count. This is a log warning. | Check the Org Key and the access level. |

## Change history

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