---
title: PathSensor type | Wartiva GraphQL API
description: An organization-wide instruction telling endpoints to collect file metadata under one filesystem path. Wartiva GraphQL API reference with examples.
url: https://wartiva.com/api-docs/types/path-sensor.html
updated: 2026-10-07
---

Organizations and users · GraphQL type

# `PathSensor` type

An organization-wide instruction telling endpoints to collect file metadata under one filesystem path. Every enrolled endpoint whose OS matches `osTarget` scans `path` every `interval`, optionally recursing, filtering with glob patterns, and collecting checksums, ACLs, or file contents. Each sensor yields one [EndpointPath](https://wartiva.com/api-docs/types/endpoint-path.html) graph object per endpoint, whose entries are the discovered files. The system seeds a set of default sensors into each organization; org admins can add their own with [createPathSensor](https://wartiva.com/api-docs/mutations/create-path-sensor.html), and list them with [pathSensors](https://wartiva.com/api-docs/queries/path-sensors.html) or fetch one with [pathSensor](https://wartiva.com/api-docs/queries/path-sensor.html).

## Fields

| Field Name | Description |
|---|---|
| `id` - [`PathSensorId!`](https://wartiva.com/api-docs/types/path-sensor-id.html) | The PathSensor's unique identifier. |
| `orgId` - [`OrganizationId!`](https://wartiva.com/api-docs/types/organization-id.html) | Unique identifier that corresponds to your deployment of this product or a specific customer account that this PathSensor belongs to. |
| `name` - [`String!`](https://wartiva.com/api-docs/types/string.html) | Human-readable label for this sensor. Required; at most 256 bytes. |
| `description` - [`String!`](https://wartiva.com/api-docs/types/string.html) | Describes what this sensor monitors. At most 4096 bytes. |
| `path` - [`String!`](https://wartiva.com/api-docs/types/string.html) | The absolute filesystem path or directory this sensor monitors, at most 4096 bytes. On Linux and macOS it starts with `/` and must be normalized (no `.` or `..` segments or repeated separators). On Windows it must be drive-rooted (for example `C:\Program Files`); UNC and device paths are rejected. |
| `inclusions` - [`[String!]!`](https://wartiva.com/api-docs/types/string.html) | Optional glob patterns (doublestar syntax, including `**`); when non-empty, only paths matching an inclusion under the monitored path are recorded. Inclusions and exclusions together are limited to 256 patterns of at most 4096 bytes each. |
| `exclusions` - [`[String!]!`](https://wartiva.com/api-docs/types/string.html) | Optional glob patterns (doublestar syntax, including `**`); paths matching an exclusion under the monitored path are skipped. Shares the 256-pattern limit with inclusions. |
| `recursive` - [`Boolean!`](https://wartiva.com/api-docs/types/boolean.html) | Whether the sensor walks directories recursively. A recursive sensor cannot collect file contents. |
| `interval` - [`Duration!`](https://wartiva.com/api-docs/types/duration.html) | How often the endpoint runs this sensor. Must be at least the deployment's configured minimum interval. |
| `collectChecksum` - [`Boolean!`](https://wartiva.com/api-docs/types/boolean.html) | Whether the endpoint computes a checksum for each matched file. |
| `checksumMaxBytes` - [`Int64!`](https://wartiva.com/api-docs/types/int64.html) | Maximum file size in bytes to checksum when collectChecksum is true. Files larger than this are not checksummed. Must be positive when collectChecksum is true. |
| `collectContents` - [`Boolean!`](https://wartiva.com/api-docs/types/boolean.html) | Whether file bytes are uploaded with each result. |
| `collectAcls` - [`Boolean!`](https://wartiva.com/api-docs/types/boolean.html) | Whether the endpoint collects ACL and extended-attribute metadata for each matched file. |
| `contentMaxBytes` - [`Int64!`](https://wartiva.com/api-docs/types/int64.html) | Maximum bytes per file upload when collectContents is true. Must be positive when collectContents is true and may not exceed the deployment's configured maximum. |
| `isDefault` - [`Boolean!`](https://wartiva.com/api-docs/types/boolean.html) | True if the system seeded this sensor as an organization default. A default sensor keeps receiving updates to the vendor defaults until an org admin edits it; deleting or disabling it persists across those updates. |
| `enabled` - [`Boolean!`](https://wartiva.com/api-docs/types/boolean.html) | Whether this sensor is currently active. [pathSensors](https://wartiva.com/api-docs/queries/path-sensors.html) lists only enabled sensors. |
| `osTarget` - [`PathSensorOsTarget!`](https://wartiva.com/api-docs/types/path-sensor-os-target.html) | The OS target this sensor applies to (platform plus optional Linux distribution restriction). |

## Returned by

- [`pathSensor`](https://wartiva.com/api-docs/queries/path-sensor.html) query: Retrieves a PathSensor configuration: an organization-wide instruction for endpoints to collect file metadata, and optionally checksums, ACLs, or…
- [`createPathSensor`](https://wartiva.com/api-docs/mutations/create-path-sensor.html) mutation: Creates a new PathSensor for the given organization.
- [`updatePathSensor`](https://wartiva.com/api-docs/mutations/update-path-sensor.html) mutation: Updates an existing user-defined PathSensor.

## Used by

- [`EndpointPath`](https://wartiva.com/api-docs/types/endpoint-path.html) type: The single graph object a PathSensor produces on an Endpoint, so an Endpoint has one EndpointPath per sensor that has reported data from it; list…
- [`PathSensorPayload`](https://wartiva.com/api-docs/types/path-sensor-payload.html) type: Payload wrapper for a single PathSensor.
- [`PathSensorsPayload`](https://wartiva.com/api-docs/types/path-sensors-payload.html) type: Payload wrapper for a page of the enabled PathSensors on an Organization.

## Example

### Example

```json
{
  "id": PathSensorId,
  "orgId": "615f3b3b28284380e28a7342",
  "name": "xyz789",
  "description": "abc123",
  "path": "abc123",
  "inclusions": ["abc123"],
  "exclusions": ["abc123"],
  "recursive": true,
  "interval": "600000000",
  "collectChecksum": false,
  "checksumMaxBytes": "-8589934592",
  "collectContents": true,
  "collectAcls": true,
  "contentMaxBytes": "-8589934592",
  "isDefault": false,
  "enabled": true,
  "osTarget": PathSensorOsTarget
}

```

---

Wartiva is in early access. Request access: https://wartiva.com/early-access.html  
All pages: https://wartiva.com/llms.txt
