{"info":{"_postman_id":"bbce6d9f-fcb5-4de3-9357-f43d438b60d9","name":"API Documentation","description":"<html><head></head><body><p>Here you can test API for learning-cards.</p>\n<p>You must have running local learning-cards</p>\n<p>It is configured so it will connect to learning-cards running on localhost.</p>\n<p>If you want to try out without installing local try <a href=\"https://learn.hajek.live/api\">https://www.learn.hajek.live/api</a> in variables</p>\n<p>For github project <a href=\"https://github.com/matyash12/learning-cards\">https://github.com/matyash12/learning-cards</a></p>\n<p>Docs autogenerated using postbot. Mistakes can be.</p>\n</body></html>","schema":"https://schema.getpostman.com/json/collection/v2.0.0/collection.json","toc":[],"owner":"23011773","collectionId":"bbce6d9f-fcb5-4de3-9357-f43d438b60d9","publishedId":"2s9YkuXxkm","public":true,"customColor":{"top-bar":"FFFFFF","right-sidebar":"303030","highlight":"FF6C37"},"publishDate":"2023-12-27T15:52:34.000Z"},"item":[{"name":"User","item":[{"name":"Recovery","item":[{"name":"Request recovery link for password","id":"1b88e5f1-e014-4c52-bd98-92edd14d90bf","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"urlencoded","urlencoded":[{"key":"email","value":"whatever@example.com","type":"text"}]},"url":"https://www.learn.hajek.live/api/recovery/request/password","description":"<p>This endpoint allows you to send a POST request to initiate a password recovery process. The request should be sent to https://www.learn.hajek.live/api/recovery/request/password.</p>\n<h3 id=\"request-body\">Request Body</h3>\n<ul>\n<li>email (text): The email address of the user for whom the password recovery process needs to be initiated.</li>\n</ul>\n<h3 id=\"response\">Response</h3>\n<ul>\n<li>Status: 200 OK</li>\n<li>message: A message indicating the outcome of the request.</li>\n<li>data: This field is null in the response.</li>\n<li>status: Indicates the status of the request.</li>\n<li>code: An integer value representing the status code of the response.</li>\n</ul>\n<p>Add documentation</p>\n","urlObject":{"path":["recovery","request","password"],"host":["https://www.learn.hajek.live/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"1b88e5f1-e014-4c52-bd98-92edd14d90bf"},{"name":"Create new password","id":"16a0b559-b3b5-49f5-8953-7c81411b7556","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"urlencoded","urlencoded":[{"key":"token","value":"54d9ca5d-7994-4e2a-a697-d3b6720b84fb","type":"text"},{"key":"userid","value":"2","type":"text"},{"key":"password","value":"Password1","type":"text"}]},"url":"https://www.learn.hajek.live/api/recovery/change/password","description":"<p>This endpoint is used to change the password for account recovery. The HTTP POST request should be made to https://www.learn.hajek.live/api/recovery/change/password. The request payload should be of x-www-form-urlencoded type and include the following parameters:</p>\n<ul>\n<li>token (text): The recovery token received via email.</li>\n<li>userid (text): The user ID for the account.</li>\n<li>password (text): The new password to be set.</li>\n</ul>\n<p>The response to the request will have a status code of 200 and will include the following fields:</p>\n<ul>\n<li>message: A message indicating the result of the password change process.</li>\n<li>data: This field will be null in this response.</li>\n<li>status: The status of the operation.</li>\n<li>code: A code indicating the result of the password change operation.</li>\n</ul>\n","urlObject":{"path":["recovery","change","password"],"host":["https://www.learn.hajek.live/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"16a0b559-b3b5-49f5-8953-7c81411b7556"}],"id":"81f54d20-b997-427f-a6a3-f5273c412ff1","description":"<p>This folder has endpoints for recovering password.</p>\n<p>NOTE: You must have configured email</p>\n","_postman_id":"81f54d20-b997-427f-a6a3-f5273c412ff1"},{"name":"Info about current user","id":"0fdddcfd-a1e1-4d3e-b963-04bf994dd499","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"https://www.learn.hajek.live/api/user/info","description":"<p>This endpoint makes an HTTP GET request to retrieve user information from the server. The request does not include a request body. The response will have a status code of 200 and will contain a JSON object with the keys \"message\", \"data\", \"status\", and \"code\". The \"data\" object will include \"userId\" and \"authorities\" as its keys.</p>\n","urlObject":{"path":["user","info"],"host":["https://www.learn.hajek.live/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"0fdddcfd-a1e1-4d3e-b963-04bf994dd499"},{"name":"login","id":"990c7ea4-3879-41e0-8426-34f277188c47","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"urlencoded","urlencoded":[{"key":"username","value":"Matyas","type":"text","disabled":true},{"key":"email","value":"test@test.com","type":"text"},{"key":"password","value":"yourpassword","type":"text"}]},"url":"https://www.learn.hajek.live/api/user/login","description":"<h3 id=\"post-userlogin\">POST /user/login</h3>\n<p>This endpoint is used to log in a user.</p>\n<h4 id=\"request-body\">Request Body</h4>\n<ul>\n<li>email (text, required): The email of the user.</li>\n<li>password (text, required): The password of the user.</li>\n</ul>\n<h4 id=\"response\">Response</h4>\n<ul>\n<li>Status: 200</li>\n<li>message: A message indicating the result of the login attempt.</li>\n<li>data: The user data if the login is successful, otherwise null.</li>\n<li>status: The status of the response.</li>\n<li>code: A code indicating the result of the login attempt.</li>\n</ul>\n","urlObject":{"path":["user","login"],"host":["https://www.learn.hajek.live/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"990c7ea4-3879-41e0-8426-34f277188c47"},{"name":"Create new user","id":"78f135e8-b6ae-48d3-be07-cafe7a79d4a9","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"formdata","formdata":[{"key":"username","value":"whatever","type":"text"},{"key":"email","value":"whatever@example.com","type":"text"},{"key":"password","value":"Password1","type":"text"}]},"url":"https://www.learn.hajek.live/api/user/register","description":"<p>This endpoint allows you to register a new user. You need to make an HTTP POST request to <code>https://www.learn.hajek.live/api/user/register</code> with the form-data request body type. The request should include the following parameters:</p>\n<ul>\n<li><code>username</code> (text): The username of the new user.</li>\n<li><code>email</code> (text): The email address of the new user.</li>\n<li><code>password</code> (text): The password for the new user.</li>\n</ul>\n<p>The response to this request will have a status code of 200 and will include the following fields:</p>\n<ul>\n<li><code>message</code>: A message indicating the result of the registration process.</li>\n<li><code>data</code>: This field will be null in this response.</li>\n<li><code>status</code>: The status of the registration process.</li>\n<li><code>code</code>: A code indicating the result of the registration process.</li>\n</ul>\n","urlObject":{"path":["user","register"],"host":["https://www.learn.hajek.live/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"78f135e8-b6ae-48d3-be07-cafe7a79d4a9"},{"name":"logout","id":"c710ca21-4ca2-4c84-811d-d7f0d8de5da2","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"url":"https://www.learn.hajek.live/api/user/logout","description":"<p>This endpoint is used to log out the user. Upon successful execution, it returns a status code of 200 with an empty message and data. The response also includes a status and code. There are no request body parameters for this endpoint.</p>\n","urlObject":{"path":["user","logout"],"host":["https://www.learn.hajek.live/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"c710ca21-4ca2-4c84-811d-d7f0d8de5da2"}],"id":"8b672d8b-1e1f-4464-a8ec-671a686ea7ec","description":"<p>The <code>/me</code> endpoints let you manage information about the authenticated user.</p>\n","_postman_id":"8b672d8b-1e1f-4464-a8ec-671a686ea7ec"},{"name":"Export","item":[{"name":"Get string of cards","id":"e74aa08e-42ba-480c-b500-2f5410d62228","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"https://www.learn.hajek.live/api/export/allcardshumanformat","description":"<p>This endpoint makes an HTTP GET request to retrieve all cards in a human-readable format. The request does not require any payload in the request body.</p>\n<h3 id=\"response\">Response</h3>\n<ul>\n<li><p>Status: 200</p>\n</li>\n<li><p>Body:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">  {\n      \"message\": \"\",\n      \"data\": {\n          \"text\": \"\"\n      },\n      \"status\": \"\",\n      \"code\": 0\n  }\n\n</code></pre>\n</li>\n</ul>\n","urlObject":{"path":["export","allcardshumanformat"],"host":["https://www.learn.hajek.live/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"e74aa08e-42ba-480c-b500-2f5410d62228"}],"id":"229c1d1a-0b52-4dcc-b6c6-21cd348d36fd","_postman_id":"229c1d1a-0b52-4dcc-b6c6-21cd348d36fd","description":""},{"name":"Card","item":[{"name":"Get card by it's id","event":[{"listen":"test","script":{"id":"7d2b5529-ba71-4b31-a83b-b8a71897c73e","exec":["var template = `","<style type=\"text/css\">","    .tftable {font-size:14px;color:#333333;width:100%;border-width: 1px;border-color: #87ceeb;border-collapse: collapse;}","    .tftable th {font-size:18px;background-color:#87ceeb;border-width: 1px;padding: 8px;border-style: solid;border-color: #87ceeb;text-align:left;}","    .tftable tr {background-color:#ffffff;}","    .tftable td {font-size:14px;border-width: 1px;padding: 8px;border-style: solid;border-color: #87ceeb;}","    .tftable tr:hover {background-color:#e0ffff;}","</style>","","<table class=\"tftable\" border=\"1\">","    <tr>","        <th>ID</th>","        <th>Hidden Part</th>","        <th>Visible Part</th>","        <th>Mark</th>","        <th>Deck Name</th>","        <th>User Name</th>","        <th>User Email</th>","        <th>User Role</th>","    </tr>","    <tr>","        <td>{{response.data.id}}</td>","        <td>{{response.data.hiddenPart}}</td>","        <td>{{response.data.visiblePart}}</td>","        <td>{{response.data.mark}}</td>","        <td>{{response.data.deckEntity.name}}</td>","        <td>{{response.data.deckEntity.tridaEntity.userEntity.username}}</td>","        <td>{{response.data.deckEntity.tridaEntity.userEntity.email}}</td>","        <td>{{response.data.deckEntity.tridaEntity.userEntity.roles.[0].authority}}</td>","    </tr>","</table>","`;","","function constructVisualizerPayload() {","    return {response: pm.response.json()}","}","","pm.visualizer.set(template, constructVisualizerPayload());"],"type":"text/javascript"}}],"id":"43671025-33cb-4855-b1d6-59e58d4cc1a8","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"https://www.learn.hajek.live/api/card/28","description":"<p>This endpoint makes an HTTP GET request to retrieve information about a specific card with the ID 28. The request does not include a request body. </p>\n<h3 id=\"response\">Response</h3>\n<ul>\n<li>Status: 200</li>\n<li>Body:<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n  \"message\": \"\",\n  \"data\": {\n    \"id\": 0,\n    \"hiddenPart\": \"\",\n    \"visiblePart\": \"\",\n    \"mark\": 0,\n    \"deckEntity\": {\n      \"id\": 0,\n      \"name\": \"\",\n      \"tridaEntity\": {\n        \"id\": 0,\n        \"name\": \"\",\n        \"userEntity\": {\n          \"id\": 0,\n          \"username\": \"\",\n          \"email\": \"\",\n          \"roles\": [\n            {\n              \"authority\": \"\"\n            }\n          ],\n          \"rolesStr\": \"\"\n        }\n      }\n    },\n    \"status\": \"\",\n    \"code\": 0\n  }\n}\n</code></pre>\n</li>\n</ul>\n<p>This endpoint retrieves detailed information about the card with the ID 28.</p>\n","urlObject":{"path":["card","28"],"host":["https://www.learn.hajek.live/api"],"query":[{"disabled":true,"key":"","value":null}],"variable":[]}},"response":[],"_postman_id":"43671025-33cb-4855-b1d6-59e58d4cc1a8"},{"name":"Get all cards","event":[{"listen":"test","script":{"id":"5fc49793-3f23-4a4f-a847-cbc4b00d4474","exec":["var template = `","<style type=\"text/css\">","    .tftable {font-size:14px;color:#333333;width:100%;border-width: 1px;border-color: #87ceeb;border-collapse: collapse;}","    .tftable th {font-size:18px;background-color:#87ceeb;border-width: 1px;padding: 8px;border-style: solid;border-color: #87ceeb;text-align:left;}","    .tftable tr {background-color:#ffffff;}","    .tftable td {font-size:14px;border-width: 1px;padding: 8px;border-style: solid;border-color: #87ceeb;}","    .tftable tr:hover {background-color:#e0ffff;}","</style>","","<table class=\"tftable\" border=\"1\">","    <tr>","        <th>ID</th>","        <th>Hidden Part</th>","        <th>Visible Part</th>","        <th>Mark</th>","        <th>Deck ID</th>","        <th>Deck Name</th>","        <th>User ID</th>","        <th>Username</th>","        <th>Email</th>","        <th>Role</th>","    </tr>","    ","    {{#each response.data}}","        <tr>","            <td>{{id}}</td>","            <td>{{hiddenPart}}</td>","            <td>{{visiblePart}}</td>","            <td>{{mark}}</td>","            <td>{{deckEntity.id}}</td>","            <td>{{deckEntity.name}}</td>","            <td>{{deckEntity.tridaEntity.id}}</td>","            <td>{{deckEntity.tridaEntity.userEntity.username}}</td>","            <td>{{deckEntity.tridaEntity.userEntity.email}}</td>","            <td>{{deckEntity.tridaEntity.userEntity.roles.[0].authority}}</td>","        </tr>","    {{/each}}","</table>","`;","","function constructVisualizerPayload() {","    return {response: pm.response.json()}","}","","pm.visualizer.set(template, constructVisualizerPayload());"],"type":"text/javascript"}}],"id":"d3f3e313-46d9-42bc-bf18-1a990d548c6c","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"https://www.learn.hajek.live/api/card/all","description":"<p>This endpoint makes an HTTP GET request to retrieve all card data. The request does not include a request body. </p>\n<p>The response to the request returns a status code of 200 along with a JSON object. The JSON object includes a \"message\" field, a \"data\" array containing card information, a \"status\" field, and a \"code\" field. Each card object in the \"data\" array includes an \"id\", \"hiddenPart\", \"visiblePart\", \"mark\", and \"deckEntity\" fields. The \"deckEntity\" includes an \"id\", \"name\", and \"tridaEntity\" with an \"id\", \"name\", and \"userEntity\" with an \"id\", \"username\", \"email\", \"roles\" array, and \"rolesStr\" fields.</p>\n","urlObject":{"path":["card","all"],"host":["https://www.learn.hajek.live/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"d3f3e313-46d9-42bc-bf18-1a990d548c6c"},{"name":"Create new card","id":"1c93a64e-9844-4f5c-b87e-3df3f44e371f","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"formdata","formdata":[{"key":"hiddenPart","value":"Dog","type":"text"},{"key":"visiblePart","value":"Pes","type":"text"},{"key":"deckid","value":"2","type":"text"},{"key":"hiddenPartImageFile","description":"<p>image</p>\n","type":"file","src":"/Users/matyashajek/Downloads/Cat_November_2010-1a.jpg"},{"key":"visiblePartImageFile","description":"<p>image</p>\n","type":"file","value":null,"disabled":true}]},"url":"https://www.learn.hajek.live/api/card/new","description":"<p>This endpoint allows you to create a new card by making an HTTP POST request to https://www.learn.hajek.live/api/card/new. The request should include form-data with the following parameters:</p>\n<ol>\n<li>hiddenPart (text) - Description of the hidden part of the card.</li>\n<li>visiblePart (text) - Description of the visible part of the card.</li>\n<li>deckid (text) - ID of the deck to which the card belongs.</li>\n</ol>\n<p>The response to the request will have a status code of 201 and will include the following fields:</p>\n<ul>\n<li>message: A message regarding the status of the request.</li>\n<li>data: The data related to the new card created.</li>\n<li>status: The status of the request.</li>\n<li>code: The status code of the response.</li>\n</ul>\n","urlObject":{"path":["card","new"],"host":["https://www.learn.hajek.live/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"1c93a64e-9844-4f5c-b87e-3df3f44e371f"},{"name":"Delete one card by id","id":"9c8bf7d7-50ea-4bb0-8f65-9f986c4f128a","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"formdata","formdata":[{"key":"id","value":"30","type":"text"}]},"url":"https://www.learn.hajek.live/api/card/delete","description":"<p>Returns 204 NO CONTENT if it was successfuly deleted</p>\n","urlObject":{"path":["card","delete"],"host":["https://www.learn.hajek.live/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"9c8bf7d7-50ea-4bb0-8f65-9f986c4f128a"},{"name":"Update one card","id":"f5776159-0e78-448e-9643-b2cd3c17024e","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"formdata","formdata":[{"key":"id","value":"32","description":"<p>required</p>\n","type":"text"},{"key":"hiddenPart","value":"Dog","type":"text"},{"key":"visiblePart","value":"Pes","type":"text"},{"key":"mark","value":"3","type":"text"},{"key":"deckid","value":"2","type":"text","disabled":true},{"key":"hiddenPartImageFile","type":"file","value":null,"disabled":true},{"key":"visiblePartImageFile","type":"file","fileNotInWorkingDirectoryWarning":"This file isn't in your working directory. Teammates you share this request with won't be able to use this file. To make collaboration easier you can setup your working directory in Settings.","filesNotInWorkingDirectory":["/Users/matyashajek/Downloads/A_cat.jpeg"],"value":null,"disabled":true},{"key":"hiddenPartImageFileDelete","value":"True","description":"<p>to delete</p>\n","type":"text","disabled":true},{"key":"visiblePartImageFileDelete","value":"True","description":"<p>to delete</p>\n","type":"text","disabled":true}]},"url":"https://www.learn.hajek.live/api/card/update","description":"<p>This endpoint is used to update a card via an HTTP POST request to https://www.learn.hajek.live/api/card/update. The request should include a form-data body with the following parameters:</p>\n<ul>\n<li>id (required): The ID of the card to be updated.</li>\n<li>hiddenPart: The hidden part of the card.</li>\n<li>mark: The mark associated with the card.</li>\n</ul>\n<p>The response to the request will have a status code of 200 and will include the following fields:</p>\n<ul>\n<li>message: A message related to the status of the request.</li>\n<li>data: Additional data related to the update, if applicable.</li>\n<li>status: The status of the request.</li>\n<li>code: A code indicating the status of the request.</li>\n</ul>\n","urlObject":{"path":["card","update"],"host":["https://www.learn.hajek.live/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"f5776159-0e78-448e-9643-b2cd3c17024e"},{"name":"Find card by deckid","id":"de254136-b253-4c12-abfe-21b91369e4b0","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"formdata","formdata":[{"key":"deckid","value":"2","type":"text"}]},"url":"https://www.learn.hajek.live/api/card/find","description":"<h3 id=\"add-card\">Add Card</h3>\n<p>This endpoint allows you to find a card using the specified deck ID.</p>\n<h4 id=\"request\">Request</h4>\n<ul>\n<li>Method: POST</li>\n<li>URL: https://www.learn.hajek.live/api/card/find</li>\n<li>Body: form-data</li>\n</ul>\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>Description</th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>deckid</td>\n<td>text</td>\n<td></td>\n</tr>\n</tbody>\n</table>\n</div><h4 id=\"response\">Response</h4>\n<ul>\n<li>Status: 200 OK</li>\n</ul>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"message\": \"\",\n    \"data\": [\n        {\n            \"id\": 0,\n            \"hiddenPart\": \"\",\n            \"visiblePart\": \"\",\n            \"mark\": 0,\n            \"deckEntity\": {\n                \"id\": 0,\n                \"name\": \"\",\n                \"tridaEntity\": {\n                    \"id\": 0,\n                    \"name\": \"\",\n                    \"userEntity\": {\n                        \"id\": 0,\n                        \"username\": \"\",\n                        \"email\": \"\",\n                        \"roles\": [\n                            {\n                                \"authority\": \"\"\n                            }\n                        ],\n                        \"rolesStr\": \"\"\n                    }\n                }\n            }\n        }\n    ],\n    \"status\": \"\",\n    \"code\": 0\n}\n\n</code></pre>\n","urlObject":{"path":["card","find"],"host":["https://www.learn.hajek.live/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"de254136-b253-4c12-abfe-21b91369e4b0"}],"id":"d5d8c637-72d1-4155-91fd-fc7886c57339","_postman_id":"d5d8c637-72d1-4155-91fd-fc7886c57339","description":""},{"name":"Deck","item":[{"name":"Create new deck","id":"b75ace77-12b3-4ed3-8824-8a7b696b47a9","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"formdata","formdata":[{"key":"name","value":"Math","type":"text"},{"key":"tridaid","value":"2","type":"text"}]},"url":"https://www.learn.hajek.live/api/deck/new","description":"<h3 id=\"create-a-new-deck\">Create a New Deck</h3>\n<p>This endpoint allows you to create a new deck.</p>\n<h4 id=\"request-body\">Request Body</h4>\n<ul>\n<li>name (text): The name of the deck.</li>\n<li>tridaid (text): The ID of the trida.</li>\n</ul>\n<h4 id=\"response\">Response</h4>\n<ul>\n<li>Status: 200</li>\n<li>message: A message related to the response.</li>\n<li>data:<ul>\n<li>id: The ID of the created deck.</li>\n<li>name: The name of the created deck.</li>\n<li>tridaEntity:<ul>\n<li>id: The ID of the trida entity.</li>\n<li>name: The name of the trida entity.</li>\n<li>userEntity:<ul>\n<li>id: The ID of the user entity.</li>\n<li>username: The username of the user.</li>\n<li>email: The email of the user.</li>\n<li>roles: An array of user roles.</li>\n<li>rolesStr: A string representation of user roles.</li>\n</ul>\n</li>\n</ul>\n</li>\n</ul>\n</li>\n<li>status: The status of the response.</li>\n<li>code: The status code of the response.</li>\n</ul>\n","urlObject":{"path":["deck","new"],"host":["https://www.learn.hajek.live/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"b75ace77-12b3-4ed3-8824-8a7b696b47a9"},{"name":"Get deck by deckid","id":"d22a2a2c-e100-4fb2-98ae-02e1dea4d01f","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"https://www.learn.hajek.live/api/deck/2","description":"<p>This endpoint makes an HTTP GET request to retrieve information about a specific deck with ID 2. The response will include data related to the deck, such as its ID, name, and associated user information.</p>\n<p>The response will have a status code of 200, indicating a successful request. The response body will contain a JSON object with a message, data, status, and code properties.</p>\n<p>The data property will include the ID and name of the deck, as well as additional information about related entities such as tridaEntity and userEntity.</p>\n<p>It's important to note that the response may contain empty strings or null values for certain properties.</p>\n","urlObject":{"path":["deck","2"],"host":["https://www.learn.hajek.live/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"d22a2a2c-e100-4fb2-98ae-02e1dea4d01f"},{"name":"Delete deck by id","id":"e0d2af38-74f7-4bd6-ac65-9d09a80fc538","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"formdata","formdata":[{"key":"id","value":"1","type":"text"}]},"url":"https://www.learn.hajek.live/api/deck/delete","urlObject":{"path":["deck","delete"],"host":["https://www.learn.hajek.live/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"e0d2af38-74f7-4bd6-ac65-9d09a80fc538"},{"name":"Get all decks","id":"072ef417-6e63-41e8-bb56-aa5b6ef34e50","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"https://www.learn.hajek.live/api/deck/all","urlObject":{"path":["deck","all"],"host":["https://www.learn.hajek.live/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"072ef417-6e63-41e8-bb56-aa5b6ef34e50"},{"name":"Update deck","id":"fe643b6e-03ee-4b5b-b770-0a64227a8141","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"formdata","formdata":[{"key":"id","value":"2","type":"text"},{"key":"name","value":"Fyzika","type":"text"}]},"url":"https://www.learn.hajek.live/api/deck/update","description":"<h3 id=\"update-deck\">Update Deck</h3>\n<p>This endpoint is used to update a deck.</p>\n<h4 id=\"request-body\">Request Body</h4>\n<ul>\n<li>id (text) - The ID of the deck to be updated.</li>\n<li>name (text) - The new name for the deck.</li>\n</ul>\n<h4 id=\"response\">Response</h4>\n<ul>\n<li>Status: 200</li>\n<li>message - A message indicating the result of the update.</li>\n<li>data - The updated data, if applicable.</li>\n<li>status - The status of the update.</li>\n<li>code - The status code of the response.</li>\n</ul>\n","urlObject":{"path":["deck","update"],"host":["https://www.learn.hajek.live/api"],"query":[{"disabled":true,"key":"","value":null}],"variable":[]}},"response":[],"_postman_id":"fe643b6e-03ee-4b5b-b770-0a64227a8141"}],"id":"2b5c0762-ad04-49e3-803a-a207a990c9a2","_postman_id":"2b5c0762-ad04-49e3-803a-a207a990c9a2","description":""},{"name":"Trida (class)","item":[{"name":"Create new trida","id":"000af593-6aff-46ba-b4b7-a3ed67e57e4a","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"formdata","formdata":[{"key":"name","value":"matika","type":"text"}]},"url":"https://www.learn.hajek.live/api/tridy/new","description":"<h3 id=\"add-new-tridy\">Add New Tridy</h3>\n<p>This endpoint is used to add a new class.</p>\n<h4 id=\"request-body\">Request Body</h4>\n<ul>\n<li><p>The request should be sent as form-data.</p>\n<ul>\n<li><code>name</code> (text) - The name of the class.</li>\n</ul>\n</li>\n</ul>\n<h4 id=\"response\">Response</h4>\n<p>Upon a successful request, the server returns a status code of 200 with the following response body:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">  {\n      \"message\": \"\",\n      \"data\": null,\n      \"status\": \"\",\n      \"code\": 0\n  }\n\n</code></pre>\n","urlObject":{"path":["tridy","new"],"host":["https://www.learn.hajek.live/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"000af593-6aff-46ba-b4b7-a3ed67e57e4a"},{"name":"Get trida by id","id":"8d69d254-4678-4c36-aec0-c80fe1fb5c79","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"https://www.learn.hajek.live/api/tridy/2","description":"<h1 id=\"get-tridyid\">GET /tridy/{id}</h1>\n<p>This endpoint retrieves information for a specific resource with the ID.</p>\n<h2 id=\"response\">Response</h2>\n<ul>\n<li><code>message</code>: A message related to the response.</li>\n<li><code>data</code><ul>\n<li><code>id</code>: The ID of the resource.</li>\n<li><code>name</code>: The name of the resource.</li>\n<li><code>userEntity</code><ul>\n<li><code>id</code>: The ID of the user associated with the resource.</li>\n<li><code>username</code>: The username of the user.</li>\n<li><code>email</code>: The email of the user.</li>\n<li><code>roles</code>: An array of roles associated with the user.<ul>\n<li><code>authority</code>: The authority of a specific role.</li>\n</ul>\n</li>\n<li><code>rolesStr</code>: A string representation of the user's roles.</li>\n</ul>\n</li>\n</ul>\n</li>\n<li><code>status</code>: The status of the response.</li>\n<li><code>code</code>: The status code of the response.</li>\n</ul>\n","urlObject":{"path":["tridy","2"],"host":["https://www.learn.hajek.live/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"8d69d254-4678-4c36-aec0-c80fe1fb5c79"},{"name":"Delete trida","id":"c82dd9a2-7910-43a2-b2e2-68858d2eb51b","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"formdata","formdata":[{"key":"id","value":"3","type":"text"}]},"url":"https://www.learn.hajek.live/api/tridy/delete","description":"<p>Returns 204 NO CONTENT if successful</p>\n","urlObject":{"path":["tridy","delete"],"host":["https://www.learn.hajek.live/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"c82dd9a2-7910-43a2-b2e2-68858d2eb51b"},{"name":"Get all trida","id":"1aa11588-2c56-41f5-bb27-3951fb559dfa","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"https://www.learn.hajek.live/api/tridy/all","description":"<p>This endpoint makes an HTTP GET request to retrieve all \"tridy\". The request does not contain a request body.</p>\n<p>The response to the last call had a status code of 200 and included a JSON object with a \"message\", \"data\", \"status\", and \"code\" keys. The \"data\" key holds an array of objects, each containing an \"id\", \"name\", and \"userEntity\" object with \"id\", \"username\", \"email\", \"roles\", and \"rolesStr\" keys.</p>\n<p>The userEntity object contains information about the user, including their \"id\", \"username\", \"email\", \"roles\", and \"rolesStr\".</p>\n","urlObject":{"path":["tridy","all"],"host":["https://www.learn.hajek.live/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"1aa11588-2c56-41f5-bb27-3951fb559dfa"},{"name":"Update trida","id":"ddcb4bfc-0d78-4fe9-a8d3-db424f2f2d7d","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"formdata","formdata":[{"key":"id","value":"2","type":"text"},{"key":"name","value":"Fyzika","type":"text"}]},"url":"https://www.learn.hajek.live/api/tridy/update","description":"<p>This endpoint makes an HTTP POST request to update a resource at the specified URL. The request should include a form-data body with 'id' and 'name' parameters. The 'id' parameter should be of type text, and the 'name' parameter should also be of type text.</p>\n<p>The response to the request will have a status code of 200, along with a JSON body containing the keys 'message', 'data', 'status', and 'code'. The 'message' key may contain a descriptive message, the 'data' key may hold the updated resource data, the 'status' key may contain a status description, and the 'code' key may hold a status code.</p>\n","urlObject":{"path":["tridy","update"],"host":["https://www.learn.hajek.live/api"],"query":[{"disabled":true,"key":"","value":null}],"variable":[]}},"response":[],"_postman_id":"ddcb4bfc-0d78-4fe9-a8d3-db424f2f2d7d"}],"id":"95d3f298-ab0f-4918-b1f3-94f44c485cb3","_postman_id":"95d3f298-ab0f-4918-b1f3-94f44c485cb3","description":""},{"name":"Image","item":[{"name":"Get image","id":"2a15cd80-f2aa-4a98-bbf5-cfddef5389d5","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"https://www.learn.hajek.live/api/image/2","description":"<p>This endpoint makes an HTTP GET request to retrieve information about a specific image. The request should be made to https://www.learn.hajek.live/api/image/2.</p>\n<p>The response to the last call had a status code of 200 and included a JSON object with the following structure:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"message\": \"\",\n    \"data\": {\n        \"id\": 0,\n        \"name\": \"\",\n        \"position\": 0\n    },\n    \"status\": \"\",\n    \"code\": 0\n}\n\n</code></pre>\n<p>The \"data\" object contains information about the image, including its ID, name, and position.</p>\n","urlObject":{"path":["image","2"],"host":["https://www.learn.hajek.live/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"2a15cd80-f2aa-4a98-bbf5-cfddef5389d5"},{"name":"Upload image","id":"052dfd41-03ff-48c5-b447-a2d0b0cfaddc","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"formdata","formdata":[{"key":"file","type":"file","src":"/Users/matyashajek/Downloads/799px-A_cat.jpeg"}]},"url":"https://www.learn.hajek.live/api/image/upload","description":"<p>Deprecated</p>\n","urlObject":{"path":["image","upload"],"host":["https://www.learn.hajek.live/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"052dfd41-03ff-48c5-b447-a2d0b0cfaddc"},{"name":"Get image by cardid","id":"722d408a-defa-45b0-9bac-027509a7b2c3","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"formdata","formdata":[{"key":"cardid","value":"56","type":"text"}]},"url":"https://www.learn.hajek.live/api/image/find","description":"<h3 id=\"post-imagefind\">POST /image/find</h3>\n<p>This endpoint is used to find an image by card ID.</p>\n<h4 id=\"request-body\">Request Body</h4>\n<ul>\n<li>form-data<ul>\n<li><code>cardid</code> (text): The ID of the card to search for.</li>\n</ul>\n</li>\n</ul>\n<h4 id=\"response\">Response</h4>\n<ul>\n<li>Status: 200</li>\n<li><code>message</code> (string): A message related to the response.</li>\n<li><code>data</code> (array): An array of objects containing image information.<ul>\n<li><code>id</code> (integer): The ID of the image.</li>\n<li><code>name</code> (string): The name of the image.</li>\n<li><code>position</code> (integer): The position of the image.</li>\n</ul>\n</li>\n<li><code>status</code> (string): The status of the response.</li>\n<li><code>code</code> (integer): The status code of the response.</li>\n</ul>\n","urlObject":{"path":["image","find"],"host":["https://www.learn.hajek.live/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"722d408a-defa-45b0-9bac-027509a7b2c3"},{"name":"Get all images","id":"2e88e126-5ea0-47a5-9108-730799e7256d","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"https://www.learn.hajek.live/api/image/all","description":"<p>This endpoint retrieves all the images.</p>\n<p>No request body is required for this request.</p>\n<h3 id=\"response\">Response</h3>\n<ul>\n<li><p>Status: 200</p>\n</li>\n<li><p>Body:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"message\": \"\",\n    \"data\": [\n        {\n            \"id\": 0,\n            \"name\": \"\",\n            \"position\": 0\n        }\n    ],\n    \"status\": \"\",\n    \"code\": 0\n}\n\n</code></pre>\n<p>  The response includes a message, data array containing image details like id, name, and position, status, and code.</p>\n</li>\n</ul>\n","urlObject":{"path":["image","all"],"host":["https://www.learn.hajek.live/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"2e88e126-5ea0-47a5-9108-730799e7256d"},{"name":"Show image","id":"8d0c9c72-a06a-4bd6-95d2-90acc052caa4","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"https://www.learn.hajek.live/api/image/show/2","description":"<p>This endpoint makes an HTTP GET request to retrieve the image with the ID 2. The request does not include a request body. The response will have a status code of 200.</p>\n","urlObject":{"path":["image","show","2"],"host":["https://www.learn.hajek.live/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"8d0c9c72-a06a-4bd6-95d2-90acc052caa4"}],"id":"908699e3-9398-4133-858f-8de8d96c45bf","_postman_id":"908699e3-9398-4133-858f-8de8d96c45bf","description":""},{"name":"Learn","item":[{"name":"Learn session","item":[{"name":"Create new session","id":"73282652-0e60-448b-8b0d-90693a98b6ca","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"formdata","formdata":[{"key":"deckId","value":"1","type":"text"},{"key":"numberOfCardsInActiveLearning","value":"3","type":"text"}]},"url":"https://www.learn.hajek.live/api/learnsession/new","description":"<h1 id=\"create-new-learn-session\">Create New Learn Session</h1>\n<p>This endpoint allows you to create a new learn session.</p>\n<h2 id=\"request-body\">Request Body</h2>\n<ul>\n<li>deckId (text): The ID of the deck for the new learn session.</li>\n<li>numberOfCardsInActiveLearning (text): The number of cards in active learning for the new session.</li>\n</ul>\n<h2 id=\"response\">Response</h2>\n<ul>\n<li>Status: 201</li>\n<li>Content-Type: application/json</li>\n</ul>\n<h3 id=\"response-body\">Response Body</h3>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"message\": \"\",\n    \"data\": {\n        \"id\": 0,\n        \"deckEntity\": {\n            \"id\": 0,\n            \"name\": \"\",\n            \"tridaEntity\": {\n                \"id\": 0,\n                \"name\": \"\",\n                \"userEntity\": {\n                    \"id\": 0,\n                    \"username\": null,\n                    \"email\": \"\",\n                    \"roles\": [\n                        {\n                            \"authority\": \"\"\n                        }\n                    ],\n                    \"rolesStr\": \"\"\n                }\n            }\n        },\n        \"currentIndex\": 0,\n        \"numberOfCardsInActiveLearning\": 0\n    },\n    \"status\": \"\",\n    \"code\": 0\n}\n</code></pre>\n","urlObject":{"path":["learnsession","new"],"host":["https://www.learn.hajek.live/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"73282652-0e60-448b-8b0d-90693a98b6ca"},{"name":"Update session","id":"b016c61d-9977-4a3f-a4c3-483fe722949a","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"formdata","formdata":[{"key":"sessionId","value":"1","description":"<p>learnsessionid</p>\n","type":"text"},{"key":"numberOfCardsInActiveLearning","value":"5","description":"<p>how many cards you wanna have in \"active learning\"</p>\n","type":"text"}]},"url":"https://www.learn.hajek.live/api/learnsession/update","description":"<h1 id=\"update-learn-session\">Update Learn Session</h1>\n<p>This endpoint is used to update a learn session.</p>\n<h2 id=\"request-body\">Request Body</h2>\n<ul>\n<li><code>sessionId</code> (text): The ID of the learn session.</li>\n<li><code>numberOfCardsInActiveLearning</code> (text): The number of cards to have in \"active learning\".</li>\n</ul>\n<h2 id=\"response\">Response</h2>\n<ul>\n<li><code>message</code> (string): A message regarding the status of the request.</li>\n<li><code>data</code> (object): The data related to the updated learn session.</li>\n<li><code>status</code> (string): The status of the response.</li>\n<li><code>code</code> (integer): The status code of the response.</li>\n</ul>\n","urlObject":{"path":["learnsession","update"],"host":["https://www.learn.hajek.live/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"b016c61d-9977-4a3f-a4c3-483fe722949a"},{"name":"Get session","id":"2c1da2f2-e5a8-42cf-b0df-54167a9291e2","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"https://www.learn.hajek.live/api/learnsession/1","description":"<h1 id=\"get-learn-session-details\">Get Learn Session Details</h1>\n<p>This endpoint retrieves details of a specific learn session.</p>\n<h2 id=\"request\">Request</h2>\n<h3 id=\"endpoint\">Endpoint</h3>\n<p><code>GET /learnsession/5</code></p>\n<h3 id=\"response\">Response</h3>\n<ul>\n<li>Status: 200</li>\n<li>Content-Type: application/json</li>\n</ul>\n<h4 id=\"response-body\">Response Body</h4>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"message\": \"\",\n    \"data\": {\n        \"id\": 0,\n        \"deckEntity\": {\n            \"id\": 0,\n            \"name\": \"\",\n            \"tridaEntity\": {\n                \"id\": 0,\n                \"name\": \"\",\n                \"userEntity\": {\n                    \"id\": 0,\n                    \"username\": null,\n                    \"email\": \"\",\n                    \"roles\": [\n                        {\n                            \"authority\": \"\"\n                        }\n                    ],\n                    \"rolesStr\": \"\"\n                }\n            }\n        },\n        \"currentIndex\": 0,\n        \"numberOfCardsInActiveLearning\": 0,\n        \"progress\": 0\n    },\n    \"status\": \"\",\n    \"code\": 0\n}\n\n</code></pre>\n<p>This endpoint returns the details of a learn session including the session ID, deck details, user information, current index, number of cards in active learning, and progress.</p>\n","urlObject":{"path":["learnsession","1"],"host":["https://www.learn.hajek.live/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"2c1da2f2-e5a8-42cf-b0df-54167a9291e2"}],"id":"d1593c30-4c99-4828-b8af-c52b0b0b4de8","_postman_id":"d1593c30-4c99-4828-b8af-c52b0b0b4de8","description":""},{"name":"Get next card","id":"3224b74c-b0c8-4355-ac67-abce5d57c562","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"formdata","formdata":[{"key":"id","value":"1","description":"<p>id of learning session</p>\n","type":"text"}]},"url":"https://www.learn.hajek.live/api/learn/next","description":"<h3 id=\"add-learning-session\">Add Learning Session</h3>\n<p>This endpoint allows the user to add a new learning session.</p>\n<h4 id=\"request-body\">Request Body</h4>\n<ul>\n<li>id (text, required): The id of the learning session.</li>\n</ul>\n<h4 id=\"response\">Response</h4>\n<ul>\n<li>Status: 200</li>\n<li>Content-Type: application/json</li>\n<li>message (string): A message related to the response.</li>\n<li>data (object): An object containing details of the learning session.<ul>\n<li>id (number): The id of the learning session.</li>\n<li>hiddenPart (string): The hidden part of the learning session.</li>\n<li>visiblePart (string): The visible part of the learning session.</li>\n<li>mark (number): The mark of the learning session.</li>\n<li>deckEntity (object): An object containing details of the deck entity.<ul>\n<li>id (number): The id of the deck entity.</li>\n<li>name (string): The name of the deck entity.</li>\n<li>tridaEntity (object): An object containing details of the trida entity.<ul>\n<li>id (number): The id of the trida entity.</li>\n<li>name (string): The name of the trida entity.</li>\n<li>userEntity (object): An object containing details of the user entity.<ul>\n<li>id (number): The id of the user entity.</li>\n<li>username (string): The username of the user entity.</li>\n<li>email (string): The email of the user entity.</li>\n<li>roles (array): An array containing roles of the user entity.<ul>\n<li>authority (string): The authority of the role.</li>\n</ul>\n</li>\n<li>rolesStr (string): String representation of the roles.</li>\n</ul>\n</li>\n</ul>\n</li>\n</ul>\n</li>\n</ul>\n</li>\n<li>status (string): The status of the response.</li>\n<li>code (number): The code related to the response.</li>\n</ul>\n","urlObject":{"path":["learn","next"],"host":["https://www.learn.hajek.live/api"],"query":[],"variable":[]}},"response":[],"_postman_id":"3224b74c-b0c8-4355-ac67-abce5d57c562"}],"id":"1c81c7f9-0908-48d6-a3c6-262ca656c288","_postman_id":"1c81c7f9-0908-48d6-a3c6-262ca656c288","description":""}],"event":[{"listen":"prerequest","script":{"id":"101a2dd4-7caf-445d-bc95-5e5572540446","type":"text/javascript","exec":[""]}},{"listen":"test","script":{"id":"3df5369c-5661-4110-bc25-681d1993f287","type":"text/javascript","exec":[""]}}],"variable":[{"key":"baseUrl","value":"http://localhost/api","disabled":true},{"key":"baseUrl","value":"https://www.learn.hajek.live/api","type":"string"}]}