updated api + cube packing functionality