Skip to content

Commit

Permalink
Feat: Create a live check for the url shortener
Browse files Browse the repository at this point in the history
  • Loading branch information
a2937 committed Nov 16, 2023
1 parent 68fe938 commit 399227a
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions apps/url-shortener-microservice/server.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,10 @@ app.get('/', (req, res) => {
res.sendFile(process.cwd() + '/views/index.html');
});

app.get('/status/ping', (req, res) => {
res.status(200).send({ msg: 'pong' });
});

// support legacy paths
app.post(['/api/shorturl', '/api/shorturl/new'], urlHandler.addUrl);

Expand Down

0 comments on commit 399227a

Please sign in to comment.