{"info":{"_postman_id":"9d70dfe5-abd7-4934-8f10-860cbe450aca","name":"Permutation Function","description":"<html><head></head><body><h1 id=\"dowell-permutation-function\">Dowell Permutation Function</h1>\n<p>To use the Dowell Permutation Function, you need to follow these steps:</p>\n<ol>\n<li>Find Permutation:<ul>\n<li>Request: This request is a POST request that generates permutations based on the given parameters. It sends a JSON payload in the request body with the following fields:<ul>\n<li><code>inserted_id</code>: The ID of the previous permutation (null for the first permutation).</li>\n<li><code>nextVariable</code>: The next variable to be included in the permutation.</li>\n<li><code>n</code>: The total number of elements available for permutation.</li>\n<li><code>r</code>: The number of elements to be selected in each permutation.</li>\n<li><code>command</code>: The command to find a permutation.</li>\n</ul>\n</li>\n<li>Response: The response returns the generated permutation in JSON format. The response body contains the following information:<ul>\n<li><code>eventId</code>: An event ID associated with the permutation.</li>\n<li><code>n</code>: The total number of elements available for permutation.</li>\n<li><code>r</code>: The number of elements selected in each permutation.</li>\n<li><code>numberOfPermutations</code>: The total number of possible permutations.</li>\n<li><code>permutationVariables</code>: An array of arrays, where each inner array represents a permutation with the selected variables.</li>\n<li><code>inserted_id</code>: The ID of the inserted permutation.</li>\n</ul>\n</li>\n</ul>\n</li>\n<li>Save Permutation:<ul>\n<li>Request: This request is a POST request that saves a selected permutation. It sends a JSON payload in the request body with the following fields:<ul>\n<li><code>inserted_id</code>: The ID of the permutation to be saved.</li>\n<li><code>selectedPermutation</code>: An array of variables representing the selected permutation.</li>\n<li><code>command</code>: The command to save the permutation.</li>\n</ul>\n</li>\n<li>Response: The response confirms the successful saving of the permutation. The response body contains a success message.</li>\n</ul>\n</li>\n<li>Show Permutation:<ul>\n<li>Request: This request is a POST request that retrieves a specific permutation based on its ID. It sends a JSON payload in the request body with the following fields:<ul>\n<li><code>inserted_id</code>: The ID of the permutation to be retrieved.</li>\n<li><code>command</code>: The command to show the permutation.</li>\n</ul>\n</li>\n<li>Response: The response returns the requested permutation in JSON format. The response body contains the following information:<ul>\n<li><code>eventId</code>: An event ID associated with the permutation.</li>\n<li><code>n</code>: The total number of elements available for permutation.</li>\n<li><code>r</code>: The number of elements selected in each permutation.</li>\n<li><code>permutationVariables</code>: An array representing the selected permutation.</li>\n<li><code>inserted_id</code>: The ID of the permutation.</li>\n</ul>\n</li>\n</ul>\n</li>\n</ol>\n<p>If you have any issues or further questions, don't hesitate to contact Dowell's customer support team. Enjoy using the services provided by Dowell API!</p>\n<p>EndFragment</p>\n</body></html>","schema":"https://schema.getpostman.com/json/collection/v2.0.0/collection.json","toc":[{"content":"Dowell Permutation Function","slug":"dowell-permutation-function"}],"owner":"27523601","collectionId":"9d70dfe5-abd7-4934-8f10-860cbe450aca","publishedId":"2s93mAVL3e","public":true,"customColor":{"top-bar":"FFFFFF","right-sidebar":"303030","highlight":"FF6C37"},"publishDate":"2023-05-31T14:33:25.000Z"},"item":[{"name":"1. Find Permutation","id":"02eab617-a9a5-42ec-92ca-86eb19efe326","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\r\n    \"inserted_id\": null,\r\n    \"nextVariable\":\"A\",\r\n    \"n\":5,\r\n    \"r\":3,\r\n    \"command\":\"findPermutation\"\r\n}","options":{"raw":{"language":"json"}}},"url":"https://100050.pythonanywhere.com/permutationapi/api/","urlObject":{"protocol":"https","path":["permutationapi","api",""],"host":["100050","pythonanywhere","com"],"query":[],"variable":[]}},"response":[{"id":"ba508fd4-2b8e-40d5-937f-7d3d00cd831f","name":"1. First Permutation is Generated","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\r\n    \"inserted_id\": null,\r\n    \"nextVariable\":\"A\",\r\n    \"n\":5,\r\n    \"r\":3,\r\n    \"command\":\"findPermutation\"\r\n}","options":{"raw":{"language":"json"}}},"url":"https://100050.pythonanywhere.com/permutationapi/api/"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Date","value":"Wed, 31 May 2023 14:11:46 GMT"},{"key":"Content-Type","value":"application/json"},{"key":"Content-Length","value":"164"},{"key":"Connection","value":"keep-alive"},{"key":"Vary","value":"Origin"},{"key":"X-Frame-Options","value":"DENY"},{"key":"X-Content-Type-Options","value":"nosniff"},{"key":"Referrer-Policy","value":"same-origin"},{"key":"Cross-Origin-Opener-Policy","value":"same-origin"},{"key":"X-Clacks-Overhead","value":"GNU Terry Pratchett"},{"key":"Server","value":"PythonAnywhere"}],"cookie":[],"responseTime":null,"body":"{\n    \"eventId\": \"FB1010000000000000000000003004\",\n    \"n\": 5,\n    \"r\": 3,\n    \"numberOfPermutations\": 60,\n    \"permutationsVariables\": [\n        \"A\"\n    ],\n    \"inserted_id\": \"6477559db5b42688f25a7eda\"\n}"},{"id":"4a3eba1e-5a51-4b38-b9c9-f9cfa8a11156","name":"2. Second Permutation is Generated","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\r\n    \"inserted_id\": \"6477559db5b42688f25a7eda\",\r\n    \"nextVariable\":\"B\",\r\n    \"n\":5,\r\n    \"r\":3,\r\n    \"command\":\"findPermutation\"\r\n}","options":{"raw":{"language":"json"}}},"url":"https://100050.pythonanywhere.com/permutationapi/api/"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Date","value":"Wed, 31 May 2023 14:21:40 GMT"},{"key":"Content-Type","value":"application/json"},{"key":"Content-Length","value":"138"},{"key":"Connection","value":"keep-alive"},{"key":"Vary","value":"Origin"},{"key":"X-Frame-Options","value":"DENY"},{"key":"X-Content-Type-Options","value":"nosniff"},{"key":"Referrer-Policy","value":"same-origin"},{"key":"Cross-Origin-Opener-Policy","value":"same-origin"},{"key":"X-Clacks-Overhead","value":"GNU Terry Pratchett"},{"key":"Server","value":"PythonAnywhere"}],"cookie":[],"responseTime":null,"body":"{\n    \"n\": 5,\n    \"r\": 3,\n    \"numberOfPermutations\": 60,\n    \"permutationsVariables\": [\n        [\n            \"B\",\n            \"A\"\n        ],\n        [\n            \"A\",\n            \"B\"\n        ]\n    ],\n    \"inserted_id\": \"6477559db5b42688f25a7eda\"\n}"},{"id":"c3e81c39-3116-43fd-9c89-d2e2c365069d","name":"3. Third Permutation is Generated","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\r\n    \"inserted_id\": \"6477559db5b42688f25a7eda\",\r\n    \"nextVariable\":\"C\",\r\n    \"n\":5,\r\n    \"r\":3,\r\n    \"command\":\"findPermutation\"\r\n}","options":{"raw":{"language":"json"}}},"url":"https://100050.pythonanywhere.com/permutationapi/api/"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Date","value":"Wed, 31 May 2023 14:24:41 GMT"},{"key":"Content-Type","value":"application/json"},{"key":"Content-Length","value":"165"},{"key":"Connection","value":"keep-alive"},{"key":"Vary","value":"Origin"},{"key":"X-Frame-Options","value":"DENY"},{"key":"X-Content-Type-Options","value":"nosniff"},{"key":"Referrer-Policy","value":"same-origin"},{"key":"Cross-Origin-Opener-Policy","value":"same-origin"},{"key":"X-Clacks-Overhead","value":"GNU Terry Pratchett"},{"key":"Server","value":"PythonAnywhere"}],"cookie":[],"responseTime":null,"body":"{\n    \"n\": 5,\n    \"r\": 3,\n    \"numberOfPermutations\": 60,\n    \"permutationsVariables\": [\n        [\n            \"C\",\n            \"B\",\n            \"A\"\n        ],\n        [\n            \"B\",\n            \"C\",\n            \"A\"\n        ],\n        [\n            \"B\",\n            \"A\",\n            \"C\"\n        ]\n    ],\n    \"inserted_id\": \"6477559db5b42688f25a7eda\"\n}"},{"id":"9890bcfe-009f-4ba4-b5e3-c1589f19d659","name":"4. Trying to Use More Number of Variables than 'r'","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\r\n    \"inserted_id\": \"6477559db5b42688f25a7eda\",\r\n    \"nextVariable\":\"D\",\r\n    \"n\":5,\r\n    \"r\":3,\r\n    \"command\":\"findPermutation\"\r\n}","options":{"raw":{"language":"json"}}},"url":"https://100050.pythonanywhere.com/permutationapi/api/"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Date","value":"Wed, 31 May 2023 14:26:36 GMT"},{"key":"Content-Type","value":"application/json"},{"key":"Content-Length","value":"44"},{"key":"Connection","value":"keep-alive"},{"key":"Vary","value":"Origin"},{"key":"X-Frame-Options","value":"DENY"},{"key":"X-Content-Type-Options","value":"nosniff"},{"key":"Referrer-Policy","value":"same-origin"},{"key":"Cross-Origin-Opener-Policy","value":"same-origin"},{"key":"X-Clacks-Overhead","value":"GNU Terry Pratchett"},{"key":"Server","value":"PythonAnywhere"}],"cookie":[],"responseTime":null,"body":"{\n    \"message\": \"3 items are already selected.\"\n}"}],"_postman_id":"02eab617-a9a5-42ec-92ca-86eb19efe326"},{"name":"2. Save Permutation","id":"b68b7fa5-1b27-4990-a600-f4219e9b167b","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\r\n    \"inserted_id\":\"6477559db5b42688f25a7eda\",\r\n    \"selectedPermutation\":    [\r\n      \"A\"\r\n    ],\r\n    \"command\":\"savePermutation\"\r\n}","options":{"raw":{"language":"json"}}},"url":"https://100050.pythonanywhere.com/permutationapi/api/","urlObject":{"protocol":"https","path":["permutationapi","api",""],"host":["100050","pythonanywhere","com"],"query":[],"variable":[]}},"response":[{"id":"104626a5-996d-40b1-80dc-27a3e56eeccd","name":"1. First Permutation is Saved","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\r\n    \"inserted_id\":\"6477559db5b42688f25a7eda\",\r\n    \"selectedPermutation\":    [\r\n      \"A\"\r\n    ],\r\n    \"command\":\"savePermutation\"\r\n}","options":{"raw":{"language":"json"}}},"url":"https://100050.pythonanywhere.com/permutationapi/api/"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Date","value":"Wed, 31 May 2023 14:15:39 GMT"},{"key":"Content-Type","value":"application/json"},{"key":"Content-Length","value":"64"},{"key":"Connection","value":"keep-alive"},{"key":"Vary","value":"Origin"},{"key":"X-Frame-Options","value":"DENY"},{"key":"X-Content-Type-Options","value":"nosniff"},{"key":"Referrer-Policy","value":"same-origin"},{"key":"Cross-Origin-Opener-Policy","value":"same-origin"},{"key":"X-Clacks-Overhead","value":"GNU Terry Pratchett"},{"key":"Server","value":"PythonAnywhere"}],"cookie":[],"responseTime":null,"body":"{\n    \"message\": \"Selected permutation ['A'] is saved successfully.\"\n}"},{"id":"7b1b492a-64bd-42f6-968d-c8efb8567216","name":"2. Second Permutation is Saved","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\r\n    \"inserted_id\":\"6477559db5b42688f25a7eda\",\r\n    \"selectedPermutation\":    [\r\n        \"B\",\r\n        \"A\"\r\n    ],\r\n    \"command\":\"savePermutation\"\r\n}","options":{"raw":{"language":"json"}}},"url":"https://100050.pythonanywhere.com/permutationapi/api/"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Date","value":"Wed, 31 May 2023 14:23:36 GMT"},{"key":"Content-Type","value":"application/json"},{"key":"Content-Length","value":"69"},{"key":"Connection","value":"keep-alive"},{"key":"Vary","value":"Origin"},{"key":"X-Frame-Options","value":"DENY"},{"key":"X-Content-Type-Options","value":"nosniff"},{"key":"Referrer-Policy","value":"same-origin"},{"key":"Cross-Origin-Opener-Policy","value":"same-origin"},{"key":"X-Clacks-Overhead","value":"GNU Terry Pratchett"},{"key":"Server","value":"PythonAnywhere"}],"cookie":[],"responseTime":null,"body":"{\n    \"message\": \"Selected permutation ['B', 'A'] is saved successfully.\"\n}"},{"id":"a3b1df61-3359-4f39-8d58-ab5f8a7b5ad3","name":"3. Third Permutation is Saved","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\r\n    \"inserted_id\":\"6477559db5b42688f25a7eda\",\r\n    \"selectedPermutation\":    [\r\n        \"B\",\r\n        \"C\",\r\n        \"A\"\r\n    ],\r\n    \"command\":\"savePermutation\"\r\n}","options":{"raw":{"language":"json"}}},"url":"https://100050.pythonanywhere.com/permutationapi/api/"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Date","value":"Wed, 31 May 2023 14:25:50 GMT"},{"key":"Content-Type","value":"application/json"},{"key":"Content-Length","value":"74"},{"key":"Connection","value":"keep-alive"},{"key":"Vary","value":"Origin"},{"key":"X-Frame-Options","value":"DENY"},{"key":"X-Content-Type-Options","value":"nosniff"},{"key":"Referrer-Policy","value":"same-origin"},{"key":"Cross-Origin-Opener-Policy","value":"same-origin"},{"key":"X-Clacks-Overhead","value":"GNU Terry Pratchett"},{"key":"Server","value":"PythonAnywhere"}],"cookie":[],"responseTime":null,"body":"{\n    \"message\": \"Selected permutation ['B', 'C', 'A'] is saved successfully.\"\n}"}],"_postman_id":"b68b7fa5-1b27-4990-a600-f4219e9b167b"},{"name":"3. See the Permutations","id":"15aa6e98-b4f5-45f4-bcf9-e1488300ac01","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\r\n    \"inserted_id\":\"6477559db5b42688f25a7eda\",\r\n    \"command\":\"showPermutation\"\r\n}","options":{"raw":{"language":"json"}}},"url":"https://100050.pythonanywhere.com/permutationapi/api/","urlObject":{"protocol":"https","path":["permutationapi","api",""],"host":["100050","pythonanywhere","com"],"query":[],"variable":[]}},"response":[{"id":"4ed5f844-acbd-4ec7-ac40-fe884fbd59f6","name":"1. Final Output of the Permutations Function","originalRequest":{"method":"POST","header":[],"body":{"mode":"raw","raw":"{\r\n    \"inserted_id\":\"6477559db5b42688f25a7eda\",\r\n    \"command\":\"showPermutation\"\r\n}","options":{"raw":{"language":"json"}}},"url":"https://100050.pythonanywhere.com/permutationapi/api/"},"status":"OK","code":200,"_postman_previewlanguage":"json","header":[{"key":"Date","value":"Wed, 31 May 2023 14:28:53 GMT"},{"key":"Content-Type","value":"application/json"},{"key":"Content-Length","value":"129"},{"key":"Connection","value":"keep-alive"},{"key":"Vary","value":"Origin"},{"key":"X-Frame-Options","value":"DENY"},{"key":"X-Content-Type-Options","value":"nosniff"},{"key":"Referrer-Policy","value":"same-origin"},{"key":"Cross-Origin-Opener-Policy","value":"same-origin"},{"key":"X-Clacks-Overhead","value":"GNU Terry Pratchett"},{"key":"Server","value":"PythonAnywhere"}],"cookie":[],"responseTime":null,"body":"{\n    \"n\": 5,\n    \"r\": 3,\n    \"numberOfPermutations\": 60,\n    \"permutationsVariables\": [\n        \"B\",\n        \"C\",\n        \"A\"\n    ],\n    \"inserted_id\": \"6477559db5b42688f25a7eda\"\n}"}],"_postman_id":"15aa6e98-b4f5-45f4-bcf9-e1488300ac01"}]}