Update url shortening and returning the shortened url; handle the redirection if the shortened url is clicked.