{"info":{"_postman_id":"2f53ffb5-511c-465a-98a8-bdf65265fec0","name":"Travel366","description":"<html><head></head><body><p>The Tavel366 API contains endpoints for Tours, Users, Reviews, and Bookings.</p>\n</body></html>","schema":"https://schema.getpostman.com/json/collection/v2.0.0/collection.json","toc":[],"owner":"11006835","collectionId":"2f53ffb5-511c-465a-98a8-bdf65265fec0","publishedId":"Tz5p6yJ8","public":true,"customColor":{"top-bar":"FFFFFF","right-sidebar":"303030","highlight":"EF5B25"},"publishDate":"2021-03-12T04:14:42.000Z"},"item":[{"name":"Tours","item":[{"name":"Get All Tours","id":"d1f803a7-3938-496c-918d-3e30885ec034","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Content-Type","name":"Content-Type","type":"text","value":"application/json"}],"url":"{{URL}}api/v1/tours","description":"<p>Use this endpoint to get all tours.</p>\n","urlObject":{"path":["v1","tours"],"host":["{{URL}}api"],"query":[{"disabled":true,"description":{"content":"<p>Query for tour price. Supports gte, lte, gt, lt operators.</p>\n","type":"text/plain"},"key":"price[lt]","value":"1500"},{"disabled":true,"description":{"content":"<p>Query for tour ratings. Supports gte, lte, gt, lt operators.</p>\n","type":"text/plain"},"key":"ratingsAverage[gte]","value":"4.7"},{"disabled":true,"description":{"content":"<p>Query for tour result limit</p>\n","type":"text/plain"},"key":"limit","value":"5"}],"variable":[]}},"response":[],"_postman_id":"d1f803a7-3938-496c-918d-3e30885ec034"},{"name":"Get Tour","id":"1626e7c0-54b1-475e-bbad-5b44a7a2a797","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"{{URL}}api/v1/tours/5c88fa8cf4afda39709c2955","description":"<p>Use this endpoint to get a specific tour details using its tourID.</p>\n","urlObject":{"path":["v1","tours","5c88fa8cf4afda39709c2955"],"host":["{{URL}}api"],"query":[],"variable":[]}},"response":[],"_postman_id":"1626e7c0-54b1-475e-bbad-5b44a7a2a797"},{"name":"Sort Tour Data","id":"1398a800-440c-4757-9274-fc2fa80bbbe7","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Content-Type","name":"Content-Type","type":"text","value":"application/json"}],"url":"{{URL}}api/v1/tours?sort=price,duration","description":"<p>Use this endpoint to get all tours.</p>\n","urlObject":{"path":["v1","tours"],"host":["{{URL}}api"],"query":[{"disabled":true,"description":{"content":"<p>Query for tour price. Supports gte, lte, gt, lt operators.</p>\n","type":"text/plain"},"key":"price[lt]","value":"1500"},{"disabled":true,"description":{"content":"<p>Query for tour ratings. Supports gte, lte, gt, lt operators.</p>\n","type":"text/plain"},"key":"ratingsAverage[gte]","value":"4.7"},{"disabled":true,"description":{"content":"<p>Query for tour result limit</p>\n","type":"text/plain"},"key":"limit","value":"5"},{"key":"sort","value":"price,duration"}],"variable":[]}},"response":[],"_postman_id":"1398a800-440c-4757-9274-fc2fa80bbbe7"},{"name":"Get Tours by Advanced Queries Copy","id":"bd921595-56fd-446d-be7d-94cdc3b379d1","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Content-Type","name":"Content-Type","type":"text","value":"application/json"}],"url":"{{URL}}api/v1/tours?duration[gte]=5&difficulty=easy","description":"<p>Use this endpoint to get all tours.</p>\n","urlObject":{"path":["v1","tours"],"host":["{{URL}}api"],"query":[{"disabled":true,"description":{"content":"<p>Query for tour price. Supports gte, lte, gt, lt operators.</p>\n","type":"text/plain"},"key":"price[lt]","value":"1500"},{"disabled":true,"description":{"content":"<p>Query for tour ratings. Supports gte, lte, gt, lt operators.</p>\n","type":"text/plain"},"key":"ratingsAverage[gte]","value":"4.7"},{"disabled":true,"description":{"content":"<p>Query for tour result limit</p>\n","type":"text/plain"},"key":"limit","value":"5"},{"key":"duration[gte]","value":"5"},{"key":"difficulty","value":"easy"}],"variable":[]}},"response":[],"_postman_id":"bd921595-56fd-446d-be7d-94cdc3b379d1"},{"name":"Get Tours by Queries","id":"8d52b419-8058-4907-8b5b-78617bbfb6e8","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Content-Type","name":"Content-Type","type":"text","value":"application/json"}],"url":"{{URL}}api/v1/tours?price=2997","description":"<p>Use this endpoint to get all tours.</p>\n","urlObject":{"path":["v1","tours"],"host":["{{URL}}api"],"query":[{"disabled":true,"description":{"content":"<p>Query for tour price. Supports gte, lte, gt, lt operators.</p>\n","type":"text/plain"},"key":"price[lt]","value":"1500"},{"disabled":true,"description":{"content":"<p>Query for tour ratings. Supports gte, lte, gt, lt operators.</p>\n","type":"text/plain"},"key":"ratingsAverage[gte]","value":"4.7"},{"disabled":true,"description":{"content":"<p>Query for tour result limit</p>\n","type":"text/plain"},"key":"limit","value":"5"},{"key":"price","value":"2997"}],"variable":[]}},"response":[],"_postman_id":"8d52b419-8058-4907-8b5b-78617bbfb6e8"},{"name":"Selecting by Fields","id":"5beda787-00db-42ce-b75e-62d91cf57bdc","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Content-Type","name":"Content-Type","type":"text","value":"application/json"}],"url":"{{URL}}api/v1/tours?fields=price,duration&sort=price,duration","description":"<p>Use this endpoint to get all tours.</p>\n","urlObject":{"path":["v1","tours"],"host":["{{URL}}api"],"query":[{"disabled":true,"description":{"content":"<p>Query for tour price. Supports gte, lte, gt, lt operators.</p>\n","type":"text/plain"},"key":"price[lt]","value":"1500"},{"disabled":true,"description":{"content":"<p>Query for tour ratings. Supports gte, lte, gt, lt operators.</p>\n","type":"text/plain"},"key":"ratingsAverage[gte]","value":"4.7"},{"disabled":true,"description":{"content":"<p>Query for tour result limit</p>\n","type":"text/plain"},"key":"limit","value":"5"},{"key":"fields","value":"price,duration"},{"key":"sort","value":"price,duration"}],"variable":[]}},"response":[],"_postman_id":"5beda787-00db-42ce-b75e-62d91cf57bdc"},{"name":"Pagination in Tour Data","id":"e8f1f08a-2716-4d66-bd93-afb4c238e0c2","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Content-Type","name":"Content-Type","type":"text","value":"application/json"}],"url":"{{URL}}api/v1/tours?limit=5&page=2","description":"<p>Use this endpoint to get all tours.</p>\n","urlObject":{"path":["v1","tours"],"host":["{{URL}}api"],"query":[{"disabled":true,"description":{"content":"<p>Query for tour price. Supports gte, lte, gt, lt operators.</p>\n","type":"text/plain"},"key":"price[lt]","value":"1500"},{"disabled":true,"description":{"content":"<p>Query for tour ratings. Supports gte, lte, gt, lt operators.</p>\n","type":"text/plain"},"key":"ratingsAverage[gte]","value":"4.7"},{"description":{"content":"<p>Query for tour result limit</p>\n","type":"text/plain"},"key":"limit","value":"5"},{"key":"page","value":"2"}],"variable":[]}},"response":[],"_postman_id":"e8f1f08a-2716-4d66-bd93-afb4c238e0c2"},{"name":"Get Tour Stats","id":"a57d6377-6bdc-4e74-8894-6c307a48af96","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"{{URL}}api/v1/tours/tour-stats","description":"<p>Use this endpoint to get tour statistics based on tour difficulty.</p>\n","urlObject":{"path":["v1","tours","tour-stats"],"host":["{{URL}}api"],"query":[],"variable":[]}},"response":[],"_postman_id":"a57d6377-6bdc-4e74-8894-6c307a48af96"},{"name":"Get Top 5 Cheap Tours","id":"277f62ed-1580-4d18-b306-e4f14dedb1b5","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"auth":{"type":"noauth","isInherited":false},"method":"GET","header":[],"url":"{{URL}}api/v1/tours/top-5-cheap","description":"<p>Use this endpoint to get the details of 5 cheapest tour.</p>\n","urlObject":{"path":["v1","tours","top-5-cheap"],"host":["{{URL}}api"],"query":[],"variable":[]}},"response":[],"_postman_id":"277f62ed-1580-4d18-b306-e4f14dedb1b5"},{"name":"Get Tours Within Radius","id":"56c59757-2502-4aa6-a46c-a097511482b0","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"{{URL}}api/v1/tours/tours-within/200/center/34.098453,-118.096327/unit/km","description":"<p>Use this endpoint to get tours within a certain radius by defining the distance (Eg. 200 miles) and the coordinates (latitude and longitude).</p>\n","urlObject":{"path":["v1","tours","tours-within","200","center","34.098453,-118.096327","unit","km"],"host":["{{URL}}api"],"query":[],"variable":[]}},"response":[],"_postman_id":"56c59757-2502-4aa6-a46c-a097511482b0"},{"name":"Get Distances to Tours From Point","id":"8f9ac068-d8e6-4437-a346-1eefdc5eac7f","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"{{URL}}api/v1/tours/distances/8.897233611359383, 76.59806649855234/unit/mi","description":"<p>Use this endpoint to get all tours distance from the specified coordinates.</p>\n","urlObject":{"path":["v1","tours","distances","8.897233611359383, 76.59806649855234","unit","mi"],"host":["{{URL}}api"],"query":[],"variable":[]}},"response":[],"_postman_id":"8f9ac068-d8e6-4437-a346-1eefdc5eac7f"},{"name":"Get Monthly Plan","id":"30c04a3a-89c6-4d80-baa6-ca819ae1000f","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{jwt}}"}]},"isInherited":false},"method":"GET","header":[],"url":"{{URL}}api/v1/tours/monthly-plan/2021","description":"<p>Use this endpoint to get monthly plan by year <br />(Requires login by admin, lead-guide, or guide)</p>\n","urlObject":{"path":["v1","tours","monthly-plan","2021"],"host":["{{URL}}api"],"query":[],"variable":[]}},"response":[],"_postman_id":"30c04a3a-89c6-4d80-baa6-ca819ae1000f"},{"name":"Update Tours","id":"0e18b34e-d63f-4005-82ba-5dc48a7aa619","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{jwt}}"}]},"isInherited":false},"method":"PATCH","header":[{"key":"Content-Type","name":"Content-Type","value":"application/json","type":"text"}],"body":{"mode":"raw","raw":"{\n\t\"maxGroupSize\": 12,\n\t\"difficulty\": \"easy\",\n\t\"imageCover\": \"tour-5-cover.jpg\",\n\t\"price\": 1497\n}"},"url":"{{URL}}api/v1/tours/5d906cba5428cc0f18a596e2","description":"<p>Use this endpoint to update an existing tour <br />(Requires login as admin or lead-guide)</p>\n","urlObject":{"path":["v1","tours","5d906cba5428cc0f18a596e2"],"host":["{{URL}}api"],"query":[],"variable":[]}},"response":[],"_postman_id":"0e18b34e-d63f-4005-82ba-5dc48a7aa619"},{"name":"Create New Tours","id":"0db8ba8c-d38b-4a62-aad2-ad14d936d54b","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{jwt}}"}]},"isInherited":false},"method":"POST","header":[{"key":"Content-Type","name":"Content-Type","value":"application/json","type":"text"}],"body":{"mode":"raw","raw":"{   \r\n    \"name\": \"The Southern Lights\",\r\n    \"duration\": 3,\r\n    \"maxGroupSize\": 12,\r\n    \"difficulty\": \"easy\",\r\n    \"price\": 2000,\r\n    \"summary\": \"Enjoy the Southern Lights in one of the best places in the world\",\r\n    \"imageCover\": \"tour-4-cover.jpg\",\r\n    \"startLocation\": {\r\n        \"type\": \"Point\",\r\n        \"description\": \"Yellowknife, CAN\",\r\n        \"coordinates\": [-114.406097, 62.439943],\r\n        \"address\": \"Yellowknife, NT X1A 2L2, Canada\"\r\n    },\r\n    \"startDates\": [\"2021-08-05T09:00:00.000Z\",\"2022-03-20T10:00:00.000Z\",\"2022-08-12T09:00:00.000Z\"],\r\n    \"locations\": [\r\n                    {\r\n                        \"coordinates\": [-80.128473,25.781842],\r\n                        \"description\": \"Lummus Park Beach\",\r\n                        \"day\": 1\r\n                    },\r\n                    {\r\n                        \"type\": \"Point\",\r\n                        \"coordinates\": [-80.647885,24.909047],\r\n                        \"description\": \"Islamorada\",\r\n                        \"day\": 2\r\n                    },\r\n                    {\r\n                        \"coordinates\": [-81.0784,24.707496],\r\n                        \"description\": \"Sombrero Beach\",\r\n                        \"day\": 3\r\n                    },\r\n                    {\r\n                        \"coordinates\": [-81.768719,24.552242],\r\n                        \"description\": \"West Key\",\r\n                        \"day\": 5\r\n                    }\r\n                ],\r\n    \"images\": [\"tour-4-1.jpg\", \"tour-9-2.jpg\", \"tour-2-3.jpg\"],\r\n    \"guides\": [ \"5c8a21f22f8fb814b56fa18a\",\"5c8a201e2f8fb814b56fa186\"],\r\n    \"description\": \"Sed do eiusmod tempor incididunt ut labore et dolore magna aliqua, ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum!\\nDolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur, exercitation ullamco laboris nisi ut aliquip. Lorem ipsum dolor sit amet, consectetur adipisicing elit!\"\r\n \r\n}"},"url":"{{URL}}api/v1/tours","description":"<p>Use this endpoint to create a new tour. <br />\n(Requires login as admin or lead-guide)</p>\n","urlObject":{"path":["v1","tours"],"host":["{{URL}}api"],"query":[],"variable":[]}},"response":[],"_postman_id":"0db8ba8c-d38b-4a62-aad2-ad14d936d54b"},{"name":"Delete Tours","id":"d6d573ce-4402-468f-8585-50d3292f9397","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{jwt}}"}]},"isInherited":false},"method":"DELETE","header":[],"url":"{{URL}}api/v1/tours/5c88fa8cf4afda39709c2955","description":"<p>Use this endpoint to delete an existing tour <br />(Requires login as admin or lead-guide)</p>\n","urlObject":{"path":["v1","tours","5c88fa8cf4afda39709c2955"],"host":["{{URL}}api"],"query":[],"variable":[]}},"response":[],"_postman_id":"d6d573ce-4402-468f-8585-50d3292f9397"}],"id":"e9282d15-7b64-40e6-9acd-d7affafe217c","description":"<p><strong>You can get all tours, create new ones, and edit and delete tour.</strong> \nThere are also special endpoints for some special requirements.</p>\n","event":[{"listen":"prerequest","script":{"id":"d4733346-fbcd-4975-a049-6b178e890698","type":"text/javascript","exec":[""]}},{"listen":"test","script":{"id":"ccd1fddf-9299-491a-83cd-e5d066f96a2c","type":"text/javascript","exec":[""]}}],"_postman_id":"e9282d15-7b64-40e6-9acd-d7affafe217c"},{"name":"Users","item":[{"name":"Get All User","id":"471bb0fb-cd76-4d90-a4f6-91951ca8e5d0","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{jwt}}"}]},"isInherited":false},"method":"GET","header":[],"url":"{{URL}}api/v1/users","description":"<p>Use this endpoint to get all users. <br />(Requires login as admin)</p>\n","urlObject":{"path":["v1","users"],"host":["{{URL}}api"],"query":[],"variable":[]}},"response":[],"_postman_id":"471bb0fb-cd76-4d90-a4f6-91951ca8e5d0"},{"name":"Get User","id":"0814da3e-d2eb-4edc-a688-24383285df65","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{jwt}}"}]},"isInherited":false},"method":"GET","header":[{"key":"Content-Type","name":"Content-Type","value":"application/json","type":"text"}],"body":{"mode":"raw","raw":""},"url":"{{URL}}api/v1/users/5c8a1e1a2f8fb814b56fa182","description":"<p>Use this endpoint to get details of a certain user. <br />(Requires login as admin)</p>\n","urlObject":{"path":["v1","users","5c8a1e1a2f8fb814b56fa182"],"host":["{{URL}}api"],"query":[],"variable":[]}},"response":[],"_postman_id":"0814da3e-d2eb-4edc-a688-24383285df65"},{"name":"Update User","id":"e2c3ea5c-e5e0-4856-a603-d860a2363a91","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{jwt}}"}]},"isInherited":false},"method":"PATCH","header":[{"key":"Content-Type","name":"Content-Type","type":"text","value":"application/json"}],"body":{"mode":"raw","raw":"{\n\t\"name\": \"Dimple\",\n    \"email\":\"dimple@gmail.com\"\n}"},"url":"{{URL}}api/v1/users/5c8a1dfa2f8fb814b56fa181","description":"<p>Use this endpoint to update a user. <br />(Requires login as admin)</p>\n","urlObject":{"path":["v1","users","5c8a1dfa2f8fb814b56fa181"],"host":["{{URL}}api"],"query":[],"variable":[]}},"response":[],"_postman_id":"e2c3ea5c-e5e0-4856-a603-d860a2363a91"},{"name":"Delete User","id":"d3f46922-1839-48ef-aef0-8bc0b9a3bf74","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{jwt}}"}]},"isInherited":false},"method":"DELETE","header":[],"url":"{{URL}}api/v1/users/5c8a211f2f8fb814b56fa188","description":"<p>Use this endpoint to delete a user. <br />(Requires login as admin)</p>\n","urlObject":{"path":["v1","users","5c8a211f2f8fb814b56fa188"],"host":["{{URL}}api"],"query":[],"variable":[]}},"response":[],"_postman_id":"d3f46922-1839-48ef-aef0-8bc0b9a3bf74"},{"name":"Get Me","id":"ad9f3bf3-cbc4-4a95-84a9-8ee7fd1543bc","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{jwt}}"}]},"isInherited":false},"method":"GET","header":[],"url":"{{URL}}api/v1/users/me","description":"<p>Use this endpoint to get details of current logged-in user. <br />(Requires login)</p>\n","urlObject":{"path":["v1","users","me"],"host":["{{URL}}api"],"query":[],"variable":[]}},"response":[],"_postman_id":"ad9f3bf3-cbc4-4a95-84a9-8ee7fd1543bc"},{"name":"Update Me","event":[{"listen":"test","script":{"id":"9620405f-41eb-4c46-a09c-dff939fd387a","exec":["pm.environment.set(\"jwt\", pm.response.json().token);"],"type":"text/javascript"}}],"id":"1917ae5b-0110-4e9c-b268-3676154819e7","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{jwt}}"}]},"isInherited":false},"method":"PATCH","header":[{"key":"Content-Type","name":"Content-Type","value":"application/json","type":"text"}],"body":{"mode":"formdata","formdata":[{"key":"name","value":"admin","type":"text"},{"key":"photo","type":"file","src":"/Users/mintukrishnan/Documents/PHOTO/mintu new copy.jpg"}]},"url":"{{URL}}api/v1/users/updateMe","description":"<p>Use this endpoint to update details of current logged-in user. <br />(Requires login)</p>\n","urlObject":{"path":["v1","users","updateMe"],"host":["{{URL}}api"],"query":[],"variable":[]}},"response":[],"_postman_id":"1917ae5b-0110-4e9c-b268-3676154819e7"},{"name":"Delete Me","id":"9c6227e1-e7b2-4cdd-b984-cb95968f1ede","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{jwt}}"}]},"isInherited":false},"method":"DELETE","header":[],"url":"{{URL}}api/v1/users/deleteMe","description":"<p>Use this endpoint to deactivating the current logged-in user account temporarily. <br />(Requires login)</p>\n","urlObject":{"path":["v1","users","deleteMe"],"host":["{{URL}}api"],"query":[],"variable":[]}},"response":[],"_postman_id":"9c6227e1-e7b2-4cdd-b984-cb95968f1ede"}],"id":"fd57c7ed-d266-42f1-8fc3-df00b02e74dd","description":"<p>You can get your user profile details, update and delete your account. There are also special endpoints for some special requirements which can only be accessed by the administrator.</p>\n","event":[{"listen":"prerequest","script":{"id":"0ebbf9d1-3240-404e-8f13-b95062ad4ff6","type":"text/javascript","exec":[""]}},{"listen":"test","script":{"id":"b8aef6e3-18e4-4d92-820e-7b17dede7312","type":"text/javascript","exec":[""]}}],"_postman_id":"fd57c7ed-d266-42f1-8fc3-df00b02e74dd"},{"name":"Authentication","item":[{"name":"Sign Up","event":[{"listen":"test","script":{"id":"48602640-e13a-41e0-9ab6-0a838c27af79","exec":["pm.environment.set(\"jwt\", pm.response.json().token);",""],"type":"text/javascript"}}],"id":"4eeacecb-7b69-41da-856e-67ad7b31816d","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"Content-Type","name":"Content-Type","type":"text","value":"application/json"}],"body":{"mode":"raw","raw":" {\r\n    \"name\": \"dimple\",\r\n    \"email\": \"dimple@gmail.com\",\r\n    \"password\": \"dimple12345\",\r\n    \"passwordConfirm\": \"dimple12345\"\r\n  }"},"url":"{{URL}}api/v1/users/signup","description":"<p>Use this endpoint to create new user.</p>\n","urlObject":{"path":["v1","users","signup"],"host":["{{URL}}api"],"query":[],"variable":[]}},"response":[],"_postman_id":"4eeacecb-7b69-41da-856e-67ad7b31816d"},{"name":"Login","event":[{"listen":"test","script":{"id":"ea32dd0e-8a8b-4102-91f8-c8cde799b6d6","exec":["pm.environment.set(\"jwt\", pm.response.json().token);"],"type":"text/javascript"}}],"id":"dc741340-7796-47fa-bd39-34c327d5c353","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"Content-Type","name":"Content-Type","value":"application/json","type":"text"}],"body":{"mode":"raw","raw":"{\n\t\"email\":\"user@gmail.com\",\n\t\"password\": \"{{password}}\"\n}"},"url":"{{URL}}api/v1/users/login","description":"<p>Use this endpoint to log in.</p>\n","urlObject":{"path":["v1","users","login"],"host":["{{URL}}api"],"query":[{"disabled":true,"key":"email","value":"admin@travel.in"},{"disabled":true,"key":"password","value":"admin12345"}],"variable":[]}},"response":[],"_postman_id":"dc741340-7796-47fa-bd39-34c327d5c353"},{"name":"LogOut","event":[{"listen":"test","script":{"id":"fc567ab2-9d70-460a-b83e-77187b0c42b4","exec":["pm.environment.set(\"jwt\", pm.response.json().token);"],"type":"text/javascript"}}],"id":"76ea5447-b419-4158-b1f4-b5050a56de91","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"Content-Type","name":"Content-Type","value":"application/json","type":"text"}],"body":{"mode":"raw","raw":"{\n\t\"email\":\"dimple@gmail.com\",\n\t\"password\": \"{{upassword}}\"\n}"},"url":"{{URL}}api/v1/users/logout","description":"<p>Use this endpoint to log in.</p>\n","urlObject":{"path":["v1","users","logout"],"host":["{{URL}}api"],"query":[{"disabled":true,"key":"email","value":"admin@travel.in"},{"disabled":true,"key":"password","value":"admin12345"}],"variable":[]}},"response":[],"_postman_id":"76ea5447-b419-4158-b1f4-b5050a56de91"},{"name":"Forgot Password","event":[{"listen":"test","script":{"id":"6651efed-7311-48c0-bb1c-471e3f6ae55c","exec":["pm.environment.set(\"jwt\", pm.response.json().token);",""],"type":"text/javascript"}}],"id":"58de9ed0-5551-41da-934d-396a30a30144","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"Content-Type","name":"Content-Type","value":"application/json","type":"text"}],"body":{"mode":"raw","raw":"{\n\t\"email\": \"admin@travel.in\"\n}"},"url":"{{URL}}api/v1/users/forgotPassword","description":"<p>Use this endpoint to send reset password request to the specified email.</p>\n","urlObject":{"path":["v1","users","forgotPassword"],"host":["{{URL}}api"],"query":[],"variable":[]}},"response":[],"_postman_id":"58de9ed0-5551-41da-934d-396a30a30144"},{"name":"Reset Password","event":[{"listen":"test","script":{"id":"17f36e63-3ed1-4603-9562-18c1cd195946","exec":["pm.environment.set(\"jwt\", pm.response.json().token);",""],"type":"text/javascript"}}],"id":"63f70001-5a76-40dd-b12a-29e390131c18","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PATCH","header":[{"key":"Content-Type","name":"Content-Type","value":"application/json","type":"text"}],"body":{"mode":"raw","raw":"{\n\t\"password\": \"admin12345\",\n\t\"passwordConfirm\": \"admin12345\"\n}"},"url":"{{URL}}api/v1/users/resetPassword/9184270e06275689d64db839057ad8afe661ba44bef6c8193e47716c94395476","description":"<p>Use this endpoint to reset the password by using the forgot-password link sent to your email.</p>\n","urlObject":{"path":["v1","users","resetPassword","9184270e06275689d64db839057ad8afe661ba44bef6c8193e47716c94395476"],"host":["{{URL}}api"],"query":[],"variable":[]}},"response":[],"_postman_id":"63f70001-5a76-40dd-b12a-29e390131c18"},{"name":"Update Current User Password","event":[{"listen":"test","script":{"id":"68d80148-5798-4276-a5c0-a2158c498b00","exec":["pm.environment.set(\"jwt\", pm.response.json().token);"],"type":"text/javascript"}}],"id":"5e8d9c5f-753b-4555-901a-ca0328ada64b","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{jwt}}"}]},"isInherited":false},"method":"PATCH","header":[{"key":"Content-Type","name":"Content-Type","value":"application/json","type":"text"}],"body":{"mode":"raw","raw":"{\n\t\"passwordCurrent\": \"12345678\",\n\t\"password\": \"admin12345\",\n\t\"passwordConfirm\": \"admin12345\"\n}"},"url":"{{URL}}api/v1/users/updateMyPassword","description":"<p>Use this endpoint to update your password. <br />(Requires login)</p>\n","urlObject":{"path":["v1","users","updateMyPassword"],"host":["{{URL}}api"],"query":[],"variable":[]}},"response":[],"_postman_id":"5e8d9c5f-753b-4555-901a-ca0328ada64b"}],"id":"c35c1668-6634-4b1c-a20e-183271c5ac8c","description":"<p>You can sign up, login, perform forgot password request, update password and reset your password.</p>\n","event":[{"listen":"prerequest","script":{"id":"e7edc094-84e5-4f25-affc-c1e29f66a52d","type":"text/javascript","exec":[""]}},{"listen":"test","script":{"id":"3e78b0c2-c5aa-4750-8320-49a6e96ff3be","type":"text/javascript","exec":[""]}}],"_postman_id":"c35c1668-6634-4b1c-a20e-183271c5ac8c"},{"name":"Reviews","item":[{"name":"Get All Reviews","id":"c1745dc9-8730-4ad2-ab46-538fb88a3a55","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{jwt}}"}]},"isInherited":false},"method":"GET","header":[],"url":"{{URL}}api/v1/reviews","description":"<p>Use this endpoint to get all reviews. <br />(Requires login)</p>\n","urlObject":{"path":["v1","reviews"],"host":["{{URL}}api"],"query":[],"variable":[]}},"response":[],"_postman_id":"c1745dc9-8730-4ad2-ab46-538fb88a3a55"},{"name":"Get Review","id":"2a72eee2-baf4-414f-87d0-c0a3b6c610be","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{jwt}}"}]},"isInherited":false},"method":"GET","header":[],"url":"{{URL}}api/v1/reviews/5c8a3e63e12c44188b4dbc5b","description":"<p>Use this endpoint to get a specific review. <br />(Requires login)</p>\n","urlObject":{"path":["v1","reviews","5c8a3e63e12c44188b4dbc5b"],"host":["{{URL}}api"],"query":[],"variable":[]}},"response":[],"_postman_id":"2a72eee2-baf4-414f-87d0-c0a3b6c610be"},{"name":"Create New Review","id":"2b13e2e9-33b2-4ceb-8a8c-706e1fa1b597","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{jwt}}"}]},"isInherited":false},"method":"POST","header":[{"key":"Content-Type","name":"Content-Type","type":"text","value":"application/json"}],"body":{"mode":"raw","raw":"{\n\t\"review\":\"Amazing!\",\n\t\"rating\": 4,\n\t\"tour\": \"5c88fa8cf4afda39709c2952\",\n\t\"user\": \"5c8a23de2f8fb814b56fa18e\"\n}"},"url":"{{URL}}api/v1/reviews","description":"<p>Use this endpoint to create a new review. <br />(Requires login as user)</p>\n","urlObject":{"path":["v1","reviews"],"host":["{{URL}}api"],"query":[],"variable":[]}},"response":[],"_postman_id":"2b13e2e9-33b2-4ceb-8a8c-706e1fa1b597"},{"name":"Update Review","id":"32d55b24-b8dd-443a-b53b-5c0cd0165e10","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{jwt}}"}]},"isInherited":false},"method":"PATCH","header":[{"key":"Content-Type","name":"Content-Type","value":"application/json","type":"text"}],"body":{"mode":"raw","raw":"{\n\t\"rating\": 2\n}"},"url":"{{URL}}api/v1/reviews/5d89f80211557e1af8c08539","description":"<p>Use this endpoint to update a review. <br />(Requires login as user or admin)</p>\n","urlObject":{"path":["v1","reviews","5d89f80211557e1af8c08539"],"host":["{{URL}}api"],"query":[],"variable":[]}},"response":[],"_postman_id":"32d55b24-b8dd-443a-b53b-5c0cd0165e10"},{"name":"Delete Review","id":"b7048d34-2880-4007-a47d-225b6cb355a4","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{jwt}}"}]},"isInherited":false},"method":"DELETE","header":[],"url":"{{URL}}api/v1/reviews/5d89f748e835c81f685bc5a3","description":"<p>Use this endpoint to delete a review. <br />(Requires login as user or admin)</p>\n","urlObject":{"path":["v1","reviews","5d89f748e835c81f685bc5a3"],"host":["{{URL}}api"],"query":[],"variable":[]}},"response":[],"_postman_id":"b7048d34-2880-4007-a47d-225b6cb355a4"}],"id":"844e370a-7baf-4e9f-a552-d6d44995cfb0","description":"<p>You can get all reviews or a specific review, create a new one, update and delete the review. These endpoints can only be used by administrator or lead-guide.</p>\n","event":[{"listen":"prerequest","script":{"id":"b2ee822f-22cf-4730-9d70-170662749db8","type":"text/javascript","exec":[""]}},{"listen":"test","script":{"id":"09e35448-1665-4159-b8e1-dd95d4ce193f","type":"text/javascript","exec":[""]}}],"_postman_id":"844e370a-7baf-4e9f-a552-d6d44995cfb0"},{"name":"Tours/Review","item":[{"name":"Create New Review on Tour","id":"6d8228c8-9655-4db7-a490-fcc36a0e9867","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{jwt}}"}]},"isInherited":false},"method":"POST","header":[{"key":"Content-Type","name":"Content-Type","type":"text","value":"application/json"}],"body":{"mode":"raw","raw":"{\n\t\"rating\":5,\n\t\"review\": \"Awesome tour\" \n}"},"url":"{{URL}}api/v1/tours/6052516bf527c3bd28d59acb/reviews","description":"<p>Use this endpoint to create a new review on a tour. <br />(Requires login as user or admin)</p>\n","urlObject":{"path":["v1","tours","6052516bf527c3bd28d59acb","reviews"],"host":["{{URL}}api"],"query":[],"variable":[]}},"response":[],"_postman_id":"6d8228c8-9655-4db7-a490-fcc36a0e9867"},{"name":"Get All Reviews on Tour","id":"df2869fe-eb17-460c-ad26-ec19a570e984","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{jwt}}"}]},"isInherited":false},"method":"GET","header":[],"url":"{{URL}}api/v1/tours/5c88fa8cf4afda39709c2951/reviews","description":"<p>Use this endpoint to get all reviews on a tour. <br />(Requires login as user or admin)</p>\n","urlObject":{"path":["v1","tours","5c88fa8cf4afda39709c2951","reviews"],"host":["{{URL}}api"],"query":[],"variable":[]}},"response":[],"_postman_id":"df2869fe-eb17-460c-ad26-ec19a570e984"}],"id":"b0399182-e58e-4696-937b-c8f162a7431e","description":"<p>You can create a new review for a specific tour and get all reviews associated with a tour. These endpoints can only be accessed by administrator or lead-guide.</p>\n","event":[{"listen":"prerequest","script":{"id":"99e066a8-5af0-4071-bf23-73b5f29276dd","type":"text/javascript","exec":[""]}},{"listen":"test","script":{"id":"e5e4976d-708d-43eb-bbec-c1f58a103dd8","type":"text/javascript","exec":[""]}}],"_postman_id":"b0399182-e58e-4696-937b-c8f162a7431e"},{"name":"Bookings","item":[{"name":"Get All Bookings","id":"61ddc054-e41e-4134-84a5-e4722cea5ede","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{jwt}}"}]},"isInherited":false},"method":"GET","header":[],"url":"{{URL}}api/v1/bookings","description":"<p>Use this endpoint to get all tour bookings. <br />(Requires login as admin or lead-guide)</p>\n","urlObject":{"path":["v1","bookings"],"host":["{{URL}}api"],"query":[],"variable":[]}},"response":[],"_postman_id":"61ddc054-e41e-4134-84a5-e4722cea5ede"},{"name":"Get Booking","id":"c448a9b1-a4b4-4a7a-b442-6d5e329ed588","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{jwt}}"}]},"isInherited":false},"method":"GET","header":[],"url":"{{URL}}api/v1/bookings/5d91a149e0dc65067883cc14","description":"<p>Use this endpoint to get a specific tour booking. <br />(Requires login as admin or lead-guide)</p>\n","urlObject":{"path":["v1","bookings","5d91a149e0dc65067883cc14"],"host":["{{URL}}api"],"query":[],"variable":[]}},"response":[],"_postman_id":"c448a9b1-a4b4-4a7a-b442-6d5e329ed588"},{"name":"Get Booking Copy","id":"e8bd62e3-87b1-4d5a-9d96-be15e634458a","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"{{jwt}}"}]},"isInherited":false},"method":"GET","header":[],"url":"{{URL}}api/v1/bookings/checkout-session/5c88fa8cf4afda39709c2955","description":"<p>Use this endpoint to get a specific tour booking. <br />(Requires login as admin or lead-guide)</p>\n","urlObject":{"path":["v1","bookings","checkout-session","5c88fa8cf4afda39709c2955"],"host":["{{URL}}api"],"query":[],"variable":[]}},"response":[],"_postman_id":"e8bd62e3-87b1-4d5a-9d96-be15e634458a"}],"id":"8abcd064-fc72-4617-94fa-635a16455406","description":"<p>You can get all bookings or a specific one. These endpoints can only be accessed by administrator or lead-guide.</p>\n","event":[{"listen":"prerequest","script":{"id":"d33363a0-fc72-4587-8f9a-4b3f50453d61","type":"text/javascript","exec":[""]}},{"listen":"test","script":{"id":"36555a7e-da73-4b8f-855e-d47736661c04","type":"text/javascript","exec":[""]}}],"_postman_id":"8abcd064-fc72-4617-94fa-635a16455406"},{"name":"Error Handling","item":[{"name":"Error Handling","id":"a2f7f22f-1a5e-41a0-a4a6-9c394cfa511f","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"http://localhost:3000/api/v1/tour","description":"<p>Use this endpoint to get a specific tour details using its tourID.</p>\n","urlObject":{"protocol":"http","port":"3000","path":["api","v1","tour"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"a2f7f22f-1a5e-41a0-a4a6-9c394cfa511f"},{"name":"Create User","id":"d61adb59-72da-4864-9cef-c08c3bc405a9","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"url":"{{URL}}api/v1/users","description":"<p>Use this endpoint to get a specific tour details using its tourID.</p>\n","urlObject":{"path":["v1","users"],"host":["{{URL}}api"],"query":[],"variable":[]}},"response":[],"_postman_id":"d61adb59-72da-4864-9cef-c08c3bc405a9"}],"id":"6fd5d3f8-c56c-4be2-9bf6-c48f170dfbbf","_postman_id":"6fd5d3f8-c56c-4be2-9bf6-c48f170dfbbf","description":""}],"event":[{"listen":"prerequest","script":{"id":"c4045d03-c40c-478b-bd91-383fc7c93ad0","type":"text/javascript","exec":[""]}},{"listen":"test","script":{"id":"fb49b8c9-1781-41b7-aac8-e9fd9a911e84","type":"text/javascript","exec":[""]}}]}