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

# Get file details with a resolved URL.



## OpenAPI

````yaml https://api.offerclub.io/public-swagger-json get /v1.0/files/{id}
openapi: 3.0.0
info:
  title: Offerclub.io Public API
  description: >-
    External API for integrations. Authenticate every request with the
    `x-api-key` header.
  version: '1.0'
  contact: {}
  license:
    name: Legal Terms
    url: https://offerclub.io/legal/terms
servers:
  - url: https://api.offerclub.io
security: []
tags: []
paths:
  /v1.0/files/{id}:
    get:
      tags:
        - Public API — Files
      summary: Get file details with a resolved URL.
      operationId: publicApiGetFile
      parameters:
        - name: id
          required: true
          in: path
          schema:
            type: string
        - name: disposition
          required: false
          in: query
          description: >-
            Content disposition for the file URL. Notice: only "inline" will be
            cached. Use "attachment" for one-off downloads.
          schema:
            default: inline
            type: string
            enum:
              - inline
              - attachment
      responses:
        '200':
          description: File details with URL
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/FileDetailsResponseDto'
        '400':
          description: '`VALIDATION_ERROR` — Validation error'
          content:
            application/json:
              schema:
                allOf:
                  - $ref: '#/components/schemas/ErrorResponseDto'
                  - type: object
                    properties:
                      details:
                        oneOf:
                          - $ref: >-
                              #/components/schemas/ValidationErrorDetailsResponseDto
        '401':
          description: '`UNAUTHORIZED` — Unauthorized — missing or invalid API key'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponseDto'
        '403':
          description: >-
            `ONBOARDING_USER_NEEDS_REGISTRATION` — User bound to the API key no
            longer exists
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponseDto'
        '404':
          description: '`FILE_NOT_FOUND` — File not found or no permission'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponseDto'
        '500':
          description: '`INTERNAL_ERROR` — An unexpected error occurred'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponseDto'
      security:
        - ApiKey: []
components:
  schemas:
    FileDetailsResponseDto:
      type: object
      properties:
        id:
          type: string
          description: The ID of the file
        originalName:
          type: string
          description: The original name of the file
        size:
          type: number
          description: The size of the file
        mimeType:
          type: string
          description: The MIME type of the file
        isPublic:
          type: boolean
          description: Whether the file is public accessible
        isDraft:
          type: boolean
          description: Whether the file is a draft
        uploadedAt:
          format: date-time
          type: string
          description: The uploaded at date of the file
        imageWidth:
          type: number
          nullable: true
          description: The width of the image
        imageHeight:
          type: number
          nullable: true
          description: The height of the image
        thumbnailWidth:
          type: number
          nullable: true
          description: The width of the thumbnail
        thumbnailHeight:
          type: number
          nullable: true
          description: The height of the thumbnail
        url:
          type: string
          description: The (signed) URL of the file
        urlExpiresAt:
          format: date-time
          type: string
          nullable: true
          description: >-
            The expiration date for the (signed) URL, null if the file is public
            accessible
        thumbnailUrl:
          type: string
          nullable: true
          description: The (signed) URL for the thumbnail, null if the file is not an image
        thumbnailUrlExpiresAt:
          format: date-time
          type: string
          nullable: true
          description: >-
            The expiration date for the (signed) URL for the thumbnail, null if
            the file is not an image or the file is public accessible
      required:
        - id
        - originalName
        - size
        - mimeType
        - isPublic
        - isDraft
        - uploadedAt
        - imageWidth
        - imageHeight
        - thumbnailWidth
        - thumbnailHeight
        - url
        - urlExpiresAt
        - thumbnailUrl
        - thumbnailUrlExpiresAt
    ErrorResponseDto:
      type: object
      properties:
        statusCode:
          type: number
          description: HTTP status code
          example: 400
        code:
          enum:
            - INTERNAL_ERROR
            - VALIDATION_ERROR
            - ONBOARDING_USER_NEEDS_REGISTRATION
            - ONBOARDING_USER_NEEDS_ORGANIZATION
            - ORGANIZATION_NOT_FOUND
            - UNAUTHORIZED
            - FILE_NOT_FOUND
            - FILE_TYPE_NOT_ALLOWED
            - FILE_TYPE_NOT_ALLOWED_FOR_CONTEXT
            - FILE_ALREADY_COMMITTED
            - FILE_UPLOAD_FAILED
            - OFFER_OFFER_NUMBER_TAKEN
            - OFFER_INVALID_TRANSITION
            - OFFER_NOT_SENDABLE
            - OFFER_PAYMENT_PLAN_INVALID
            - OFFER_PAYMENT_PLAN_VALIDATION_FAILED
            - OFFER_ASSETS_VALIDATION_FAILED
            - ENTITY_NOT_FOUND
          type: string
          description: Machine-readable error code
          example: VALIDATION_ERROR
        message:
          type: string
          description: Human-readable error message
          example: Validation failed
        details:
          type: object
          additionalProperties: true
          nullable: true
          description: Additional error details (e.g. validation errors, missing fields)
          example:
            errors:
              - email must be a string
      required:
        - statusCode
        - code
        - message
    ValidationErrorDetailsResponseDto:
      type: object
      properties:
        errors:
          description: The validation errors
          type: array
          items:
            $ref: '#/components/schemas/FlatValidationErrorDetailsResponseDto'
      required:
        - errors
    FlatValidationErrorDetailsResponseDto:
      type: object
      properties:
        field:
          type: string
          description: The field that failed validation
        message:
          type: string
          description: The message that explains the validation failure
      required:
        - field
        - message
  securitySchemes:
    ApiKey:
      type: apiKey
      in: header
      name: x-api-key
      description: API key for authentication (can be generated in the settings)

````