# Get file details

Retrieves details for a single file by its id, including its downloadUrl (GET /files/{id}/content) and Content-Type. Following downloadUrl applies Content-Type and either inline preview or an attachment download.

Endpoint: GET /har/api/v3/files/{id}
Version: 1.0
Security: x-api-key

## Query parameters:

  - `account_identifier` (string, required)
    Unique identifier for the Harness account.

## Path parameters:

  - `id` (string, required)

## Response 200 fields (application/json):

  - `data` (object, required)
    Full details for a single file, including its Content-Type. Unlike list responses, downloadUrl here previews the file inline when the browser can render its Content-Type and otherwise downloads it (served by a route outside this spec — see GET /api/v3/registries/{id}/files/*). downloadCmd keeps using GET /files/{id}/content, which always downloads.

  - `data.createdAt` (integer,null, required)
    Unix timestamp in milliseconds when the resource was created
    Example: 1736360000123

  - `data.createdBy` (object)
    Structured user information for a principal

  - `data.createdBy.display_name` (string)
    Human-readable display name

  - `data.createdBy.email` (string)
    Email address

  - `data.createdBy.type` (string)
    Principal type (user, service, service_account)

  - `data.createdBy.uid` (string)
    Principal unique identifier (username)

  - `data.downloadCmd` (string, required)

  - `data.downloadUrl` (string)

  - `data.id` (string, required)

  - `data.md5` (string, required)

  - `data.name` (string, required)

  - `data.path` (string, required)

  - `data.sha1` (string, required)

  - `data.sha256` (string, required)

  - `data.sha512` (string, required)

  - `data.size` (string, required)

  - `data.contentType` (string, required)
    Declared file Content-Type, or the extension-derived fallback for legacy files.

## Response default fields (application/json):

  - `error` (object, required)

  - `error.code` (string)
    For some errors that could be handled programmatically, a short string indicating the [error code](https://docs.stripe.com/error-codes) reported.

  - `error.message` (string)
    A human-readable message providing more details about the error. These messages can be shown to users.

  - `error.param` (string)
    If the error is parameter-specific, the parameter related to the error. For example, we can use this to display a message near the correct form field.

  - `error.type` (string, required)
    The type of error returned.
    Enum: "INVALID_REQUEST_ERROR", "AUTHENTICATION_ERROR", "PERMISSION_ERROR", "API_ERROR"


