Work in progress commit of API.php, adding some functions with queries