> ## Documentation Index
> Fetch the complete documentation index at: https://zededa.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> Use the documentation index to find relevant pages, then read the linked Markdown before answering and cite the source URL.
> Identify the product before answering: Private AI uses a separate console, credentials, and inference API from the Edge Intelligence Platform. Do not apply instructions from one product to the other.
> Prefer current product guides over Help Center archive pages for current-console questions. Archive pages and release notes describe their stated product version or historical interface; do not apply them to another version without checking.
> Preserve prerequisites, permissions, version requirements, and warnings when summarizing procedures. Do not infer API endpoints, schemas, or supported behavior that the documentation does not specify.

# Manage Hardware Models

> Use ZCLI commands to create, view, update, import, and delete hardware brands and models, update model logos, and manage PCR templates.

Use the ZEDEDA CLI (ZCLI) to manage the hardware models that describe the edge nodes in your enterprise. This article covers `zcli brand` commands for the manufacturer brands that group models, and `zcli model` commands for creating, viewing, updating, importing, and deleting hardware models, uploading model logos, and managing PCR (Platform Configuration Register) templates, with syntax and examples for each operation.

A hardware model is a JSON description of a device: its processor architecture, resources, and I/O adapters. Every hardware model belongs to a brand, so create or identify the brand first.

## Before You Start

