{"info":{"_postman_id":"7e8d0f9c-fe37-465f-a264-e077bcad5204","name":"okdoc-backend","description":"<html><head></head><body><p>The JWT has the following structure:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code>{\n  \"_id\": \"615043f6d0fb0121f3d50512\",\n  \"iat\": 1632656922,\n  \"exp\": 1632660522\n}\n</code></pre><p>The <code>_id</code> is the patientId. To get the contents of the token, use jwt.decode.</p>\n<p>The API is deployed to Heroku here: <a href=\"https://okdoc-backend.herokuapp.com/\">https://okdoc-backend.herokuapp.com/</a> (&lt;- <code>prod_url</code>)\nYou can see how to make each request in different programming languages by changing language in the top menu bar.</p>\n</body></html>","schema":"https://schema.getpostman.com/json/collection/v2.0.0/collection.json","toc":[],"owner":"8654070","collectionId":"7e8d0f9c-fe37-465f-a264-e077bcad5204","publishedId":"UUxxhUAL","public":true,"customColor":{"top-bar":"FFFFFF","right-sidebar":"303030","highlight":"EF5B25"},"publishDate":"2021-10-04T10:31:01.000Z"},"item":[{"name":"/healthcheck","id":"d95f031a-8f15-4ea6-95d1-ffbd2ada61a5","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"{{test_url}}/healthcheck","description":"<p>Check that the server is working.</p>\n","urlObject":{"path":["healthcheck"],"host":["{{test_url}}"],"query":[],"variable":[]}},"response":[{"id":"0ec2ccc8-efcf-44b5-9abd-ceb83d9700f6","name":"success","originalRequest":{"method":"GET","header":[],"url":"{{test_url}}/healthcheck"},"status":"OK","code":200,"_postman_previewlanguage":"plain","header":[{"key":"X-Powered-By","value":"Express"},{"key":"Content-Type","value":"text/plain; charset=utf-8"},{"key":"Content-Length","value":"2"},{"key":"ETag","value":"W/\"2-nOO9QiTIwXgNtWtBJezz8kv3SLc\""},{"key":"Date","value":"Wed, 29 Sep 2021 07:51:29 GMT"},{"key":"Connection","value":"keep-alive"},{"key":"Keep-Alive","value":"timeout=5"}],"cookie":[],"responseTime":null,"body":"OK"}],"_postman_id":"d95f031a-8f15-4ea6-95d1-ffbd2ada61a5"},{"name":"/api/tokens","id":"2d0b7b52-b1c4-4dc9-92d9-279a90b57def","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\r\n    \"amka\": \"12345678911\"\r\n}","options":{"raw":{"language":"json"}}},"url":"{{test_url}}/api/tokens","description":"<p>Used to login.\nRequires the AMKA of the patient and returns a JWT in the Authorization header.</p>\n","urlObject":{"path":["api","tokens"],"host":["{{test_url}}"],"query":[],"variable":[]}},"response":[{"id":"43aea619-0905-4a7e-a1c0-e315d902544d","name":"success","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\r\n    \"amka\": \"12345678910\"\r\n}","options":{"raw":{"language":"json"}}},"url":"{{prod_url}}/api/tokens"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"X-Powered-By","value":"Express"},{"key":"Authorization","value":"token"},{"key":"Content-Type","value":"application/json; charset=utf-8"},{"key":"Content-Length","value":"44"},{"key":"ETag","value":"W/\"2c-6bMXj5KeU5oM4hPnolb5cve4asE\""},{"key":"Date","value":"Sun, 26 Sep 2021 06:25:25 GMT"},{"key":"Connection","value":"keep-alive"},{"key":"Keep-Alive","value":"timeout=5"}],"cookie":[],"responseTime":null,"body":"{\n    \"success\": true,\n    \"message\": \"Login succesful\"\n}"},{"id":"baed91b4-0eec-4d1f-bf97-d42a0a5c28b1","name":"no amka","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\r\n    \r\n}","options":{"raw":{"language":"json"}}},"url":"{{prod_url}}/api/tokens"},"status":"Bad Request","code":400,"_postman_previewlanguage":"json","header":[{"key":"X-Powered-By","value":"Express"},{"key":"Content-Type","value":"application/json; charset=utf-8"},{"key":"Content-Length","value":"46"},{"key":"ETag","value":"W/\"2e-0lF/goTOJDO3bHAPC0Fde5JcFcY\""},{"key":"Date","value":"Sun, 26 Sep 2021 06:43:38 GMT"},{"key":"Connection","value":"keep-alive"},{"key":"Keep-Alive","value":"timeout=5"}],"cookie":[],"responseTime":null,"body":"{\n    \"success\": false,\n    \"message\": \"AMKA is required\"\n}"}],"_postman_id":"2d0b7b52-b1c4-4dc9-92d9-279a90b57def"},{"name":"/api/patients/:patientId","id":"2149453c-4c62-445e-a670-ab1cd9972087","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"Bearer {{token}}","type":"text"}],"url":"{{prod_url}}/api/patients/:patientId","description":"<p>Get the information of a specific patient (requires to be logged in).</p>\n","urlObject":{"path":["api","patients",":patientId"],"host":["{{prod_url}}"],"query":[],"variable":[{"type":"any","value":"{{patientIdJudith}}","key":"patientId"}]}},"response":[{"id":"5bf7f731-2456-4f3c-89a8-6082f37b0c9b","name":"no token","originalRequest":{"method":"GET","header":[],"url":{"raw":"{{prod_url}}/api/patients/:patientId","host":["{{prod_url}}"],"path":["api","patients",":patientId"],"variable":[{"key":"patientId","value":"{{patientIdJim}}"}]}},"status":"Bad Request","code":400,"_postman_previewlanguage":"html","header":[{"key":"X-Powered-By","value":"Express"},{"key":"Content-Type","value":"text/html; charset=utf-8"},{"key":"Content-Length","value":"17"},{"key":"ETag","value":"W/\"11-/cPsI6tJJrsRsn68gJrh7xWg0Og\""},{"key":"Date","value":"Sun, 26 Sep 2021 06:47:32 GMT"},{"key":"Connection","value":"keep-alive"},{"key":"Keep-Alive","value":"timeout=5"}],"cookie":[],"responseTime":null,"body":"No token received"},{"id":"58d674f7-5467-4255-93f9-b604f2cff614","name":"success","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJfaWQiOiI2MTUxZGYwNzRhMjk5NTdiMTYzZjk4YTgiLCJpYXQiOjE2MzQ5OTkxNzgsImV4cCI6MTYzNTAwMjc3OH0.9kd76A_FytwMxZnovQFHLqOXOkr5jLpVxJJeCXg_9G4","type":"text"}],"url":{"raw":"{{test_url}}/api/patients/:patientId","host":["{{test_url}}"],"path":["api","patients",":patientId"],"variable":[{"key":"patientId","value":"{{patientIdJudith}}"}]}},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"X-Powered-By","value":"Express"},{"key":"Content-Type","value":"application/json; charset=utf-8"},{"key":"Content-Length","value":"468"},{"key":"ETag","value":"W/\"1d4-YiE4AqCF0f8fqGzjblW5tn793UY\""},{"key":"Date","value":"Sat, 23 Oct 2021 14:29:21 GMT"},{"key":"Connection","value":"keep-alive"},{"key":"Keep-Alive","value":"timeout=5"}],"cookie":[],"responseTime":null,"body":"{\n    \"success\": true,\n    \"message\": \"Success\",\n    \"data\": {\n        \"_id\": \"6151df074a29957b163f98a8\",\n        \"name\": \"Judith\",\n        \"lastName\": \"Lewis\",\n        \"amka\": \"12345678911\",\n        \"bloodType\": \"A+\",\n        \"familyDoctor\": {\n            \"_id\": \"6151d9d34a29957b163f98a2\",\n            \"profession\": {\n                \"_id\": \"615c427a14da612a4f026f6b\",\n                \"name\": \"Gynecologists\"\n            },\n            \"name\": \"Lillian\",\n            \"lastName\": \"Ladner\",\n            \"hospital\": {\n                \"_id\": \"6151de4a4a29957b163f98a6\",\n                \"name\": \"Ippokrateio\",\n                \"address\": \"Konstantinoupoleos 49\",\n                \"phoneNumber\": \"2310892000\",\n                \"email\": \"devsoncall@gmail.com\"\n            }\n        }\n    }\n}"}],"_postman_id":"2149453c-4c62-445e-a670-ab1cd9972087"},{"name":"/api/patients/:patientId/appointments","id":"50b5dcae-b244-462b-a66d-92447b0fd3d2","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"Bearer {{token}}","type":"text"}],"url":"{{prod_url}}/api/patients/:patientId/appointments","description":"<p>Get all the appointments of a patient.</p>\n","urlObject":{"path":["api","patients",":patientId","appointments"],"host":["{{prod_url}}"],"query":[],"variable":[{"type":"any","value":"{{patientIdJudith}}","key":"patientId"}]}},"response":[{"id":"ee938993-98a9-4043-b375-c9f3772fd092","name":"success","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJfaWQiOiI2MTUxZGYwNzRhMjk5NTdiMTYzZjk4YTgiLCJpYXQiOjE2MzUwMDIxNjksImV4cCI6MTYzNTAwNTc2OX0.cL1isjfSybDckn4O7Lg7gkNy7Sqzgb5B2Xx3JFNA8iI","type":"text"}],"url":{"raw":"{{test_url}}/api/patients/:patientId/appointments","host":["{{test_url}}"],"path":["api","patients",":patientId","appointments"],"variable":[{"key":"patientId","value":"{{patientIdJudith}}"}]}},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"X-Powered-By","value":"Express"},{"key":"Content-Type","value":"application/json; charset=utf-8"},{"key":"Content-Length","value":"4412"},{"key":"ETag","value":"W/\"113c-jNeEi0Vo3WTEiX/Vq7jN9EFiVD4\""},{"key":"Date","value":"Sat, 23 Oct 2021 15:18:38 GMT"},{"key":"Connection","value":"keep-alive"},{"key":"Keep-Alive","value":"timeout=5"}],"cookie":[],"responseTime":null,"body":"{\n    \"success\": true,\n    \"message\": \"Success\",\n    \"data\": [\n        {\n            \"_id\": \"617148a10918cffb03b6f400\",\n            \"date\": \"2021-10-27T09:30:00.000Z\",\n            \"reason\": \"-\",\n            \"doctor\": {\n                \"_id\": \"6151da404a29957b163f98a4\",\n                \"profession\": {\n                    \"_id\": \"615c42fe14da612a4f026f6d\",\n                    \"name\": \"Endocrinologist\"\n                },\n                \"name\": \"Larry\",\n                \"lastName\": \"Hodges\",\n                \"hospital\": {\n                    \"_id\": \"6151de924a29957b163f98a7\",\n                    \"name\": \"Papageorgiou\",\n                    \"address\": \"Agiou Pavlou 76\",\n                    \"phoneNumber\": \"2313323000\",\n                    \"email\": \"devsoncall@gmail.com\"\n                }\n            },\n            \"hospital\": {\n                \"_id\": \"6151de924a29957b163f98a7\",\n                \"name\": \"Papageorgiou\",\n                \"address\": \"Agiou Pavlou 76\",\n                \"phoneNumber\": \"2313323000\",\n                \"email\": \"devsoncall@gmail.com\"\n            }\n        },\n        {\n            \"_id\": \"61714c120918cffb03b6f430\",\n            \"date\": \"2021-10-27T09:30:00.000Z\",\n            \"reason\": \"Checkup\",\n            \"doctor\": {\n                \"_id\": \"6151d9d34a29957b163f98a2\",\n                \"profession\": {\n                    \"_id\": \"615c427a14da612a4f026f6b\",\n                    \"name\": \"Gynecologists\"\n                },\n                \"name\": \"Lillian\",\n                \"lastName\": \"Ladner\",\n                \"hospital\": {\n                    \"_id\": \"6151de4a4a29957b163f98a6\",\n                    \"name\": \"Ippokrateio\",\n                    \"address\": \"Konstantinoupoleos 49\",\n                    \"phoneNumber\": \"2310892000\",\n                    \"email\": \"devsoncall@gmail.com\"\n                }\n            },\n            \"hospital\": {\n                \"_id\": \"6151de4a4a29957b163f98a6\",\n                \"name\": \"Ippokrateio\",\n                \"address\": \"Konstantinoupoleos 49\",\n                \"phoneNumber\": \"2310892000\",\n                \"email\": \"devsoncall@gmail.com\"\n            }\n        },\n        {\n            \"_id\": \"6151dfa24a29957b163f98a9\",\n            \"reason\": \"Not feeling well\",\n            \"date\": \"2021-11-05T09:30:00.000Z\",\n            \"doctor\": {\n                \"_id\": \"6151da404a29957b163f98a4\",\n                \"profession\": {\n                    \"_id\": \"615c42fe14da612a4f026f6d\",\n                    \"name\": \"Endocrinologist\"\n                },\n                \"name\": \"Larry\",\n                \"lastName\": \"Hodges\",\n                \"hospital\": {\n                    \"_id\": \"6151de924a29957b163f98a7\",\n                    \"name\": \"Papageorgiou\",\n                    \"address\": \"Agiou Pavlou 76\",\n                    \"phoneNumber\": \"2313323000\",\n                    \"email\": \"devsoncall@gmail.com\"\n                }\n            },\n            \"hospital\": {\n                \"_id\": \"6151ddb64a29957b163f98a5\",\n                \"name\": \"AHEPA\",\n                \"address\": \"Kiriakidi 1\",\n                \"phoneNumber\": \"2313303110\",\n                \"email\": \"devsoncall@gmail.com\"\n            }\n        },\n        {\n            \"_id\": \"616c379e4ca37c1356954ce9\",\n            \"date\": \"2021-11-05T16:00:00.000Z\",\n            \"reason\": \"Dead\",\n            \"doctor\": {\n                \"_id\": \"6151da404a29957b163f98a4\",\n                \"profession\": {\n                    \"_id\": \"615c42fe14da612a4f026f6d\",\n                    \"name\": \"Endocrinologist\"\n                },\n                \"name\": \"Larry\",\n                \"lastName\": \"Hodges\",\n                \"hospital\": {\n                    \"_id\": \"6151de924a29957b163f98a7\",\n                    \"name\": \"Papageorgiou\",\n                    \"address\": \"Agiou Pavlou 76\",\n                    \"phoneNumber\": \"2313323000\",\n                    \"email\": \"devsoncall@gmail.com\"\n                }\n            },\n            \"hospital\": {\n                \"_id\": \"6151ddb64a29957b163f98a5\",\n                \"name\": \"AHEPA\",\n                \"address\": \"Kiriakidi 1\",\n                \"phoneNumber\": \"2313303110\",\n                \"email\": \"devsoncall@gmail.com\"\n            }\n        },\n        {\n            \"_id\": \"6151e2a14a29957b163f98aa\",\n            \"reason\": \"Headaches\",\n            \"date\": \"2021-11-07T09:00:00.000Z\",\n            \"doctor\": {\n                \"_id\": \"6151d9d34a29957b163f98a2\",\n                \"profession\": {\n                    \"_id\": \"615c427a14da612a4f026f6b\",\n                    \"name\": \"Gynecologists\"\n                },\n                \"name\": \"Lillian\",\n                \"lastName\": \"Ladner\",\n                \"hospital\": {\n                    \"_id\": \"6151de4a4a29957b163f98a6\",\n                    \"name\": \"Ippokrateio\",\n                    \"address\": \"Konstantinoupoleos 49\",\n                    \"phoneNumber\": \"2310892000\",\n                    \"email\": \"devsoncall@gmail.com\"\n                }\n            },\n            \"hospital\": {\n                \"_id\": \"6151de4a4a29957b163f98a6\",\n                \"name\": \"Ippokrateio\",\n                \"address\": \"Konstantinoupoleos 49\",\n                \"phoneNumber\": \"2310892000\",\n                \"email\": \"devsoncall@gmail.com\"\n            }\n        },\n        {\n            \"_id\": \"6171d8713d93944c832bfd67\",\n            \"date\": \"2021-11-17T14:00:00.000Z\",\n            \"reason\": \"headache\",\n            \"doctor\": {\n                \"_id\": \"6151d9d34a29957b163f98a2\",\n                \"profession\": {\n                    \"_id\": \"615c427a14da612a4f026f6b\",\n                    \"name\": \"Gynecologists\"\n                },\n                \"name\": \"Lillian\",\n                \"lastName\": \"Ladner\",\n                \"hospital\": {\n                    \"_id\": \"6151de4a4a29957b163f98a6\",\n                    \"name\": \"Ippokrateio\",\n                    \"address\": \"Konstantinoupoleos 49\",\n                    \"phoneNumber\": \"2310892000\",\n                    \"email\": \"devsoncall@gmail.com\"\n                }\n            },\n            \"hospital\": {\n                \"_id\": \"6151de4a4a29957b163f98a6\",\n                \"name\": \"Ippokrateio\",\n                \"address\": \"Konstantinoupoleos 49\",\n                \"phoneNumber\": \"2310892000\",\n                \"email\": \"devsoncall@gmail.com\"\n            }\n        },\n        {\n            \"_id\": \"6174103b2a01bae6e5fac488\",\n            \"date\": \"2021-12-05T16:00:00.000Z\",\n            \"reason\": \"Dead\",\n            \"doctor\": {\n                \"_id\": \"6151da404a29957b163f98a4\",\n                \"profession\": {\n                    \"_id\": \"615c42fe14da612a4f026f6d\",\n                    \"name\": \"Endocrinologist\"\n                },\n                \"name\": \"Larry\",\n                \"lastName\": \"Hodges\",\n                \"hospital\": {\n                    \"_id\": \"6151de924a29957b163f98a7\",\n                    \"name\": \"Papageorgiou\",\n                    \"address\": \"Agiou Pavlou 76\",\n                    \"phoneNumber\": \"2313323000\",\n                    \"email\": \"devsoncall@gmail.com\"\n                }\n            },\n            \"hospital\": {\n                \"_id\": \"6151ddb64a29957b163f98a5\",\n                \"name\": \"AHEPA\",\n                \"address\": \"Kiriakidi 1\",\n                \"phoneNumber\": \"2313303110\",\n                \"email\": \"devsoncall@gmail.com\"\n            }\n        },\n        {\n            \"_id\": \"616eb0664db99edc3ccc5e68\",\n            \"date\": \"2021-12-06T16:00:00.000Z\",\n            \"reason\": \"Dead\",\n            \"doctor\": {\n                \"_id\": \"6151da404a29957b163f98a4\",\n                \"profession\": {\n                    \"_id\": \"615c42fe14da612a4f026f6d\",\n                    \"name\": \"Endocrinologist\"\n                },\n                \"name\": \"Larry\",\n                \"lastName\": \"Hodges\",\n                \"hospital\": {\n                    \"_id\": \"6151de924a29957b163f98a7\",\n                    \"name\": \"Papageorgiou\",\n                    \"address\": \"Agiou Pavlou 76\",\n                    \"phoneNumber\": \"2313323000\",\n                    \"email\": \"devsoncall@gmail.com\"\n                }\n            },\n            \"hospital\": {\n                \"_id\": \"6151ddb64a29957b163f98a5\",\n                \"name\": \"AHEPA\",\n                \"address\": \"Kiriakidi 1\",\n                \"phoneNumber\": \"2313303110\",\n                \"email\": \"devsoncall@gmail.com\"\n            }\n        }\n    ]\n}"}],"_postman_id":"50b5dcae-b244-462b-a66d-92447b0fd3d2"},{"name":"/api/patients/:patientId/prescriptions","id":"921570b0-d1c0-41da-a1f5-f263fb83eb05","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"Bearer {{token}}","type":"text"}],"url":"{{prod_url}}/api/patients/:patientId/prescriptions","description":"<p>Get all the prescriptions of a patient.</p>\n","urlObject":{"path":["api","patients",":patientId","prescriptions"],"host":["{{prod_url}}"],"query":[],"variable":[{"type":"any","value":"{{patientIdJudith}}","key":"patientId"}]}},"response":[{"id":"457d3647-dc2c-4583-9682-6e631dc4c6de","name":"success","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJfaWQiOiI2MTUxZGYwNzRhMjk5NTdiMTYzZjk4YTgiLCJpYXQiOjE2MzUwMDIxNjksImV4cCI6MTYzNTAwNTc2OX0.cL1isjfSybDckn4O7Lg7gkNy7Sqzgb5B2Xx3JFNA8iI","type":"text"}],"url":{"raw":"{{test_url}}/api/patients/:patientId/prescriptions","host":["{{test_url}}"],"path":["api","patients",":patientId","prescriptions"],"variable":[{"key":"patientId","value":"{{patientIdJudith}}"}]}},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"X-Powered-By","value":"Express"},{"key":"Content-Type","value":"application/json; charset=utf-8"},{"key":"Content-Length","value":"623"},{"key":"ETag","value":"W/\"26f-zBN0eG5IgCGd+YAcvCn7TNXqiWU\""},{"key":"Date","value":"Sat, 23 Oct 2021 15:24:46 GMT"},{"key":"Connection","value":"keep-alive"},{"key":"Keep-Alive","value":"timeout=5"}],"cookie":[],"responseTime":null,"body":"{\n    \"success\": true,\n    \"message\": \"Success\",\n    \"data\": [\n        {\n            \"_id\": \"6172b96ccb00c131bff29dc2\",\n            \"date\": \"2021-09-22T21:00:00.000Z\",\n            \"diagnosis\": {\n                \"_id\": \"6152f00455fad9d47827b9bd\",\n                \"date\": \"2021-12-10T22:00:00.000Z\",\n                \"diagnosis\": \"Streptococcus\",\n                \"prescription\": \"6172b96ccb00c131bff29dc2\"\n            },\n            \"dosage\": \"1,2g\",\n            \"drug\": \"Paracetamol\",\n            \"duration\": 40,\n            \"doctor\": {\n                \"_id\": \"6151da034a29957b163f98a3\",\n                \"profession\": {\n                    \"_id\": \"615c429314da612a4f026f6c\",\n                    \"name\": \"Ophthalmologist\"\n                },\n                \"name\": \"James\",\n                \"lastName\": \"Arnorld\",\n                \"hospital\": {\n                    \"_id\": \"6151de924a29957b163f98a7\",\n                    \"name\": \"Papageorgiou\",\n                    \"address\": \"Agiou Pavlou 76\",\n                    \"phoneNumber\": \"2313323000\",\n                    \"email\": \"devsoncall@gmail.com\"\n                }\n            }\n        }\n    ]\n}"}],"_postman_id":"921570b0-d1c0-41da-a1f5-f263fb83eb05"},{"name":"/api/patients/:patientId/diagnoses","id":"fd729f57-c62e-4e28-aeba-48b20ef5b293","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"Bearer {{token}}","type":"text"}],"url":"{{prod_url}}/api/patients/:patientId/diagnoses","description":"<p>Get all the diagnoses of a patient.</p>\n","urlObject":{"path":["api","patients",":patientId","diagnoses"],"host":["{{prod_url}}"],"query":[],"variable":[{"type":"any","value":"{{patientIdJudith}}","key":"patientId"}]}},"response":[{"id":"77dd0171-b4aa-40f3-98cb-d836220d2259","name":"success","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"Bearer {{token}}","type":"text"}],"url":{"raw":"{{test_url}}/api/patients/:patientId/diagnoses","host":["{{test_url}}"],"path":["api","patients",":patientId","diagnoses"],"variable":[{"key":"patientId","value":"{{patientIdJudith}}"}]}},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"X-Powered-By","value":"Express"},{"key":"Content-Type","value":"application/json; charset=utf-8"},{"key":"Content-Length","value":"511"},{"key":"ETag","value":"W/\"1ff-ahW8HZmoCQhYZQS68i8Po5NFwEo\""},{"key":"Date","value":"Sat, 23 Oct 2021 23:10:10 GMT"},{"key":"Connection","value":"keep-alive"},{"key":"Keep-Alive","value":"timeout=5"}],"cookie":[],"responseTime":null,"body":"{\n    \"success\": true,\n    \"message\": \"Success\",\n    \"data\": [\n        {\n            \"_id\": \"6152f00455fad9d47827b9bd\",\n            \"date\": \"2021-12-10T22:00:00.000Z\",\n            \"doctor\": {\n                \"_id\": \"6151da034a29957b163f98a3\",\n                \"profession\": {\n                    \"_id\": \"615c429314da612a4f026f6c\",\n                    \"name\": \"Ophthalmologist\"\n                },\n                \"name\": \"James\",\n                \"lastName\": \"Arnorld\",\n                \"hospital\": {\n                    \"_id\": \"6151de924a29957b163f98a7\",\n                    \"name\": \"Papageorgiou\",\n                    \"address\": \"Agiou Pavlou 76\",\n                    \"phoneNumber\": \"2313323000\",\n                    \"email\": \"devsoncall@gmail.com\"\n                }\n            },\n            \"prescription\": \"6172b96ccb00c131bff29dc2\",\n            \"details\": \"Details here\",\n            \"name\": \"Streptococcus\"\n        }\n    ]\n}"}],"_postman_id":"fd729f57-c62e-4e28-aeba-48b20ef5b293"},{"name":"/api/professions","id":"563ce0b7-d26b-4ac4-9c05-8173890d0702","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"Bearer {{token}}","type":"text"}],"url":"{{prod_url}}/api/professions","description":"<p>Returns all the available professions.</p>\n","urlObject":{"path":["api","professions"],"host":["{{prod_url}}"],"query":[],"variable":[]}},"response":[{"id":"5eabcca3-4f76-42e1-a465-16023f314a8e","name":"success","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"Bearer {{token}}","type":"text"}],"url":"{{prod_url}}/api/professions"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Server","value":"Cowboy"},{"key":"Connection","value":"keep-alive"},{"key":"X-Powered-By","value":"Express"},{"key":"Content-Type","value":"application/json; charset=utf-8"},{"key":"Content-Length","value":"280"},{"key":"Etag","value":"W/\"118-JYCvGv6Ea5RmqWArGqQKPflN2es\""},{"key":"Date","value":"Tue, 12 Oct 2021 14:03:27 GMT"},{"key":"Via","value":"1.1 vegur"}],"cookie":[],"responseTime":null,"body":"{\n    \"success\": true,\n    \"message\": \"Success\",\n    \"data\": [\n        {\n            \"_id\": \"615c425614da612a4f026f6a\",\n            \"name\": \"Cardiologist\"\n        },\n        {\n            \"_id\": \"615c427a14da612a4f026f6b\",\n            \"name\": \"Gynecologists\"\n        },\n        {\n            \"_id\": \"615c429314da612a4f026f6c\",\n            \"name\": \"Ophthalmologist\"\n        },\n        {\n            \"_id\": \"615c42fe14da612a4f026f6d\",\n            \"name\": \"Endocrinologist\"\n        }\n    ]\n}"}],"_postman_id":"563ce0b7-d26b-4ac4-9c05-8173890d0702"},{"name":"/api/hospitals","id":"d569bba0-f264-4ec0-a948-b197ff81d6d8","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"Bearer {{token}}","type":"text"}],"url":"{{test_url}}/api/hospitals?professionId={{professionIdCardiologist}}","description":"<p>Returns all hospitals (can specify profession).</p>\n","urlObject":{"path":["api","hospitals"],"host":["{{test_url}}"],"query":[{"key":"professionId","value":"{{professionIdCardiologist}}"}],"variable":[]}},"response":[{"id":"8cac2fac-2ca5-4edd-9c93-44d4b7e3d0c7","name":"success without professionId","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"Bearer {{token}}","type":"text"}],"url":"{{test_url}}/api/hospitals"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"X-Powered-By","value":"Express"},{"key":"Content-Type","value":"application/json; charset=utf-8"},{"key":"Content-Length","value":"387"},{"key":"ETag","value":"W/\"183-+PFYlWGzGn5Z4RRoOVHlb16Jk5g\""},{"key":"Date","value":"Sat, 23 Oct 2021 23:12:14 GMT"},{"key":"Connection","value":"keep-alive"},{"key":"Keep-Alive","value":"timeout=5"}],"cookie":[],"responseTime":null,"body":"{\n    \"success\": true,\n    \"message\": \"Success\",\n    \"data\": [\n        {\n            \"_id\": \"6151ddb64a29957b163f98a5\",\n            \"name\": \"AHEPA\",\n            \"address\": \"Kiriakidi 1\",\n            \"email\": \"devsoncall@gmail.com\"\n        },\n        {\n            \"_id\": \"6151de4a4a29957b163f98a6\",\n            \"name\": \"Ippokrateio\",\n            \"address\": \"Konstantinoupoleos 49\",\n            \"email\": \"devsoncall@gmail.com\"\n        },\n        {\n            \"_id\": \"6151de924a29957b163f98a7\",\n            \"name\": \"Papageorgiou\",\n            \"address\": \"Agiou Pavlou 76\",\n            \"email\": \"devsoncall@gmail.com\"\n        }\n    ]\n}"},{"id":"f1a2c7f8-729a-4c35-aa91-deaa1499de0a","name":"success with professionId","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"Bearer {{token}}","type":"text"}],"url":{"raw":"{{test_url}}/api/hospitals?professionId={{professionIdCardiologist}}","host":["{{test_url}}"],"path":["api","hospitals"],"query":[{"key":"professionId","value":"{{professionIdCardiologist}}"}]}},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"X-Powered-By","value":"Express"},{"key":"Content-Type","value":"application/json; charset=utf-8"},{"key":"Content-Length","value":"150"},{"key":"ETag","value":"W/\"96-zuVf1L4QpTweDGx4L/FLEhKIiJ4\""},{"key":"Date","value":"Sat, 23 Oct 2021 23:13:05 GMT"},{"key":"Connection","value":"keep-alive"},{"key":"Keep-Alive","value":"timeout=5"}],"cookie":[],"responseTime":null,"body":"{\n    \"success\": true,\n    \"message\": \"Success\",\n    \"data\": [\n        {\n            \"_id\": \"6151ddb64a29957b163f98a5\",\n            \"name\": \"AHEPA\",\n            \"address\": \"Kiriakidi 1\",\n            \"email\": \"devsoncall@gmail.com\"\n        }\n    ]\n}"}],"_postman_id":"d569bba0-f264-4ec0-a948-b197ff81d6d8"},{"name":"/api/doctors","id":"7ca08cc6-4ce7-4aca-8b02-492813af2886","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"Bearer {{token}} ","type":"text"}],"url":"{{prod_url}}/api/doctors?professionId={{professionIdCardiologist}}&hospitalId={{hospitalIdAhepa}}","description":"<p>Returns all the available doctors for specific profession &amp; hospital.</p>\n","urlObject":{"path":["api","doctors"],"host":["{{prod_url}}"],"query":[{"key":"professionId","value":"{{professionIdCardiologist}}"},{"key":"hospitalId","value":"{{hospitalIdAhepa}}"}],"variable":[]}},"response":[{"id":"ee85ab5a-702b-4f62-a0cb-3d2172e62a31","name":"success","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJfaWQiOiI2MTUxZGYwNzRhMjk5NTdiMTYzZjk4YTgiLCJpYXQiOjE2MzQ5OTc3MjgsImV4cCI6MTYzNTAwMTMyOH0.FOBHlxGhMPZpKI63hePytHX66fkwTwdm6RCKGayBL-Q","type":"text"}],"url":{"raw":"{{test_url}}/api/doctors?professionId={{professionIdCardiologist}}&hospitalId={{hospitalIdAhepa}}","host":["{{test_url}}"],"path":["api","doctors"],"query":[{"key":"professionId","value":"{{professionIdCardiologist}}"},{"key":"hospitalId","value":"{{hospitalIdAhepa}}"}]}},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"X-Powered-By","value":"Express"},{"key":"Content-Type","value":"application/json; charset=utf-8"},{"key":"Content-Length","value":"185"},{"key":"ETag","value":"W/\"b9-U1rSYJY3IyOOW9XegDch+f9klB0\""},{"key":"Date","value":"Sat, 23 Oct 2021 14:09:56 GMT"},{"key":"Connection","value":"keep-alive"},{"key":"Keep-Alive","value":"timeout=5"}],"cookie":[],"responseTime":null,"body":"{\n    \"success\": true,\n    \"message\": \"Success\",\n    \"data\": [\n        {\n            \"_id\": \"61504467d0fb0121f3d50513\",\n            \"profession\": {\n                \"_id\": \"615c425614da612a4f026f6a\",\n                \"name\": \"Cardiologist\"\n            },\n            \"name\": \"Doctor\",\n            \"lastName\": \"Smith\"\n        }\n    ]\n}"}],"_postman_id":"7ca08cc6-4ce7-4aca-8b02-492813af2886"},{"name":"/api/appointments","id":"43d97f13-b0f7-4c98-8207-e03c94a272a9","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Authorization","value":"Bearer {{token}}","type":"text"}],"url":"{{test_url}}/api/appointments?doctorId={{doctorIdLarry}}","description":"<p>Returns all appointments a specific doctor has grouped by date.</p>\n","urlObject":{"path":["api","appointments"],"host":["{{test_url}}"],"query":[{"key":"doctorId","value":"{{doctorIdLarry}}"}],"variable":[]}},"response":[{"id":"103a07f9-6276-4e9b-a5a0-f38acd576186","name":"success","originalRequest":{"method":"GET","header":[{"key":"Authorization","value":"Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJfaWQiOiI2MTUxZGYwNzRhMjk5NTdiMTYzZjk4YTgiLCJpYXQiOjE2MzUwMDIxNjksImV4cCI6MTYzNTAwNTc2OX0.cL1isjfSybDckn4O7Lg7gkNy7Sqzgb5B2Xx3JFNA8iI","type":"text"}],"url":{"raw":"{{test_url}}/api/appointments?doctorId={{doctorIdLarry}}","host":["{{test_url}}"],"path":["api","appointments"],"query":[{"key":"doctorId","value":"{{doctorIdLarry}}"}]}},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"X-Powered-By","value":"Express"},{"key":"Content-Type","value":"application/json; charset=utf-8"},{"key":"Content-Length","value":"191"},{"key":"ETag","value":"W/\"bf-U9vRiK6ydqAqXjyf7c7GCLkKPgU\""},{"key":"Date","value":"Sat, 23 Oct 2021 15:32:29 GMT"},{"key":"Connection","value":"keep-alive"},{"key":"Keep-Alive","value":"timeout=5"}],"cookie":[],"responseTime":null,"body":"{\n    \"success\": true,\n    \"message\": \"Success\",\n    \"data\": [\n        {\n            \"_id\": \"2021-10-27\",\n            \"booked_times\": [\n                \"09:30\"\n            ]\n        },\n        {\n            \"_id\": \"2021-11-12\",\n            \"booked_times\": [\n                \"12:30\"\n            ]\n        },\n        {\n            \"_id\": \"2021-11-05\",\n            \"booked_times\": [\n                \"09:30\",\n                \"16:00\"\n            ]\n        }\n    ]\n}"}],"_postman_id":"43d97f13-b0f7-4c98-8207-e03c94a272a9"},{"name":"/api/appointments","id":"b05bbe7d-904a-40f3-9a42-26adbbb627f6","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"Authorization","value":"Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJfaWQiOiI2MTUxZGYwNzRhMjk5NTdiMTYzZjk4YTgiLCJpYXQiOjE2MzQ0ODA1NTIsImV4cCI6MTYzNDQ4NDE1Mn0.5NqvFNFS7AfuOvjMLrkJCs9HxmTdKqi2tmaBlTw0CRA","type":"text"}],"body":{"mode":"raw","raw":"{\r\n    \"patient\": \"6151df074a29957b163f98a8\",\r\n    \"reason\": \"Dead\",\r\n    \"doctor\": \"6151da404a29957b163f98a4\",\r\n    \"hospital\": \"6151ddb64a29957b163f98a5\",\r\n    \"date\": \"2021-11-05T16:00:00.000+00:00\"\r\n}","options":{"raw":{"language":"json"}}},"url":"{{test_url}}/api/appointments","description":"<p>Creates a new appointment.</p>\n","urlObject":{"path":["api","appointments"],"host":["{{test_url}}"],"query":[],"variable":[]}},"response":[{"id":"15907fc9-ae49-4308-a2d9-68424ac78646","name":"success","originalRequest":{"method":"POST","header":[{"key":"Authorization","value":"Bearer {{token}}","type":"text"}],"body":{"mode":"raw","raw":"{\r\n    \"patient\": \"6151df074a29957b163f98a8\",\r\n    \"reason\": \"Dead\",\r\n    \"doctor\": \"6151da404a29957b163f98a4\",\r\n    \"hospital\": \"6151ddb64a29957b163f98a5\",\r\n    \"date\": \"2021-12-05T16:00:00.000+00:00\"\r\n}","options":{"raw":{"language":"json"}}},"url":"{{prod_url}}/api/appointments"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Server","value":"Cowboy"},{"key":"Connection","value":"keep-alive"},{"key":"X-Powered-By","value":"Express"},{"key":"Content-Type","value":"application/json; charset=utf-8"},{"key":"Content-Length","value":"67"},{"key":"Etag","value":"W/\"43-EZ2zDXCbSc1YT9Ww8x5tzmAtQ6Q\""},{"key":"Date","value":"Sat, 23 Oct 2021 13:38:03 GMT"},{"key":"Via","value":"1.1 vegur"}],"cookie":[],"responseTime":null,"body":"{\n    \"success\": true,\n    \"message\": \"Your appoinment was added successfully\"\n}"}],"_postman_id":"b05bbe7d-904a-40f3-9a42-26adbbb627f6"}]}