Back End Development and APIs Projects - URL Shortener Microservice

Tell us what’s happening:

Hi,

I am trying to finish url shorter microservice from backend development and service is working for me and everything seeems fine but ı can’t pass 2 things:

  1. You can POST a URL to /api/shorturl and get a JSON response with original_url and short_url properties. Here’s an example: { original_url : 'https://freeCodeCamp.org', short_url : 1}

  2. When you visit /api/shorturl/<short_url> , you will be redirected to the original URL.

Results:

ı used freecodecamp for that screenshots and as you can see ı got json result with original_url and short_url but bot says

Your project link(s)
solution: https://ExpressUrlShorter.ertan222.repl.co

githubLink: GitHub - Ertan222/ExpressUrlShorter

Your browser information:

User Agent is: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/106.0.0.0 Safari/537.36

Challenge: Back End Development and APIs Projects - URL Shortener Microservice

Link to the challenge:

When I submit https://ExpressUrlShorter.ertan222.repl.co I get “invalid URL” as a response. It seems you are rejecting valid URLs.

My repl was down, sorry for that. I am using free version.

Even when it’s running, that URL doesn’t work. It seems like you have an error with your validator.