---
title: "Search Systems"
method: POST
path: "/api/search/systems"
tags: ["Search"]
---

# Search Systems

`POST /api/search/systems`

## Request

- Base URL: `https://console.jumpcloud.com`
- URL: `https://console.jumpcloud.com/api/search/systems`
- Auth: API key in header `x-api-key`
- TypeScript: <https://skmtc.dev/jumpcloud/apis/jumpcloud-console-api/docs/api/search/systems/post.ts> (a function with typed inputs; its response is checked against the schema)

Return Systems in multi-record format allowing for the passing of the `filter` and `searchFilter` parameters. This WILL NOT allow you to add a new system.

To support advanced filtering you can use the `filter` and `searchFilter` parameters that can only be passed in the body of POST /api/search/* routes. The `filter` and `searchFilter` parameters must be passed as Content-Type application/json.

The `filter` parameter is an object with a single property, either `and` or `or` with the value of the property being an array of query expressions.

This allows you to filter records using the logic of matching ALL or ANY records in the array of query expressions. If the `and` or `or` are not included the default behavior is to match ALL query expressions.

The `searchFilter` parameter allows text searching on supported fields by specifying a `searchTerm` and a list of `fields` to query on. If any `field` has a partial text match on the `searchTerm` the record will be returned.


#### Sample Request

Exact search for a list of hostnames
```
curl -X POST https://console.jumpcloud.com/api/search/systems \
  -H 'Accept: application/json' \
  -H 'Content-Type: application/json' \
  -H 'x-api-key: {API_KEY}' \
  -d '{
  "filter": {
    "or": [
      {"hostname" : "my-hostname"},
      {"hostname" : "other-hostname"}
    ]
  },
  "fields" : "os hostname displayName"
}'
```

Text search for a hostname or display name
```
curl -X POST https://console.jumpcloud.com/api/search/systems \
  -H 'Accept: application/json' \
  -H 'Content-Type: application/json' \
  -H 'x-api-key: {API_KEY}' \
  -d '{
  "searchFilter": {
    "searchTerm": "my-host",
    "fields": ["hostname", "displayName"]
  },
  "fields": "os hostname displayName"
}'
```

Text search for a multiple hostnames.
```
curl -X POST https://console.jumpcloud.com/api/search/systems \
  -H 'Accept: application/json' \
  -H 'Content-Type: application/json' \
  -H 'x-api-key: {API_KEY}' \
  -d '{
  "searchFilter": {
    "searchTerm": ["my-host", "my-other-host"],
    "fields": ["hostname"]
  },
  "fields": "os hostname displayName"
}'
```

Combining `filter` and `searchFilter` to search for names that match a given OS
```
curl -X POST https://console.jumpcloud.com/api/search/systems \
  -H 'Accept: application/json' \
  -H 'Content-Type: application/json' \
  -H 'x-api-key: {API_KEY}' \
  -d '{
  "searchFilter": {
    "searchTerm": "my-host",
    "fields": ["hostname", "displayName"]
  },
  "filter": {
    "or": [
      {"os" : "Ubuntu"},
      {"os" : "Mac OS X"}
    ]
  },
  "fields": "os hostname displayName"
}'
```

## Query parameters

- `fields` string
- `limit` integer
- `skip` integer
- `filter` string

## Headers

- `x-org-id` string
- `x-eventually-consistent` boolean

## Request body

- Search
  - `fields` string
  - `filter` object
  - `searchFilter` object

## Response `200`

OK

- SystemsSearchlist
  - `results` SystemSearch[]: The list of systems.
    - `_id` string
    - `active` boolean
    - `agentHasFullDiskAccess` boolean
    - `agentVersion` string
    - `allowMultiFactorAuthentication` boolean
    - `allowPublicKeyAuthentication` boolean
    - `allowSshPasswordAuthentication` boolean
    - `allowSshRootLogin` boolean
    - `amazonInstanceID` string
    - `arch` string
    - `archFamily` string
    - `attributes` Attribute[]
      - `name` string
      - `value` string
    - `connectionHistory` object[]
    - `created` string, date-time
    - `description` string
    - `desktopCapable` boolean
    - `displayName` string
    - `fde` Fde: Indicates if the Full Disk Encryption is active in the system
      - `active` boolean
      - `keyPresent` boolean
    - `fileSystem` string, nullable
    - `hasServiceAccount` boolean
    - `hostname` string
    - `hwVendor` string
    - `isPolicyBound` boolean
    - `lastContact` string, date-time, nullable
    - `modifySSHDConfig` boolean
    - `networkInterfaces` object[]
      - `address` string
      - `family` 'IPv4' | 'IPv6'
      - `internal` boolean
      - `name` string
    - `networkInfo` object
      - `imei` string: PII data; do not log.
      - `macAddress` string: PII data; do not log.
      - `simInfo` object[]
        - `phoneNumber` string: PII data; do not log.
        - `iccid` string: PII data; do not log.
    - `organization` string
    - `os` string
    - `osVersionDetail` object
      - `osName` string
      - `releaseName` string
      - `major` string
      - `minor` string
      - `patch` string
      - `majorNumber` integer
      - `minorNumber` integer
      - `patchNumber` integer
      - `revision` string
      - `distributionName` string
      - `version` string
    - `policyStats` object
      - `duplicate` integer
      - `failed` integer
      - `pending` integer
      - `success` integer
      - `total` integer
      - `unsupportedOs` integer
    - `provisionMetadata` object
      - `provisioner` object
        - `type` 'administrator' | 'mdm' | 'user'
        - `provisionerId` string
    - `primarySystemUser` object
      - `id` string, nullable
    - `remoteIP` string
    - `serialNumber` string
    - `sshRootEnabled` boolean
    - `sshdParams` object[]
      - `name` string
      - `value` string
    - `systemInsights` object
      - `state` 'enabled' | 'disabled' | 'deferred'
    - `systemTimezone` integer
    - `tags` string[]
    - `templateName` string
    - `version` string
    - `mdm` object
      - `vendor` 'unknown' | 'none' | 'internal' | 'external'
      - `internal` object
        - `deviceId` string
        - `windowsDeviceId` string
      - `profileIdentifier` string
      - `dep` boolean
      - `userApproved` boolean
      - `enrollmentType` 'unknown' | 'automated device' | 'device' | 'user'
      - `providerId` string
      - `windows` object
        - `upn` string
      - `lostModeStatus` string
      - `deviceLockStatus` 0 | 1 | 2 | 3 | 4
      - `enrollmentStatus` 0 | 1
    - `builtInCommands` object[]
      - `type` 'security'
      - `name` 'erase' | 'lock' | 'restart' | 'shutdown'
    - `osFamily` string
    - `domainInfo` object
      - `partOfDomain` boolean
      - `domainName` string
    - `userMetrics` object[]
      - `userName` string
      - `admin` boolean
      - `managed` boolean
      - `suspended` boolean
      - `secureTokenEnabled` boolean
    - `serviceAccountState` object
      - `hasSecureToken` boolean
      - `passwordODValid` boolean
      - `passwordAPFSValid` boolean
    - `azureAdJoined` boolean
    - `displayManager` string
    - `secureLogin` object
      - `supported` boolean
      - `enabled` boolean
    - `remoteAssistAgentVersion` string
    - `primarySystemUser._id` string
    - `primarySystemUser.attributes` Attribute[]
      - `name` string
      - `value` string
    - `primarySystemUser.company` string
    - `primarySystemUser.costCenter` string
    - `primarySystemUser.delegatedAuthority.id` string: ObjectId of the primary user's Active Directory delegated authority connection
    - `primarySystemUser.department` string
    - `primarySystemUser.description` string
    - `primarySystemUser.email` string
    - `primarySystemUser.employeeType` string
    - `primarySystemUser.jobTitle` string
    - `primarySystemUser.location` string
    - `primarySystemUser.manager` string: Relation with another systemuser to identify the last as a manager.
    - `primarySystemUser.state` 'STAGED' | 'ACTIVATED' | 'SUSPENDED'
    - `memberof` string[]
    - `primarySystemUser.memberof` string[]
  - `totalCount` integer: The total number of systems.

## Other responses

- `401`: Unauthorized

---

[API](https://skmtc.dev/jumpcloud/apis/jumpcloud-console-api.md) - [All operations](https://skmtc.dev/jumpcloud/apis/jumpcloud-console-api/llms.txt) - [OpenAPI document](https://skmtc.dev/jumpcloud/apis/jumpcloud-console-api/revisions/f396d9271b46?raw)