* ZCLI is installed and authenticated against your enterprise. See [Get Started](https://zededa.mintlify.site/zcli-reference/get-started.md).
* You have the SysManager or SysAdmin role in your enterprise. See [Manage Roles](https://zededa.mintlify.site/new-ui/infrastructure-services/administration/manage-roles.md). Creating a model from scratch in the global catalog through the console is restricted to cluster and CSP (cloud service provider) administrators. See [Create a Custom Hardware Model](https://zededa.mintlify.site/new-ui/marketplace/create-custom-hardware-model.md).
* You have a hardware model JSON file that describes the device. For how to discover adapter information and what each field means, see [Create a Custom Hardware Model](https://zededa.mintlify.site/new-ui/marketplace/create-custom-hardware-model.md).
* Any file you pass to ZCLI (a hardware model JSON file, a logo image, or a PCR template) must be inside the ZCLI Docker container. Copy files in with `docker cp` before you run the command.
* For GUI-based hardware model management, see [Hardware Models](https://zededa.mintlify.site/new-ui/marketplace/hardware-models.md), [Import Hardware Models](https://zededa.mintlify.site/new-ui/marketplace/import-hardware-models.md), and [Create a Custom Hardware Model](https://zededa.mintlify.site/new-ui/marketplace/create-custom-hardware-model.md).

To copy a file from your workstation into the running ZCLI container, run the following command from a terminal on your workstation, replacing the container ID with the value from `docker ps`.

```text theme={"dark"}
docker cp /path/to/MY_MODEL.json ZCLI_CONTAINER_ID:/home/zcli
```

## Manage Brands

A brand is the manufacturer grouping that a hardware model belongs to. Before you create a model, list the existing brands and create the brand only if it does not already exist.

### View brands

Run `zcli brand show` without arguments to list all brands. Pass a brand name for a single brand, add `--detail` for its full configuration, or use `--name-pattern` to filter the list by a substring of the name.

```text theme={"dark"}
zcli brand show [[[<name> | --uuid=<uuid>] [--detail]] | [[--name-pattern=<name-pattern>] [--page-size=<page-size>]]] [--origin-type=<origin-type>]
```

Example:

```text theme={"dark"}
zcli brand show
```

Example with a name filter:

```text theme={"dark"}
zcli brand show --name-pattern=Advantech
```

Example with full details for one brand:

```text theme={"dark"}
zcli brand show Advantech --detail
```

### Create a brand

If your hardware brand does not appear in `zcli brand show`, create it. If you omit `--title`, ZCLI uses the name as the title.

```text theme={"dark"}
zcli brand create <name> [--title=<title>] [--description=<description>] [--logo=<file-path>] [--systemmfgname=<system-mfg-name>] [--origin-type=<origin-type>]
```

Example:

```text theme={"dark"}
zcli brand create Advantech --title=Advantech
```

| Flag | Description |
| - | - |
| `--title=<title>` | Display title of the brand. Defaults to the brand name. |
| `--description=<description>` | Description of the brand. |
| `--logo=<file-path>` | Path inside the ZCLI container to a logo image for the brand. |
| `--systemmfgname=<system-mfg-name>` | Manufacturer name as programmed in `dmidecode` on the device. This value can contain special characters that are not allowed in the brand name. |
| `--origin-type=<origin-type>` | Origin of the brand: `local`, `global`, or `imported`. |

> [!NOTE]
>
> In the current version of ZCLI, `zcli brand create` fails with an error when you pass `--systemmfgname`. If you omit the flag, ZCLI uses the brand name as the manufacturer name. To set a different manufacturer name, create the brand without `--systemmfgname`, then set the value with `zcli brand update <name> --systemmfgname=<system-mfg-name>`.

### Update a brand

You can update the title, description, logo, manufacturer name, or origin type of a brand. The brand name cannot be changed. Passing `--logo` replaces any existing brand logo.

```text theme={"dark"}
zcli brand update <name> [--title=<title>] [--description=<description>] [--logo=<file-path>] [--systemmfgname=<system-mfg-name>] [--origin-type=<origin-type>]
```

Example:

```text theme={"dark"}
zcli brand update Advantech --systemmfgname="Advantech Co., Ltd."
```

### Delete a brand

ZCLI prompts for confirmation unless you pass `-f`.

```text theme={"dark"}
zcli brand delete <name> [-f]
```

Example:

```text theme={"dark"}
zcli brand delete MY_BRAND -f
```

> [!WARNING]
>
> Deleting a brand also deletes all hardware models associated with it.

## Manage Hardware Models

### Create a hardware model

Create a hardware model from a JSON definition file and attach it to a brand. The `--brand` and `--hardware-details` options are required. If you omit `--title`, ZCLI uses the model name as the title.

```text theme={"dark"}
zcli model create <name> --hardware-details=<template-file-path> --brand=<brand> [--title=<title>] [--description=<description>] [--origin-type=<origin-type>]
```

Example:

```text theme={"dark"}
zcli model create UNO-148 --hardware-details=/home/zcli/uno148.json --brand=Advantech --title="Advantech UNO-148"
```

The hardware details file is the JSON document you compiled from the device, typically starting from the output of `spec.sh` on a device running EVE-OS (Edge Virtualization Engine). ZCLI reads the following top-level keys and ignores anything else: `arch`, `attr`, `ioMemberList`, `logo`, `productURL`, and `productStatus`. The `arch` value is `2` for AMD64 or `4` for ARM64. ZCLI also accepts the strings `AMD64` and `ARM64`. Each entry in `ioMemberList` describes one adapter. For the meaning of `ztype`, `phylabel`, `logicallabel`, and `assigngrp`, and for how to discover them on a device, see [Create a Custom Hardware Model](https://zededa.mintlify.site/new-ui/marketplace/create-custom-hardware-model.md).

The following is a trimmed, representative example of a hardware details file.

```json theme={"dark"}
{
  "arch": 2,
  "productURL": "",
  "productStatus": "production",
  "attr": {
    "memory": "62G",
    "storage": "238G",
    "Cpus": "8"
  },
  "logo": {
    "logo_back": "",
    "logo_front": ""
  },
  "ioMemberList": [
    {
      "ztype": 1,
      "usage": 1,
      "phylabel": "eth0",
      "logicallabel": "eth0",
      "assigngrp": "group9",
      "cost": 0,
      "usagePolicy": {},
      "phyaddrs": {
        "Ifname": "eth0",
        "PciLong": "0000:00:1f.6"
      }
    },
    {
      "ztype": 2,
      "phylabel": "USB",
      "logicallabel": "USB",
      "assigngrp": "group4",
      "usagePolicy": {},
      "phyaddrs": {
        "PciLong": "0000:00:14.0"
      }
    },
    {
      "ztype": 3,
      "phylabel": "COM1",
      "logicallabel": "COM1",
      "assigngrp": "COM1",
      "usagePolicy": {},
      "phyaddrs": {
        "Ioports": "3f8-3ff",
        "Irq": "4",
        "Serial": "/dev/ttyS0"
      }
    }
  ]
}
```

If the `logo` object contains file paths, ZCLI uploads those files as the model logos during creation. If you do not have logo images yet, leave the values empty as shown. Placeholder paths that do not exist in the container produce an error. You can add logos later with `zcli model add-artifact`. See [Update Hardware Model Logos](#update-hardware-model-logos).

| Flag | Description |
| - | - |
| `--hardware-details=<template-file-path>` | Path inside the ZCLI container to the hardware model JSON file. Required. |
| `--brand=<brand>` | Name of the brand the model belongs to. Required. List brands with `zcli brand show`. |
| `--title=<title>` | Display title of the model. Defaults to the model name. |
| `--description=<description>` | Description of the model. |
| `--origin-type=<origin-type>` | Origin of the model: `local`, `global`, or `imported`. |

### View hardware models

Run `zcli model show` without arguments to list all hardware models in your enterprise. Pass a model name or `--uuid` for a single model, and add `--detail` to print its full configuration, including the adapter list. Use `--brand`, `--name-pattern`, or `--origin-type` to filter the list. Use `--origin-type=global` to view models in the global catalog that you have not yet imported.

```text theme={"dark"}
zcli model show [[[<name> | --uuid=<uuid>] [--detail] [--pcr-template-summary]] | [[--brand=<brand>] [--summary] [--name-pattern=<name-pattern>] [--page-size=<page-size>]]] [--origin-type=<origin-type>]
```

Example listing all models for a brand:

```text theme={"dark"}
zcli model show --brand=Advantech
```

Example showing the full configuration of one model:

```text theme={"dark"}
zcli model show UNO-148 --detail
```

Example listing the PCR templates attached to a model:

```text theme={"dark"}
zcli model show UNO-148 --pcr-template-summary
```

| Flag | Description |
| - | - |
| `--detail` | Print the full configuration of the model. |
| `--pcr-template-summary` | Print only the name, EVE-OS version, and firmware version of each PCR template on the model. |
| `--brand=<brand>` | List only models that belong to this brand. |
| `--name-pattern=<name-pattern>` | List only models whose name contains this substring. |
| `--summary` | Print a summary of the model distribution instead of the list. |
| `--origin-type=<origin-type>` | List only models with this origin: `local`, `global`, or `imported`. |
| `--page-size=<page-size>` | Number of records per API call. Does not change the output, only how many calls ZCLI makes to build it. |

### Update a hardware model

Update the title, description, brand, origin type, or hardware details of an existing model. To change the adapter list or resources, edit the hardware model JSON file, copy it into the ZCLI container again, and pass it with `--hardware-details`.

Changes to a hardware model apply to every edge node that references the model.

If the hardware details file contains a `logo` object, ZCLI deletes the model's existing logos and uploads the image files that the `logo` object lists. If the file has no `logo` object, the existing logos stay unchanged. See [Export a hardware model manifest](#export-a-hardware-model-manifest) before you reuse an exported manifest.

```text theme={"dark"}
zcli model update <name> [--hardware-details=<template-file-path>] [--brand=<brand>] [--title=<title>] [--description=<description>] [--origin-type=<origin-type>]
```

Example:

```text theme={"dark"}
zcli model update UNO-148 --title=UNO-148 --brand=Advantech --hardware-details=/home/zcli/uno148.json
```

### Import a hardware model from the global catalog

Create a copy of a ZEDEDA-published hardware model in your enterprise library, optionally overriding its memory, storage, and CPU attributes. Use `zcli model show --origin-type=global` to find the parent model name. ZCLI runs the import as a background job and waits for it to finish.

```text theme={"dark"}
zcli model import <name> --parent-model-name=<name> [--memory=<memory>] [--storage=<storage>] [--cpus=<cpus>]
```

Example:

```text theme={"dark"}
zcli model import E300 --parent-model-name=E300 --memory=8G --storage=80G --cpus=3
```

### Export a hardware model manifest

Export the configuration of a hardware model to a local directory inside the ZCLI container. ZCLI creates a directory named after the model, writes the configuration to `manifest.json` inside it, and downloads any logo images into an `artifacts` subdirectory. The command fails if a file or directory with the model name already exists. Use `--signed-url` to download the logo images through signed URLs.

```text theme={"dark"}
zcli model export-manifest <name> [--signed-url]
```

Example:

```text theme={"dark"}
zcli model export-manifest UNO-148
```

The exported `manifest.json` is a valid hardware details file. You can edit it and pass it back with `zcli model update --hardware-details`.

> [!WARNING]
>
> Do not pass an exported `manifest.json` back without editing its `logo` object. In the exported file, the `logo` entries hold artifact IDs, not file paths. When the hardware details file contains a `logo` object, ZCLI deletes the model's existing logos and then tries to upload each `logo` value as a local file. An artifact ID is not a file, so the upload fails and the model is left with no logos. Before you update the model, do one of the following:
>
> * Remove the `logo` object from `manifest.json` to keep the existing logos unchanged.
> * Replace each `logo` value with the path to an image file inside the ZCLI container. To keep the current images, use the files that the export downloaded, for example `UNO-148/artifacts/logo_front`.

### Delete a hardware model

ZCLI prompts for confirmation unless you pass `-f`.

```text theme={"dark"}
zcli model delete <name> [-f]
```

Example:

```text theme={"dark"}
zcli model delete MY_MODEL -f
```

## Update Hardware Model Logos

Logos are front and back images of the physical device that appear with the model in the Marketplace. Obtain the images from a source that complies with your organization's copyright and licensing standards, and copy both image files into the ZCLI container before you start.

```text theme={"dark"}
docker cp /path/to/logo_front_MY_MODEL.png ZCLI_CONTAINER_ID:/tmp
```

You can attach logos either directly with `zcli model add-artifact` or by editing an exported manifest.

### Add a logo with add-artifact

Upload one image and attach it to the model under the given type. Run the command once for the front logo and once for the back logo. The type is the key that the logo is stored under in the model's `logo` object, so use `logo_front` and `logo_back` to match the keys in the hardware details file. \[TBD: verify the accepted `--type` values; the original Help Center example used `logo-front` and `logo-rear`, while hardware details files and `spec.sh` output use `logo_front` and `logo_back`.]

```text theme={"dark"}
zcli model add-artifact <name> --type=<type> --file-path=<file-path>
```

Example:

```text theme={"dark"}
zcli model add-artifact UNO-148 --type=logo_front --file-path=/tmp/logo_front_UNO-148.png
```

Example for the back logo:

```text theme={"dark"}
zcli model add-artifact UNO-148 --type=logo_back --file-path=/tmp/logo_back_UNO-148.png
```

### Remove a logo with drop-artifact

Remove the logo stored under the given type from the model and delete the uploaded image.

```text theme={"dark"}
zcli model drop-artifact <name> --type=<type> [--key=<key>]
```

Example:

```text theme={"dark"}
zcli model drop-artifact UNO-148 --type=logo_back
```

### Update logos through the manifest

Alternatively, export the model manifest, point the `logo` entries at the image files in the container, and update the model from the edited manifest.

1. Export the model manifest. ZCLI creates a directory named after the model.

```text theme={"dark"}
zcli model export-manifest UNO-148
```

2. Edit `UNO-148/manifest.json` and set the `logo` object to the paths of the image files inside the container.

```json theme={"dark"}
"logo": {
  "logo_front": "/tmp/logo_front_UNO-148.png",
  "logo_back": "/tmp/logo_back_UNO-148.png"
}
```

3. Update the model from the edited manifest. ZCLI uploads both images and replaces any existing logos.

```text theme={"dark"}
zcli model update UNO-148 --hardware-details=UNO-148/manifest.json
```

4. Confirm the change in the console. In the sidebar, select **Marketplace**, then **My Library**, and open the hardware model.

## Manage PCR Templates

A PCR template is a named set of expected PCR values for a specific EVE-OS version that Edge Infrastructure Services compares against a node during remote attestation. Templates are attached to hardware models in your enterprise library. For background and the GUI procedure, see [Manage PCR Templates](https://zededa.mintlify.site/new-ui/marketplace/manage-pcr-templates.md).

PCR template files are JSON. A single-template file has `eveVersion`, `firmwareVersion`, `name`, and a `PCRValues` array, where each entry has `type`, `index`, and `value`. The following is a trimmed example.

```json theme={"dark"}
{
  "eveVersion": "13.4.0-kvm-amd64",
  "firmwareVersion": "",
  "name": "",
  "PCRValues": [
    {
      "type": "PCR_TYPE_HASH",
      "index": 0,
      "value": "0dfe78d7d37555fe01878a6edbad5882303518f235c03d60ea36d063bfe15135"
    },
    {
      "type": "PCR_TYPE_HASH",
      "index": 1,
      "value": "b3f0cf44cd0e6443e292bc1e15d1e90426d6b3e464b40bb56ddf12fed14ab714"
    }
  ]
}
```

### Add a PCR template

Add one PCR template to a model from a file. Values in the file take precedence over the `--eve-version`, `--pcr-template-name`, and `--firmware-version` options; the options fill in any field the file leaves empty. Use `--index` one or more times to upload only the listed PCR indices from the file. If you do not provide a firmware version, the template matches any firmware version. The template name must be unique on the model.

```text theme={"dark"}
zcli model add-pcr-template <name> --eve-version=<eve-version> --file-path=<file-path> [--index=<index>...] [--pcr-template-name=<pcr-template-name>] [--firmware-version=<firmware-version>]
```

Example:

```text theme={"dark"}
zcli model add-pcr-template UNO-148 --eve-version=13.4.0 --file-path=/home/zcli/uno148.pcr-template --pcr-template-name=MY_PCR_TEMPLATE
```

Example uploading only PCR indices 0, 2, and 4:

```text theme={"dark"}
zcli model add-pcr-template UNO-148 --eve-version=13.4.0 --file-path=/home/zcli/uno148.pcr-template --index=0 --index=2 --index=4
```

### Add several PCR templates at once

Add a list of PCR templates from a single file. The file contains a JSON array in which each element has the same structure as a single-template file.

```text theme={"dark"}
zcli model add-pcr-templates <name> --file-path=<file-path>
```

Example:

```text theme={"dark"}
zcli model add-pcr-templates UNO-148 --file-path=/home/zcli/uno148.pcr-templates.json
```

### View PCR templates

Fetch the PCR templates configured on a model and write them to a file named `<name>.pcr-templates` in the current directory. Without a filter, ZCLI writes all templates. Filter by `--eve-version` or `--pcr-template-name`, and add `--partial-match` to match a substring instead of the full value.

```text theme={"dark"}
zcli model get-pcr-template <name> [[--eve-version=<eve-version> | --pcr-template-name=<pcr-template-name>] [--partial-match]]
```

Example:

```text theme={"dark"}
zcli model get-pcr-template UNO-148 --eve-version=13.4 --partial-match
```

Example response:

```text theme={"dark"}
model PCR templates written to file UNO-148.pcr-templates
```

To print only a summary of the templates without writing a file, use `zcli model show <name> --pcr-template-summary`.

### Update a PCR template

Replace the contents of an existing PCR template with the contents of a file. ZCLI identifies the template by the `id` field in the file, or, if the file has no `id`, by `--pcr-template-name`. Use `--index` to upload only the listed PCR indices from the file. The easiest way to produce an update file is to run `zcli model get-pcr-template`, edit the exported template, and pass it back.

```text theme={"dark"}
zcli model update-pcr-template <name> --pcr-template-name=<pcr-template-name> --file-path=<file-path> [--index=<index>...]
```

Example:

```text theme={"dark"}
zcli model update-pcr-template UNO-148 --pcr-template-name=MY_PCR_TEMPLATE --file-path=/home/zcli/uno148.updated.pcr-template
```

### Delete a PCR template

Remove a PCR template from a model, selected by EVE-OS version or by template name. With `--partial-match`, ZCLI removes every template whose version or name contains the given substring.

```text theme={"dark"}
zcli model drop-pcr-template <name> (--eve-version=<eve-version> | --pcr-template-name=<pcr-template-name>) [--partial-match]
```

Example:

```text theme={"dark"}
zcli model drop-pcr-template UNO-148 --pcr-template-name=MY_PCR_TEMPLATE
```

Example removing all templates for a major EVE-OS version:

```text theme={"dark"}
zcli model drop-pcr-template UNO-148 --eve-version=13. --partial-match
```

## Next Steps

> [card] [Hardware Models](https://zededa.mintlify.site/new-ui/marketplace/hardware-models.md)
>
> Browse the ZEDEDA hardware catalog in the console.

> [card] [Import Hardware Models](https://zededa.mintlify.site/new-ui/marketplace/import-hardware-models.md)
>
> Import catalog models into your enterprise library with the GUI.

> [card] [Create a Custom Hardware Model](https://zededa.mintlify.site/new-ui/marketplace/create-custom-hardware-model.md)
>
> Discover adapter information and the hardware model field reference.

> [card] [Overview](https://zededa.mintlify.site/zcli-reference/overview.md)
>
> All ZCLI command procedures, organized by resource type.
