---
title: Adding Conditions to Computer Types
slug: adding-conditions-to-computer-types
docTags: 
createdAt: 2026-06-11T22:59:35.926Z
---

## Overview

Computer Types are used to categorise computers in Activate.

A computer type is calculated from the `//Resources/Computers/ComputerTypes` configuration. Activate checks each configured type in order and compares the matching rules against properties on the `ComputerDirectoryEntry`.

The first matching type is assigned to the computer.

Computer Types are mainly used with service delivery methods. They allow services to be deployed only to specific types of computers, or to prevent a service from being deployed to computers that do not meet the required criteria.

For example, a service delivery method can be configured so that it is only available for Windows 11 computers, server devices, kiosk machines, or another defined computer category.

## Use Case

Use Computer Types when you need to control which computers can be selected for a service deployment.

Common examples include:

- Allowing a service to be deployed only to Windows 11 computers
- Restricting server-only services to server computer types
- Preventing workstation software from being deployed to servers
- Separating kiosk devices from standard user workstations
- Creating deployment methods for specific device groups or environments

This is useful when the operating system alone is not specific enough to determine whether a computer should be eligible for a service.

## Configuration

Navigate to:

```text
//Resources/Computers/ComputerTypes
```

Computer Types are defined inside a `<types>` node. Each `<type>` has a name and a `<match>` section.

The `<match>` section contains one or more properties that Activate checks against the `ComputerDirectoryEntry`.

## Standard Example

```xml
<types>
  <type name="WinXP">
    <match>
      <property name="operatingSystem">Windows XP*</property>
    </match>
  </type>
  <type name="Win7">
    <match>
      <property name="operatingSystem">Windows 7*</property>
    </match>
  </type>
  <type name="Win8">
    <match>
      <property name="operatingSystem">Windows 8*</property>
    </match>
  </type>
  <type name="Win10">
    <match>
      <property name="operatingSystem">Windows 10*</property>
    </match>
  </type>
  <type name="WinServer">
    <match>
      <property name="operatingSystem">Windows Server*</property>
    </match>
  </type>
  <type name="Other">
    <match>
      <property name="name">*</property>
    </match>
  </type>
</types>
```

In this example, Activate checks the computer's `operatingSystem` property and assigns the first matching type.

The final `Other` type acts as a fallback because it matches any computer name.

## Matching Multiple Properties

To make a Computer Type more specific, add additional properties to the `<match>` section and set the match type to `all`.

```xml
<types>
  <type name="Finance Workstations">
    <match type="all">
      <property name="operatingSystem">Windows 10*</property>
      <property name="department">Finance</property>
    </match>
  </type>

  <type name="Win10">
    <match>
      <property name="operatingSystem">Windows 10*</property>
    </match>
  </type>

  <type name="Other">
    <match>
      <property name="name">*</property>
    </match>
  </type>
</types>
```

In this example, a computer is only classified as `Finance Workstations` when both conditions match:

- The operating system matches `Windows 10*`
- The department matches `Finance`

If either condition does not match, Activate continues checking the remaining computer types.

## Matching Behaviour

Computer Types are evaluated in the order they appear in the configuration.

The first matching type is selected and assigned to the computer. A computer can only have one Computer Type.

For this reason, more specific types should be listed before more general types.

For example, this order is recommended:

```xml
<type name="Finance Workstations">
  ...
</type>

<type name="Win10">
  ...
</type>

<type name="Other">
  ...
</type>
```

This ensures that a Finance workstation is matched before the broader `Win10` type.

## Use with Delivery Methods

Computer Types are used by delivery methods through the `AvailableComputers` parameter.

If a delivery method has `AvailableComputers` configured, Activate treats it as a computer-based delivery method. The selected computer must match one of the allowed Computer Types before the delivery method can be used.

For example, if a delivery method has:

```text
AvailableComputers = Win11
```

then only computers with the `Win11` Computer Type can be selected for that delivery method.

If a selected computer does not match the allowed type, Activate prevents the selection and requires a valid computer to be chosen.

## Supported Properties

Computer Type matching can use properties available on the `ComputerDirectoryEntry`, including:

- Active Directory attributes
- Activate-stored attributes

## Notes

- Computer Types are defined in `//Resources/Computers/ComputerTypes`.
- The first matching type is assigned to the computer.
- A computer can only have one Computer Type.
- Use `match type="all"` when multiple properties must match.
- Order Computer Types from most specific to most general.
- Delivery methods use `AvailableComputers` to restrict which Computer Types can be used.
- Use a fallback type, such as `Other`, at the end of the list.
