Documentation

Available

{
  # Whether or not all resources are available to the user.
  'all_available': <bool>,
  
  # Whether or not all resources are available at the given time.
  'all_available_for_times': <bool>,
  
  # List of resource IDs that are available both for the time
  # and to the user.
  'availability_combined': [<str>],
  
  # List of resource IDs available to the user.
  'available': [<str>],
  
  # Detailed information as to whether or not a resource is
  # available at a given time.
  # If the unit is available, the dictionary will be in a short
  # form like:
  # {
  #   'reservable_id': 'reservable_id',
  #   'conflict': False,
  #   'available_units': 1,
  # }
  #
  # If the availability for times check is skipped due to not
  # being available to the user, another short form is given:
  # {
  #   'available_units': 0,
  #   'conflict': False,
  #   'reservable_id': 'reservable_id',
  #   'skipped': True,
  # }
  'available_for_times': <bool>, [{
    'available_units': <dec>,
    'conflict': <bool> or {
      'conflict_details': <none> or [{
        'buffer_conflict': <bool, str>, # False if not a buffer conflict
        'end': <datetime>,
        'reservable': {
          'reservable_id': <str>,
          'name': <str>,
        },
        'reservation_id': <str>,
        'start': <datetime>,
        'status': <str>,
        't': <str>, # 'start' or 'end', refers to where the conflict takes place
        'user_id': <str>,
      }],
      'conflict_id': <str>, <int>, [<str>], [<int>], # ID(s) of object causing conflict
      'msg': <str>, # Description of conflict
    },
    'reservable_id': <str>,
  }],
  'not_availability_combined': [<str>],
  
  # List of resource IDs not available to the user.
  'not_available': [<str>],
  
  # List of resource IDs not available at the given times.
  'not_available_for_times': [<str>],
  
  # List of all reservables requested and whether or not they
  # are able to be reserved by the user.
  'reservables_status': [{
      'reservable_id': <str>,
      'can_reserve': <bool>,
  }],
}