Cleaned up and commented api files