{"info":{"_postman_id":"ca4264f9-901f-45e9-baad-913b87b741ef","name":"Blog API","description":"<html><head></head><body><h2 id=\"this-is-the-full-documentation-of-this-simple-blog-api\"><strong>This is the full documentation of this simple Blog API</strong></h2>\n<p>Feel free to clone the repo on GitHub and test it out on Postman 🚀</p>\n<p>The API enables users to register and sends them a verification code to use to verify their email address.</p>\n<p>A user can make a post, delete a post, comment and like posts!!</p>\n<p>The API comes with all the functionality!!</p>\n<p>You can reach me:</p>\n<p>📞: +2348186513024</p>\n<p>📧: <a href=\"mailto:akinloluwaolumuyide@mail.com\">akinloluwaolumuyide@mail.com</a></p>\n<p>💻: <a href=\"https://github.com/pick-cee/BLOG-API\">https://github.com/pick-cee/BLOG-API</a></p>\n</body></html>","schema":"https://schema.getpostman.com/json/collection/v2.0.0/collection.json","toc":[],"owner":"16987750","collectionId":"ca4264f9-901f-45e9-baad-913b87b741ef","publishedId":"VUxRQmph","public":true,"customColor":{"top-bar":"FFFFFF","right-sidebar":"303030","highlight":"EF5B25"},"publishDate":"2022-09-02T22:21:19.000Z"},"item":[{"name":"Users","item":[{"name":"Register User","id":"ace9ec8f-582c-4c5f-8ef0-fb98118dc474","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\r\n    \"fullname\": \"Akinloluwa Olumuyide\",\r\n    \"email\": \"akinloluwaolumuyide@gmail.com\",\r\n    \"password\": \"AKIN\"\r\n}","options":{"raw":{"language":"json"}}},"url":"localhost:5000/blog/register","urlObject":{"port":"5000","path":["blog","register"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"ace9ec8f-582c-4c5f-8ef0-fb98118dc474"},{"name":"Login User","id":"95852077-8f77-4530-930c-70cca99829bb","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\r\n    \"email\": \"akinloluwaolumuyide@gmail.com\",\r\n    \"password\": \"AKIN\"\r\n}","options":{"raw":{"language":"json"}}},"url":"localhost:5000/blog/login","urlObject":{"port":"5000","path":["blog","login"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"95852077-8f77-4530-930c-70cca99829bb"},{"name":"Resend Token","id":"4db6ce9e-add9-4fe1-9378-cb8578acff40","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\r\n    \r\n}","options":{"raw":{"language":"json"}}},"url":"localhost:5000/blog/resendToken?userId=62f6da6cc92c5037cc7e709b","urlObject":{"port":"5000","path":["blog","resendToken"],"host":["localhost"],"query":[{"key":"userId","value":"62f6da6cc92c5037cc7e709b"}],"variable":[]}},"response":[],"_postman_id":"4db6ce9e-add9-4fe1-9378-cb8578acff40"},{"name":"Verify Email Address","id":"bcac902a-8f22-4cec-8cb6-8eceb3c43144","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\r\n    \"token\": \"M1Z2koBnWXpzdJnP\"\r\n}","options":{"raw":{"language":"json"}}},"url":"localhost:5000/blog/verifyEmail?id=62f6f3f25a0750a7767d5d64","urlObject":{"port":"5000","path":["blog","verifyEmail"],"host":["localhost"],"query":[{"key":"id","value":"62f6f3f25a0750a7767d5d64"}],"variable":[]}},"response":[],"_postman_id":"bcac902a-8f22-4cec-8cb6-8eceb3c43144"},{"name":"Forgot Password","id":"fdee63e2-59af-45cb-bc29-69a1c7e52124","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\r\n    \"email\": \"akinloluwaolumuyide@gmail.com\"\r\n}","options":{"raw":{"language":"json"}}},"url":"localhost:5000/blog/forgotPassword","urlObject":{"port":"5000","path":["blog","forgotPassword"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"fdee63e2-59af-45cb-bc29-69a1c7e52124"},{"name":"Reset password","id":"59bdea83-26e8-4bb5-a3f1-6cbf6d71aec0","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\r\n    \"token\": \"O5ZFmYiE0DjWvQ9N\",\r\n    \"password\": \"akin\",\r\n    \"confirmPassword\": \"akin\"\r\n}","options":{"raw":{"language":"json"}}},"url":"localhost:5000/blog/resetPassword","urlObject":{"port":"5000","path":["blog","resetPassword"],"host":["localhost"],"query":[],"variable":[]}},"response":[],"_postman_id":"59bdea83-26e8-4bb5-a3f1-6cbf6d71aec0"}],"id":"c73338b1-1876-4b23-96fa-621462a99ce7","description":"<h4 id=\"this-is-the-users-folder\">This is the Users folder</h4>\n<p>It contains all the possible operations a user can carry out</p>\n<h5 id=\"list-of-endpoints\">List of endpoints:</h5>\n<ol>\n<li><strong>Register User</strong>: This endpoint is used to create new users and send them a verification code to their mail address.</li>\n<li><strong>Login User</strong>: This endpoint is used to login users with their email and password. You must have verified your email before you can login.</li>\n<li><strong>Verify Email Address</strong>: This endpoint is used to verify the email address of the user.</li>\n<li><strong>Resend Token</strong>: The verification code token expires within 10 minutes, so this endpoint is used to request for another one.</li>\n<li><strong>Forgot Password</strong>: This endpoint is used when you need a reset token to reset your password. It sends it to the email provided.</li>\n<li><strong>Reset Password</strong>: This endpoint uses the token from the previous endpoint to reset the user password.</li>\n</ol>\n","_postman_id":"c73338b1-1876-4b23-96fa-621462a99ce7"},{"name":"Posts","item":[{"name":"Create Post","id":"0efdd06a-a413-46e6-bcfb-ca167449fefd","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"token","value":"bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJfaWQiOiI2MmY2ZGE2Y2M5MmM1MDM3Y2M3ZTcwOWIiLCJlbWFpbCI6ImFraW5sb2x1d2FvbHVtdXlpZGVAZ21haWwuY29tIiwiZnVsbG5hbWUiOiJBa2lubG9sdXdhIE9sdW11eWlkZSIsImlhdCI6MTY2MDM0OTU3Mn0.oxoeXFcb44zAJnAhJeFgDocc4QihgB1YClYsipNf9KM","type":"text"}],"body":{"mode":"raw","raw":"{\r\n    \"post\": \"Manchester city might just win the league if Arsenal does not flop 💀\"\r\n}","options":{"raw":{"language":"json"}}},"url":"localhost:5000/blog/post?userId=62f6da6cc92c5037cc7e709b","urlObject":{"port":"5000","path":["blog","post"],"host":["localhost"],"query":[{"key":"userId","value":"62f6da6cc92c5037cc7e709b"}],"variable":[]}},"response":[],"_postman_id":"0efdd06a-a413-46e6-bcfb-ca167449fefd"},{"name":"Delete Post","id":"efbe2fe1-96b7-4fdb-9218-e54275348750","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"DELETE","header":[{"key":"token","value":"bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJfaWQiOiI2MmY2ZGE2Y2M5MmM1MDM3Y2M3ZTcwOWIiLCJlbWFpbCI6ImFraW5sb2x1d2FvbHVtdXlpZGVAZ21haWwuY29tIiwiZnVsbG5hbWUiOiJBa2lubG9sdXdhIE9sdW11eWlkZSIsImlhdCI6MTY2MDM0OTU3Mn0.oxoeXFcb44zAJnAhJeFgDocc4QihgB1YClYsipNf9KM","type":"text"}],"url":"localhost:5000/blog/deletePost?userId=62f6da6cc92c5037cc7e709b&postId=631222d0a520f82f98b8592d","urlObject":{"port":"5000","path":["blog","deletePost"],"host":["localhost"],"query":[{"key":"userId","value":"62f6da6cc92c5037cc7e709b"},{"key":"postId","value":"631222d0a520f82f98b8592d"}],"variable":[]}},"response":[],"_postman_id":"efbe2fe1-96b7-4fdb-9218-e54275348750"},{"name":"Get all users post","id":"86164466-7e46-489f-a48f-a7abd02ddf57","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"token","value":"bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJfaWQiOiI2MmY2ZGE2Y2M5MmM1MDM3Y2M3ZTcwOWIiLCJlbWFpbCI6ImFraW5sb2x1d2FvbHVtdXlpZGVAZ21haWwuY29tIiwiZnVsbG5hbWUiOiJBa2lubG9sdXdhIE9sdW11eWlkZSIsImlhdCI6MTY2MDM0OTU3Mn0.oxoeXFcb44zAJnAhJeFgDocc4QihgB1YClYsipNf9KM","type":"text"}],"url":"localhost:5000/blog/getPost?userId=62f6da6cc92c5037cc7e709b","urlObject":{"port":"5000","path":["blog","getPost"],"host":["localhost"],"query":[{"key":"userId","value":"62f6da6cc92c5037cc7e709b"}],"variable":[]}},"response":[],"_postman_id":"86164466-7e46-489f-a48f-a7abd02ddf57"}],"id":"a03bee1d-abc5-47dc-b2e0-8bd17a0c1125","description":"<h4 id=\"this-is-the-post-folder\">This is the Post folder</h4>\n<p>It contains all the operations that can be carried out on a post.</p>\n<h5 id=\"list-of-endpoints\">List of endpoints:</h5>\n<ol>\n<li><strong>Create Post</strong>: This endpoint is used to create user specific post. It simply means only the logged in user can create a post.</li>\n<li><strong>Delete Post</strong>: This endpoint is used to delete a post created by a user. The user must be logged in for this to happen.</li>\n<li><strong>Get all users post</strong>: This endpoint is used to get all users specific posts, posts created by a specific user. User must be logged in.</li>\n</ol>\n","_postman_id":"a03bee1d-abc5-47dc-b2e0-8bd17a0c1125"},{"name":"Comments","item":[{"name":"Comment Post","id":"24f0fb59-341e-403a-af70-aa86c6e57950","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"token","value":"bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJfaWQiOiI2MmY2ZGE2Y2M5MmM1MDM3Y2M3ZTcwOWIiLCJlbWFpbCI6ImFraW5sb2x1d2FvbHVtdXlpZGVAZ21haWwuY29tIiwiZnVsbG5hbWUiOiJBa2lubG9sdXdhIE9sdW11eWlkZSIsImlhdCI6MTY2MDM0OTU3Mn0.oxoeXFcb44zAJnAhJeFgDocc4QihgB1YClYsipNf9KM","type":"text"}],"body":{"mode":"raw","raw":"{\r\n    \"comment\": \"Deffs!!!! Pep is the GOAT 🐐\"\r\n}","options":{"raw":{"language":"json"}}},"url":"localhost:5000/blog/commentPost?userId=62f6da6cc92c5037cc7e709b&postId=631222d0a520f82f98b8592d","urlObject":{"port":"5000","path":["blog","commentPost"],"host":["localhost"],"query":[{"key":"userId","value":"62f6da6cc92c5037cc7e709b"},{"key":"postId","value":"631222d0a520f82f98b8592d"}],"variable":[]}},"response":[],"_postman_id":"24f0fb59-341e-403a-af70-aa86c6e57950"},{"name":"Get Comment","id":"a80a98ca-96b5-41b3-875b-6e541eca3f7b","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"token","value":"bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJfaWQiOiI2MmY2ZGE2Y2M5MmM1MDM3Y2M3ZTcwOWIiLCJlbWFpbCI6ImFraW5sb2x1d2FvbHVtdXlpZGVAZ21haWwuY29tIiwiZnVsbG5hbWUiOiJBa2lubG9sdXdhIE9sdW11eWlkZSIsImlhdCI6MTY2MDM0OTMwM30.8OusLxdxdUz18_ZZYpl2wOSsOqXe70dd_eIZLZqrQPc","type":"text"}],"url":"localhost:5000/blog/getComment?postId=631217bf7040bd7a23814682","urlObject":{"port":"5000","path":["blog","getComment"],"host":["localhost"],"query":[{"key":"postId","value":"631217bf7040bd7a23814682"}],"variable":[]}},"response":[],"_postman_id":"a80a98ca-96b5-41b3-875b-6e541eca3f7b"},{"name":"Delete Comment","id":"1dfc3c23-6afb-407a-9536-b8fdc1ddc806","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"DELETE","header":[{"key":"token","value":"bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJfaWQiOiI2MmY2ZGE2Y2M5MmM1MDM3Y2M3ZTcwOWIiLCJlbWFpbCI6ImFraW5sb2x1d2FvbHVtdXlpZGVAZ21haWwuY29tIiwiZnVsbG5hbWUiOiJBa2lubG9sdXdhIE9sdW11eWlkZSIsImlhdCI6MTY2MDM0OTU3Mn0.oxoeXFcb44zAJnAhJeFgDocc4QihgB1YClYsipNf9KM","type":"text"}],"url":"localhost:5000/blog/deleteComment?commentId=6312235da520f82f98b85939&userId=62f6f3f25a0750a7767d5d64&postId=631222d0a520f82f98b8592d","urlObject":{"port":"5000","path":["blog","deleteComment"],"host":["localhost"],"query":[{"key":"commentId","value":"6312235da520f82f98b85939"},{"key":"userId","value":"62f6f3f25a0750a7767d5d64"},{"key":"postId","value":"631222d0a520f82f98b8592d"}],"variable":[]}},"response":[],"_postman_id":"1dfc3c23-6afb-407a-9536-b8fdc1ddc806"}],"id":"e06b87d3-2c7b-4cdc-815f-076a7fa2f2c6","description":"<h4 id=\"this-is-the-comments-folder\">This is the Comments folder.</h4>\n<p>It contains all the possible operations that can be carried out on comments</p>\n<h5 id=\"list-of-endpoints\">List of endpoints:</h5>\n<ol>\n<li><strong>Comment Post:</strong> This endpoint allows users to comment on a post. All users must be logged in.</li>\n<li><strong>Get Comments</strong>: This endpoint is used to get all comments associated with a post.</li>\n<li><strong>Delete Comments</strong>: This endpoints deletes comments made by a specific user</li>\n</ol>\n","_postman_id":"e06b87d3-2c7b-4cdc-815f-076a7fa2f2c6"},{"name":"Likes","item":[{"name":"Like post","id":"6ebf1c0a-842b-47cd-be06-c3cb570a2c08","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"url":"localhost:5000/blog/likePost?postId=63122247b666c546ff9049f0&userId=62f6f3f25a0750a7767d5d64","urlObject":{"port":"5000","path":["blog","likePost"],"host":["localhost"],"query":[{"key":"postId","value":"63122247b666c546ff9049f0"},{"key":"userId","value":"62f6f3f25a0750a7767d5d64"}],"variable":[]}},"response":[],"_postman_id":"6ebf1c0a-842b-47cd-be06-c3cb570a2c08"},{"name":"Count post likes","id":"e8eee84c-aaeb-4b04-91c5-d5b3a5e61f5d","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"localhost:5000/blog/countPostLikes?postId=63122247b666c546ff9049f0","urlObject":{"port":"5000","path":["blog","countPostLikes"],"host":["localhost"],"query":[{"key":"postId","value":"63122247b666c546ff9049f0"}],"variable":[]}},"response":[],"_postman_id":"e8eee84c-aaeb-4b04-91c5-d5b3a5e61f5d"},{"name":"Delete likes from post","id":"a7363e5f-6ca7-4405-aadf-c28973446b93","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"DELETE","header":[],"url":"localhost:5000/blog/deleteLikesFromPost?postId=63122247b666c546ff9049f0&userId=62f6f3f25a0750a7767d5d64","urlObject":{"port":"5000","path":["blog","deleteLikesFromPost"],"host":["localhost"],"query":[{"key":"postId","value":"63122247b666c546ff9049f0"},{"key":"userId","value":"62f6f3f25a0750a7767d5d64"}],"variable":[]}},"response":[],"_postman_id":"a7363e5f-6ca7-4405-aadf-c28973446b93"}],"id":"4b552ae1-d2c3-4544-804a-07b47376cf3c","description":"<p>StartFragment</p>\n<h4 id=\"this-is-the-likes-folder\">This is the Likes folder.</h4>\n<p>It contains all the possible operations that can be carried out on likes</p>\n<h5 id=\"list-of-endpoints\">List of endpoints:</h5>\n<ol>\n<li><strong>Like Post:</strong> This endpoint allows users to comment on a post. All users must be logged in.</li>\n<li><strong>Get likes on a post</strong>: This endpoint is used to get all comments associated with a post.</li>\n<li><strong>Delete likes from a post</strong>: This endpoints deletes comments made by a specific user.</li>\n</ol>\n","_postman_id":"4b552ae1-d2c3-4544-804a-07b47376cf3c"}]}