Improving the API backend