> ## Documentation Index
> Fetch the complete documentation index at: https://docs.quentli.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Get file metadata and download URL

> Returns a file owned by the API key organization and a signed download URL valid for 5 minutes. Signing credentials are excluded.



## OpenAPI

````yaml /openapi.yaml get /v1/files/{id}
openapi: 3.1.0
info:
  title: Quentli REST API
  version: 1.0.0
  description: OpenAPI spec for Quentli REST endpoints.
servers:
  - url: https://api.quentli.com
    description: Production API
  - url: https://api.staging.quentli.com
    description: Staging API for production-like validation
security:
  - organizationApiKey: []
tags:
  - name: Auth
  - name: Files
  - name: Billing
  - name: Catalog
  - name: Customers
  - name: Invoices
  - name: Payment Methods
  - name: Payment Sessions
  - name: Payments
  - name: Subscriptions
  - name: Tax Invoices
  - name: Webhooks
paths:
  /v1/files/{id}:
    get:
      tags:
        - Files
      summary: Get file metadata and download URL
      description: >-
        Returns a file owned by the API key organization and a signed download
        URL valid for 5 minutes. Signing credentials are excluded.
      operationId: files_get_by_id
      parameters:
        - schema:
            type: string
            minLength: 1
          required: true
          name: id
          in: path
      responses:
        '200':
          description: File metadata
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/File'
        '401':
          description: Authentication required
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/UserError'
        '403':
          description: Permission denied
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/UserError'
        '404':
          description: File not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/UserError'
components:
  schemas:
    File:
      type: object
      properties:
        id:
          type: string
          description: Unique file identifier.
        organizationId:
          type:
            - string
            - 'null'
          description: >-
            Owning organization identifier. Null for shared or
            organization-independent files.
        createdAt:
          anyOf:
            - type: string
              description: Date string
            - type: string
              format: date-time
              description: Date object
          description: When the file was created.
        updatedAt:
          anyOf:
            - type: string
              description: Date string
            - type: string
              format: date-time
              description: Date object
          description: When the file metadata was last updated.
        name:
          type: string
          description: Filename used for downloads and attachments.
        type:
          type: string
          description: File MIME type.
        size:
          type: integer
          minimum: 0
          description: File size in bytes.
        url:
          type: string
          format: uri
          description: Signed download URL, valid for 5 minutes.
      required:
        - id
        - organizationId
        - createdAt
        - updatedAt
        - name
        - type
        - size
        - url
      description: File metadata and a temporary download URL.
    UserError:
      type: object
      properties:
        error:
          type: object
          properties:
            message:
              type: string
          required:
            - message
      required:
        - error
      additionalProperties: false
      description: Standard user-facing error response envelope.
  securitySchemes:
    organizationApiKey:
      type: http
      scheme: bearer
      description: 'Organization API key using `Authorization: Bearer sk_...`.'

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.