Coding task · Python course · Module 5: Flask and Web Apps

API endpoints

Create an /animals/<int:id> endpoint that returns animal data.

Task

Write a view function with a dynamic id parameter of type int.