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

# Upload a file



## OpenAPI

````yaml get /file/{type}/{id}/upload
openapi: 3.0.0
info:
  title: Example for response examples value
  version: '1.0'
servers:
  - url: https://api.helpyousponsor.com/v1
    description: Production
security: []
paths:
  /file/{type}/{id}/upload:
    get:
      tags:
        - Files
      summary: Upload a file
      operationId: 42872f65031140200a1d7ea09a61fc58
      parameters:
        - name: type
          in: path
          description: Type of the file (entity or donor)
          required: true
          schema:
            type: string
        - name: id
          in: path
          description: ID of the entity or donor
          required: true
          schema:
            type: integer
      responses:
        '200':
          description: Successful operation
          content:
            application/json:
              schema:
                properties:
                  type:
                    type: string
                    example: entity
                  id:
                    type: integer
                    example: 1
                  name:
                    type: string
                    example: John Doe
                  program:
                    type: object
                  hysform:
                    type: object
                  entity:
                    type: object
                  program_id:
                    type: string
                    example: program1
                  profileThumb:
                    type: string
                    example: http://example.com/thumb.jpg
                  submit:
                    type: array
                    items:
                      type: object
                  donor:
                    type: object
                  slug:
                    type: string
                    example: 5f4dcc3b5aa765d61d8327deb882cf99
                  upload:
                    type: object
                  box_access_token:
                    type: string
                    example: access_token
                  box_folder_id:
                    type: string
                    example: folder_id
                  emailsets:
                    type: boolean
                    example: false
                  years:
                    type: array
                    items:
                      type: object
                  template_errors:
                    type: array
                    items:
                      type: object
                type: object
        '404':
          description: Entity or Donor not found
          content:
            application/json:
              schema:
                properties:
                  message:
                    type: string
                    example: 'Error: Entity Not Found.'
                type: object
      security:
        - apiKeyAuth: []
components:
  securitySchemes:
    apiKeyAuth:
      type: apiKey
      description: 'API key generated from Developer Settings. Format: hys_...'
      name: X-HYS-API-Key
      in: header

````