Updating Visitor Count
Update Your Visitor Count. When you visit the
"administration info" endpoint, the response body contains data about your shortened URL. One data point of the response body is how many times the shortened URL was clicked. So far, that count has remained at zero. To count the clicks when the shortened URL is visited, add a new function to the
crud.update_db_clicks() is inserted in the function call. Every time a friend uses the shortened URL, the click count is increased. You can use this number of clicks to see how many times a link was visited.
Become a Member to join the conversation.