{"info":{"_postman_id":"87c81464-740a-4f24-88ab-d1f90a2825a2","name":"LumaHealth","description":"<html><head></head><body><h1 id=\"api-for-scheduling-doctor-appointments\">API for scheduling doctor appointments</h1>\n<ul>\n<li>Implemented the following functionality as an importable library:</li>\n</ul>\n<ul>\n<li> Find a doctor's working hours</li>\n<li> Book an doctor opening</li>\n<li> Create and update the list of doctor's working hours</li>\n</ul>\n</body></html>","schema":"https://schema.getpostman.com/json/collection/v2.0.0/collection.json","toc":[{"content":"API for scheduling doctor appointments","slug":"api-for-scheduling-doctor-appointments"}],"owner":"1318242","collectionId":"87c81464-740a-4f24-88ab-d1f90a2825a2","publishedId":"S11NMGhM","public":true,"customColor":{"top-bar":"FFFFFF","right-sidebar":"303030","highlight":"EF5B25"},"publishDate":"2019-03-05T12:22:35.000Z"},"item":[{"name":"Doctor","item":[{"name":"Create doctor","id":"a410f8d6-1ffe-4bc1-ba86-4b9de0f13fb8","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"Content-Type","name":"Content-Type","value":"application/json","type":"text"}],"body":{"mode":"raw","raw":"{\n\t\"name\": \"Doc Strange\",\n    \"workingHours\": [\n        {\n            \"date\": \"2019-03-04\",\n            \"startTime\": 15700,\n            \"endTime\": 70000\n        },\n        {\n            \"date\": \"2019-03-05\",\n            \"startTime\": 15700,\n            \"endTime\": 70000\n        },\n        {\n            \"date\": \"2019-03-06\",\n            \"startTime\": 15700,\n            \"endTime\": 70000\n        },\n        {\n            \"date\": \"2019-03-07\",\n            \"startTime\": 15700,\n            \"endTime\": 70000\n        }\n    ]\n}"},"url":"http://localhost:3000/doctors","description":"<p>Create a doctor with his/her working hours</p>\n<p>Request Body Parameters:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code>{\n    \"name\": String,\n    \"workingHours\": [\n        {\n            \"date\": String(YYYY-MM-DD),\n            \"startTime\": Number(24hr time converted to seconds),\n            \"endTime\": Number(24hr time converted to seconds)\n        }\n    ]\n}\n</code></pre>","urlObject":{"protocol":"http","port":"3000","path":["doctors"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"a410f8d6-1ffe-4bc1-ba86-4b9de0f13fb8"},{"name":"Get Doctor","id":"ee1644a7-0421-4381-a64c-8e614d034b2c","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"http://localhost:3000/doctors/5c7e2ceb48c80753d8d9da07","description":"<p>Get information about a particular doctor</p>\n<p>Path Parameter: </p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code>docId: String(ObjectId from MongoDB)\n</code></pre>","urlObject":{"protocol":"http","port":"3000","path":["doctors","5c7e2ceb48c80753d8d9da07"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"ee1644a7-0421-4381-a64c-8e614d034b2c"},{"name":"List all doctors","id":"bfa14b83-a17a-4311-8836-9251adf35c00","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"http://localhost:3000/doctors","description":"<p>Get a list of all doctors with their working hours</p>\n","urlObject":{"protocol":"http","port":"3000","path":["doctors"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"bfa14b83-a17a-4311-8836-9251adf35c00"},{"name":"Update Doctor","id":"8d2faba9-26af-4d9b-8137-6a5a314b96df","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PATCH","header":[{"key":"Content-Type","name":"Content-Type","value":"application/json","type":"text"}],"body":{"mode":"raw","raw":"{\n\t\"name\": \"Doc Strange\",\n    \"workingHours\": [\n        {\n            \"date\": \"2019-03-02\",\n            \"startTime\": 15900,\n            \"endTime\": 70000\n        },\n        {\n            \"date\": \"2019-03-03\",\n            \"startTime\": 15900,\n            \"endTime\": 70000\n        },\n        {\n            \"date\": \"2019-03-04\",\n            \"startTime\": 15900,\n            \"endTime\": 70000\n        },\n        {\n            \"date\": \"2019-03-05\",\n            \"startTime\": 15900,\n            \"endTime\": 70000\n        }\n    ]\n}"},"url":"http://localhost:3000/doctors/5c7e2ceb48c80753d8d9da07","description":"<p>Update information about a particular doctor</p>\n<p>Path Parameter:</p>\n<p>docId: String (ObjectId from Doctor collection in MongoDB) \nRequest Body Parameters:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code>{\n    \"name\": String,\n    \"workingHours\": [\n        {\n            \"date\": String(YYYY-MM-DD),\n            \"startTime\": Number(24hr time converted to seconds),\n            \"endTime\": Number(24hr time converted to seconds)\n        }\n    ]\n}\n</code></pre>","urlObject":{"protocol":"http","port":"3000","path":["doctors","5c7e2ceb48c80753d8d9da07"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"8d2faba9-26af-4d9b-8137-6a5a314b96df"},{"name":"Delete Doctor","id":"6f95fcc7-2241-4984-8168-9e9feae89681","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"DELETE","header":[],"body":{"mode":"raw","raw":""},"url":"http://localhost:3000/doctors/5c7e2ceb48c80753d8d9da07","description":"<p>Delete a particular doctor completely from the database</p>\n<p>Path Parameter:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code>docId: String (ObjectId from Doctor collection in MongoDB)\n</code></pre>","urlObject":{"protocol":"http","port":"3000","path":["doctors","5c7e2ceb48c80753d8d9da07"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"6f95fcc7-2241-4984-8168-9e9feae89681"}],"id":"310769ef-9420-44a7-936d-58fce11ab516","description":"<h1 id=\"doctor-apis\">Doctor API's</h1>\n<ul>\n<li>Get list of all doctors in the system</li>\n<li>Add a doctor to the system</li>\n<li>Get individual doctor working / available hours status</li>\n<li>Update hours for the doctor</li>\n<li>Delete or Remove a doctor from the system</li>\n</ul>\n","event":[{"listen":"prerequest","script":{"id":"d6c333aa-5e2d-4e55-886c-5dfc7a6a74f7","type":"text/javascript","exec":[""]}},{"listen":"test","script":{"id":"a11f949e-2bc5-436d-9585-52b742b30eeb","type":"text/javascript","exec":[""]}}],"_postman_id":"310769ef-9420-44a7-936d-58fce11ab516"},{"name":"Patient","item":[{"name":"Create patient","id":"c0bcdf8a-b5b3-4c04-b47f-c0db1e9d6181","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"Content-Type","name":"Content-Type","value":"application/json","type":"text"}],"body":{"mode":"raw","raw":"{\n\t\"name\": \"Amancio Ortega\"\n}"},"url":"http://localhost:3000/patients","description":"<p>Create a patient</p>\n<p>Request Body Parameters:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code>{\n    \"name\": String\n}\n</code></pre>","urlObject":{"protocol":"http","port":"3000","path":["patients"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"c0bcdf8a-b5b3-4c04-b47f-c0db1e9d6181"},{"name":"List all patients","id":"16479bb7-4846-4e03-b15e-9b36e687db62","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"http://localhost:3000/patients","description":"<p>Get a list of all patients</p>\n","urlObject":{"protocol":"http","port":"3000","path":["patients"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"16479bb7-4846-4e03-b15e-9b36e687db62"},{"name":"Get Patient","id":"46f5d8a0-dfba-41b5-ab79-567b86b82cad","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"http://localhost:3000/patients/5c7e2d8d48c80753d8d9da3b","description":"<p>Get information about a particular patient</p>\n<p>Path Parameter:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code>patientId: String (ObjectId from Patient collection in MongoDB)\n</code></pre>","urlObject":{"protocol":"http","port":"3000","path":["patients","5c7e2d8d48c80753d8d9da3b"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"46f5d8a0-dfba-41b5-ab79-567b86b82cad"},{"name":"Update Patient","id":"74555699-47a4-4f87-b53c-12c018db2476","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PATCH","header":[{"key":"Content-Type","name":"Content-Type","type":"text","value":"application/json"}],"body":{"mode":"raw","raw":"{\n\t\"name\": \"Jeff Bezos\"\n}"},"url":"http://localhost:3000/patients/5c7e2d8d48c80753d8d9da3b","description":"<p>Update information about a particular patient</p>\n<p>Path Parameter:</p>\n<p>patientId: String (ObjectId from patient collection in mongoDB)</p>\n<p>Request Body:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code>{\n    \"name\": String\n}\n</code></pre>","urlObject":{"protocol":"http","port":"3000","path":["patients","5c7e2d8d48c80753d8d9da3b"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"74555699-47a4-4f87-b53c-12c018db2476"},{"name":"Delete Patient","id":"f3a1c0e4-35cc-4134-81f2-29c93f9e5a32","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"DELETE","header":[],"body":{"mode":"raw","raw":""},"url":"http://localhost:3000/patients/5c7e2d8d48c80753d8d9da3b","description":"<p>Delete a particular patient completely from the database</p>\n<p>Path Parameter:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code>patientId: String (ObjectId from patient collection in MongoDB)\n</code></pre>","urlObject":{"protocol":"http","port":"3000","path":["patients","5c7e2d8d48c80753d8d9da3b"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"f3a1c0e4-35cc-4134-81f2-29c93f9e5a32"}],"id":"22cc264f-d3e9-4c3a-9c5d-a48e8b82a199","description":"<h1 id=\"patient-apis\">Patient API's</h1>\n<ul>\n<li>Get list of all patients in the system</li>\n<li>Add a patient to the system</li>\n<li>Get individual patient scheduled hours status</li>\n<li>Update name for the patient</li>\n<li>Delete or Remove a patient from the system</li>\n</ul>\n","event":[{"listen":"prerequest","script":{"id":"1594bb27-c40c-4cb9-93ca-86f6edcc43b3","type":"text/javascript","exec":[""]}},{"listen":"test","script":{"id":"44fdc51e-7e6f-46e2-aa3c-5c05c472f49b","type":"text/javascript","exec":[""]}}],"_postman_id":"22cc264f-d3e9-4c3a-9c5d-a48e8b82a199"},{"name":"Appointment","item":[{"name":"Create Appointment","id":"2a0e560e-54f1-45c4-90d9-655eacc47707","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"Content-Type","name":"Content-Type","value":"application/json","type":"text"}],"body":{"mode":"raw","raw":"{\n\t\"docId\": \"5c7e2ceb48c80753d8d9da07\",\n\t\"patientId\": \"5c7e2d8d48c80753d8d9da3b\",\n\t\"date\": \"2019-03-05\",\n\t\"startTime\": 15900,\n\t\"endTime\": 65000\n}"},"url":"http://localhost:3000/appointments","description":"<p>Create an appointment</p>\n<p>Request Body:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code>{\n    \"docId\": String (ObjectId from doctor collection in MongoDB),\n    \"patientId\": String (ObjectId from patient collection in MongoDB),\n    \"date\": String (YYYY-MM-DD),\n    \"startTime\": Number (24Hr time converted to seconds),\n    \"endTime\": Number (24Hr time converted to seconds)\n}\n</code></pre>","urlObject":{"protocol":"http","port":"3000","path":["appointments"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"2a0e560e-54f1-45c4-90d9-655eacc47707"},{"name":"List appointments by DocId","id":"609e2877-831f-4156-a9a4-8aff13fda4e0","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"http://localhost:3000/appointments?docId=5c7e2ceb48c80753d8d9da07","description":"<p>Get all appointments for a particular doctor</p>\n<p>Query Parameter:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code>docId: String (ObjectId from Doctor collection in mongoDb)\n</code></pre>","urlObject":{"protocol":"http","port":"3000","path":["appointments"],"host":["localhost"],"query":[{"key":"docId","value":"5c7e2ceb48c80753d8d9da07"}],"variable":[]}},"response":[],"_postman_id":"609e2877-831f-4156-a9a4-8aff13fda4e0"},{"name":"List appointments by DocId and Date","id":"0d5d18e4-1420-4435-bd5c-3ced7d61202d","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"http://localhost:3000/appointments?docId=5c7e2ceb48c80753d8d9da07&date=2019-03-05","description":"<p>Get a list of all appointments for a particular doctor on a particular date</p>\n<p>Query Parameters:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code>docId: String (ObjectId from Doctor collection in mongoDB)\ndate: String (YYYY-MM-DD)\n</code></pre>","urlObject":{"protocol":"http","port":"3000","path":["appointments"],"host":["localhost"],"query":[{"key":"docId","value":"5c7e2ceb48c80753d8d9da07"},{"key":"date","value":"2019-03-05"}],"variable":[]}},"response":[],"_postman_id":"0d5d18e4-1420-4435-bd5c-3ced7d61202d"},{"name":"Update an appointment","id":"c2b54416-4ed9-4cd4-be8f-5f95ce6592d7","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PATCH","header":[{"key":"Content-Type","name":"Content-Type","value":"application/json","type":"text"}],"body":{"mode":"raw","raw":"{\n\t\"docId\": \"5c7e2ceb48c80753d8d9da07\",\n\t\"patientId\": \"5c7e2d8d48c80753d8d9da3b\",\n\t\"date\": \"2019-03-05\",\n    \"startTime\": 20000,\n    \"endTime\": 60000\n}"},"url":"http://localhost:3000/appointments/5c7e2ceb48c80753d8d9da07","description":"<p>Update information for a particular appointment</p>\n<p>Path Parameter:</p>\n<p>appointmentId: String (ObjectId from Appointment collection in mongoDB)</p>\n<p>Request Body:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code>{\n    \"docId\": String (ObjectId from doctor collection in MongoDB),\n    \"patientId\": String (ObjectId from patient collection in MongoDB),\n    \"date\": String (YYYY-MM-DD),\n    \"startTime\": Number (24Hr time converted to seconds),\n    \"endTime\": Number (24Hr time converted to seconds)\n}\n</code></pre>","urlObject":{"protocol":"http","port":"3000","path":["appointments","5c7e2ceb48c80753d8d9da07"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"c2b54416-4ed9-4cd4-be8f-5f95ce6592d7"},{"name":"Delete Appointment","id":"65141e1d-58c1-48a7-bdb0-3e0542834b80","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"DELETE","header":[],"body":{"mode":"raw","raw":""},"url":"http://localhost:3000/appointments/5c7e2ceb48c80753d8d9da07","description":"<p>Delete an appointment</p>\n<p>Path Parameter:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code>appointmentId: String (ObjectId from Appointment collection in mongoDB)\n</code></pre>","urlObject":{"protocol":"http","port":"3000","path":["appointments","5c7e2ceb48c80753d8d9da07"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"65141e1d-58c1-48a7-bdb0-3e0542834b80"}],"id":"188dfe10-51cc-4889-a01c-1ba84d24e5b8","description":"<h1 id=\"appointments-apis\">Appointments API's</h1>\n<ul>\n<li>Create Appointment</li>\n<li>Get list of all Appointments by Doctor</li>\n<li>Get list of all Appointments by Doctor and the date</li>\n<li>Update schedule for the patient and of doctor</li>\n<li>Delete or Remove an appointment from the system</li>\n</ul>\n","event":[{"listen":"prerequest","script":{"id":"7d06b447-4349-4677-8b1b-2f488f12276b","type":"text/javascript","exec":[""]}},{"listen":"test","script":{"id":"9d6c2a9c-6f3b-466d-97ea-db3e05780301","type":"text/javascript","exec":[""]}}],"_postman_id":"188dfe10-51cc-4889-a01c-1ba84d24e5b8"}],"event":[{"listen":"prerequest","script":{"id":"555a9423-7cb4-4cff-bcb5-4e0084a6202e","type":"text/javascript","exec":[""]}},{"listen":"test","script":{"id":"b4c72dab-d0e9-4002-8dd2-021b6e0df96e","type":"text/javascript","exec":[""]}}]}