docs: def prepare_volume_order_object(manager, storage_type, location, size,
                                  iops, tier, snapshot_size, service_offering,
                                  volume_type, hourly_billing_flag=False):
      """Prepare the order object which is submitted to the placeOrder() method
  
      :param manager: The File or Block manager calling this function
      :param storage_type: "performance" or "endurance"
      :param location: Requested datacenter location name for the ordered volume
      :param size: Desired size of the volume, in GB
      :param iops: Number of IOPs for a "Performance" volume order
      :param tier: Tier level to use for an "Endurance" volume order
      :param snapshot_size: The size of snapshot space for the volume (optional)
      :param service_offering: Requested offering package to use for the order
      :param volume_type: The type of the volume to order ('file' or 'block')
      :param hourly_billing_flag: Billing type, monthly (False) or hourly (True)
      :return: Returns the order object for the
               Product_Order service's placeOrder() method
      """
      # Ensure the volume storage type is valid
      if storage_type != 'performance' and storage_type != 'endurance':
          raise exceptions.SoftLayerError(
              "Volume storage type must be either performance or endurance")
  
      # Find the ID for the requested location
      try:
          location_id = get_location_id(manager, location)
      except ValueError:
          raise exceptions.SoftLayerError(
              "Invalid datacenter name specified. "
              "Please provide the lower case short name (e.g.: dal09)")
  
      # Determine the category code to use for the order (and product package)
      order_type_is_saas, order_category_code = _get_order_type_and_category(
          service_offering,
          storage_type,
          volume_type
      )
  
      # Get the product package for the given category code
      package = get_package(manager, order_category_code)
  
      # Based on the storage type and product package, build up the complex type
      # and array of price codes to include in the order object
      base_type_name = 'SoftLayer_Container_Product_Order_Network_'
      if order_type_is_saas:
          complex_type = base_type_name + 'Storage_AsAService'
          if storage_type == 'performance':
              prices = [
                  find_price_by_category(package, order_category_code),
                  find_price_by_category(package, 'storage_' + volume_type),
                  find_saas_perform_space_price(package, size),
                  find_saas_perform_iops_price(package, size, iops)
              ]
              if snapshot_size is not None:
                  prices.append(find_saas_snapshot_space_price(
                      package, snapshot_size, iops=iops))
          else:  # storage_type == 'endurance'
              prices = [
                  find_price_by_category(package, order_category_code),
                  find_price_by_category(package, 'storage_' + volume_type),
                  find_saas_endurance_space_price(package, size, tier),
                  find_saas_endurance_tier_price(package, tier)
              ]
              if snapshot_size is not None:
                  prices.append(find_saas_snapshot_space_price(
                      package, snapshot_size, tier=tier))
      else:  # offering package is enterprise or performance
          if storage_type == 'performance':
              if volume_type == 'block':
                  complex_type = base_type_name + 'PerformanceStorage_Iscsi'
              else:
                  complex_type = base_type_name + 'PerformanceStorage_Nfs'
              prices = [
                  find_price_by_category(package, order_category_code),
                  find_perf_space_price(package, size),
                  find_perf_iops_price(package, size, iops),
              ]
          else:  # storage_type == 'endurance'
              complex_type = base_type_name + 'Storage_Enterprise'
              prices = [
                  find_price_by_category(package, order_category_code),
                  find_price_by_category(package, 'storage_' + volume_type),
                  find_ent_space_price(package, 'endurance', size, tier),
                  find_ent_endurance_tier_price(package, tier),
              ]
              if snapshot_size is not None:
                  prices.append(find_ent_space_price(
                      package, 'snapshot', snapshot_size, tier))
  
      # Build and return the order object
      order = {
          'complexType': complex_type,
          'packageId': package['id'],
          'prices': prices,
          'quantity': 1,
          'location': location_id,
          'useHourlyPricing': hourly_billing_flag
      }
  
      if order_type_is_saas:
          order['volumeSize'] = size
          if storage_type == 'performance':
              order['iops'] = iops
  
      return order