---
title: "Get one project file"
method: GET
path: "/v1/integration/projects/{projectId}/files/{fileId}"
tags: ["Unified Project Lifecycle APIs"]
---

# Get one project file

`GET /v1/integration/projects/{projectId}/files/{fileId}`

## Request

- Base URL: `https://integration-adapter.connect.cloud.precisely.com`
- URL: `https://integration-adapter.connect.cloud.precisely.com/v1/integration/projects/{projectId}/files/{fileId}`
- Auth: HTTP bearer

Retrieves one project file's metadata, and optionally its content, for either an Advanced Replication (DSL) project or a Mainframe Replication pipeline.

**Features:**
- Set `includeContent=true` to also return the file's Base64-encoded content; omit it (or set it to `false`) to fetch only metadata when you don't need the file body, saving payload size for large files.
- Pass the caller's last-known `ETag` value in the `If-None-Match` request header to check for changes without re-downloading unchanged content — if nothing changed since that value, the client library returns a not-modified result with no body.
- The response `ETag` header is a fingerprint hash of the current content.

**Use Cases:**
- VS Code extension opens a file for editing.
- User polls for content changes using ETags to avoid unnecessary downloads.

**Authorization:** Requires `replication-pipeline::view`.

## Path parameters

- `projectId` string, required
- `fileId` string, required

## Query parameters

- `projectType` 'REPLICATION' | 'MAINFRAME_REPLICATION' | 'ADVANCED_REPLICATION': Supported project types for unified project operations
- `pipelineId` string
- `includeContent` boolean

## Headers

- `If-None-Match` string

## Response `200`

Project file retrieved

- ProjectFileDetailResponse: Project file metadata with optional Base64-encoded content
  - `fileId` string: Unique identifier of the file
  - `dataFlowId` string: Advanced Replication dataflow identifier owning this file, when applicable
  - `fileName` string: File name derived from the flattened path
  - `flattenedPath` string: Path of the file within the project's flattened file tree
  - `version` integer: Current version number of the file
  - `phase` 'DRAFT' | 'APPROVED' | 'PENDING_DELETION': Lifecycle phase of the file
  - `mimeType` string: MIME type of the file content
  - `encoding` string: Encoding of the file content
  - `sizeBytes` integer: Size of the file content in bytes
  - `contentHash` string: Hash of the file content, used for change detection
  - `entryFile` boolean: Whether this file is the project's designated entry file
  - `content` string: Base64-encoded file content, present only when requested

## Other responses

- `304`: Project file has not changed since the supplied If-None-Match value
- `400`: Bad Request — the resolved project type does not support files (DI-ADAPTER-PRF-0009)
- `401`: Unauthorized
- `403`: Forbidden — requires replication-pipeline::view
- `404`: Not Found — project or file does not exist (DI-ADAPTER-PRF-0001)
- `500`: Internal Server Error — file retrieval failed (DI-ADAPTER-PRF-0002)

---

[API](https://skmtc.dev/precisely/apis/precisely-integration-adapter-service.md) · [All operations](https://skmtc.dev/precisely/apis/precisely-integration-adapter-service/llms.txt) · [OpenAPI document](https://skmtc.dev/precisely/apis/precisely-integration-adapter-service/revisions/2d2629f4987d?raw)
