Back End Development and APIs Projects - Timestamp Microservice

Hello everyone! I wanted to ask wether the test case is space-sensitive?

I am getting this output for the 4th test case:
{“unix”:“1451001600000”,“utc”:“Fri, 25 Dec 2015 00:00:00 GMT”}

but it is not being accepted. Could someone please clarify what I’m doing wrong?

Replit link:

Thank you!

The 4th test case is:

A request to /api/1451001600000 should return { unix: 1451001600000, utc: “Fri, 25 Dec 2015 00:00:00 GMT” }

Your app’s link runs fine with this test.

It looks like your 3rd test gets thru too. But, not the 2nd test, below:

A request to /api/:date? with a valid date should return a JSON object with a unix key that is a Unix timestamp of the input date in milliseconds

Really? For some reason they were showing as unsuccessful to me.

Thanks for pointing that out! I’ll try to fix it. We only have to consider inputs in the form of unix format right?

The input formats and the corresponding response need to be as per the listed tests.

You can try the provided app ( with similar functionality. Try the various queries/tests and the results - and see if your results match for the same query/data.

P.S.: Please use the <Reply> button when you are replying to a specific post/comment, so that I or the poster can see the notification.

1 Like

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.