{"info":{"_postman_id":"b012b572-450f-4619-9c0b-90b8369fd797","name":"Zoomer API","description":"<html><head></head><body><p>This collection stores all the Microservices information needed for Zoomer's API (Apart of the CSC301 assignment)</p>\n</body></html>","schema":"https://schema.getpostman.com/json/collection/v2.0.0/collection.json","toc":[],"owner":"14483503","collectionId":"b012b572-450f-4619-9c0b-90b8369fd797","publishedId":"UVsLSRqT","public":true,"customColor":{"top-bar":"FFFFFF","right-sidebar":"303030","highlight":"EF5B25"},"publishDate":"2023-02-27T01:28:20.000Z"},"item":[{"name":"Location Microservice","item":[{"name":"Add User's Initial Location Information","id":"55f89aaa-c32f-4c6f-a45d-38ee1fb051bb","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PUT","header":[],"body":{"mode":"raw","raw":"{\n    \"uid\": String,\n    \"is_driver\": Boolean\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8000/location/user","description":"<p>Add user's location into the database.<br />Initializes with the following values:</p>\n<ul>\n<li>latitude = 0</li>\n<li>longitude = 0</li>\n<li>street = \"\"</li>\n</ul>\n<h1 id=\"body-parameters\">Body Parameters</h1>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>ID</th>\n<th>Type</th>\n<th>Descripton</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>uid</td>\n<td>String</td>\n<td>user's ID from the location microservice</td>\n</tr>\n<tr>\n<td>is_driver</td>\n<td>Boolean</td>\n<td>Whether the user is a driver</td>\n</tr>\n</tbody>\n</table>\n</div><h1 id=\"expected-responses\">Expected Responses</h1>\n<p>For any valid Request, status code should be 200 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"OK\"\n}\n\n</code></pre>\n<p>If any attribute is missing, status code should be 400 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"BAD REQUEST\"\n}\n\n</code></pre>\n<p>Otherwise, the status should be 500 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"INTERNAL SERVER ERROR\"\n}\n\n</code></pre>\n<h1 id=\"body-type\">Body Type</h1>\n","urlObject":{"path":["location","user"],"host":["localhost:8000"],"query":[],"variable":[]}},"response":[{"id":"8bf05f30-0d1b-4ad7-8dbd-ced3e9d1ebfe","name":"Bad Request (No UID)","originalRequest":{"method":"PUT","header":[],"body":{"mode":"raw","raw":"{\n    \"is_driver\": true\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8000/location/user"},"code":400,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"BAD REQUEST\"\n}"},{"id":"d2dc57a9-dbc3-4e3b-8225-6ecea80a35a7","name":"Successful Response","originalRequest":{"method":"PUT","header":[],"body":{"mode":"raw","raw":"{\n    \"uid\": \"1\",\n    \"is_driver\": true\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8000/location/user"},"code":200,"_postman_previewlanguage":"json","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"OK\"\n}"},{"id":"d6b7b2c3-6757-4a4a-bc4e-6fcf7c255b9b","name":"Bad Request (No Driver)","originalRequest":{"method":"PUT","header":[],"body":{"mode":"raw","raw":"{\n    \"uid\": \"1\"\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8000/location/user"},"code":400,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"BAD REQUEST\"\n}"}],"_postman_id":"55f89aaa-c32f-4c6f-a45d-38ee1fb051bb"},{"name":"Delete User from Database","id":"df36a621-c5fe-400a-8e20-8a4545da3244","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"DELETE","header":[],"body":{"mode":"raw","raw":"{\n    \"uid\": String\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8000/location/user","description":"<p>Deletes a user from the location microservice database</p>\n<h1 id=\"body-parameters\">Body Parameters</h1>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>ID</th>\n<th>Type</th>\n<th>Descripton</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>uid</td>\n<td>String</td>\n<td>user's ID from the location microservice</td>\n</tr>\n</tbody>\n</table>\n</div><h1 id=\"expected-responses\">Expected Responses</h1>\n<p>For any valid Request, status code should be 200 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"OK\"\n}\n\n</code></pre>\n<p>If the UID is not found, status code should be 404 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"NOT FOUND\"\n}\n\n</code></pre>\n<p>If any attribute is missing, status code should be 400 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"BAD REQUEST\"\n}\n\n</code></pre>\n<p>Otherwise, the status should be 500 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"INTERNAL SERVER ERROR\"\n}\n\n</code></pre>\n<h1 id=\"body-type\">Body Type</h1>\n","urlObject":{"path":["location","user"],"host":["localhost:8000"],"query":[],"variable":[]}},"response":[{"id":"4f1b7c9d-bfda-45a6-b5df-07c1da37827f","name":"Bad Request (No UID)","originalRequest":{"method":"DELETE","header":[],"body":{"mode":"raw","raw":"","options":{"raw":{"language":"json"}}},"url":"localhost:8000/location/user"},"code":400,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"BAD REQUEST\"\n}"},{"id":"a720c2e1-9de7-40f2-8325-aba50a66c163","name":"Not Found (UID not found)","originalRequest":{"method":"DELETE","header":[],"body":{"mode":"raw","raw":"{\n    \"uid\": \"2\"\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8000/location/user"},"code":404,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"NOT FOUND\"\n}"},{"id":"d2932b09-f4fd-496a-9ee8-79ff0b181a72","name":"Successful Response","originalRequest":{"method":"DELETE","header":[],"body":{"mode":"raw","raw":"{\n    \"uid\": \"1\"\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8000/location/user"},"code":200,"_postman_previewlanguage":"json","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"OK\"\n}"}],"_postman_id":"df36a621-c5fe-400a-8e20-8a4545da3244"},{"name":"Get User Location","id":"293dd30b-a5a9-48da-8996-0bb220713ff2","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"localhost:8000/location/:uid","description":"<p>Get the current location for a given user</p>\n<h1 id=\"expected-responses\">Expected Responses</h1>\n<p>For any valid Request, status code should be 200 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"OK\",\n    \"data\": {\n        \"longitude\": Double,\n        \"latitude\": Double,\n        \"street\": String\n    }\n}\n</code></pre>\n<p>If UID is missing, status code should be 400 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"BAD REQUEST\"\n}\n</code></pre>\n<p>If the UID is not found in the database, the status code should be 404 and the response body should be </p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"NOT FOUND\"\n}\n</code></pre>\n<p>Otherwise, the status code should be 500 and the response body should be </p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"INTERNAL SERVER ERROR\"\n}\n</code></pre>\n","urlObject":{"path":["location",":uid"],"host":["localhost:8000"],"query":[{"disabled":true,"key":"","value":""}],"variable":[{"description":{"content":"<p>The UID (from the location microservice) to retrieve the location from</p>\n","type":"text/plain"},"type":"any","value":"","key":"uid"}]}},"response":[{"id":"174c72ad-b5d7-4f38-a628-46cdea8d03d4","name":"Successful Response","originalRequest":{"method":"GET","header":[],"url":{"raw":"localhost:8000/location/:uid","host":["localhost"],"port":"8000","path":["location",":uid"],"variable":[{"key":"uid","value":"1","description":"The UID (from the location microservice) to retrieve the location from"}]}},"code":200,"_postman_previewlanguage":"json","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"OK\",\n    \"data\": {\n        \"longitude\": 41.303921,\n        \"latitude\": -81.901693,\n        \"street\": \"Mississauga Road\"\n    }\n}"},{"id":"dae81264-b652-4276-b71f-0e00464a40a5","name":"Not Found (UID NOT FOUND)","originalRequest":{"method":"GET","header":[],"url":{"raw":"localhost:8000/location/:uid","host":["localhost:8000"],"path":["location",":uid"],"query":[{"key":"","value":null,"disabled":true}],"variable":[{"key":"uid","value":"3","description":"The UID (from the location microservice) to retrieve the location from"}]}},"code":404,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"NOT FOUND\"\n}"},{"id":"e497d7ef-73b0-462f-9b25-29d08d457282","name":"Bad Request (UID MISSING)","originalRequest":{"method":"GET","header":[],"url":{"raw":"localhost:8000/location","host":["localhost:8000"],"path":["location"],"query":[{"key":"","value":null,"disabled":true}]}},"code":400,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"BAD REQUEST\"\n}"}],"_postman_id":"293dd30b-a5a9-48da-8996-0bb220713ff2"},{"name":"Update User Location","id":"2284fcad-6382-478d-bd0f-96ba8e6a9019","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PATCH","header":[],"body":{"mode":"raw","raw":"{\n    \"longitude\": Double,\n    \"latitude\": Double,\n    \"street\": String\n}","options":{"raw":{"language":"text"}}},"url":"localhost:8000/location/:uid","description":"<p>Updates the current location of the user</p>\n<h1 id=\"body-parameters\">Body Parameters</h1>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>ID</th>\n<th>Type</th>\n<th>Descripton</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>longitude</td>\n<td>Double</td>\n<td>The new longitude</td>\n</tr>\n<tr>\n<td>latitude</td>\n<td>Double</td>\n<td>The new latitude</td>\n</tr>\n<tr>\n<td>street</td>\n<td>String</td>\n<td>The new street</td>\n</tr>\n</tbody>\n</table>\n</div><h1 id=\"expected-responses\">Expected Responses</h1>\n<p>For any valid Request, status code should be 200 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"OK\"\n}\n\n</code></pre>\n<p>If any parameter is missing, status code should be 400 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"BAD REQUEST\"\n}\n\n</code></pre>\n<p>If the UID is not found in the database, the status code should be 404 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"NOT FOUND\"\n}\n\n</code></pre>\n<p>Otherwise, the status code should be 500 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"INTERNAL SERVER ERROR\"\n}\n\n</code></pre>\n","urlObject":{"path":["location",":uid"],"host":["localhost:8000"],"query":[],"variable":[{"description":{"content":"<p>The UID (from the location microservice) to retrieve the location from</p>\n","type":"text/plain"},"type":"any","value":"1","key":"uid"}]}},"response":[{"id":"dcec7228-1891-46e7-8e1b-2b32f599d3c3","name":"Successful Response","originalRequest":{"method":"PATCH","header":[],"body":{"mode":"raw","raw":"{\n    \"longitude\": 1234.56,\n    \"latitude\": -123.456,\n    \"street\": \"Streetsville\"\n}","options":{"raw":{"language":"text"}}},"url":{"raw":"localhost:8000/location/:uid","host":["localhost:8000"],"path":["location",":uid"],"variable":[{"key":"uid","value":"2","description":"The UID (from the location microservice) to retrieve the location from"}]}},"code":200,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"OK\"\n}"},{"id":"b311dd93-fa15-46a8-8e69-b103ddb1f348","name":"Bad Request (UID MISSING)","originalRequest":{"method":"PATCH","header":[],"body":{"mode":"raw","raw":"{\n    \"longitude\": Double,\n    \"latitude\": Double,\n    \"street\": String\n}","options":{"raw":{"language":"text"}}},"url":"localhost:8000/location"},"code":400,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"BAD REQUEST\"\n}"},{"id":"c1141c4d-616e-418f-a9f0-7d8616b00d20","name":"Not Found (UID NOT FOUND)","originalRequest":{"method":"PATCH","header":[],"body":{"mode":"raw","raw":"{\n    \"longitude\": Double,\n    \"latitude\": Double,\n    \"street\": String\n}","options":{"raw":{"language":"text"}}},"url":{"raw":"localhost:8000/location/:uid","host":["localhost:8000"],"path":["location",":uid"],"variable":[{"key":"uid","value":"3","description":"The UID (from the location microservice) to retrieve the location from"}]}},"code":404,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"NOT FOUND\"\n}"}],"_postman_id":"2284fcad-6382-478d-bd0f-96ba8e6a9019"},{"name":"Get Nearby Drivers within the given radius","id":"fa0bcbd1-9a34-48c0-9a19-79f87991cc58","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"localhost:8000/location/nearbyDriver/:uid?radius=","description":"<p>Get all nearby drivers WITHIN a given radius around a given user - <strong>TODO</strong></p>\n<h1 id=\"edge-cases\">Edge Cases</h1>\n<ul>\n<li>If a driver requests a trip, include their own uid in the returned uids</li>\n<li>If a driver is exactly radius km away, don't include their uid in the returned data</li>\n</ul>\n<h1 id=\"expected-responses\">Expected Responses</h1>\n<p>For any valid Request, status code should be 200 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"OK\",\n    \"data\": {\n        \"driverID\": {\n            \"longitude\": Double,\n            \"latitude\": Double,\n            \"street\": String\n        },\n        ...\n    }\n}\n\n</code></pre>\n<p>If any parameter is missing or if any values are of the wrong type or if the URI has extra arguments, status code should be 400 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"BAD REQUEST\"\n}\n\n</code></pre>\n<p>If the UID is not found in the database or if there are no nearby drivers, the status code should be 404 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"NOT FOUND\"\n}\n\n</code></pre>\n<p>Otherwise, the status code should be 500 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"INTERNAL SERVER ERROR\"\n}\n\n</code></pre>\n","urlObject":{"path":["location","nearbyDriver",":uid"],"host":["localhost:8000"],"query":[{"description":{"content":"<p>Positive integer that represents the radius in km</p>\n","type":"text/plain"},"key":"radius","value":""}],"variable":[{"description":{"content":"<p>The UID of the user (from the location microservice)</p>\n","type":"text/plain"},"type":"any","value":"","key":"uid"}]}},"response":[{"id":"3dbfee3d-a06f-48f4-88ef-9d0a5416a078","name":"Bad Request (UID MISSING)","originalRequest":{"method":"GET","header":[],"url":{"raw":"localhost:8000/location/nearbyDriver?radius=5","host":["localhost:8000"],"path":["location","nearbyDriver"],"query":[{"key":"radius","value":"5","description":"Positive integer that represents the radius in km"}]}},"code":400,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"BAD REQUEST\"\n}"},{"id":"21db377a-25fa-4f06-be2b-68449c602d24","name":"Successful Response","originalRequest":{"method":"GET","header":[],"url":{"raw":"localhost:8000/location/nearbyDriver/:uid?radius=3","host":["localhost:8000"],"path":["location","nearbyDriver",":uid"],"query":[{"key":"radius","value":"3","description":"Positive integer that represents the radius in km"}],"variable":[{"key":"uid","value":"2","description":"The UID of the user (from the location microservice)"}]}},"code":200,"_postman_previewlanguage":"text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"OK\",\n    \"data\": {\n        \"3\": {\n            \"longitude\": 139.321,\n            \"latitude\": 129.3,\n            \"street\": \"Missauga Road\"\n        },\n        \"5\": {\n            \"longitude\": 151.451,\n            \"latitude\": 167.5,\n            \"street\": \"FooBar Street\"\n        }\n    }\n}"},{"id":"84fc1bdb-9d1c-4461-a1c5-f20c29b62345","name":"Not Found (UID MISSING/No Nearby Drivers)","originalRequest":{"method":"GET","header":[],"url":{"raw":"localhost:8000/location/nearbyDriver/:uid?radius=6","host":["localhost:8000"],"path":["location","nearbyDriver",":uid"],"query":[{"key":"radius","value":"6","description":"Positive integer that represents the radius in km"}],"variable":[{"key":"uid","value":"4","description":"The UID of the user (from the location microservice)"}]}},"code":404,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"NOT FOUND\"\n}"},{"id":"83410258-b647-4a8b-8ec3-a277a0ffd368","name":"Bad Request (RADIUS MISSING)","originalRequest":{"method":"GET","header":[],"url":{"raw":"localhost:8000/location/nearbyDriver/:uid","host":["localhost:8000"],"path":["location","nearbyDriver",":uid"],"variable":[{"key":"uid","value":"7"}]}},"code":400,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"BAD REQUEST\"\n}"}],"_postman_id":"fa0bcbd1-9a34-48c0-9a19-79f87991cc58"},{"name":"Add/Update Road","id":"847312e7-36ff-44b1-b4ad-148d02a83972","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PUT","header":[],"body":{"mode":"raw","raw":"{\n    \"roadName\": String,\n    \"hasTraffic\": Boolean\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8000/location/road","description":"<p>Add a road into the database. \nIf the road name is already exist in the database, update the rest of the info in the database with the road name.</p>\n<h1 id=\"body-parameters\">Body Parameters</h1>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>ID</th>\n<th>Type</th>\n<th>Descripton</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>roadName</td>\n<td>String</td>\n<td>The road name to update/add</td>\n</tr>\n<tr>\n<td>hasTraffic</td>\n<td>Boolean</td>\n<td>Whether the road has traffic or not</td>\n</tr>\n</tbody>\n</table>\n</div><h1 id=\"expected-responses\">Expected Responses</h1>\n<p>For any valid Request, status code should be 200 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"OK\"\n}\n</code></pre>\n<p>If any parameter is missing, status code should be 400 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"BAD REQUEST\"\n}\n</code></pre>\n<p>Otherwise, the status code should be 500 and the response body should be </p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"INTERNAL SERVER ERROR\"\n}\n</code></pre>\n","urlObject":{"path":["location","road"],"host":["localhost:8000"],"query":[],"variable":[]}},"response":[{"id":"d7dce402-2eb4-4b05-a6b0-e9b0d05d9d38","name":"Bad Request (MISSING roadName)","originalRequest":{"method":"PUT","header":[],"body":{"mode":"raw","raw":"{\n    \"roadName\": String\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8000/location/road"},"code":400,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"BAD REQUEST\"\n}"},{"id":"fab02ded-5c59-42f7-95d0-c2c3345c06a7","name":"Successful Response","originalRequest":{"method":"PUT","header":[],"body":{"mode":"raw","raw":"{\n    \"roadName\": \"New Road\",\n    \"hasTraffic\": false\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8000/location/road"},"code":200,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"OK\"\n}"},{"id":"ff05a6f1-a3ff-4a9a-aaf5-cdb739886131","name":"Bad Request (MISSING hasTraffic)","originalRequest":{"method":"PUT","header":[],"body":{"mode":"raw","raw":"{\n    \"roadName\": String,\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8000/location/road"},"code":400,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"BAD REQUEST\"\n}"}],"_postman_id":"847312e7-36ff-44b1-b4ad-148d02a83972"},{"name":"Add Route to Database","id":"0bc40e07-93ac-4d77-9286-6c6db7a71e3b","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"roadName1\": String,\n    \"roadName2\": String,\n    \"hasTraffic\": Boolean,\n    \"time\": Number\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8000/location/hasRoute","description":"<p>Create a connection from a road to another; making a relationship in Neo4j.</p>\n<h1 id=\"body-parameters\">Body Parameters</h1>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>ID</th>\n<th>Type</th>\n<th>Descripton</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>roadName1</td>\n<td>String</td>\n<td>The first road</td>\n</tr>\n<tr>\n<td>roadName2</td>\n<td>String</td>\n<td>The second road</td>\n</tr>\n<tr>\n<td>hasTraffic</td>\n<td>Boolean</td>\n<td>whether the route is on heavy traffic</td>\n</tr>\n<tr>\n<td>time</td>\n<td>Integer</td>\n<td>positive integer representing the time to travel from roadName1 to roadName2 in minutes</td>\n</tr>\n</tbody>\n</table>\n</div><h1 id=\"expected-responses\">Expected Responses</h1>\n<p>For any valid Request, status code should be 200 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"OK\"\n}\n</code></pre>\n<p>If either Road is not found in the database, status code should be 404 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"NOT FOUND\"\n}\n</code></pre>\n<p>If any parameter is missing, status code should be 400 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"BAD REQUEST\"\n}\n</code></pre>\n<p>Otherwise, the status code should be 500 and the response body should be </p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"INTERNAL SERVER ERROR\"\n}\n</code></pre>\n","urlObject":{"path":["location","hasRoute"],"host":["localhost:8000"],"query":[],"variable":[]}},"response":[{"id":"ffbf5e7c-7bea-4492-80cf-ef75300c5ac0","name":"Bad Request (TIME MISSING)","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"roadName1\": String,\n    \"roadName2\": String,\n    \"hasTraffic\": Boolean\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8000/location/hasRoute"},"code":400,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"BAD REQUEST\"\n}"},{"id":"4cdc7354-0382-4044-9495-e70575de0137","name":"Not Found (Road MISSING)","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"roadName1\": String,\n    \"roadName2\": String,\n    \"hasTraffic\": Boolean,\n    \"time\": Number\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8000/location/hasRoute"},"code":404,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"NOT FOUND\"\n}"},{"id":"ba6e0987-d29c-4d51-a992-a0f35a61e593","name":"Bad Request (roadName1 MISSING)","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"roadName2\": String,\n    \"hasTraffic\": Boolean,\n    \"time\": Number\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8000/location/hasRoute"},"code":400,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"BAD REQUEST\"\n}"},{"id":"a527692d-3ee2-4d09-98e5-46d31d2a7f16","name":"Successful Response","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"roadName1\": \"Street1\",\n    \"roadName2\": \"Street2\",\n    \"hasTraffic\": false,\n    \"time\": 40\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8000/location/hasRoute"},"code":200,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"OK\"\n}"},{"id":"5a6ea6a1-cc37-48c4-99bd-3481188bdc9d","name":"Bad Request (hasTraffic MISSING)","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"roadName1\": String,\n    \"roadName2\": String,\n    \"time\": Number\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8000/location/hasRoute"},"code":400,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"BAD REQUEST\"\n}"},{"id":"91bb5d8d-2943-4685-965d-43fa103fe509","name":"Bad Request (roadName2 MISSING)","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"roadName1\": String,\n    \"hasTraffic\": Boolean,\n    \"time\": Number\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8000/location/hasRoute"},"code":400,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"BAD REQUEST\"\n}"}],"_postman_id":"0bc40e07-93ac-4d77-9286-6c6db7a71e3b"},{"name":"Remove a Route","id":"cc1262aa-bc74-400a-9c0c-54d5e78817a7","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"DELETE","header":[],"body":{"mode":"raw","raw":"{\n    \"roadName1\": String,\n    \"roadName2\": String\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8000/location/route","description":"<p>Disconnect a road with another; unbound the relationship in Neo4j</p>\n<h1 id=\"body-parameters\">Body Parameters</h1>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>ID</th>\n<th>Type</th>\n<th>Descripton</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>roadName1</td>\n<td>String</td>\n<td>The first road</td>\n</tr>\n<tr>\n<td>roadName2</td>\n<td>String</td>\n<td>The second road</td>\n</tr>\n</tbody>\n</table>\n</div><h1 id=\"expected-responses\">Expected Responses</h1>\n<p>For any valid Request, status code should be 200 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"OK\"\n}\n</code></pre>\n<p>If either road doesn't exist, status code should be 404 and the response body should be </p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"NOT FOUND\"\n}\n</code></pre>\n<p>If any parameter is missing, status code should be 400 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"BAD REQUEST\"\n}\n</code></pre>\n<p>Otherwise, the status code should be 500 and the response body should be </p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"INTERNAL SERVER ERROR\"\n}\n</code></pre>\n","urlObject":{"path":["location","route"],"host":["localhost:8000"],"query":[],"variable":[]}},"response":[{"id":"3d53e266-4821-41cd-937e-6e35be136b18","name":"Bad Request (roadName2 MISSING)","originalRequest":{"method":"DELETE","header":[],"body":{"mode":"raw","raw":"{\n    \"roadName1\": String\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8000/location/route"},"code":400,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"BAD REQUEST\"\n}"},{"id":"7deb725c-57f2-4167-9901-40e2f97fbe1e","name":"Successful Response","originalRequest":{"method":"DELETE","header":[],"body":{"mode":"raw","raw":"{\n    \"roadName1\": \"New Road\",\n    \"roadName2\": \"New Road2\"\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8000/location/route"},"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"OK\"\n}"},{"id":"9fd8a4ca-2bc3-4b28-984d-ca9f61e79ca3","name":"Bad Request (roadName1 MISSING)","originalRequest":{"method":"DELETE","header":[],"body":{"mode":"raw","raw":"{\n    \"roadName2\": String\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8000/location/route"},"code":400,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"BAD REQUEST\"\n}"},{"id":"b5c5c609-b169-4e4b-92ae-434a9e37e452","name":"Road Not Found (NOT FOUND)","originalRequest":{"method":"DELETE","header":[],"body":{"mode":"raw","raw":"{\n    \"roadName1\": String,\n    \"roadName2\": String\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8000/location/route"},"code":404,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"NOT FOUND\"\n}"}],"_postman_id":"cc1262aa-bc74-400a-9c0c-54d5e78817a7"},{"name":"Get Navigation route","id":"26433118-1579-4073-892a-e33d40ae861f","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"localhost:8000/location/navigation/:driverUid?passengerUid=","description":"<p>Get the shortest path between the given driver's street and the given passenger's street, weighted by the travel_time attribute of the ROUTE_TO relationship - <strong>TODO</strong></p>\n<h1 id=\"edge-cases\">Edge Cases</h1>\n<ul>\n<li>A path between the two streets of the given driver and passenger may not always exist, in which case you can return a 404 as shown under 'Expected Responses'</li>\n<li>You may assume the streets of the given users do correspond to existing road nodes in the database</li>\n</ul>\n<h1 id=\"expected-responses\">Expected Responses</h1>\n<p>For any valid Request, status code should be 200 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"OK\"\n    \"data\": {\n        \"total_time\": Integer,\n        \"route\": [{\n            \"street\": String,\n            \"has_traffic\": Boolean,\n            \"time\": Integer\n        },\n        ...\n        ]\n    }\n}\n\n</code></pre>\n<p>Where the \"route\" field has a list of objects that represent each road in the shortest path. In the list of objects, \"street\" is the name attribute of the road node, \"has_traffic\" is has_traffic attribute of the road node, and \"time\" is the travel_time attribute of the ROUTE_TO relationship between the road and the next road in the shortest path. The \"time\" attribute should be 0 for the first object in the route list. The \"total_time\" field is simply the sum of all time values from the route list.</p>\n<p>If either driverUid or passengerUid is not in the database or if driverUid is not a driver or if a path between driver and passenger doesn't exist, status code should be 404 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"NOT FOUND\"\n}\n\n</code></pre>\n<p>If any parameter is missing or if any value is of the wrong type or if the URI has extra arguments, status code should be 400 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"BAD REQUEST\"\n}\n\n</code></pre>\n<p>Otherwise, the status code should be 500 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"INTERNAL SERVER ERROR\"\n}\n\n</code></pre>\n","urlObject":{"path":["location","navigation",":driverUid"],"host":["localhost:8000"],"query":[{"description":{"content":"<p>the passenger's UID - from the location microservice</p>\n","type":"text/plain"},"key":"passengerUid","value":""}],"variable":[{"description":{"content":"<p>the driver's UID - from the location microservice</p>\n","type":"text/plain"},"type":"any","value":"","key":"driverUid"}]}},"response":[{"id":"c7a52a1b-0f74-4df6-9250-cbd32f5f4ddf","name":"Bad Request (driverUid MISSING)","originalRequest":{"method":"GET","header":[],"url":{"raw":"localhost:8000/location/navigation?passengerUid=4","host":["localhost:8000"],"path":["location","navigation"],"query":[{"key":"passengerUid","value":"4"}]}},"code":400,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"BAD REQUEST\"\n}"},{"id":"eb07afb6-e2c1-4964-95af-b7a3949e8ef2","name":"Bad Request (passengerUid MISSING)","originalRequest":{"method":"GET","header":[],"url":{"raw":"localhost:8000/location/navigation/:driverUid","host":["localhost:8000"],"path":["location","navigation",":driverUid"],"variable":[{"key":"driverUid","value":"5","description":"the driver's UID - from the location microservice"}]}},"code":400,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"BAD REQUEST\"\n}"},{"id":"997c9511-1e0b-4fb3-8452-8d6249be7da0","name":"Successful Response","originalRequest":{"method":"GET","header":[],"url":{"raw":"localhost:8000/location/navigation/:driverUid?passengerUid=2","host":["localhost:8000"],"path":["location","navigation",":driverUid"],"query":[{"key":"passengerUid","value":"2","description":"the passenger's UID - from the location microservice"}],"variable":[{"key":"driverUid","value":"1"}]}},"code":200,"_postman_previewlanguage":"json","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"OK\",\n    \"data\": {\n        \"total_time\": 10,\n        \"route\": [{\n            \"street\": \"Street1\",\n            \"time\": 0,\n            \"has_traffic\": false\n        },\n        {\n            \"street\": \"Street2\",\n            \"time\": 4,\n            \"has_traffic\": true\n        },\n        {\n            \"street\": \"Street3\",\n            \"time\": 6,\n            \"has_traffic\": false\n        }\n        ]\n    }\n\n}"},{"id":"dfb028a4-f56e-4077-85b5-fb4ca3cfd257","name":"DriverUid/passengerUid/path not found (NOT FOUND)","originalRequest":{"method":"GET","header":[],"url":{"raw":"localhost:8000/location/navigation/:driverUid?passengerUid=4","host":["localhost:8000"],"path":["location","navigation",":driverUid"],"query":[{"key":"passengerUid","value":"4","description":"the passenger's UID - from the location microservice"}],"variable":[{"key":"driverUid","value":"3","description":"the driver's UID - from the location microservice"}]}},"code":404,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"NOT FOUND\"\n}"}],"_postman_id":"26433118-1579-4073-892a-e33d40ae861f"}],"id":"978e2051-d87d-4302-8125-258cd7311b69","description":"<p>This microservice is used to handle all location information about users and the map.</p>\n<p>This service supports the following actions:</p>\n<ul>\n<li>PUT /location/user </li>\n<li>DELETE /location/user </li>\n<li>GET /location/:uid </li>\n<li>PATCH /location/:uid</li>\n<li>GET /location/nearbyDriver/:uid?radius=:radius - <strong>TODO</strong></li>\n<li>PUT /location/road</li>\n<li>POST /location/hasRoute </li>\n<li>DELETE /location/route</li>\n<li>GET /location/navigation/:driverUid?passengerUid=:passengerUid - <strong>TODO</strong></li>\n</ul>\n","event":[{"listen":"prerequest","script":{"id":"c0791966-6806-4247-83b2-a2d73a253134","type":"text/javascript","exec":[""]}},{"listen":"test","script":{"id":"68357bda-4de2-4fa0-b79e-5a449f15fc89","type":"text/javascript","exec":[""]}}],"_postman_id":"978e2051-d87d-4302-8125-258cd7311b69"},{"name":"TripInfo Microservice","item":[{"name":"Request Trip","id":"c91f0477-c4cb-46bc-8d47-0c72fb13dc67","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"uid\": String,\n    \"radius\": Integer\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8002/trip/request","description":"<p>Send a request for a trip by sending a request to Location Microservice for a list of drivers WITHIN a given radius around a given user - <strong>TODO</strong></p>\n<h1 id=\"edge-cases\">Edge Cases</h1>\n<ul>\n<li>If a driver requests a trip, include their own uid in the returned uids</li>\n<li>If a driver is exactly radius km away, don't include their uid in the returned list</li>\n<li>If /location/nearbyDriver returns a failing status code then you should return that status code</li>\n</ul>\n<h1 id=\"body-parameters\">Body Parameters</h1>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>ID</th>\n<th>Type</th>\n<th>Descripton</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>uid</td>\n<td>String</td>\n<td>The passenger’s UID (from the location microservice)</td>\n</tr>\n<tr>\n<td>radius</td>\n<td>Integer</td>\n<td>Positive integer that represents the radius in km</td>\n</tr>\n</tbody>\n</table>\n</div><h1 id=\"expected-responses\">Expected Responses</h1>\n<p>For any valid Request, status code should be 200 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"OK\",\n    \"data\": [String, ...]\n}\n\n</code></pre>\n<p>If any parameter is missing, radius is below 0, or the types are incorrect, status code should be 400 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"BAD REQUEST\"\n}\n\n</code></pre>\n<p>If the UID is not in the database, or there are no nearby drivers, status code should be 404 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"NOT FOUND\"\n}\n\n</code></pre>\n<p>Otherwise, the status code should be 500 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"INTERNAL SERVER ERROR\"\n}\n\n</code></pre>\n","urlObject":{"path":["trip","request"],"host":["localhost:8002"],"query":[],"variable":[]}},"response":[{"id":"b69c5960-17cc-48fb-a45b-1c6fcd298ec0","name":"Bad Request (Radius below 0)","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"uid\": String,\n    \"radius\": -4\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8002/trip/request"},"code":400,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"BAD REQUEST\"\n}"},{"id":"93ca56c7-d2c5-49f2-a22e-3a6bd396d6d6","name":"Bad Request (PARAMETER MISSING)","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"uid\": String\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8002/trip/request"},"code":400,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"BAD REQUEST\"\n}"},{"id":"2af28171-15cf-4877-9f3c-91b0de167f32","name":"Bad Request (WRONG TYPES)","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"uid\": 2,\n    \"radius\": \"4\"\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8002/trip/request"},"code":400,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"BAD REQUEST\"\n}"},{"id":"10a92156-dc35-41d9-9e94-c67e914476c2","name":"Successful Response","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"uid\": \"2\",\n    \"radius\": 5\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8002/trip/request"},"code":200,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"OK\",\n    \"data\": [\"1\",\"4\",\"20\",\"6\"]\n}"},{"id":"3e038170-ae06-4757-942a-6b13c4e330b4","name":"UID Not Found or No Nearby Drivers (NOT FOUND)","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"uid\": \"2\",\n    \"radius\": Integer\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8002/trip/request"},"code":404,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"NOT FOUND\"\n}"}],"_postman_id":"c91f0477-c4cb-46bc-8d47-0c72fb13dc67"},{"name":"Confirm Trip","id":"71b89da2-10e2-4900-8ecf-c2a331a9f955","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"driver\": String,\n    \"passenger\": String,\n    \"startTime\": Integer\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8002/trip/confirm","description":"<p>Assuming a trip request has already been made, create &amp; add trip to the database - <strong>TODO</strong></p>\n<h1 id=\"edge-cases\">Edge Cases</h1>\n<ul>\n<li>startTime can be any time in Unix time stamp format</li>\n<li>You can assume driver and passenger UIDs exist in location microservice so you don't need to check</li>\n</ul>\n<h1 id=\"body-parameters\">Body Parameters</h1>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>ID</th>\n<th>Type</th>\n<th>Descripton</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>driver</td>\n<td>String</td>\n<td>Driver's UID (from location microservice)</td>\n</tr>\n<tr>\n<td>passenger</td>\n<td>String</td>\n<td>Passenger's UID (from location microservice)</td>\n</tr>\n<tr>\n<td>startTime</td>\n<td>Integer (Unix time stamp in seconds)</td>\n<td>The time when the trip started</td>\n</tr>\n</tbody>\n</table>\n</div><h1 id=\"expected-responses\">Expected Responses</h1>\n<p>For any valid Request, status code should be 200 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"OK\",\n    \"data\": {\n        \"_id\": {\n            \"$oid\": String\n        }\n    }\n}\n\n</code></pre>\n<p>Where \"$oid\" is the _id created by MongoDB</p>\n<p>If any parameter is missing or the types are incorrect, status code should be 400 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"BAD REQUEST\"\n}\n\n</code></pre>\n<p>Otherwise, the status code should be 500 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"INTERNAL SERVER ERROR\"\n}\n\n</code></pre>\n","urlObject":{"path":["trip","confirm"],"host":["localhost:8002"],"query":[],"variable":[]}},"response":[{"id":"e112a14c-cca7-4cda-bf87-9e57fd9ac404","name":"Bad Request (WRONG TYPE)","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"driver\": 2,\n    \"passenger\": 4,\n    \"startTime\": \"12909841\"\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8002/trip/confirm"},"code":400,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"BAD REQUEST\"\n}"},{"id":"e07d4851-8e64-4b3d-84c7-f4806484f3b9","name":"Bad Request (PARAMETER MISSING)","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"driver\": String,\n    \"passenger\": String\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8002/trip/confirm"},"code":400,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"BAD REQUEST\"\n}"},{"id":"bfab5249-0d0e-489b-bbb5-d7539f314285","name":"Successful Response","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"driver\": \"3\",\n    \"passenger\": \"2\",\n    \"startTime\": 1645917102\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8002/trip/confirm"},"code":200,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"OK\",\n    \"data\": {\n        \"_id\": {\n            \"$oid\": \"507f1f77bcf86cd799439011\"\n        }\n    }\n}"}],"_postman_id":"71b89da2-10e2-4900-8ecf-c2a331a9f955"},{"name":"Update Trip","id":"57ef85a0-8fc1-46f0-81af-c3ee3608d57e","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PATCH","header":[],"body":{"mode":"raw","raw":"{\n    \"distance\": Integer,\n    \"endTime\": Integer,\n    \"timeElapsed\": Integer,\n    \"totalCost\": String\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8002/trip/:_id","description":"<p>Updates a trip by adding extra information - <strong>TODO</strong></p>\n<h1 id=\"edge-cases\">Edge Cases</h1>\n<ul>\n<li>You may assume timeElapsed is correctly calculated i.e. you can assume startTime minus the given endTime equals timeElapsed</li>\n</ul>\n<h1 id=\"body-parameters\">Body Parameters</h1>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>ID</th>\n<th>Type</th>\n<th>Descripton</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>distance</td>\n<td>Integer</td>\n<td>The distance travelled</td>\n</tr>\n<tr>\n<td>endTime</td>\n<td>Integer (Unix time stamp in seconds)</td>\n<td>The time the trip ended</td>\n</tr>\n<tr>\n<td>timeElapsed</td>\n<td>Integer</td>\n<td>The total time the trip took</td>\n</tr>\n<tr>\n<td>totalCost</td>\n<td>String (In the form of a Double)</td>\n<td>The total cost of the trip</td>\n</tr>\n</tbody>\n</table>\n</div><h1 id=\"note\">Note</h1>\n<p>totalCost is a string, because Javascript automatically converts any Float with trailing zeros as a full Integer, which breaks the type constraint</p>\n<h1 id=\"expected-responses\">Expected Responses</h1>\n<p>For any valid Request, status code should be 200 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"OK\"\n}\n\n</code></pre>\n<p>If the trip ID is not in the database, status code should be 404 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"NOT FOUND\"\n}\n\n</code></pre>\n<p>If parameters are missing or if values are of the wrong type or if _id has the wrong format or if the URI has extra arguments, status code should be 400 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"BAD REQUEST\"\n}\n\n</code></pre>\n<p>Otherwise, the status code should be 500 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"INTERNAL SERVER ERROR\"\n}\n\n</code></pre>\n","urlObject":{"path":["trip",":_id"],"host":["localhost:8002"],"query":[],"variable":[{"id":"bf24b725-1edd-4863-aa31-39f47634f9d6","description":{"content":"<p>The trip ID (from the trip microservice)</p>\n","type":"text/plain"},"type":"any","value":"","key":"_id"}]}},"response":[{"id":"8ffefaf3-86ff-4ae6-8a98-6aa2a3c5f10e","name":"Bad Request (Wrong Type)","originalRequest":{"method":"PATCH","header":[],"body":{"mode":"raw","raw":"{\n    \"distance\": \"40\",\n    \"endTime\": Integer,\n    \"timeElapsed\": Integer,\n    \"totalCost\": String\n}","options":{"raw":{"language":"json"}}},"url":{"raw":"localhost:8002/trip/:_id","host":["localhost:8002"],"path":["trip",":_id"],"variable":[{"key":"_id","value":"507f1f77bcf86cd799439011","description":"The trip ID (from the trip microservice)"}]}},"code":400,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"BAD REQUEST\"\n}"},{"id":"ca0c8c02-540e-42a4-b2a1-ead246c497f0","name":"Successful Response","originalRequest":{"method":"PATCH","header":[],"body":{"mode":"raw","raw":"{\n    \"distance\": 3,\n    \"endTime\": 1645919897,\n    \"timeElapsed\": 40,\n    \"totalCost\": \"80.0\"\n}","options":{"raw":{"language":"json"}}},"url":{"raw":"localhost:8002/trip/:_id","host":["localhost:8002"],"path":["trip",":_id"],"variable":[{"key":"_id","value":"507f1f77bcf86cd799439011","description":"The trip ID (from the trip microservice)"}]}},"code":200,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"OK\"\n}"},{"id":"ade55e61-dad7-4229-bc3b-ca4e146fd748","name":"Trip ID Not Found (NOT FOUND)","originalRequest":{"method":"PATCH","header":[],"body":{"mode":"raw","raw":"{\n    \"distance\": Integer,\n    \"endTime\": Integer,\n    \"timeElapsed\": Integer,\n    \"totalCost\": String\n}","options":{"raw":{"language":"json"}}},"url":{"raw":"localhost:8002/trip/:_id","host":["localhost:8002"],"path":["trip",":_id"],"variable":[{"key":"_id","value":"507f1f77bcf86cd799439011","description":"The trip ID (from the trip microservice)"}]}},"code":404,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"NOT FOUND\"\n}"},{"id":"647a57e5-102e-4bda-9b9f-921ee603b3c0","name":"Bad Request (Trip ID MISSING)","originalRequest":{"method":"PATCH","header":[],"body":{"mode":"raw","raw":"{\n    \"distance\": Integer,\n    \"endTime\": Integer,\n    \"timeElapsed\": Integer,\n    \"totalCost\": String\n}","options":{"raw":{"language":"json"}}},"url":"localhost:8002/trip"},"code":400,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"BAD REQUEST\"\n}"}],"_postman_id":"57ef85a0-8fc1-46f0-81af-c3ee3608d57e"},{"name":"Get Passenger Trips","id":"c94392d3-cfac-4010-9aa6-983850c53487","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"localhost:8002/trip/passenger/:uid","description":"<p>Get all the (completed &amp; in-progress) trips that the person was a passenger in. - <strong>TODO</strong></p>\n<h1 id=\"notes\">Notes</h1>\n<ul>\n<li>A completed trip is a trip that also has: distance, totalCost, endTime, timeElapsed attributes</li>\n</ul>\n<h1 id=\"expected-responses\">Expected Responses</h1>\n<p>For any valid Request, status code should be 200 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"OK\",\n    \"data\":{\n        \"trips\":[{\n            \"_id\": String,\n            \"distance\": Integer,\n            \"totalCost\": String,\n            \"startTime\": Integer,\n            \"endTime\": Integer,\n            \"driver\": String,\n            \"timeElapsed\": Integer\n        },\n        ...\n        ]\n    }\n}\n\n</code></pre>\n<p>If UID is not found in the database or if the user with this UID has never been a passenger on a trip, status code should be 404 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"NOT FOUND\"\n}\n\n</code></pre>\n<p>If UID is missing or the URI has extra arguments, the status code should be 400 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"BAD REQUEST\"\n}\n\n</code></pre>\n<p>Otherwise, the status code should be 500 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"INTERNAL SERVER ERROR\"\n}\n\n</code></pre>\n","urlObject":{"path":["trip","passenger",":uid"],"host":["localhost:8002"],"query":[],"variable":[{"description":{"content":"<p>Passenger's UID (from location microservice)</p>\n","type":"text/plain"},"type":"any","value":"","key":"uid"}]}},"response":[{"id":"eb30b01c-76a9-43c9-8348-a2e60c85caa1","name":"Uid Not Found (NOT FOUND)","originalRequest":{"method":"GET","header":[],"url":{"raw":"localhost:8002/trip/passenger/:uid","host":["localhost:8002"],"path":["trip","passenger",":uid"],"variable":[{"key":"uid","value":"7","description":"Passenger's UID (from location microservice)"}]}},"code":404,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"NOT FOUND\"\n}"},{"id":"44ddb006-b058-4fba-bc2d-42e37712d624","name":"Bad Request (Uid Missing)","originalRequest":{"method":"GET","header":[],"url":"localhost:8002/trip/passenger"},"code":400,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"BAD REQUEST\"\n}"},{"id":"a7306c57-1b0a-4254-a4af-2e0cd1808571","name":"Successful Response","originalRequest":{"method":"GET","header":[],"url":{"raw":"localhost:8002/trip/passenger/:uid","host":["localhost:8002"],"path":["trip","passenger",":uid"],"variable":[{"key":"uid","value":"3","description":"Passenger's UID (from location microservice)"}]}},"code":200,"_postman_previewlanguage":"json","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"OK\",\n    \"data\": {\n        \"trips\": [\n            {\n                \"driver\": \"4\",\n                \"_id\": \"507f1f77bcf86cd799439011\",\n                \"distance\": 40,\n                \"totalCost\": \"80.3\",\n                \"startTime\": 1645919897,\n                \"endTime\": 1645919900,\n                \"timeElapsed\": 30\n            },\n            {\n                \"driver\": \"8\",\n                \"_id\": \"507f1f77bcf86cd799439012\",\n                \"startTime\": 164592000\n            }\n        ]\n    }\n}"}],"_postman_id":"c94392d3-cfac-4010-9aa6-983850c53487"},{"name":"Get Driver Trips","id":"311ae810-d61a-488c-9ecb-b89f2e7060b7","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"localhost:8002/trip/driver/:uid","description":"<p>Get all the (completed &amp; in-progress) trips that the person was a Driver in. - <strong>TODO</strong></p>\n<h1 id=\"notes\">Notes</h1>\n<ul>\n<li>A completed trip is a trip that has: distance, totalCost, endTime, timeElapsed attributes</li>\n</ul>\n<h1 id=\"expected-responses\">Expected Responses</h1>\n<p>For any valid Request, status code should be 200 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"OK\",\n    \"data\":{\n        \"trips\":[{\n            \"_id\": String,\n            \"distance\": Integer,\n            \"totalCost\": String,\n            \"startTime\": Integer,\n            \"endTime\": Integer,\n            \"passenger\": String,\n            \"timeElapsed\": Integer\n        },\n        ...\n        ]\n    }\n}\n\n</code></pre>\n<p>If UID is not found in the database or if the user with this UID has never been a driver on a trip, status code should be 404 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"NOT FOUND\"\n}\n\n</code></pre>\n<p>If UID is missing or the URI has extra arguments, the status code should be 400 and the resposne body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"BAD REQUEST\"\n}\n\n</code></pre>\n<p>Otherwise, the status code should be 500 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"INTERNAL SERVER ERROR\"\n}\n\n</code></pre>\n","urlObject":{"path":["trip","driver",":uid"],"host":["localhost:8002"],"query":[],"variable":[{"description":{"content":"<p>Driver's UID (from location microservice)</p>\n","type":"text/plain"},"type":"any","value":"","key":"uid"}]}},"response":[{"id":"c9f5c9af-a837-470e-9234-2dc17d949677","name":"Uid Not Found (NOT FOUND)","originalRequest":{"method":"GET","header":[],"url":{"raw":"localhost:8002/trip/driver/:uid","host":["localhost:8002"],"path":["trip","driver",":uid"],"variable":[{"key":"uid","value":"7","description":"Driver's UID (from location microservice)"}]}},"code":404,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"NOT FOUND\"\n}"},{"id":"63664ea2-ffda-4476-8938-78296e859ea5","name":"Bad Request (Uid Missing)","originalRequest":{"method":"GET","header":[],"url":"localhost:8002/trip/driver"},"code":400,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"BAD REQUEST\"\n}"},{"id":"806e60ab-8ad6-4895-b54b-98e6298838cc","name":"Successful Response","originalRequest":{"method":"GET","header":[],"url":{"raw":"localhost:8002/trip/driver/:uid","host":["localhost:8002"],"path":["trip","driver",":uid"],"variable":[{"key":"uid","value":"3","description":"Driver's UID (from location microservice)"}]}},"code":200,"_postman_previewlanguage":"json","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"OK\",\n    \"data\": {\n        \"trips\": [\n            {\n                \"passenger\": \"7\",\n                \"_id\": \"507f1f77bcf86cd799439011\",\n                \"distance\": 60,\n                \"totalCost\": \"83.3\",\n                \"startTime\": 1645919900,\n                \"endTime\": 1645920000,\n                \"timeElapsed\": 60\n            },\n            {\n                \"passenger\": \"9\",\n                \"_id\": \"507f1f77bcf86cd799439011\",\n                \"startTime\": 164592300\n            }\n        ]\n    }\n}"}],"_postman_id":"311ae810-d61a-488c-9ecb-b89f2e7060b7"},{"name":"Get Driver Time","id":"d1622f9b-20c6-4c2c-a525-3c2e2b14c88c","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"localhost:8002/trip/driverTime/:_id","description":"<p>Given the Trip ID of a finished or unfinished trip in the database, get the time it will take for the driver of the trip to arrive to the passenger of the trip. This time is obtained from /location/navigation - <strong>TODO</strong></p>\n<h1 id=\"edge-cases\">Edge Cases</h1>\n<ul>\n<li>If /location/navigation returns a failing status code then you should return that status code</li>\n<li>The time should be the same regardless of whether the trip is finished or unfinished</li>\n</ul>\n<h1 id=\"expected-responses\">Expected Responses</h1>\n<p>For any valid Request, status code should be 200 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"OK\",\n    \"data\": {\n        \"arrival_time\": Integer\n    }\n}\n\n</code></pre>\n<p>If Trip ID is missing or if _id has the wrong format or if the URI has extra arguments, status code should be 400 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"BAD REQUEST\"\n}\n\n</code></pre>\n<p>If Trip ID is not in the database, the status code should be 404 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"NOT FOUND\"\n} \n\n</code></pre>\n<p>Otherwise, the status code should be 500 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"INTERNAL SERVER ERROR\"\n}\n\n</code></pre>\n","urlObject":{"path":["trip","driverTime",":_id"],"host":["localhost:8002"],"query":[],"variable":[{"id":"6b8145c7-123d-4cc6-9937-e560b129e542","description":{"content":"<p>The trip's ID (from the trip microservice)</p>\n","type":"text/plain"},"type":"any","value":"","key":"_id"}]}},"response":[{"id":"c9d1ba7b-9c49-42b9-a771-fe1866053f50","name":"Bad Request (Trip ID Missing)","originalRequest":{"method":"GET","header":[],"url":"localhost:8002/trip/driverTime"},"code":400,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"BAD REQUEST\"\n}"},{"id":"6afe7ff0-84c8-41f5-a425-bea8605bbc13","name":"Trip ID Not Found (NOT FOUND)","originalRequest":{"method":"GET","header":[],"url":{"raw":"localhost:8002/trip/driverTime/:_id","host":["localhost:8002"],"path":["trip","driverTime",":_id"],"variable":[{"key":"_id","value":"507f1f77bcf86cd799439011","description":"The trip's ID (from the trip microservice)"}]}},"code":404,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"NOT FOUND\"\n}"},{"id":"3c8e05b4-24b3-4b3b-b93d-087680d57ea2","name":"Successful Response","originalRequest":{"method":"GET","header":[],"url":{"raw":"localhost:8002/trip/driverTime/:_id","host":["localhost:8002"],"path":["trip","driverTime",":_id"],"variable":[{"key":"_id","value":"507f1f77bcf86cd799439011","description":"The trip's ID (from the trip microservice)"}]}},"code":200,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"OK\",\n    \"data\": {\n        \"arrival_time\" 50\n    }\n}"}],"_postman_id":"d1622f9b-20c6-4c2c-a525-3c2e2b14c88c"}],"id":"bb75dcca-c461-4c2d-afa1-1298f0fa227f","description":"<p>This microservice is used to handle all the Trip Information APIs</p>\n<p>The service supports the following actions:</p>\n<ul>\n<li>POST /trip/request - <strong>TODO</strong></li>\n<li>POST /trip/confirm - <strong>TODO</strong></li>\n<li>PATCH /trip/:_id - <strong>TODO</strong></li>\n<li>GET /trip/passenger/:uid - <strong>TODO</strong></li>\n<li>GET /trip/driver/:uid - <strong>TODO</strong></li>\n<li>GET /trip/driverTime/:_id - <strong>TODO</strong></li>\n</ul>\n","event":[{"listen":"prerequest","script":{"id":"d9fed13b-6ed0-4e8c-b1f0-2d65e576d1ec","type":"text/javascript","exec":[""]}},{"listen":"test","script":{"id":"7c962c58-eabc-4d2c-8212-f50155e1b3b2","type":"text/javascript","exec":[""]}}],"_postman_id":"bb75dcca-c461-4c2d-afa1-1298f0fa227f"},{"name":"User Microservice","item":[{"name":"Get User Information","id":"63475971-1ff3-4cd0-9641-f02123ae2d1d","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"localhost:8001/user/:uid","description":"<p>Get user’s basic information</p>\n<h1 id=\"expected-responses\">Expected Responses</h1>\n<p>For any valid Request, status code should be 200 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"OK\",\n    \"data\": {\n        \"name\": String,\n        \"email\": String,\n        \"rides\": Integer,\n        \"isDriver\": Boolean\n    }\n}\n</code></pre>\n<p>If UID is missing, status code should be 400 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"BAD REQUEST\"\n}\n</code></pre>\n<p>If UID is not in the database, the status code should be 404 and the response body should be </p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"NOT FOUND\"\n} \n</code></pre>\n<p>Otherwise, the status code should be 500 and the response body should be </p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"INTERNAL SERVER ERROR\"\n}\n</code></pre>\n","urlObject":{"path":["user",":uid"],"host":["localhost:8001"],"query":[],"variable":[{"description":{"content":"<p>The user's UID (from the user/location microservice)</p>\n","type":"text/plain"},"type":"any","value":"","key":"uid"}]}},"response":[{"id":"bd585ca2-24b3-4566-be53-09fc9e0da7e5","name":"Bad Request (UID MISSING)","originalRequest":{"method":"GET","header":[],"url":"localhost:8001/user"},"code":400,"_postman_previewlanguage":"plain","header":[{"key":"Date","value":"Sat, 26 Feb 2022 20:32:12 GMT"},{"key":"Access-control-allow-origin","value":"*"},{"key":"Content-length","value":"32"}],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"BAD REQUEST\"\n}"},{"id":"7fbca351-6583-4840-ad50-fba93a14c941","name":"Successful Response","originalRequest":{"method":"GET","header":[],"url":{"raw":"localhost:8001/user/:uid","host":["localhost:8001"],"path":["user",":uid"],"variable":[{"key":"uid","value":"1","description":"The user's UID (from the user/location microservice)"}]}},"code":200,"_postman_previewlanguage":"plain","header":[{"key":"Date","value":"Sat, 26 Feb 2022 20:28:57 GMT"},{"key":"Access-control-allow-origin","value":"*"},{"key":"Content-length","value":"97"}],"cookie":[],"responseTime":null,"body":"{\"data\":{\"name\":\"TestName354\",\"isDriver\":false,\"rides\":3,\"email\":\"test@gmail.com\"},\"status\":\"OK\"}"},{"id":"fd57559c-bc3a-4989-842b-58c8efc14f1b","name":"UID Not Found","originalRequest":{"method":"GET","header":[],"url":{"raw":"localhost:8001/user/:uid","host":["localhost:8001"],"path":["user",":uid"],"variable":[{"key":"uid","value":"20","description":"The user's UID (from the user/location microservice)"}]}},"code":404,"_postman_previewlanguage":"plain","header":[{"key":"Date","value":"Sat, 26 Feb 2022 20:28:57 GMT"},{"key":"Access-control-allow-origin","value":"*"},{"key":"Content-length","value":"97"}],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"NOT FOUND\"\n}"}],"_postman_id":"63475971-1ff3-4cd0-9641-f02123ae2d1d"},{"name":"Register User","id":"ffb06d38-a3f0-46b8-a68b-4fe771c8207a","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"name\": String,\n    \"email\": String,\n    \"password\": String\n}"},"url":"localhost:8001/user/register","description":"<p>Register a user into the system. - <strong>TODO</strong></p>\n<h1 id=\"edge-cases\">Edge Cases</h1>\n<ul>\n<li>You may assume the given email will be in the form of an email address so you don't have to verify the email format</li>\n<li>The password can contain any character and can be however many characters long</li>\n</ul>\n<h1 id=\"body-parameters\">Body Parameters</h1>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>ID</th>\n<th>Type</th>\n<th>Description</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>name</td>\n<td>String</td>\n<td>The user's name</td>\n</tr>\n<tr>\n<td>email</td>\n<td>String</td>\n<td>The user's email</td>\n</tr>\n<tr>\n<td>password</td>\n<td>String</td>\n<td>The user's password</td>\n</tr>\n</tbody>\n</table>\n</div><h1 id=\"expected-responses\">Expected Responses</h1>\n<p>For any valid Request, status code should be 200 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"OK\",\n    \"uid\": Integer\n}\n\n</code></pre>\n<p>If any parameter is missing or if the value is of the wrong type, status code should be 400 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"BAD REQUEST\"\n}\n\n</code></pre>\n<p>If the email already exists in the database, status code should be 409 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"CONFLICT\"\n}\n\n</code></pre>\n<p>Otherwise, if there are any other issues, the status code should be 500 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"INTERNAL SERVER ERROR\"\n}\n\n</code></pre>\n","urlObject":{"path":["user","register"],"host":["localhost:8001"],"query":[],"variable":[]}},"response":[{"id":"59a0e2f9-839b-44a0-92e7-fb4a4782bbfa","name":"Bad Request (MISSING PARAMETERS)","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"name\": \"Foo\",\n}"},"url":"localhost:8001/user/register"},"code":400,"_postman_previewlanguage":"plain","header":[{"key":"Date","value":"Sat, 26 Feb 2022 20:46:53 GMT"},{"key":"Access-control-allow-origin","value":"*"},{"key":"Content-length","value":"34"}],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"BAD REQUEST\"\n}"},{"id":"2fc7089e-2b24-41d1-8026-6905e0b4c0cb","name":"Successful Response","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"name\": \"Foo Bar\",\n    \"email\": \"Foo@gmail.com\",\n    \"password\": \"Fooooooo\"\n}"},"url":"localhost:8001/user/register"},"status":"OK","code":200,"_postman_previewlanguage":"plain","header":[{"key":"Date","value":"Sat, 26 Feb 2022 20:46:53 GMT"},{"key":"Access-control-allow-origin","value":"*"},{"key":"Content-length","value":"34"}],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"OK\",\n    \"uid\": \"1\"\n}"},{"id":"41b12d61-370f-49b2-a1a4-4274afacfbd7","name":"Email Already Exists","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"name\": \"Foo Bar\",\n    \"email\": \"Foo@gmail.com\",\n    \"password\": \"Foooooo\"\n}"},"url":"localhost:8001/user/register"},"status":"Conflict","code":409,"_postman_previewlanguage":"plain","header":[{"key":"Date","value":"Sat, 26 Feb 2022 20:46:53 GMT"},{"key":"Access-control-allow-origin","value":"*"},{"key":"Content-length","value":"34"}],"cookie":[],"responseTime":null,"body":"{\"status\":\"CONFLICT\"}"}],"_postman_id":"ffb06d38-a3f0-46b8-a68b-4fe771c8207a"},{"name":"Login User","id":"deac5fd4-cf10-456f-b583-e28917b19f48","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"email\": String,\n    \"password\": String\n}"},"url":"localhost:8001/user/login","description":"<p>Login a user into the system (meaning return 200) if the given email and password match the email and password of a user already registered in the database - <strong>TODO</strong></p>\n<h1 id=\"body-parameters\">Body Parameters</h1>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>ID</th>\n<th>Type</th>\n<th>Description</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>email</td>\n<td>String</td>\n<td>The user's email</td>\n</tr>\n<tr>\n<td>password</td>\n<td>String</td>\n<td>The user's password</td>\n</tr>\n</tbody>\n</table>\n</div><h1 id=\"expected-responses\">Expected Responses</h1>\n<p>For any valid Request, status code should be 200 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"OK\",\n    \"uid\": Integer\n}\n\n</code></pre>\n<p>If any parameter is missing, or if the values are of the wrong type, status code should be 400 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"BAD REQUEST\"\n}\n\n</code></pre>\n<p>If the email is not found in the database, status code should be 404 and the response body should be:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"NOT FOUND\"\n}\n\n</code></pre>\n<p>If the email exists and the password doesn't match, status code should be 401 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"UNAUTHORIZED\"\n}\n\n</code></pre>\n<p>Otherwise, the status code should be 500 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"INTERNAL SERVER ERROR\"\n}\n\n</code></pre>\n","urlObject":{"path":["user","login"],"host":["localhost:8001"],"query":[],"variable":[]}},"response":[{"id":"11f61bf4-f999-4b2b-b459-c917834e9b67","name":"Wrong Password","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"email\": \"ritvik@gmail.com\",\n    \"password\": \"String\"\n}"},"url":"localhost:8001/user/login"},"status":"undefined","code":401,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"UNAUTHORIZED\"\n}"},{"id":"bee2934d-708b-4806-b866-b14f837176a5","name":"User Doesn't exist","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"email\": \"Foo@gmail.com\",\n    \"password\": \"Foooooo\"\n}"},"url":"localhost:8001/user/login"},"code":404,"_postman_previewlanguage":"plain","header":[{"key":"Date","value":"Sat, 26 Feb 2022 20:46:53 GMT"},{"key":"Access-control-allow-origin","value":"*"},{"key":"Content-length","value":"34"}],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"NOT FOUND\"\n}"},{"id":"622b7311-ca08-40af-bbc7-c55bc3b8cf7e","name":"Successful Response","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"email\": \"Foo@gmail.com\",\n    \"password\": \"Fooooooo\"\n}"},"url":"localhost:8001/user/login"},"status":"OK","code":200,"_postman_previewlanguage":"plain","header":[{"key":"Date","value":"Sat, 26 Feb 2022 20:46:53 GMT"},{"key":"Access-control-allow-origin","value":"*"},{"key":"Content-length","value":"34"}],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"OK\",\n    \"uid\": 1\n}"},{"id":"499b3b44-15a7-4fd5-85ad-43efa462e2bf","name":"Bad Request (MISSING PARAMETERS)","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\n    \"name\": \"Foo\",\n}"},"url":"localhost:8001/user/login"},"code":400,"_postman_previewlanguage":"plain","header":[{"key":"Date","value":"Sat, 26 Feb 2022 20:46:53 GMT"},{"key":"Access-control-allow-origin","value":"*"},{"key":"Content-length","value":"34"}],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"BAD REQUEST\"\n}"}],"_postman_id":"deac5fd4-cf10-456f-b583-e28917b19f48"},{"name":"Edit User information","id":"441bf856-a074-448e-be39-2cb66ce90928","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PATCH","header":[],"body":{"mode":"raw","raw":"{\n    \"email\": String,\n    \"password\": String,\n    \"rides\": Integer,\n    \"isDriver\": Boolean\n}"},"url":"localhost:8001/user/:uid","description":"<p>Editing part of user’s information</p>\n<h1 id=\"edge-cases\">Edge Cases</h1>\n<ul>\n<li>At least one of the body parameters need to appear, the body cannot be empty</li>\n</ul>\n<h1 id=\"body-parameters\">Body Parameters</h1>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>ID</th>\n<th>Type</th>\n<th>Descripton</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>email</td>\n<td>String</td>\n<td>The new email (Optional)</td>\n</tr>\n<tr>\n<td>password</td>\n<td>String</td>\n<td>The new password (Optional)</td>\n</tr>\n<tr>\n<td>rides</td>\n<td>Integer</td>\n<td>The new ride count (Optional)</td>\n</tr>\n<tr>\n<td>isDriver</td>\n<td>Boolean</td>\n<td>Whether the user is a driver now (Optional)</td>\n</tr>\n</tbody>\n</table>\n</div><h1 id=\"expected-responses\">Expected Responses</h1>\n<p>For any valid Request, status code should be 200 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"OK\"\n}\n</code></pre>\n<p>If the UID is not in the database, status code should be 404 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"NOT FOUND\"\n}\n</code></pre>\n<p>If all body parameters are missing or UID is missing, status code should be 400 and the response body should be</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"BAD REQUEST\"\n}\n</code></pre>\n<p>Otherwise, the status code should be 500 and the response body should be </p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"status\": \"INTERNAL SERVER ERROR\"\n}\n</code></pre>\n","urlObject":{"path":["user",":uid"],"host":["localhost:8001"],"query":[],"variable":[{"id":"3e2fbe25-7ba8-4389-b50a-352b4756a1e4","description":{"content":"<p>The user's UID (from user/location microservice)</p>\n","type":"text/plain"},"type":"any","value":"","key":"uid"}]}},"response":[{"id":"1ef75729-6b46-4c3c-95f2-6543a2547a10","name":"Bad Request (body parameters missing)","originalRequest":{"method":"PATCH","header":[],"body":{"mode":"raw","raw":""},"url":{"raw":"localhost:8001/user/:uid","host":["localhost:8001"],"path":["user",":uid"],"variable":[{"key":"uid","value":"3","description":"The user's UID (from user/location microservice)"}]}},"code":400,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"BAD REQUEST\"\n}"},{"id":"05ce7748-960e-42f7-a90b-763a12a1a874","name":"UID Not Found","originalRequest":{"method":"PATCH","header":[],"body":{"mode":"raw","raw":"{\n    \"email\": String,\n    \"password\": String,\n    \"rides\": Integer,\n    \"isDriver\": Boolean\n}"},"url":{"raw":"localhost:8001/user/:uid","host":["localhost:8001"],"path":["user",":uid"],"variable":[{"key":"uid","value":"4","description":"The user's UID (from user/location microservice)"}]}},"code":404,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"NOT FOUND\"\n}"},{"id":"99a21888-51e1-42eb-b936-13d060cb5dcd","name":"Bad Request (Missing Uid)","originalRequest":{"method":"PATCH","header":[],"body":{"mode":"raw","raw":"{\n    \"email\": String,\n    \"password\": String,\n    \"rides\": Integer,\n    \"isDriver\": Boolean\n}"},"url":"localhost:8001/user"},"code":400,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"BAD REQUEST\"\n}"},{"id":"9729e076-894a-4354-adfd-2cbf8c6103bd","name":"Successful Response (all attributes)","originalRequest":{"method":"PATCH","header":[{"key":"Content-Type","name":"Content-Type","value":"application/json","type":"text","disabled":true}],"body":{"mode":"raw","raw":"{\n    \"email\": \"New Email\",\n    \"password\": \"New Password\",\n    \"rides\": 3,\n    \"isDriver\": false\n}","options":{"raw":{"language":"json"}}},"url":{"raw":"localhost:8001/user/:uid","host":["localhost:8001"],"path":["user",":uid"],"variable":[{"key":"uid","value":"3","description":"The user's UID (from user/location microservice)"}]}},"code":200,"_postman_previewlanguage":"Text","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"OK\"\n}"},{"id":"df558763-17c8-4a83-8acf-fcb9250cb11a","name":"Successful Response","originalRequest":{"method":"PATCH","header":[],"body":{"mode":"raw","raw":"{\n    \"email\": \"New Email\",\n    \"password\": \"New Password\"\n}"},"url":{"raw":"localhost:8001/user/:uid","host":["localhost:8001"],"path":["user",":uid"],"variable":[{"key":"uid","value":"2","description":"The user's UID (from user/location microservice)"}]}},"code":200,"_postman_previewlanguage":"json","header":[],"cookie":[],"responseTime":null,"body":"{\n    \"status\": \"OK\"\n}"}],"_postman_id":"441bf856-a074-448e-be39-2cb66ce90928"}],"id":"9b4c5352-a4f3-4983-ba69-2a12f59c2481","description":"<p>This microservice is used to handle all the User APIs</p>\n<p>The service supports the following actions:</p>\n<ul>\n<li>GET /user/:uid</li>\n<li>POST /user/register - <strong>TODO</strong></li>\n<li>POST /user/login - <strong>TODO</strong></li>\n<li>PATCH /user/:uid</li>\n</ul>\n","event":[{"listen":"prerequest","script":{"id":"f319223b-f75c-4145-adea-81ed2866fda9","type":"text/javascript","exec":[""]}},{"listen":"test","script":{"id":"0bd265f0-dccc-459e-8c52-e7d64d04b13f","type":"text/javascript","exec":[""]}}],"_postman_id":"9b4c5352-a4f3-4983-ba69-2a12f59c2481"}],"event":[{"listen":"prerequest","script":{"id":"b32498c0-b398-4cd9-8fa9-8fdf120ff33e","type":"text/javascript","exec":[""]}},{"listen":"test","script":{"id":"d025e99a-df10-4bfc-8c42-21159277f52b","type":"text/javascript","exec":[""]}}],"variable":[{"key":"locationURL","value":"localhost:8000"},{"key":"userURL","value":"localhost:8001"},{"key":"tripURL","value":"localhost:8002"},{"key":"gatewayURL","value":"localhost:8004"}]}