You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardexpand all lines: exercises/http_json_api_server/problem.md
+3-2
Original file line number
Diff line number
Diff line change
@@ -14,7 +14,7 @@ The JSON response should contain only 'hour', 'minute' and 'second' properties.
14
14
}
15
15
```
16
16
17
-
Add second endpoint for the path '/api/unixtime' which accepts the same query string but returns UNIX epoch time in milliseconds (the number of milliseconds since 1 Jan 1970 00:00:00 UTC) under the property 'unixtime'. For example:
17
+
Add a second endpoint for the path '/api/unixtime' which accepts the same query string, but returns UNIX epoch time in milliseconds (the number of milliseconds since 1 Jan 1970 00:00:00 UTC) under the property 'unixtime'. For example:
18
18
19
19
```json
20
20
{ "unixtime": 1376136615474 }
@@ -27,7 +27,8 @@ Your server should listen on the port provided by the first argument to your pro
27
27
28
28
The `request` object from an HTTP server has a `url` property that you will need to use to *"route"* your requests for the two endpoints.
29
29
30
-
You can parse the URL and query string using the Node core 'url' module. `url.parse(request.url, true)` will parse content of request.url and provide you with an object with helpful properties.
30
+
You can parse the URL and query string using the Node core 'url' module.
31
+
`url.parse(request.url, true)` will parse content of `request.url` and provide you with an object with helpful properties.
0 commit comments