Removes files that are no longer needed
Adds in conditional api endpoint loading - Sorry Vince