Update api/index.php

found it from yg error log, packages need to be set as array.