Loading...
req.body -> long url from the user
return short url;
}
input -> short url from the user;
return mapped url (actual long url)
}
user send's long url we have to create a dictornary and store it in the key value paire
note before storing the repeated long url try to check weather the url present if yes then dont store again just get that url and return so we can save db size
the user will give short url we have to check weather the url present in the dictnory if yes send the mapped url to the user as a response