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

# Get File or Directory

> Get a specific file or directory based on ID



## OpenAPI

````yaml /openapi.yaml get /files/{fileOrDirId}
openapi: 3.1.1
info:
  title: MijnKlantportaal API
  version: v1
servers:
  - url: https://api.mijnklantportaal.nl/v1
security:
  - APIKey: []
tags:
  - name: Agreements API
  - name: Appointments API
  - name: Customers API
  - name: Customer Groups API
  - name: Customer Invoices API
  - name: Customer Offers API
  - name: Customer Subscriptions API
  - name: Customer Subscription Packages API
  - name: Files API
  - name: File Request API
  - name: File Share API
  - name: Invoices API
  - name: Payment Links API
  - name: Punch Cards API
  - name: Tickets API
  - name: Webhooks API
paths:
  /files/{fileOrDirId}:
    get:
      tags:
        - Files API
      summary: Get File or Directory
      description: Get a specific file or directory based on ID
      operationId: get-file
      parameters:
        - name: fileOrDirId
          in: path
          description: ID of the file or directory to get
          required: true
          schema:
            type: string
            example: fsf_abc12345678
      responses:
        '200':
          description: The requested file or directory
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/FileOrDirectory'
        '404':
          description: The file or directory could not be found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error_ApiError'
components:
  schemas:
    FileOrDirectory:
      type: object
      description: File or Directory
      properties:
        id:
          type: string
          example: fsf_abc12345678
          description: >-
            ID of the file or directory. Files are starting with `fsf_`,
            directories with `fsd_`.
        type:
          type: string
          example: file
          description: Type of this content item. Can be `file` or `directory`.
        name:
          type: string
          example: contract_v2.pdf
          description: Name of the file or directory
        size:
          type: integer
          nullable: true
          example: 1284
          description: Size of the file in bytes. Will be `null` for directories.
        mime:
          type: string
          nullable: true
          example: application/pdf
          description: The mime-type of the file. Will be `null` for directories.
        fileShareId:
          type: string
          nullable: true
          example: fss_abc12345678
          description: ID of the Share this file or directory is shared in, if shared.
        createdAt:
          type: string
          example: '2024-04-29T21:00:00+02:00'
          description: >-
            Date and time when the payment link was created. Written in ATOM
            format.
    Error_ApiError:
      type: object
      properties:
        message:
          type: string
          description: Explanation what went wrong
  securitySchemes:
    APIKey:
      type: http
      scheme: bearer

````