---
title: endpointPathEntryContents query | Wartiva GraphQL API
description: Retrieves the collected contents of one file path discovered by an EndpointPath — list discovered paths with its entries field.
url: https://wartiva.com/api-docs/queries/endpoint-path-entry-contents.html
updated: 2026-10-07
---

File path sensors · GraphQL query

# `endpointPathEntryContents` query

Retrieves the collected contents of one file path discovered by an [EndpointPath](https://wartiva.com/api-docs/types/endpoint-path.html) — list discovered paths with its `entries` field. Returns null when the sensor never reported that path or no contents are stored for it (e.g. the sensor does not collect contents, or the file was reported deleted). The file bytes are only read from storage when the result's `contentsAsString` is selected; see [endpointPathEntryStats](https://wartiva.com/api-docs/queries/endpoint-path-entry-stats.html) for the file's stat record.

## Response

Returns an [`EndpointPathEntryContentsPayload`](https://wartiva.com/api-docs/types/endpoint-path-entry-contents-payload.html)

## Arguments

| Name | Description |
|---|---|
| `id` - [`ID!`](https://wartiva.com/api-docs/types/id.html) | The EndpointPath identifier. |
| `path` - [`String!`](https://wartiva.com/api-docs/types/string.html) | The absolute file path exactly as reported by the endpoint. |
| `mockOptions` - [`MockDataInput`](https://wartiva.com/api-docs/types/mock-data-input.html) | Options for mock data generation. Options supported: key: "PLATFORM", value: OsPlatform example: "mockOptions": { "options": [ { "key": "PLATFORM", "value": "WINDOWS" } ] } |

## Example

### Query

```graphql
query endpointPathEntryContents(
  $id: ID!,
  $path: String!,
  $mockOptions: MockDataInput
) {
  endpointPathEntryContents(
    id: $id,
    path: $path,
    mockOptions: $mockOptions
  ) {
    node {
      path
      contentsAsString
      contentsUrl
    }
  }
}

```

### Variables

```json
{
  "id": 4,
  "path": "xyz789",
  "mockOptions": MockDataInput
}

```

### Response

```json
{
  "data": {
    "endpointPathEntryContents": {
      "node": EndpointPathEntryContents
    }
  }
}

```

---

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