{"info":{"_postman_id":"ff69b819-eb7b-42db-a9cd-f5f3d0b22ec3","name":"XConf Log Server","description":"<html><head></head><body><p>This collection defines the REST API between the Alticast Xconf Log Server and the RDK LLC Xconf Data Server. The API is used to upload log files to the Log Server as well as gather meta-data associated with the logs.</p>\n</body></html>","schema":"https://schema.getpostman.com/json/collection/v2.0.0/collection.json","toc":[],"owner":"5341212","collectionId":"ff69b819-eb7b-42db-a9cd-f5f3d0b22ec3","publishedId":"SzmcbzBm","public":true,"customColor":{"top-bar":"FFFFFF","right-sidebar":"303030","highlight":"EF5B25"},"publishDate":"2020-05-11T23:20:08.000Z"},"item":[{"name":"Admin","item":[{"name":"Ping logserver Request","id":"7e00d912-0d7f-4b1a-900a-33fe6a81a125","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"http://{{ip_address}}:8080/api/{{version}}/ping","description":"<p>Detect whether the Xconf Log Server is active or not.</p>\n<ul>\n<li>{{ip_address}} is the IP Address for the log server.</li>\n<li>{{version}} is a string literal indicating the version number for the API.</li>\n</ul>\n<h1 id=\"reponse\">Reponse</h1>\n<p>The response for this request will be a JSON formatted string.</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code>{\n    \"message\": \"pong\"\n}\n</code></pre><h1 id=\"example\">Example</h1>\n<p>http://192.168.1.28:8080/api/v1/ping</p>\n<p>where <strong>192.168.1.28</strong> is the IP Address of the log server and <strong>v1</strong> is version 1 of the API.</p>\n","urlObject":{"protocol":"http","port":"8080","path":["api","{{version}}","ping"],"host":["{{ip_address}}"],"query":[],"variable":[]}},"response":[],"_postman_id":"7e00d912-0d7f-4b1a-900a-33fe6a81a125"}],"id":"362bf12f-fb77-4b54-b840-c3d085b962b1","description":"<p>The Admin APIs are used to administer the Alticast Xconf Log Server.</p>\n","_postman_id":"362bf12f-fb77-4b54-b840-c3d085b962b1"},{"name":"API v1","item":[{"name":"Upload File Request","id":"4365f7a1-33d8-433a-9fe9-9dd6601f17d0","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"POST","header":[{"key":"Content-Type","name":"Content-Type","value":"multipart/form-data","type":"text"}],"body":{"mode":"formdata","formdata":[{"key":"filename","description":"<p>The name of the file to upload.</p>\n","type":"file","value":null},{"key":"description","value":"Xconf Log Files Package","description":"<p>Description of the uploaded file.</p>\n","type":"text"},{"key":"contact","value":"mmillard@alticast.com","description":"<p>Contact information, i.e. email address for file submitter.</p>\n","type":"text"}]},"url":"http://{{ip_address}}:8080/api/{{version}}/logs/upload","description":"<p>Upload a log file to the log server.</p>\n<ul>\n<li>{{ip_address}} is the IP Address for the log server.</li>\n<li>{{version}} is a string literal indicating the version number for the API.</li>\n</ul>\n<h1 id=\"body-defintion\">Body Defintion</h1>\n<p>The body is comprised of three key/value pairs:</p>\n<ul>\n<li><strong>filename</strong> : The file to upload.</li>\n<li><strong>description</strong> : A description of the file (optional).</li>\n<li><strong>contact</strong> : Contact information for the file, i.e. email address (optional).</li>\n</ul>\n<p>The RDK LLC Xconf Data Server requires the <strong>filename</strong> parameter. The <strong>description</strong> and <strong>contact</strong> parameters are not currently supported by the RDK LLC Xconf clients.</p>\n<h1 id=\"reponse\">Reponse</h1>\n<p>The reponse to this request will be a JSON formatted string.</p>\n<h2 id=\"success-response\">Success Response</h2>\n<p>Upon success the string will contain the meta-data associated with the uploaded file.</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code>{\n    \"message\": \"Log upload success\",\n    \"reason\": \"\",\n    \"info\": [\n        {\n            \"timeID\": {{uuid}},\n            \"fileName\": {{file_name}},\n            \"location\": {{file_location}},\n            \"size\": {{file_size}},\n            \"createDate\": {{create_data}},\n            \"owner\": {{owner}},\n            \"contact\": {{email}},\n            \"description\": {{description}}\n        }\n    ]\n}\n</code></pre><p><code>{{uuid}}</code> is a unique identifier based on a timestamp when the log was uploaded. This identifier is generated by the log server.</p>\n<p><code>{{file_name}}</code> is the name of the log file.</p>\n<p><code>{{file_location}}</code> is the location on the file server where the log is stored. The location will be determined by the log server configuration.</p>\n<p><code>{{file_size}}</code> is the size of the log files, in Bytes.</p>\n<p><code>{{create_data}}</code> is the creation date for the log file, extracted from the <strong>file_name</strong>.</p>\n<p><code>{{owner}}</code> is the owner of the log file, extracted from the <strong>file_name</strong>.</p>\n<p><code>{{email}}</code> is contact information for the log file. This value is not currently supported by the Xconf client.</p>\n<p><code>{{description}}</code> is textual information describing the contents of the log file. This value isnot currently supported by the Xconf client.</p>\n<p>For example:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code>{\n    \"message\": \"Log upload success\",\n    \"reason\": \"\",\n    \"info\": [\n        {\n            \"timeID\": \"d8f9724b-7dd2-11ea-81e1-000c29c9ae51\",\n            \"fileName\": \"B827EBEADCAB_Logs_03-31-20-09-55PM.tgz\",\n            \"location\": \"file:///opt/logserver/logs\",\n            \"size\": 119042,\n            \"createDate\": \"2020-03-31T21:55:00-06:00\",\n            \"owner\": \"B827EBEADCAB\",\n            \"contact\": \"mmillard@alticast.com\",\n            \"description\": \"Xconf Log Files Package\"\n        }\n    ]\n}\n</code></pre><h2 id=\"error-response\">Error Response</h2>\n<p>In addition to the HTTP status, an error response will return a JSON formatted string:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code>{\n    \"message\": \"Upload error\",\n    \"reason\": {{reason_for_error}}\n}\n</code></pre><p>where {{reason_for_error}} will be a textual description for the error.</p>\n<p>For example:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code>{\n    \"message\": \"GET Form error\",\n    \"reason\": \"http: no such file\"\n}\n</code></pre><h1 id=\"example\">Example</h1>\n<p>http://192.168.1.28:8080/api/v1/logs/upload.</p>\n<p>where <strong>192.168.1.28</strong> is the log server IP Address and <strong>v1</strong> is version 1 of the API.</p>\n","urlObject":{"protocol":"http","port":"8080","path":["api","{{version}}","logs","upload"],"host":["{{ip_address}}"],"query":[],"variable":[]}},"response":[],"_postman_id":"4365f7a1-33d8-433a-9fe9-9dd6601f17d0"},{"name":"Download File Request","id":"553cb22d-bbe3-4bd5-aeb7-b84e049b21ba","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"http://{{ip_address}}:8080/api/{{version}}/logs/download?name={{file_name}}","description":"<p>Download a log file to the log server.</p>\n<ul>\n<li>{{ip_address}} is the IP Address for the log server.</li>\n<li>{{version}} is a string literal indicating the version number for the API.</li>\n<li>{{file_name}} is the name of the file to download.</li>\n</ul>\n<h1 id=\"reponse\">Reponse</h1>\n<p>The reponse to this request will be a JSON formatted string.</p>\n<h2 id=\"success-response\">Success Response</h2>\n<p>Upon success the contents of the file will be downloaded.</p>\n<h2 id=\"error-response\">Error Response</h2>\n<p>In addition to the HTTP status, an error response will return a JSON-formatted string:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code>{\n    \"message\": \"Download error\",\n    \"reason\": {{reason_for_error}}\n}\n</code></pre><p>where {{reason_for_error}} will be a textual description for the error.</p>\n<p>For example:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code>{\n    \"message\": \"Download log error\",\n    \"reason\": \"stat /opt/logserver/logs/_Logs_03-31-20-09-55PM.tgz: no such file or directory\"\n}\n</code></pre><h1 id=\"example\">Example</h1>\n<p>http://192.168.1.28:8080/api/v1/logs/download?name=B827EBEADCAB_Logs_03-31-20-09-55PM.tgz.</p>\n<p>where <strong>192.168.1.28</strong> is the log server IP Address, <strong>v1</strong> is version 1 of the API and <strong>B827EBEADCAB_Logs_03-31-20-09-55PM.tgz</strong> is the name of the file to download.</p>\n","urlObject":{"protocol":"http","port":"8080","path":["api","{{version}}","logs","download"],"host":["{{ip_address}}"],"query":[{"description":{"content":"<p>The name of the log to download.</p>\n","type":"text/plain"},"key":"name","value":"{{file_name}}"}],"variable":[]}},"response":[],"_postman_id":"553cb22d-bbe3-4bd5-aeb7-b84e049b21ba"},{"name":"Delete File Request","id":"3c6e912f-bfbe-490d-8712-b33ce8ea8bdc","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"DELETE","header":[],"body":{"mode":"raw","raw":""},"url":"http://{{ip_address}}:8080/api/{{version}}/logs/{{file_name}}","description":"<p>Delete a log from the Xconf Log Server.</p>\n<ul>\n<li>{{ip_address}} is the IP Address for the log server.</li>\n<li>{{version}} is a string literal indicating the version number for the API.</li>\n<li>{{file_name}} is the name of the file to delete.</li>\n</ul>\n<h1 id=\"reponse\">Reponse</h1>\n<p>The response for this request will be a JSON formatted string indicating success or failure.</p>\n<h2 id=\"success-response\">Success Response</h2>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code>{\n    \"message\": \"Delete success\",\n    \"reason\": \"\"\n}\n</code></pre><h2 id=\"error-response\">Error Response</h2>\n<p>In addition to the HTTP status, an error response will return a JSON-formatted string:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code>{\n    \"message\": \"Delete error\",\n    \"reason\": {{reason_for_error}}\n}\n</code></pre><p>where {{reason_for_error}} will be a textual description for the error.</p>\n<p>For example:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code>{\n    \"message\": \"Delete error\",\n    \"reason\": \"stat /opt/logserver/logs/B827EBEADCAB_Logs_03-31-20-09-55PM.tgz: no such file or directory\"\n}\n</code></pre><h1 id=\"example\">Example</h1>\n<p>http://192.168.1.28:8080/api/v1/logs/B827EBEADCAB_Logs_03-31-20-09-55PM.tgz</p>\n<p>where <strong>192.168.1.28</strong> is the IP Address of the log server, <strong>v1</strong> is version 1 of the API and <strong>B827EBEADCAB_Logs_03-31-20-09-55PM.tgz</strong> is the name of the file to delete.</p>\n","urlObject":{"protocol":"http","port":"8080","path":["api","{{version}}","logs","{{file_name}}"],"host":["{{ip_address}}"],"query":[],"variable":[]}},"response":[],"_postman_id":"3c6e912f-bfbe-490d-8712-b33ce8ea8bdc"},{"name":"Info Request","id":"099cfbef-8726-456d-b7f2-69d37666c709","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[],"url":"http://{{ip_address}}:8080/api/{{version}}/logs/info?id={{uuid}}&fileName={{file_name}}&owner={{owner}}&createDate={{create_date}}&size={{size}}","description":"<p>Retrieve log files' meta-data from the log server.</p>\n<ul>\n<li>{{ip_address}} is the IP Address for the log server.</li>\n<li>{{version}} is a string literal indicating the version number for the API.</li>\n</ul>\n<p>Filtering parameters include:</p>\n<ul>\n<li>{{uuid}} is a unique identifier assigned to the log when it is uploaded to the server.</li>\n<li>{{file_name}} is the name of the file that was uploaded to the server.</li>\n<li>{{owner}} is the name of the log file's owner (i.e. the device MAC Address).</li>\n<li>{{create_date}} is the creation date timestamp for the log file.</li>\n<li>{{size}} is the size of the file (in KB).</li>\n</ul>\n<p>Based on the filtering parameters, the query will find all matching entries in the log server database. If no parameters are specified, then <strong>all</strong> entries in the database will be returned. If no match is found in the database for the specified parameters, then success will be returned but the array of info JSON elements will be empty.</p>\n<h1 id=\"reponse\">Reponse</h1>\n<p>The reponse to this request will be a JSON formatted string.</p>\n<h2 id=\"success-response\">Success Response</h2>\n<p>Upon success the string will contain the meta-data associated with the uploaded file(s). The response may contain information for multiple logs based on the parameters passed as part of the query.</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code>{\n    \"message\": \"Log upload success\",\n    \"reason\": \"\",\n    \"info\": [\n        {\n            \"timeID\": {{uuid}},\n            \"fileName\": {{file_name}},\n            \"location\": {{file_location}},\n            \"size\": {{file_size}},\n            \"createDate\": {{create_data}},\n            \"owner\": {{owner}},\n            \"contact\": {{email}},\n            \"description\": {{description}}\n        }\n    ]\n}\n</code></pre><p><code>{{uuid}}</code> is a unique identifier based on a timestamp when the log was uploaded. This identifier is generated by the log server.</p>\n<p><code>{{file_name}}</code> is the name of the log file.</p>\n<p><code>{{file_location}}</code> is the location on the file server where the log is stored. The location will be determined by the log server configuration.</p>\n<p><code>{{file_size}}</code> is the size of the log files, in Bytes.</p>\n<p><code>{{create_data}}</code> is the creation date for the log file, extracted from the <strong>file_name</strong>.</p>\n<p><code>{{owner}}</code> is the owner of the log file, extracted from the <strong>file_name</strong>.</p>\n<p><code>{{email}}</code> is contact information for the log file. This value is not currently supported by the Xconf client.</p>\n<p><code>{{description}}</code> is textual information describing the contents of the log file. This value isnot currently supported by the Xconf client.</p>\n<h2 id=\"error-response\">Error Response</h2>\n<p>In addition to the HTTP status, an error response will return a JSON formatted string:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code>{\n    \"message\": \"Info error\",\n    \"reason\": {{reason_for_error}}\n}\n</code></pre><p>where {{reason_for_error}} will be a textual description for the error.</p>\n<p>For example:</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code>{\n    \"message\": \"GET Form error\",\n    \"reason\": \"http: no such file\"\n}\n</code></pre><h1 id=\"examples\">Examples</h1>\n<h2 id=\"file-name-filtering-example\">File name filtering example</h2>\n<p>http://192.168.1.28:8080/api/v1/logs/info?fileName=B827EBEADCAB_Logs_03-31-20-09-55PM.tgz.</p>\n<p>where <strong>192.168.1.28</strong> is the log server IP Address, <strong>v1</strong> is version 1 of the API and <strong>B827EBEADCAB_Logs_03-31-20-09-55PM.tgz</strong> is the name of the log to retrieve the meta-data for.</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code>{\n    \"message\": \"Info retrieval success\",\n    \"reason\": \"\",\n    \"info\": [\n        {\n            \"timeID\": \"d8f9724b-7dd2-11ea-81e1-000c29c9ae51\",\n            \"fileName\": \"B827EBEADCAB_Logs_03-31-20-09-55PM.tgz\",\n            \"location\": \"file:///opt/logserver/logs\",\n            \"size\": 119042,\n            \"createDate\": \"2020-04-01T03:55:00Z\",\n            \"owner\": \"B827EBEADCAB\",\n            \"contact\": \"mmillard@alticast.com\",\n            \"description\": \"Xconf Log Files Package\"\n        }\n    ]\n}\n</code></pre><h2 id=\"no-matching-filtering-example\">No matching filtering example</h2>\n<p>http://192.168.1.28:8080/api/v1/logs/info?fileName=log_does_not_exist.tgz.</p>\n<p>where <strong>192.168.1.28</strong> is the log server IP Address, <strong>v1</strong> is version 1 of the API and <strong>log_does_not_exist</strong> is the name of the log to retrieve the meta-data for (but it does not exist on the log erver).</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code>{\n    \"message\": \"Info retrieval success\",\n    \"reason\": \"\",\n    \"info\": []\n}\n</code></pre>","urlObject":{"protocol":"http","port":"8080","path":["api","{{version}}","logs","info"],"host":["{{ip_address}}"],"query":[{"description":{"content":"<p>A unique identifier for the file meta-data</p>\n","type":"text/plain"},"key":"id","value":"{{uuid}}"},{"description":{"content":"<p>The name of the file to retrieve.</p>\n","type":"text/plain"},"key":"fileName","value":"{{file_name}}"},{"description":{"content":"<p>The owner of the file to retrieve.</p>\n","type":"text/plain"},"key":"owner","value":"{{owner}}"},{"description":{"content":"<p>The date of creation for the file to retrieve.</p>\n","type":"text/plain"},"key":"createDate","value":"{{create_date}}"},{"description":{"content":"<p>The size of the file to retrieve.</p>\n","type":"text/plain"},"key":"size","value":"{{size}}"}],"variable":[]}},"response":[],"_postman_id":"099cfbef-8726-456d-b7f2-69d37666c709"}],"id":"189e8220-a7cc-4e5d-b1e1-24e9397e9184","description":"<p>Version <strong>v1</strong> of the log server REST APIs.</p>\n","_postman_id":"189e8220-a7cc-4e5d-b1e1-24e9397e9184"}]}