Fixed API request and view