Retrieves a mainframe file or directory by its unique file ID.
HTML
GET https://hostname/v1/integration/mainframe/projects/{projectId}/pipelines/{pipelineId}/files/{fileId}Use cases
- Download raw file content (
contentOnly=true, default, files only). - View file or directory details and content (
contentOnly=false). - Access individual file or directory metadata.
Required permissions
replication-pipeline::view
Request
Path parameters
| Key | Required | Type | Description |
|---|---|---|---|
| projectId | Yes | string |
Unique identifier of the project. |
| pipelineId | Yes | string |
Unique identifier of the pipeline. |
| fileId | Yes | string |
Unique identifier of the file. |
Query parameters
| Key | Required | Type | Description |
|---|---|---|---|
| contentOnly | No | boolean |
If true, returns only file content as octet-stream; if false, returns full file metadata as JSON. |
Response
Header keys
| Key | Required | Type | Description |
|---|---|---|---|
| Cache-Control | No | string |
No-cache headers to prevent caching of the ZIP file. |
| Content-Disposition | No | string | Indicates that the content is an attachment with filename. |
Response body properties
| Property | Required | Type | Description |
|---|---|---|---|
| id | No | string |
Unique identifier of the mainframe file. Example:
123e4567-e89b-12d3-a456-426614174000 |
| fileName | No | string |
Name of the mainframe file. Example:
DATAFILE01 |
| fileContent | No | string |
Base64-encoded content of the mainframe file. Example:
SGVsbG8sIFdvcmxkIQ== |
| uploadedDate | No | string |
Date when the file was uploaded. Example:
2024-01-01T12:00:00Z |
| modifiedDate | No | string |
Date when the file was last modified. Example:
2024-01-02T15:30:00Z |
| lastModifiedBy | No | string |
Username of the last person who modified the file. Example:
jane.smith@example.com |
| fileApplicationType | No | string |
Application type of the file, for example, Example:
ENGINE_SCRIPT" |
Response body examples
Example status code responses for this method are shown here. To view the response schemas, you can download the Data Integration API specification (Precisely Integration Adapter Service) from the Precisely Developer Portal.
{
"id": "123e4567-e89b-12d3-a456-426614174000",
"fileName": "DATAFILE01",
"fileContent": "SGVsbG8sIFdvcmxkIQ==",
"uploadedDate": "2024-01-01T12:00:00Z",
"modifiedDate": "2024-01-02T15:30:00Z",
"lastModifiedBy": "jane.smith@example.com",
"fileApplicationType": "ENGINE_SCRIPT"
}
{
"type": "https://datatracker.ietf.org/doc/html/rfc9110#section-15.5.1",
"title": "Bad Request",
"status": 400,
"detail": "Validation error occurred",
"instance": "/v1/integration/mainframe/projects/{projectId}/pipelines/{pipelineId}/files",
"properties": {
"errorCode": "DI-ADAPTER-VAL-0000"
}
}
{
"type": "https://datatracker.ietf.org/doc/html/rfc9110#section-15.5.2",
"title": "Unauthorized",
"status": 401,
"detail": "Authorization failed - missing or invalid credentials",
"instance": "/v1/integration/mainframe/projects/{projectId}/pipelines/{pipelineId}/files",
"properties": {
"errorCode": "DI-ADAPTER-AUT-0001"
}
}
{
"type": "https://datatracker.ietf.org/doc/html/rfc9110#section-15.5.4",
"title": "Forbidden",
"status": 403,
"detail": "Authorization failed - insufficient permissions",
"instance": "/v1/integration/mainframe/projects/{projectId}/pipelines/{pipelineId}/files",
"properties": {
"errorCode": "DI-ADAPTER-AUT-0002"
}
}
{
"type": "https://datatracker.ietf.org/doc/html/rfc9110#section-15.5.5",
"title": "Not Found",
"status": 404,
"detail": "Not Found - Resource does not exist",
"instance": "/v1/integration/mainframe/projects/{projectId}/pipelines/{pipelineId}/files",
"properties": {
"errorCode": "DI-ADAPTER-MFF-0004"
}
}
{
"type": "https://datatracker.ietf.org/doc/html/rfc9110#section-15.6",
"title": "Internal Server Error",
"status": 500,
"detail": "An unexpected error occurred",
"instance": "/v1/integration/mainframe/projects/{projectId}/pipelines/{pipelineId}/files",
"properties": {
"errorCode": "DI-ADAPTER-MFF-0003"
}
}