# Download a File

Endpoint: GET /files/{file_id}/download
Security: BasicAuth

## Security:

  - `BasicAuth` (unknown)
    http basic

## Path parameters:

  - `file_id` (string, required)
    The ID of the `File` that was created to upload the file.

## Query parameters:

  - `stream` (boolean)
    Stream the contents of the `File` so it's displayed inline in the user's web browser.

## Header parameters:

  - `Finix-Version` (string)
    Specify the API version of your request. For more details, see [Versioning](../../../../additional-resources/developers/authentication-and-api-basics/versioning).

## Response 200:

  - `200` (unknown)
    A single `File Download`

## Response 200 headers (application/octet-stream):

  - `date` (string)
    A response header indicating the date and time of the API request.
    Example: Tue, 08 Jul 2025 17:38:01 GMT

  - `finix-apiuser-role` (string)
    This response header indicating the role of the user who sent the API request.
    Enum: "ROLE_PLATFORM", "ROLE_PARTNER", "ROLE_MERCHANT"

  - `x-request-id` (string)
    This response header provides a unique identifier for the API request.
    Example: 055972f6534f92a896fbb61b11313ebb

## Response 401:

  - `401` (unknown)
    Unauthorized. Authentication is required and has failed or has not been provided.

## Response 401 fields (application/json):

  - `total` (integer, required)
    Total number of errors returned.

  - `_embedded` (object, required)
    Container for embedded error objects.

  - `_embedded.errors` (array)
    List of individual error objects.

  - `_embedded.errors.code` (string)
    The error code. The `UNKNOWN` error code is returned for a 401 Unauthorized or 403 Forbidden request.

  - `_embedded.errors.logref` (string)
    A log reference identifier for the error, useful for debugging and support purposes.

  - `_embedded.errors.message` (string)
    A human-friendly error message.

  - `_embedded.errors._links` (object)
    Links related to this error.

  - `_embedded.errors._links.self` (object)
    Link to the resource related to the error.

  - `_embedded.errors._links.self.href` (string)
    URL of the related resource.

## Response 403:

  - `403` (unknown)
    Forbidden. The client is authenticated but does not have permission to access the resource.

## Response 403 fields (application/json):

  - `total` (integer, required)
    Total number of errors returned.

  - `_embedded` (object, required)
    Container for embedded error objects.

  - `_embedded.errors` (array)
    List of individual error objects.

  - `_embedded.errors.code` (string)
    The error code. The `UNKNOWN` error code is returned for a 401 Unauthorized or 403 Forbidden request.

  - `_embedded.errors.logref` (string)
    A log reference identifier for the error, useful for debugging and support purposes.

  - `_embedded.errors.message` (string)
    A human-friendly error message.

  - `_embedded.errors._links` (object)
    Links related to this error.

  - `_embedded.errors._links.self` (object)
    Link to the resource related to the error.

  - `_embedded.errors._links.self.href` (string)
    URL of the related resource.

## Response 404:

  - `404` (unknown)
    Not Found. The requested resource could not be found on the server.

## Response 404 fields (application/json):

  - `total` (integer, required)
    Total number of errors returned.

  - `_embedded` (object, required)
    Container for embedded error objects.

  - `_embedded.errors` (array)
    List of individual error objects.

  - `_embedded.errors.code` (string)
    The error code. The `UNKNOWN` error code is returned for a 401 Unauthorized or 403 Forbidden request.

  - `_embedded.errors.logref` (string)
    A log reference identifier for the error, useful for debugging and support purposes.

  - `_embedded.errors.message` (string)
    A human-friendly error message.

  - `_embedded.errors._links` (object)
    Links related to this error.

  - `_embedded.errors._links.self` (object)
    Link to the resource related to the error.

  - `_embedded.errors._links.self.href` (string)
    URL of the related resource.

## Response 406:

  - `406` (unknown)
    Not Acceptable. The server could not accept the submitted request. Confirm how the request was formatted and submitted.

## Response 406 fields (application/json):

  - `total` (integer, required)
    Total number of errors returned.

  - `_embedded` (object, required)
    Container for embedded error objects.

  - `_embedded.errors` (array)
    List of individual error objects.

  - `_embedded.errors.code` (string)
    The error code. The `UNKNOWN` error code is returned for a 401 Unauthorized or 403 Forbidden request.

  - `_embedded.errors.logref` (string)
    A log reference identifier for the error, useful for debugging and support purposes.

  - `_embedded.errors.message` (string)
    A human-friendly error message.

  - `_embedded.errors._links` (object)
    Links related to this error.

  - `_embedded.errors._links.self` (object)
    Link to the resource related to the error.

  - `_embedded.errors._links.self.href` (string)
    URL of the related resource.

## Response 401 examples:

  - `Unauthorized request` (unknown)

## Response 403 examples:

  - `Forbidden request` (unknown)

## Response 404 examples:

  - `NotFound` (unknown)

## Response 406 examples:

  - `Not acceptable` (unknown)

