Added more settings for api.php

Small bug fixes as well.