{"info":{"_postman_id":"29e53be8-1e4d-40a6-be06-a6f873910494","name":"LinkTree API Implementation","description":"<html><head></head><body><h3 id=\"what-can-i-do-with-the-api\">What can I do with the API?</h3>\n<p>The core features of the API are:</p>\n<ul>\n<li>Login/Signup Users.</li>\n<li>Editing of Users profile.</li>\n<li>Creating/Editing/Updating/Deleting of Links.</li>\n</ul>\n<p>With the basic features above you can basically build a Linktree clone or at least the base features.</p>\n<h3 id=\"rate-limits\">Rate Limits</h3>\n<p>There are no rate limits set yet.</p>\n<p>Based on simple REST principles, this Web API endpoints return JSON metadata about users and links directly from the Database.</p>\n<h3 id=\"requests\">Requests</h3>\n<p>The Web API is based on REST principles. Data resources are accessed via standard HTTPS requests in UTF-8 format to an API endpoint. Where possible, Web API uses appropriate HTTP verbs for each action:</p>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>METHOD</th>\n<th>ACTION</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>GET</td>\n<td>Retrieves resources</td>\n</tr>\n<tr>\n<td>POST</td>\n<td>Creates resources</td>\n</tr>\n<tr>\n<td>PUT</td>\n<td>Changes and/or replaces resources or collections</td>\n</tr>\n<tr>\n<td>DELETE</td>\n<td>Deletes resources</td>\n</tr>\n</tbody>\n</table>\n</div><h3 id=\"responses\">Responses</h3>\n<p>Web API returns all response data as a JSON object. See the Web API Object Model for a description of all the retrievable objects.</p>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>STATUS CODE</th>\n<th>DESCRIPTION</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>200 OK</td>\n<td>The request has succeeded. The client can read the result of the request in the body and the headers of the response.</td>\n</tr>\n<tr>\n<td>201 Created</td>\n<td>The request has been fulfilled and resulted in a new resource being created.</td>\n</tr>\n<tr>\n<td>202 Accepted</td>\n<td>The request has been accepted for processing, but the processing has not been completed.</td>\n</tr>\n<tr>\n<td>204 No Content</td>\n<td>The request has succeeded but returns no message body.</td>\n</tr>\n<tr>\n<td>304 Not Modified. See Conditional requests.</td>\n<td></td>\n</tr>\n<tr>\n<td>400 Bad Request</td>\n<td>The request could not be understood by the server due to malformed syntax. The message body will contain more information; see Response Schema.</td>\n</tr>\n<tr>\n<td>401 Unauthorized</td>\n<td>The request requires user authentication or, if the request included authorization credentials, authorization has been refused for those credentials.</td>\n</tr>\n<tr>\n<td>403 Forbidden</td>\n<td>The server understood the request, but is refusing to fulfill it.</td>\n</tr>\n<tr>\n<td>404 Not Found</td>\n<td>The requested resource could not be found. This error can be due to a temporary or permanent condition.</td>\n</tr>\n<tr>\n<td>500 Internal Server Error. You should never receive this error because our clever coders catch them all … but if you are unlucky enough to get one, please report it to us through a comment at the bottom of this page.</td>\n<td></td>\n</tr>\n</tbody>\n</table>\n</div><h3 id=\"error-codes\">Error Codes</h3>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>Code</th>\n<th>Description</th>\n<th>Status</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>E001</td>\n<td>Insufficient Parameters</td>\n<td>400</td>\n</tr>\n<tr>\n<td>E002</td>\n<td>Invalid Request JSON</td>\n<td>400</td>\n</tr>\n<tr>\n<td>E003</td>\n<td>Username Already Exists</td>\n<td>400</td>\n</tr>\n<tr>\n<td>E004</td>\n<td>Email Already Exists</td>\n<td>400</td>\n</tr>\n<tr>\n<td>E011</td>\n<td>Authentication Error</td>\n<td>401</td>\n</tr>\n<tr>\n<td>E012</td>\n<td>SignUp Error</td>\n<td>401</td>\n</tr>\n<tr>\n<td>E013</td>\n<td>Login Error</td>\n<td>401</td>\n</tr>\n<tr>\n<td>E014</td>\n<td>Error Authenticating User</td>\n<td>400</td>\n</tr>\n<tr>\n<td>E021</td>\n<td>User Does not Exists</td>\n<td>404</td>\n</tr>\n<tr>\n<td>E022</td>\n<td>Cannot Delete this User</td>\n<td>401</td>\n</tr>\n<tr>\n<td>E023</td>\n<td>Cannot Edit this User</td>\n<td>401</td>\n</tr>\n<tr>\n<td>E024</td>\n<td>Error Editing User</td>\n<td>304</td>\n</tr>\n<tr>\n<td>E025</td>\n<td>Error Deleting User</td>\n<td>304</td>\n</tr>\n<tr>\n<td>E031</td>\n<td>Link Does not exists</td>\n<td>404</td>\n</tr>\n<tr>\n<td>E032</td>\n<td>User Cannot Delete this Link</td>\n<td>401</td>\n</tr>\n<tr>\n<td>E033</td>\n<td>User Cannot Edit this Link</td>\n<td>401</td>\n</tr>\n<tr>\n<td>E034</td>\n<td>Error Editing Link</td>\n<td>304</td>\n</tr>\n<tr>\n<td>E035</td>\n<td>Error Deleting Link</td>\n<td>304</td>\n</tr>\n<tr>\n<td>E036</td>\n<td>Error Adding Link</td>\n<td>304</td>\n</tr>\n</tbody>\n</table>\n</div><h3 id=\"regular-error-object\">Regular Error Object</h3>\n<p>Apart from the response code and error codes, unsuccessful responses return a JSON object containing the following information:</p>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>KEY</th>\n<th>VALUE TYPE</th>\n<th>VALUE DESCRIPTION</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>status</td>\n<td>integer</td>\n<td>The HTTP status code that is also returned in the response header. For further information, see Response Status Codes.</td>\n</tr>\n<tr>\n<td>message</td>\n<td>string</td>\n<td>A short description of the cause of the error.</td>\n</tr>\n<tr>\n<td>data</td>\n<td>Object</td>\n<td>More info of error</td>\n</tr>\n<tr>\n<td>code</td>\n<td>string (nullable)</td>\n<td>One of the Error codes</td>\n</tr>\n</tbody>\n</table>\n</div><h3 id=\"user-object\">User Object</h3>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>KEY</th>\n<th>VALUE TYPE</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>public_id</td>\n<td>string</td>\n</tr>\n<tr>\n<td>name</td>\n<td>string (nullable)</td>\n</tr>\n<tr>\n<td>username</td>\n<td>string</td>\n</tr>\n<tr>\n<td>email</td>\n<td>string (nullable)</td>\n</tr>\n<tr>\n<td>description</td>\n<td>string (nullable)</td>\n</tr>\n<tr>\n<td>website</td>\n<td>string (nullable)</td>\n</tr>\n<tr>\n<td>verified</td>\n<td>boolean</td>\n</tr>\n<tr>\n<td>links</td>\n<td>List[Link Object]</td>\n</tr>\n<tr>\n<td>social_links</td>\n<td>List[Social Link Object]</td>\n</tr>\n</tbody>\n</table>\n</div><h3 id=\"link-object\">Link Object</h3>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>KEY</th>\n<th>VALUE TYPE</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>title</td>\n<td>string</td>\n</tr>\n<tr>\n<td>public_id</td>\n<td>string</td>\n</tr>\n<tr>\n<td>description</td>\n<td>string (nullable)</td>\n</tr>\n<tr>\n<td>url</td>\n<td>string</td>\n</tr>\n</tbody>\n</table>\n</div><h3 id=\"social-link-object\">Social Link Object</h3>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>KEY</th>\n<th>VALUE TYPE</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>platform_id</td>\n<td>integer</td>\n</tr>\n<tr>\n<td>url</td>\n<td>string</td>\n</tr>\n</tbody>\n</table>\n</div><h3 id=\"auth-object\">Auth Object</h3>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>KEY</th>\n<th>VALUE TYPE</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>token</td>\n<td>string</td>\n</tr>\n<tr>\n<td>user</td>\n<td>User Object</td>\n</tr>\n</tbody>\n</table>\n</div></body></html>","schema":"https://schema.getpostman.com/json/collection/v2.0.0/collection.json","toc":[],"owner":"14039622","collectionId":"29e53be8-1e4d-40a6-be06-a6f873910494","publishedId":"Tzsik4P8","public":true,"customColor":{"top-bar":"FFFFFF","right-sidebar":"303030","highlight":"1e1f20"},"publishDate":"2021-08-05T16:12:28.000Z"},"item":[{"name":"Auth","item":[{"name":"Sign Up","id":"ff4abf2e-1b0e-47d0-b0ec-132a9b55f57e","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\r\n    \"username\": \"keosariel\",\r\n    \"email\": \"test@gmail.com\",\r\n    \"password\": \"@Passwordtest1\"\r\n}","options":{"raw":{"language":"json"}}},"url":"127.0.0.1:5000/auth/signup","description":"<h2 id=\"sign-up\">Sign Up</h2>\n<p>Creates/Adds a new User</p>\n<h3 id=\"request\">Request</h3>\n<p><strong>JSON Data</strong></p>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>Key</th>\n<th>Type</th>\n<th>Required</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>username</td>\n<td>string</td>\n<td>required</td>\n</tr>\n<tr>\n<td>email</td>\n<td>string</td>\n<td>required</td>\n</tr>\n<tr>\n<td>password</td>\n<td>string</td>\n<td>required</td>\n</tr>\n</tbody>\n</table>\n</div><h3 id=\"response\">Response</h3>\n<p>On success, the HTTP status code in the response header is 200 OK and the response body contains a Auth object in JSON format.</p>\n<p>On error, the header status code is an error code and the response body contains an error object and an error code possible.</p>\n<p><strong>Note:</strong> The token value in a successful response would be used as a <strong>Bearer token</strong> value in your <strong>Authorization</strong> header.</p>\n","urlObject":{"port":"5000","path":["auth","signup"],"host":["127","0","0","1"],"query":[],"variable":[]}},"response":[],"_postman_id":"ff4abf2e-1b0e-47d0-b0ec-132a9b55f57e"},{"name":"Login","id":"ee17847e-375c-40be-8cd2-02a85ffecb40","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\r\n    \"email\": \"test@gmail.com\",\r\n    \"password\": \"@Passwordtest1\"\r\n}","options":{"raw":{"language":"json"}}},"url":"127.0.0.1:5000/auth/login","description":"<h2 id=\"login\">Login</h2>\n<p>Authenticates a user.</p>\n<h3 id=\"request\">Request</h3>\n<p><strong>JSON Data</strong></p>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>Key</th>\n<th>Type</th>\n<th>Required</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>email</td>\n<td>string</td>\n<td>required</td>\n</tr>\n<tr>\n<td>password</td>\n<td>string</td>\n<td>required</td>\n</tr>\n</tbody>\n</table>\n</div><h3 id=\"response\">Response</h3>\n<p>On success, the HTTP status code in the response header is 200 OK and the response body contains a Auth object in JSON format.</p>\n<p>On error, the header status code is an error code and the response body contains an error object and an error code possible.</p>\n<p><strong>Note:</strong> The token value in a successful response would be used as a <strong>Bearer token</strong> value in your <strong>Authorization</strong> header.</p>\n","urlObject":{"port":"5000","path":["auth","login"],"host":["127","0","0","1"],"query":[],"variable":[]}},"response":[],"_postman_id":"ee17847e-375c-40be-8cd2-02a85ffecb40"}],"id":"59d9a877-3d7a-4538-b3b7-9f27c4d2fe79","description":"<h3 id=\"basic-authentication\">Basic Authentication</h3>\n<p>To make certain actions i.e <strong>Edit/Update/Delete</strong> a user needs to be logged in or authorized. This section show how to authorize a user.</p>\n<h3 id=\"possible-error-codes\">Possible Error Codes</h3>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>Code</th>\n<th>Description</th>\n<th>Status</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>E001</td>\n<td>Insufficient Parameters</td>\n<td>400</td>\n</tr>\n<tr>\n<td>E002</td>\n<td>Invalid Request JSON</td>\n<td>400</td>\n</tr>\n<tr>\n<td>E003</td>\n<td>Username Already Exists</td>\n<td>400</td>\n</tr>\n<tr>\n<td>E004</td>\n<td>Email Already Exists</td>\n<td>400</td>\n</tr>\n<tr>\n<td>E011</td>\n<td>Authentication Error</td>\n<td>401</td>\n</tr>\n<tr>\n<td>E012</td>\n<td>SignUp Error</td>\n<td>401</td>\n</tr>\n<tr>\n<td>E013</td>\n<td>Login Error</td>\n<td>401</td>\n</tr>\n<tr>\n<td>E014</td>\n<td>Error Authenticating User</td>\n<td>400</td>\n</tr>\n<tr>\n<td>E021</td>\n<td>User Does not Exists</td>\n<td>404</td>\n</tr>\n</tbody>\n</table>\n</div>","_postman_id":"59d9a877-3d7a-4538-b3b7-9f27c4d2fe79"},{"name":"Users","item":[{"name":"Get User","id":"8aa81fb4-2c62-47b4-92d1-54df4bef743f","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"127.0.0.1:5000/users/keosariel","description":"<h2 id=\"gets-user-info\">Gets User Info</h2>\n<p>Gets user info</p>\n<h3 id=\"request\">Request</h3>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>Header</th>\n<th>Type</th>\n<th>Required</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>Authorization</td>\n<td>Bearer Token</td>\n<td></td>\n</tr>\n</tbody>\n</table>\n</div><div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>Path Parameter</th>\n<th>Type</th>\n<th>Required</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>username</td>\n<td>string</td>\n<td>required</td>\n</tr>\n</tbody>\n</table>\n</div><h3 id=\"response\">Response</h3>\n<p>On success, the HTTP status code in the response header is 200 OK and the response body contains a <strong>User object</strong> in JSON format.</p>\n<p>On error, the header status code is an error code and the response body contains an error object and an error code possible.</p>\n","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"<token>"}]},"isInherited":true,"source":{"_postman_id":"9bcf93a6-6eb5-48cc-8251-c5d2f88fad89","id":"9bcf93a6-6eb5-48cc-8251-c5d2f88fad89","name":"Users","type":"folder"}},"urlObject":{"port":"5000","path":["users","keosariel"],"host":["127","0","0","1"],"query":[],"variable":[]}},"response":[],"_postman_id":"8aa81fb4-2c62-47b4-92d1-54df4bef743f"},{"name":"Edit Profile","id":"8e7e5def-30af-4aca-b7ad-16f4e817121d","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PUT","header":[],"body":{"mode":"raw","raw":"{\r\n    \"name\": \"kenneth gabriel\",\r\n    \"description\": \"python dev\",\r\n    \"email\": \"\",\r\n    \"username\": \"\",\r\n    \"social_links\": [\r\n        {\r\n            \"platform_id\": 1,\r\n            \"url\": \"https://facebook.com/username\"\r\n        },\r\n        {\r\n            \"platform_id\": 2,\r\n            \"url\": \"https://twitter.com/username\"\r\n        },\r\n        {\r\n            \"platform_id\": 3,\r\n            \"url\": \"https://instagram.com/username\"\r\n        },\r\n        {\r\n            \"platform_id\": 4,\r\n            \"url\": \"https://github.com/username\"\r\n        }\r\n    ]\r\n}","options":{"raw":{"language":"json"}}},"url":"127.0.0.1:5000/users","description":"<h2 id=\"editupdate-user-info\">Edit/Update User Info</h2>\n<p>Edits/Updates the current authenticated user's info</p>\n<h3 id=\"request\">Request</h3>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>Header</th>\n<th>Type</th>\n<th>Required</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>Authorization</td>\n<td>Bearer Token</td>\n<td>required</td>\n</tr>\n</tbody>\n</table>\n</div><p><strong>JSON Data</strong></p>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>Key</th>\n<th>Type</th>\n<th>Required</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>name</td>\n<td>string (nullable)</td>\n<td>required</td>\n</tr>\n<tr>\n<td>username</td>\n<td>string (nullable)</td>\n<td>required</td>\n</tr>\n<tr>\n<td>email</td>\n<td>string (nullable)</td>\n<td>required</td>\n</tr>\n<tr>\n<td>description</td>\n<td>string</td>\n<td>required</td>\n</tr>\n<tr>\n<td>social_links</td>\n<td>List[Object] : an object with keys [\"platform_id:integer\", \"url:string\"]</td>\n<td></td>\n</tr>\n</tbody>\n</table>\n</div><p><strong>Note:</strong> If these fields are null, no changes would be made</p>\n<h3 id=\"response\">Response</h3>\n<p>On success, the HTTP status code in the response header is 200 OK and the response body contains a <strong>User object</strong> in JSON format.</p>\n<p>On error, the header status code is an error code and the response body contains an error object and an error code possible.</p>\n","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"<token>"}]},"isInherited":true,"source":{"_postman_id":"9bcf93a6-6eb5-48cc-8251-c5d2f88fad89","id":"9bcf93a6-6eb5-48cc-8251-c5d2f88fad89","name":"Users","type":"folder"}},"urlObject":{"port":"5000","path":["users"],"host":["127","0","0","1"],"query":[],"variable":[]}},"response":[],"_postman_id":"8e7e5def-30af-4aca-b7ad-16f4e817121d"},{"name":"Delete User","id":"a146f705-7808-4ecc-b013-d3f03883b7e0","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"DELETE","header":[],"url":"127.0.0.1:5000/users","description":"<h2 id=\"deletes-a-user\">Deletes a User</h2>\n<p>Deactivates the current authenticated user</p>\n<h3 id=\"request\">Request</h3>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>Header</th>\n<th>Type</th>\n<th>Required</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>Authorization</td>\n<td>Bearer Token</td>\n<td>required</td>\n</tr>\n</tbody>\n</table>\n</div><h3 id=\"response\">Response</h3>\n<p>On success, the HTTP status code in the response header is 200 OK and the response body contains an empty object in JSON format.</p>\n<p>On error, the header status code is an error code and the response body contains an error object and an error code possible.</p>\n","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"<token>"}]},"isInherited":true,"source":{"_postman_id":"9bcf93a6-6eb5-48cc-8251-c5d2f88fad89","id":"9bcf93a6-6eb5-48cc-8251-c5d2f88fad89","name":"Users","type":"folder"}},"urlObject":{"port":"5000","path":["users"],"host":["127","0","0","1"],"query":[],"variable":[]}},"response":[],"_postman_id":"a146f705-7808-4ecc-b013-d3f03883b7e0"}],"id":"9bcf93a6-6eb5-48cc-8251-c5d2f88fad89","description":"<p>Every user need a means to <strong>get/edit/update</strong> their information. This section enlightens you on how to go about that.</p>\n<h3 id=\"possible-error-codes\">Possible Error Codes</h3>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>Code</th>\n<th>Description</th>\n<th>Status</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>E001</td>\n<td>Insufficient Parameters</td>\n<td>400</td>\n</tr>\n<tr>\n<td>E002</td>\n<td>Invalid Request JSON</td>\n<td>400</td>\n</tr>\n<tr>\n<td>E003</td>\n<td>Username Already Exists</td>\n<td>400</td>\n</tr>\n<tr>\n<td>E004</td>\n<td>Email Already Exists</td>\n<td>400</td>\n</tr>\n<tr>\n<td>E011</td>\n<td>Authentication Error</td>\n<td>401</td>\n</tr>\n<tr>\n<td>E021</td>\n<td>User Does not Exists</td>\n<td>404</td>\n</tr>\n<tr>\n<td>E022</td>\n<td>Cannot Delete this User</td>\n<td>401</td>\n</tr>\n<tr>\n<td>E023</td>\n<td>Cannot Edit this User</td>\n<td>401</td>\n</tr>\n<tr>\n<td>E024</td>\n<td>Error Editing User</td>\n<td>304</td>\n</tr>\n<tr>\n<td>E025</td>\n<td>Error Deleting User</td>\n<td>304</td>\n</tr>\n</tbody>\n</table>\n</div>","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"<token>"}]},"isInherited":false},"event":[{"listen":"prerequest","script":{"type":"text/javascript","exec":[""],"id":"73aec453-d5da-43b3-9281-65d23b062b37"}},{"listen":"test","script":{"type":"text/javascript","exec":[""],"id":"9e40c57e-0085-448f-984e-a6ec75a829bf"}}],"_postman_id":"9bcf93a6-6eb5-48cc-8251-c5d2f88fad89"},{"name":"Links","item":[{"name":"Get Link Details","id":"5a398efe-803c-4d4e-acd3-5361bcae811f","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"127.0.0.1:5000/links/30b484535582ea8b3252677a12fa6a10","description":"<h2 id=\"gets-link-info\">Gets Link Info</h2>\n<p>Gets link info</p>\n<h3 id=\"request\">Request</h3>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>Header</th>\n<th>Type</th>\n<th>Required</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>Authorization</td>\n<td>Bearer Token</td>\n<td></td>\n</tr>\n</tbody>\n</table>\n</div><div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>Path Parameter</th>\n<th>Type</th>\n<th>Required</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>public_id: links <code>public id</code></td>\n<td>string</td>\n<td>required</td>\n</tr>\n</tbody>\n</table>\n</div><h3 id=\"response\">Response</h3>\n<p>On success, the HTTP status code in the response header is 200 OK and the response body contains a <strong>Link object</strong> in JSON format.</p>\n<p>On error, the header status code is an error code and the response body contains an error object and an error code possible.</p>\n","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"<token>"}]},"isInherited":true,"source":{"_postman_id":"1c5513f4-e890-4015-a98e-a6650103b1cc","id":"1c5513f4-e890-4015-a98e-a6650103b1cc","name":"Links","type":"folder"}},"urlObject":{"port":"5000","path":["links","30b484535582ea8b3252677a12fa6a10"],"host":["127","0","0","1"],"query":[],"variable":[]}},"response":[],"_postman_id":"5a398efe-803c-4d4e-acd3-5361bcae811f"},{"name":"Add Link to Tree","id":"7802cf31-4f16-4907-a79c-860d8176b8af","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\r\n    \"title\": \"link title\",\r\n    \"description\": \"link description\",\r\n    \"url\": \"https://link-url.com\"\r\n}","options":{"raw":{"language":"json"}}},"url":"127.0.0.1:5000/links","description":"<h2 id=\"create-a-new-link\">Create a new Link</h2>\n<p>Adds a Link to the current authenticated user's tree.</p>\n<h3 id=\"request\">Request</h3>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>Header</th>\n<th>Type</th>\n<th>Required</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>Authorization</td>\n<td>Bearer Token</td>\n<td></td>\n</tr>\n</tbody>\n</table>\n</div><p><strong>JSON Data</strong></p>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>Key</th>\n<th>Type</th>\n<th>Required</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>title</td>\n<td>String</td>\n<td>required</td>\n</tr>\n<tr>\n<td>url</td>\n<td>String</td>\n<td>required</td>\n</tr>\n<tr>\n<td>description</td>\n<td>String</td>\n<td></td>\n</tr>\n</tbody>\n</table>\n</div><h3 id=\"response\">Response</h3>\n<p>On success, the HTTP status code in the response header is 200 OK and the response body contains a <strong>Link object</strong> in JSON format.</p>\n<p>On error, the header status code is an error code and the response body contains an error object and an error code possible.</p>\n","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"<token>"}]},"isInherited":true,"source":{"_postman_id":"1c5513f4-e890-4015-a98e-a6650103b1cc","id":"1c5513f4-e890-4015-a98e-a6650103b1cc","name":"Links","type":"folder"}},"urlObject":{"port":"5000","path":["links"],"host":["127","0","0","1"],"query":[],"variable":[]}},"response":[],"_postman_id":"7802cf31-4f16-4907-a79c-860d8176b8af"},{"name":"Edit Link Details","id":"adf5fa73-0a40-487c-8ce4-cafd38a71bbd","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"PUT","header":[],"body":{"mode":"raw","raw":"{\r\n    \"title\": \"new link title\",\r\n    \"description\": \"new link description\",\r\n    \"url\": \"https://new-link-url.com\"\r\n}","options":{"raw":{"language":"json"}}},"url":"127.0.0.1:5000/links/30b484535582ea8b3252677a12fa6a10","description":"<h2 id=\"update-links-info\">Update Link's info</h2>\n<p>Updates the link with the path-parameter <code>public_id</code> info.</p>\n<h3 id=\"request\">Request</h3>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>Header</th>\n<th>Type</th>\n<th>Required</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>Authorization</td>\n<td>Bearer Token</td>\n<td>required</td>\n</tr>\n</tbody>\n</table>\n</div><div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>Path Parameter</th>\n<th>Type</th>\n<th>Required</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>public_id: links <code>public id</code></td>\n<td>string</td>\n<td>required</td>\n</tr>\n</tbody>\n</table>\n</div><p><strong>JSON Data</strong></p>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>Key</th>\n<th>Type</th>\n<th>Required</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>title</td>\n<td>String</td>\n<td>required</td>\n</tr>\n<tr>\n<td>url</td>\n<td>String</td>\n<td>required</td>\n</tr>\n<tr>\n<td>description</td>\n<td>String</td>\n<td></td>\n</tr>\n</tbody>\n</table>\n</div><h3 id=\"response\">Response</h3>\n<p>On success, the HTTP status code in the response header is 200 OK and the response body contains a <strong>Link object</strong> in JSON format.</p>\n<p>On error, the header status code is an error code and the response body contains an error object and an error code possible.</p>\n","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"<token>"}]},"isInherited":true,"source":{"_postman_id":"1c5513f4-e890-4015-a98e-a6650103b1cc","id":"1c5513f4-e890-4015-a98e-a6650103b1cc","name":"Links","type":"folder"}},"urlObject":{"port":"5000","path":["links","30b484535582ea8b3252677a12fa6a10"],"host":["127","0","0","1"],"query":[],"variable":[]}},"response":[],"_postman_id":"adf5fa73-0a40-487c-8ce4-cafd38a71bbd"},{"name":"Delete Link","id":"b2e571a6-66ec-4e8d-936c-228117e5fa59","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"DELETE","header":[],"url":"127.0.0.1:5000/links/30b484535582ea8b3252677a12fa6a10","description":"<h2 id=\"deletes-a-link\">Deletes a Link</h2>\n<p>Removes a Link from a user's tree.</p>\n<h3 id=\"request\">Request</h3>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>Header</th>\n<th>Type</th>\n<th>Required</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>Authorization</td>\n<td>Bearer Token</td>\n<td>required</td>\n</tr>\n</tbody>\n</table>\n</div><div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>Path Parameter</th>\n<th>Type</th>\n<th>Required</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>public_id: links <code>public id</code></td>\n<td>string</td>\n<td>required</td>\n</tr>\n</tbody>\n</table>\n</div><h3 id=\"response\">Response</h3>\n<p>On success, the HTTP status code in the response header is 200 OK and the response body contains an empty object in JSON format.</p>\n<p>On error, the header status code is an error code and the response body contains an error object and an error code possible.</p>\n","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"<token>"}]},"isInherited":true,"source":{"_postman_id":"1c5513f4-e890-4015-a98e-a6650103b1cc","id":"1c5513f4-e890-4015-a98e-a6650103b1cc","name":"Links","type":"folder"}},"urlObject":{"port":"5000","path":["links","30b484535582ea8b3252677a12fa6a10"],"host":["127","0","0","1"],"query":[],"variable":[]}},"response":[],"_postman_id":"b2e571a6-66ec-4e8d-936c-228117e5fa59"}],"id":"1c5513f4-e890-4015-a98e-a6650103b1cc","description":"<p>This section would enable you make requests to <strong>create/edit/update/delete</strong> links for a persons tree.</p>\n<h3 id=\"possible-error-codes\">Possible Error Codes</h3>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th>Code</th>\n<th>Description</th>\n<th>Status</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>E001</td>\n<td>Insufficient Parameters</td>\n<td>400</td>\n</tr>\n<tr>\n<td>E002</td>\n<td>Invalid Request JSON</td>\n<td>400</td>\n</tr>\n<tr>\n<td>E003</td>\n<td>Username Already Exists</td>\n<td>400</td>\n</tr>\n<tr>\n<td>E004</td>\n<td>Email Already Exists</td>\n<td>400</td>\n</tr>\n<tr>\n<td>E011</td>\n<td>Authentication Error</td>\n<td>401</td>\n</tr>\n<tr>\n<td>E031</td>\n<td>Link Does not exists</td>\n<td>404</td>\n</tr>\n<tr>\n<td>E032</td>\n<td>User Cannot Delete this Link</td>\n<td>401</td>\n</tr>\n<tr>\n<td>E033</td>\n<td>User Cannot Edit this Link</td>\n<td>401</td>\n</tr>\n<tr>\n<td>E034</td>\n<td>Error Editing Link</td>\n<td>304</td>\n</tr>\n<tr>\n<td>E035</td>\n<td>Error Deleting Link</td>\n<td>304</td>\n</tr>\n<tr>\n<td>E036</td>\n<td>Error Adding Link</td>\n<td>304</td>\n</tr>\n</tbody>\n</table>\n</div>","auth":{"type":"bearer","bearer":{"basicConfig":[{"key":"token","value":"<token>"}]},"isInherited":false},"event":[{"listen":"prerequest","script":{"type":"text/javascript","exec":[""],"id":"9a6598d7-a207-4f94-b2e2-e73ae08c83dc"}},{"listen":"test","script":{"type":"text/javascript","exec":[""],"id":"873e0cb3-0ff4-40bc-a708-695d3103d0c6"}}],"_postman_id":"1c5513f4-e890-4015-a98e-a6650103b1cc"}]}