type: dictionary
additionalProperties: false
properties:
  'applicationToken': { type: string, required: true }
  'baseUri':
    type: [string, 'null']
    required: true
  'middlewares':
    type: dictionary
    required: true
    additionalProperties:
      -
        type: 'null'
      -
        type: dictionary
        additionalProperties: false
        properties:
          'position': [string, number]
          'middleware': { type: string, format: class-name }
  'trustedProxies':
    type: dictionary
    required: true
    additionalProperties: false
    properties:
      'proxies':
         required: true
         type:
           -
             type: 'string'
           -
             # in case an env var is used but not set this will be false
             type: 'boolean'
           -
             type: dictionary
             additionalProperties:
               type: string
      'headers':
        required: true
        type:
          -
            type: 'string'
          -
            type: dictionary
            additionalProperties: false
            properties:
              'clientIp': { type: string, required: true }
              'host': { type: string, required: true }
              'port': { type: string, required: true }
              'proto': { type: string, required: true }
  'serverRequestDefaults':
    type: dictionary
    required: true
    additionalProperties: false
    properties:
      'userAgent':
        required: true
        type: string
      'scriptPath':
        required: true
        type: string
      'protocolVersion':
        required: true
        type: string
