/
REST API Infographics
REST API Infographics
Charles Bishop (Deactivated)
Owned by Charles Bishop (Deactivated)
For each call, you can add the following command:
-w"\n%{http_code}\n"
After the username and password in order to receive more meaningful HTTP errors.
Read Infographic
Request method - GET
Description
Returns information on a specified infographic within Datameer including version number, class name, link path, file information (uuid, path, description, name), and the infographic configuration and style data.
URI syntax
curl -u '<username>:<password>' -X GET 'http://<Datameer-serverIP>:<port-number>/rest/infographics/<infographics-configuration-id>'
Example response
Large example. Click to expand.
{ "version": "2.1", "className": "datameer.dap.common.entity.infographic.Infographic", "links": { "self": "/rest/infographics/1" }, "file": { "uuid": "26be0e75-d191-4cc2-bc31-e5dbbfa356c3", "path": "/Examples/Basic Tutorial/Solution/Basic Infographic.ifg", "description": "A simple infographic that displays basic web traffic statistics, measuring clicks and traffic per visitor. This infographic is powered by the 'Basic Workbook' workbook.", "name": "Basic Infographic" }, "backgroundType": "color", "backgroundImagePlacement": "full", "backgroundImageFixed": "center", "backgroundImageTile": "both", "tabs": [ { "name": "Page 1", "order": 0, "id": "5dcde2b0-3f63-4132-961d-6230692e3d38", "widgets": [ { "backgroundType": "without", "backgroundImagePlacement": "full", "backgroundImageFixed": "center", "backgroundImageTile": "both", "type": { "name": "Pie Chart", "chart": "infographics/charts/pie_chart", "dataDescriptor": { "maxSize": 20, "data": { "type": [ "INTEGER", "BIG_INTEGER", "FLOAT", "BIG_DECIMAL" ], "dimensions": [ 1, 1 ] }, "label": { "type": [ "ANY" ], "dimensions": [ 1, 1 ] } }, "inspector": "infographics/views/piechart_inspector", "panelGroup": "chart" }, "name": "Pie Chart", "inspectorName": "infographics/views/piechart_inspector", "left": 340, "top": 229, "width": 513, "height": 439, "angle": 0, "isResizable": true, "isDraggable": true, "isLockedToBack": false, "z-index": 2, "id": "199edb02-f195-42ac-ba39-c6d602547dbd", "dataSet": { "maxSize": 20, "descriptor": { "data": { "type": [ "INTEGER", "BIG_INTEGER", "FLOAT", "BIG_DECIMAL" ], "dimensions": [ 1, 1 ] }, "label": { "type": [ "ANY" ], "dimensions": [ 1, 1 ] } }, "dataSeriesGroups": { "data": [ { "type": "INTEGER", "name": "Impressions", "index": 3, "id": "20771089-e7e1-4bfa-8548-e934a3b455fa", "dataSourceId": "V0JLOy9FeGFtcGxlcy9CYXNpYyBUdXRvcmlhbC9Tb2x1dGlvbi9CYXNpYyBXb3JrYm9vay53Yms7MWY3MzZlZWItMDQ4NC00OTU0LWE3YWQtMDNjZmFjOGUyOTBiOzA7MDtkZjRkZTVlNi0zOWVmLTRjMDQtYmE4MS0xZjY2MmY4MzY0ZmM", "dataSourceSpec": { "jobId": 3, "path": "/Examples/Basic Tutorial/Solution/Basic Workbook.wbk", "sheetId": "df4de5e6-39ef-4c04-ba81-1f662f8364fc", "dataType": "latest" } } ], "label": [ { "type": "STRING", "name": "Visitor", "index": 0, "id": "46a828fe-1b0f-4143-895c-1a10a06de02f", "dataSourceId": "V0JLOy9FeGFtcGxlcy9CYXNpYyBUdXRvcmlhbC9Tb2x1dGlvbi9CYXNpYyBXb3JrYm9vay53Yms7MWY3MzZlZWItMDQ4NC00OTU0LWE3YWQtMDNjZmFjOGUyOTBiOzA7MDtkZjRkZTVlNi0zOWVmLTRjMDQtYmE4MS0xZjY2MmY4MzY0ZmM", "dataSourceSpec": { "jobId": 3, "path": "/Examples/Basic Tutorial/Solution/Basic Workbook.wbk", "sheetId": "df4de5e6-39ef-4c04-ba81-1f662f8364fc", "dataType": "latest" } } ] }, "lastExecutionDate": "06/27/2012 05:32:59 PM", "isTruncated": false, "dataSourceId": "V0JLOy9FeGFtcGxlcy9CYXNpYyBUdXRvcmlhbC9Tb2x1dGlvbi9CYXNpYyBXb3JrYm9vay53Yms7MWY3MzZlZWItMDQ4NC00OTU0LWE3YWQtMDNjZmFjOGUyOTBiOzA7MDtkZjRkZTVlNi0zOWVmLTRjMDQtYmE4MS0xZjY2MmY4MzY0ZmM", "dataSourceSpec": { "jobId": 3, "path": "/Examples/Basic Tutorial/Solution/Basic Workbook.wbk", "sheetId": "df4de5e6-39ef-4c04-ba81-1f662f8364fc", "dataType": "latest" } }, "showFrame": true, "opacity": 1, "maxSize": "20", "fillColorList": [ "#1f77b4", "#ff7f0e", "#2ca02c", "#d62728", "#9467bd", "#8c564b", "#e377c2", "#7f7f7f", "#bcbd22", "#17becf" ], "strokeColor": "steelblue", "labelColor": "black", "colorScheme": "categorical", "isShadowVisible": true, "style": "glossy", "showLabels": true, "labelType": "percentage", "fontSize": 10, "fontName": "Verdana", "labelLength": 100, "enableTooltips": true, "labelReduction": "0", "style_text": "Glossy", "colorScheme_text": "Categorical", "marginTop": 184.38, "marginRight": 215.46, "marginBottom": 168.576, "marginLeft": 196.99200000000002 }, { "backgroundType": "without", "backgroundImagePlacement": "full", "backgroundImageFixed": "center", "backgroundImageTile": "both", "type": { "name": "Text", "chart": "infographics/charts/text", "inspector": "infographics/views/text_inspector", "panelGroup": "other", "defaultWidth": 150, "defaultHeight": 50 }, "name": "Text", "inspectorName": "infographics/views/text_inspector", "left": 530, "top": 205, "width": 153, "height": 20, "angle": 0, "isResizable": true, "isDraggable": true, "isLockedToBack": false, "z-index": 3, "id": "de8ac616-1c13-42c8-a46a-5dd1f7577569", "showFrame": true, "opacity": 1, "fillColor": "black", "backColor": "transparent", "editMode": false, "textContent": "Most Active Visitors", "fontSize": "16", "fontName": "Arial", "bold": false, "italic": false, "underline": false, "align": "left", "color": "black" }, { "backgroundType": "without", "backgroundImagePlacement": "full", "backgroundImageFixed": "center", "backgroundImageTile": "both", "type": { "name": "Multi bar chart", "chart": "infographics/charts/multi_bar_chart", "dataDescriptor": { "maxSize": 20, "data": { "type": [ "INTEGER", "BIG_INTEGER", "FLOAT", "BIG_DECIMAL" ], "dimensions": [ 1, 10 ] }, "label": { "type": [ "ANY" ], "dimensions": [ 1, 1 ] } }, "inspector": "infographics/views/multi_bar_chart_inspector", "panelGroup": "chart", "isBarChart": true }, "name": "Multi bar chart", "inspectorName": "infographics/views/multi_bar_chart_inspector", "left": 889.5, "top": 301, "width": 594, "height": 406, "angle": 0, "isResizable": true, "isDraggable": true, "isLockedToBack": false, "z-index": 4, "id": "4ab95e01-4f2b-4593-82e8-3630c6670b66", "dataSet": { "maxSize": 20, "descriptor": { "data": { "type": [ "INTEGER", "BIG_INTEGER", "FLOAT", "BIG_DECIMAL" ], "dimensions": [ 1, 10 ] }, "label": { "type": [ "ANY" ], "dimensions": [ 1, 1 ] } }, "dataSeriesGroups": { "data": [ { "type": "INTEGER", "name": "Traffic", "index": 2, "id": "a180f860-5af6-479b-b803-f950e10ada34", "dataSourceId": "V0JLOy9FeGFtcGxlcy9CYXNpYyBUdXRvcmlhbC9Tb2x1dGlvbi9CYXNpYyBXb3JrYm9vay53Yms7MWY3MzZlZWItMDQ4NC00OTU0LWE3YWQtMDNjZmFjOGUyOTBiOzA7MDtkZjRkZTVlNi0zOWVmLTRjMDQtYmE4MS0xZjY2MmY4MzY0ZmM", "dataSourceSpec": { "jobId": 3, "path": "/Examples/Basic Tutorial/Solution/Basic Workbook.wbk", "sheetId": "df4de5e6-39ef-4c04-ba81-1f662f8364fc", "dataType": "latest" } } ], "label": [ { "type": "STRING", "name": "Visitor", "index": 0, "id": "17be495e-c915-4acf-a449-5439ff18f008", "dataSourceId": "V0JLOy9FeGFtcGxlcy9CYXNpYyBUdXRvcmlhbC9Tb2x1dGlvbi9CYXNpYyBXb3JrYm9vay53Yms7MWY3MzZlZWItMDQ4NC00OTU0LWE3YWQtMDNjZmFjOGUyOTBiOzA7MDtkZjRkZTVlNi0zOWVmLTRjMDQtYmE4MS0xZjY2MmY4MzY0ZmM", "dataSourceSpec": { "jobId": 3, "path": "/Examples/Basic Tutorial/Solution/Basic Workbook.wbk", "sheetId": "df4de5e6-39ef-4c04-ba81-1f662f8364fc", "dataType": "latest" } } ] }, "lastExecutionDate": "06/27/2012 05:32:59 PM", "isTruncated": false, "dataSourceId": "V0JLOy9FeGFtcGxlcy9CYXNpYyBUdXRvcmlhbC9Tb2x1dGlvbi9CYXNpYyBXb3JrYm9vay53Yms7MWY3MzZlZWItMDQ4NC00OTU0LWE3YWQtMDNjZmFjOGUyOTBiOzA7MDtkZjRkZTVlNi0zOWVmLTRjMDQtYmE4MS0xZjY2MmY4MzY0ZmM", "dataSourceSpec": { "jobId": 3, "path": "/Examples/Basic Tutorial/Solution/Basic Workbook.wbk", "sheetId": "df4de5e6-39ef-4c04-ba81-1f662f8364fc", "dataType": "latest" } }, "showFrame": true, "opacity": 1, "maxSize": "20", "offset": 10, "scale": "linear", "isShadowVisible": true, "isStyleVisible": true, "labelOrientation": "diagonal", "fillColorList": [ "#1f77b4", "#ff7f0e", "#2ca02c", "#d62728", "#9467bd", "#8c564b", "#e377c2", "#7f7f7f", "#bcbd22", "#17becf" ], "strokeColor": "steelblue", "labelColor": "black", "dataDescriptor": { "maxSize": 20, "data": { "type": [ "INTEGER", "BIG_INTEGER", "FLOAT", "BIG_DECIMAL" ], "dimensions": [ 1, 10 ] }, "label": { "type": [ "ANY" ], "dimensions": [ 1, 1 ] } }, "variant": "grouped", "groupGapInPercent": 20, "fontSize": "10", "fontName": "Verdana", "labelLength": "100", "colorScheme": "categorical", "isBarChart": true, "showPoints": true, "enableTooltips": true, "xAxisSkipCount": "0", "labelOrientation_text": "Diagonal", "colorScheme_text": "Categorical", "transpose": false, "marginRight": 75.11, "marginTop": 10, "marginBottom": 150.22, "marginLeft": 75.11 }, { "backgroundType": "without", "backgroundImagePlacement": "full", "backgroundImageFixed": "center", "backgroundImageTile": "both", "type": { "name": "Text", "chart": "infographics/charts/text", "inspector": "infographics/views/text_inspector", "panelGroup": "other", "defaultWidth": 150, "defaultHeight": 50 }, "name": "Text", "inspectorName": "infographics/views/text_inspector", "left": 1103, "top": 206, "width": 167, "height": 23, "angle": 0, "isResizable": true, "isDraggable": true, "isLockedToBack": false, "z-index": 5, "id": "e0be8eb4-b29e-420b-8b83-858861e350b8", "showFrame": true, "opacity": 1, "fillColor": "black", "backColor": "transparent", "editMode": false, "textContent": "Total Traffic By Visitor", "fontSize": "16", "fontName": "Arial", "bold": false, "italic": false, "underline": false, "align": "left", "color": "black" } ] } ] }
Create Infographic
Request method - POST
Description
Adds an infographic file in Datameer.
URI syntax
curl -u '<username>:<password>' -X POST -d @<job-payload>.json 'http://<Datameer-serverIP>:<port-number>/rest/infographics'
Example response
Click here to expand...
{ "version": "2.1", "className": "datameer.dap.common.entity.infographic.Infographic", "links": { "self": "/rest/infographics/9" }, "file": { "uuid": "7e30825d-4923-4ade-8ad1-f06e60a08a1b", "path": "/Examples/REST API Test Infographic.ifg", "description": "A simple infographic that displays basic web traffic statistics, measuring clicks and traffic per visitor. This infographic is powered by the 'Basic Workbook' workbook.", "name": "REST API Test Infographic" }, "backgroundType": "color", "backgroundImagePlacement": "full", "backgroundImageFixed": "center", "backgroundImageTile": "both", "tabs": [ { "name": "Page 1", "order": 0, "id": "5dcde2b0-3f63-4132-961d-6230692e3d38", "widgets": [ { "backgroundType": "without", "backgroundImagePlacement": "full", "backgroundImageFixed": "center", "backgroundImageTile": "both", "type": { "name": "Pie Chart", "chart": "infographics/charts/pie_chart", "dataDescriptor": { "maxSize": 20, "data": { "type": [ "INTEGER", "BIG_INTEGER", "FLOAT", "BIG_DECIMAL" ], "dimensions": [ 1, 1 ] }, "label": { "type": [ "ANY" ], "dimensions": [ 1, 1 ] } }, "inspector": "infographics/views/piechart_inspector", "panelGroup": "chart" }, "name": "Pie Chart", "inspectorName": "infographics/views/piechart_inspector", "left": 340, "top": 229, "width": 513, "height": 439, "angle": 0, "isResizable": true, "isDraggable": true, "isLockedToBack": false, "z-index": 2, "id": "199edb02-f195-42ac-ba39-c6d602547dbd", "dataSet": { "maxSize": 20, "descriptor": { "data": { "type": [ "INTEGER", "BIG_INTEGER", "FLOAT", "BIG_DECIMAL" ], "dimensions": [ 1, 1 ] }, "label": { "type": [ "ANY" ], "dimensions": [ 1, 1 ] } }, "dataSeriesGroups": { "data": [ { "type": "INTEGER", "name": "Impressions", "index": 3, "id": "20771089-e7e1-4bfa-8548-e934a3b455fa", "dataSourceId": "V0JLOy9FeGFtcGxlcy9CYXNpYyBUdXRvcmlhbC9Tb2x1dGlvbi9CYXNpYyBXb3JrYm9vay53Yms7MWY3MzZlZWItMDQ4NC00OTU0LWE3YWQtMDNjZmFjOGUyOTBiOzA7MDtkZjRkZTVlNi0zOWVmLTRjMDQtYmE4MS0xZjY2MmY4MzY0ZmM", "dataSourceSpec": { "jobId": 3, "path": "/Examples/Basic Tutorial/Solution/Basic Workbook.wbk", "sheetId": "df4de5e6-39ef-4c04-ba81-1f662f8364fc", "dataType": "latest" } } ], "label": [ { "type": "STRING", "name": "Visitor", "index": 0, "id": "46a828fe-1b0f-4143-895c-1a10a06de02f", "dataSourceId": "V0JLOy9FeGFtcGxlcy9CYXNpYyBUdXRvcmlhbC9Tb2x1dGlvbi9CYXNpYyBXb3JrYm9vay53Yms7MWY3MzZlZWItMDQ4NC00OTU0LWE3YWQtMDNjZmFjOGUyOTBiOzA7MDtkZjRkZTVlNi0zOWVmLTRjMDQtYmE4MS0xZjY2MmY4MzY0ZmM", "dataSourceSpec": { "jobId": 3, "path": "/Examples/Basic Tutorial/Solution/Basic Workbook.wbk", "sheetId": "df4de5e6-39ef-4c04-ba81-1f662f8364fc", "dataType": "latest" } } ] }, "lastExecutionDate": "06/27/2012 05:32:59 PM", "isTruncated": false, "dataSourceId": "V0JLOy9FeGFtcGxlcy9CYXNpYyBUdXRvcmlhbC9Tb2x1dGlvbi9CYXNpYyBXb3JrYm9vay53Yms7MWY3MzZlZWItMDQ4NC00OTU0LWE3YWQtMDNjZmFjOGUyOTBiOzA7MDtkZjRkZTVlNi0zOWVmLTRjMDQtYmE4MS0xZjY2MmY4MzY0ZmM", "dataSourceSpec": { "jobId": 3, "path": "/Examples/Basic Tutorial/Solution/Basic Workbook.wbk", "sheetId": "df4de5e6-39ef-4c04-ba81-1f662f8364fc", "dataType": "latest" } }, "showFrame": true, "opacity": 1, "maxSize": "20", "fillColorList": [ "#1f77b4", "#ff7f0e", "#2ca02c", "#d62728", "#9467bd", "#8c564b", "#e377c2", "#7f7f7f", "#bcbd22", "#17becf" ], "strokeColor": "steelblue", "labelColor": "black", "colorScheme": "categorical", "isShadowVisible": true, "style": "glossy", "showLabels": true, "labelType": "percentage", "fontSize": 10, "fontName": "Verdana", "labelLength": 100, "enableTooltips": true, "labelReduction": "0", "style_text": "Glossy", "colorScheme_text": "Categorical", "marginTop": 184.38, "marginRight": 215.46, "marginBottom": 168.576, "marginLeft": 196.99200000000002 }, { "backgroundType": "without", "backgroundImagePlacement": "full", "backgroundImageFixed": "center", "backgroundImageTile": "both", "type": { "name": "Text", "chart": "infographics/charts/text", "inspector": "infographics/views/text_inspector", "panelGroup": "other", "defaultWidth": 150, "defaultHeight": 50 }, "name": "Text", "inspectorName": "infographics/views/text_inspector", "left": 530, "top": 205, "width": 153, "height": 20, "angle": 0, "isResizable": true, "isDraggable": true, "isLockedToBack": false, "z-index": 3, "id": "de8ac616-1c13-42c8-a46a-5dd1f7577569", "showFrame": true, "opacity": 1, "fillColor": "black", "backColor": "transparent", "editMode": false, "textContent": "Most Active Visitors", "fontSize": "16", "fontName": "Arial", "bold": false, "italic": false, "underline": false, "align": "left", "color": "black" }, { "backgroundType": "without", "backgroundImagePlacement": "full", "backgroundImageFixed": "center", "backgroundImageTile": "both", "type": { "name": "Multi bar chart", "chart": "infographics/charts/multi_bar_chart", "dataDescriptor": { "maxSize": 20, "data": { "type": [ "INTEGER", "BIG_INTEGER", "FLOAT", "BIG_DECIMAL" ], "dimensions": [ 1, 10 ] }, "label": { "type": [ "ANY" ], "dimensions": [ 1, 1 ] } }, "inspector": "infographics/views/multi_bar_chart_inspector", "panelGroup": "chart", "isBarChart": true }, "name": "Multi bar chart", "inspectorName": "infographics/views/multi_bar_chart_inspector", "left": 889.5, "top": 301, "width": 594, "height": 406, "angle": 0, "isResizable": true, "isDraggable": true, "isLockedToBack": false, "z-index": 4, "id": "4ab95e01-4f2b-4593-82e8-3630c6670b66", "dataSet": { "maxSize": 20, "descriptor": { "data": { "type": [ "INTEGER", "BIG_INTEGER", "FLOAT", "BIG_DECIMAL" ], "dimensions": [ 1, 10 ] }, "label": { "type": [ "ANY" ], "dimensions": [ 1, 1 ] } }, "dataSeriesGroups": { "data": [ { "type": "INTEGER", "name": "Traffic", "index": 2, "id": "a180f860-5af6-479b-b803-f950e10ada34", "dataSourceId": "V0JLOy9FeGFtcGxlcy9CYXNpYyBUdXRvcmlhbC9Tb2x1dGlvbi9CYXNpYyBXb3JrYm9vay53Yms7MWY3MzZlZWItMDQ4NC00OTU0LWE3YWQtMDNjZmFjOGUyOTBiOzA7MDtkZjRkZTVlNi0zOWVmLTRjMDQtYmE4MS0xZjY2MmY4MzY0ZmM", "dataSourceSpec": { "jobId": 3, "path": "/Examples/Basic Tutorial/Solution/Basic Workbook.wbk", "sheetId": "df4de5e6-39ef-4c04-ba81-1f662f8364fc", "dataType": "latest" } } ], "label": [ { "type": "STRING", "name": "Visitor", "index": 0, "id": "17be495e-c915-4acf-a449-5439ff18f008", "dataSourceId": "V0JLOy9FeGFtcGxlcy9CYXNpYyBUdXRvcmlhbC9Tb2x1dGlvbi9CYXNpYyBXb3JrYm9vay53Yms7MWY3MzZlZWItMDQ4NC00OTU0LWE3YWQtMDNjZmFjOGUyOTBiOzA7MDtkZjRkZTVlNi0zOWVmLTRjMDQtYmE4MS0xZjY2MmY4MzY0ZmM", "dataSourceSpec": { "jobId": 3, "path": "/Examples/Basic Tutorial/Solution/Basic Workbook.wbk", "sheetId": "df4de5e6-39ef-4c04-ba81-1f662f8364fc", "dataType": "latest" } } ] }, "lastExecutionDate": "06/27/2012 05:32:59 PM", "isTruncated": false, "dataSourceId": "V0JLOy9FeGFtcGxlcy9CYXNpYyBUdXRvcmlhbC9Tb2x1dGlvbi9CYXNpYyBXb3JrYm9vay53Yms7MWY3MzZlZWItMDQ4NC00OTU0LWE3YWQtMDNjZmFjOGUyOTBiOzA7MDtkZjRkZTVlNi0zOWVmLTRjMDQtYmE4MS0xZjY2MmY4MzY0ZmM", "dataSourceSpec": { "jobId": 3, "path": "/Examples/Basic Tutorial/Solution/Basic Workbook.wbk", "sheetId": "df4de5e6-39ef-4c04-ba81-1f662f8364fc", "dataType": "latest" } }, "showFrame": true, "opacity": 1, "maxSize": "20", "offset": 10, "scale": "linear", "isShadowVisible": true, "isStyleVisible": true, "labelOrientation": "diagonal", "fillColorList": [ "#1f77b4", "#ff7f0e", "#2ca02c", "#d62728", "#9467bd", "#8c564b", "#e377c2", "#7f7f7f", "#bcbd22", "#17becf" ], "strokeColor": "steelblue", "labelColor": "black", "dataDescriptor": { "maxSize": 20, "data": { "type": [ "INTEGER", "BIG_INTEGER", "FLOAT", "BIG_DECIMAL" ], "dimensions": [ 1, 10 ] }, "label": { "type": [ "ANY" ], "dimensions": [ 1, 1 ] } }, "variant": "grouped", "groupGapInPercent": 20, "fontSize": "10", "fontName": "Verdana", "labelLength": "100", "colorScheme": "categorical", "isBarChart": true, "showPoints": true, "enableTooltips": true, "xAxisSkipCount": "0", "labelOrientation_text": "Diagonal", "colorScheme_text": "Categorical", "transpose": false, "marginRight": 75.11, "marginTop": 10, "marginBottom": 150.22, "marginLeft": 75.11 }, { "backgroundType": "without", "backgroundImagePlacement": "full", "backgroundImageFixed": "center", "backgroundImageTile": "both", "type": { "name": "Text", "chart": "infographics/charts/text", "inspector": "infographics/views/text_inspector", "panelGroup": "other", "defaultWidth": 150, "defaultHeight": 50 }, "name": "Text", "inspectorName": "infographics/views/text_inspector", "left": 1103, "top": 206, "width": 167, "height": 23, "angle": 0, "isResizable": true, "isDraggable": true, "isLockedToBack": false, "z-index": 5, "id": "e0be8eb4-b29e-420b-8b83-858861e350b8", "showFrame": true, "opacity": 1, "fillColor": "black", "backColor": "transparent", "editMode": false, "textContent": "Total Traffic By Visitor", "fontSize": "16", "fontName": "Arial", "bold": false, "italic": false, "underline": false, "align": "left", "color": "black" } ] }
Additional notes
<job-payload>.json
- The payload is a JSON representation of all information entered during the creation process using the web interface.
- An easy method of creating a payload is to use REST to read an import job, data link, or workbook and change the JSON that is returned.
Update Infographic
Request method - PUT
Description
Edits an existing infographic file in Datameer.
URI syntax
curl -u '<username>:<password>' -X PUT -d @<job-payload>.json 'http://<Datameer-serverIP>:<port-number>/rest/infographics/<infographics-configuration-id>'
Example response
Click here to expand...
{ "version": "2.1", "className": "datameer.dap.common.entity.infographic.Infographic", "links": { "self": "/rest/infographics/9" }, "file": { "uuid": "7e30825d-4923-4ade-8ad1-f06e60a08a1b", "path": "/Examples/REST API Test Infographic.ifg", "description": "A copy of a simple infographic used to show the responses to REST calls.", "name": "REST API Test Infographic" }, "backgroundType": "color", "backgroundImagePlacement": "full", "backgroundImageFixed": "center", "backgroundImageTile": "both", "tabs": [ { "name": "Page 1", "order": 0, "id": "5dcde2b0-3f63-4132-961d-6230692e3d38", "widgets": [ { "backgroundType": "without", "backgroundImagePlacement": "full", "backgroundImageFixed": "center", "backgroundImageTile": "both", "type": { "name": "Pie Chart", "chart": "infographics/charts/pie_chart", "dataDescriptor": { "maxSize": 20, "data": { "type": [ "INTEGER", "BIG_INTEGER", "FLOAT", "BIG_DECIMAL" ], "dimensions": [ 1, 1 ] }, "label": { "type": [ "ANY" ], "dimensions": [ 1, 1 ] } }, "inspector": "infographics/views/piechart_inspector", "panelGroup": "chart" }, "name": "Pie Chart", "inspectorName": "infographics/views/piechart_inspector", "left": 340, "top": 229, "width": 513, "height": 439, "angle": 0, "isResizable": true, "isDraggable": true, "isLockedToBack": false, "z-index": 2, "id": "199edb02-f195-42ac-ba39-c6d602547dbd", "dataSet": { "maxSize": 20, "descriptor": { "data": { "type": [ "INTEGER", "BIG_INTEGER", "FLOAT", "BIG_DECIMAL" ], "dimensions": [ 1, 1 ] }, "label": { "type": [ "ANY" ], "dimensions": [ 1, 1 ] } }, "dataSeriesGroups": { "data": [ { "type": "INTEGER", "name": "Impressions", "index": 3, "id": "20771089-e7e1-4bfa-8548-e934a3b455fa", "dataSourceId": "V0JLOy9FeGFtcGxlcy9CYXNpYyBUdXRvcmlhbC9Tb2x1dGlvbi9CYXNpYyBXb3JrYm9vay53Yms7MWY3MzZlZWItMDQ4NC00OTU0LWE3YWQtMDNjZmFjOGUyOTBiOzA7MDtkZjRkZTVlNi0zOWVmLTRjMDQtYmE4MS0xZjY2MmY4MzY0ZmM", "dataSourceSpec": { "jobId": 3, "path": "/Examples/Basic Tutorial/Solution/Basic Workbook.wbk", "sheetId": "df4de5e6-39ef-4c04-ba81-1f662f8364fc", "dataType": "latest" } } ], "label": [ { "type": "STRING", "name": "Visitor", "index": 0, "id": "46a828fe-1b0f-4143-895c-1a10a06de02f", "dataSourceId": "V0JLOy9FeGFtcGxlcy9CYXNpYyBUdXRvcmlhbC9Tb2x1dGlvbi9CYXNpYyBXb3JrYm9vay53Yms7MWY3MzZlZWItMDQ4NC00OTU0LWE3YWQtMDNjZmFjOGUyOTBiOzA7MDtkZjRkZTVlNi0zOWVmLTRjMDQtYmE4MS0xZjY2MmY4MzY0ZmM", "dataSourceSpec": { "jobId": 3, "path": "/Examples/Basic Tutorial/Solution/Basic Workbook.wbk", "sheetId": "df4de5e6-39ef-4c04-ba81-1f662f8364fc", "dataType": "latest" } } ] }, "lastExecutionDate": "06/27/2012 05:32:59 PM", "isTruncated": false, "dataSourceId": "V0JLOy9FeGFtcGxlcy9CYXNpYyBUdXRvcmlhbC9Tb2x1dGlvbi9CYXNpYyBXb3JrYm9vay53Yms7MWY3MzZlZWItMDQ4NC00OTU0LWE3YWQtMDNjZmFjOGUyOTBiOzA7MDtkZjRkZTVlNi0zOWVmLTRjMDQtYmE4MS0xZjY2MmY4MzY0ZmM", "dataSourceSpec": { "jobId": 3, "path": "/Examples/Basic Tutorial/Solution/Basic Workbook.wbk", "sheetId": "df4de5e6-39ef-4c04-ba81-1f662f8364fc", "dataType": "latest" } }, "showFrame": true, "opacity": 1, "maxSize": "20", "fillColorList": [ "#1f77b4", "#ff7f0e", "#2ca02c", "#d62728", "#9467bd", "#8c564b", "#e377c2", "#7f7f7f", "#bcbd22", "#17becf" ], "strokeColor": "steelblue", "labelColor": "black", "colorScheme": "categorical", "isShadowVisible": true, "style": "glossy", "showLabels": true, "labelType": "percentage", "fontSize": 10, "fontName": "Verdana", "labelLength": 100, "enableTooltips": true, "labelReduction": "0", "style_text": "Glossy", "colorScheme_text": "Categorical", "marginTop": 184.38, "marginRight": 215.46, "marginBottom": 168.576, "marginLeft": 196.99200000000002 }, { "backgroundType": "without", "backgroundImagePlacement": "full", "backgroundImageFixed": "center", "backgroundImageTile": "both", "type": { "name": "Text", "chart": "infographics/charts/text", "inspector": "infographics/views/text_inspector", "panelGroup": "other", "defaultWidth": 150, "defaultHeight": 50 }, "name": "Text", "inspectorName": "infographics/views/text_inspector", "left": 530, "top": 205, "width": 153, "height": 20, "angle": 0, "isResizable": true, "isDraggable": true, "isLockedToBack": false, "z-index": 3, "id": "de8ac616-1c13-42c8-a46a-5dd1f7577569", "showFrame": true, "opacity": 1, "fillColor": "black", "backColor": "transparent", "editMode": false, "textContent": "Most Active Visitors", "fontSize": "16", "fontName": "Arial", "bold": false, "italic": false, "underline": false, "align": "left", "color": "black" }, { "backgroundType": "without", "backgroundImagePlacement": "full", "backgroundImageFixed": "center", "backgroundImageTile": "both", "type": { "name": "Multi bar chart", "chart": "infographics/charts/multi_bar_chart", "dataDescriptor": { "maxSize": 20, "data": { "type": [ "INTEGER", "BIG_INTEGER", "FLOAT", "BIG_DECIMAL" ], "dimensions": [ 1, 10 ] }, "label": { "type": [ "ANY" ], "dimensions": [ 1, 1 ] } }, "inspector": "infographics/views/multi_bar_chart_inspector", "panelGroup": "chart", "isBarChart": true }, "name": "Multi bar chart", "inspectorName": "infographics/views/multi_bar_chart_inspector", "left": 889.5, "top": 301, "width": 594, "height": 406, "angle": 0, "isResizable": true, "isDraggable": true, "isLockedToBack": false, "z-index": 4, "id": "4ab95e01-4f2b-4593-82e8-3630c6670b66", "dataSet": { "maxSize": 20, "descriptor": { "data": { "type": [ "INTEGER", "BIG_INTEGER", "FLOAT", "BIG_DECIMAL" ], "dimensions": [ 1, 10 ] }, "label": { "type": [ "ANY" ], "dimensions": [ 1, 1 ] } }, "dataSeriesGroups": { "data": [ { "type": "INTEGER", "name": "Traffic", "index": 2, "id": "a180f860-5af6-479b-b803-f950e10ada34", "dataSourceId": "V0JLOy9FeGFtcGxlcy9CYXNpYyBUdXRvcmlhbC9Tb2x1dGlvbi9CYXNpYyBXb3JrYm9vay53Yms7MWY3MzZlZWItMDQ4NC00OTU0LWE3YWQtMDNjZmFjOGUyOTBiOzA7MDtkZjRkZTVlNi0zOWVmLTRjMDQtYmE4MS0xZjY2MmY4MzY0ZmM", "dataSourceSpec": { "jobId": 3, "path": "/Examples/Basic Tutorial/Solution/Basic Workbook.wbk", "sheetId": "df4de5e6-39ef-4c04-ba81-1f662f8364fc", "dataType": "latest" } } ], "label": [ { "type": "STRING", "name": "Visitor", "index": 0, "id": "17be495e-c915-4acf-a449-5439ff18f008", "dataSourceId": "V0JLOy9FeGFtcGxlcy9CYXNpYyBUdXRvcmlhbC9Tb2x1dGlvbi9CYXNpYyBXb3JrYm9vay53Yms7MWY3MzZlZWItMDQ4NC00OTU0LWE3YWQtMDNjZmFjOGUyOTBiOzA7MDtkZjRkZTVlNi0zOWVmLTRjMDQtYmE4MS0xZjY2MmY4MzY0ZmM", "dataSourceSpec": { "jobId": 3, "path": "/Examples/Basic Tutorial/Solution/Basic Workbook.wbk", "sheetId": "df4de5e6-39ef-4c04-ba81-1f662f8364fc", "dataType": "latest" } } ] }, "lastExecutionDate": "06/27/2012 05:32:59 PM", "isTruncated": false, "dataSourceId": "V0JLOy9FeGFtcGxlcy9CYXNpYyBUdXRvcmlhbC9Tb2x1dGlvbi9CYXNpYyBXb3JrYm9vay53Yms7MWY3MzZlZWItMDQ4NC00OTU0LWE3YWQtMDNjZmFjOGUyOTBiOzA7MDtkZjRkZTVlNi0zOWVmLTRjMDQtYmE4MS0xZjY2MmY4MzY0ZmM", "dataSourceSpec": { "jobId": 3, "path": "/Examples/Basic Tutorial/Solution/Basic Workbook.wbk", "sheetId": "df4de5e6-39ef-4c04-ba81-1f662f8364fc", "dataType": "latest" } }, "showFrame": true, "opacity": 1, "maxSize": "20", "offset": 10, "scale": "linear", "isShadowVisible": true, "isStyleVisible": true, "labelOrientation": "diagonal", "fillColorList": [ "#1f77b4", "#ff7f0e", "#2ca02c", "#d62728", "#9467bd", "#8c564b", "#e377c2", "#7f7f7f", "#bcbd22", "#17becf" ], "strokeColor": "steelblue", "labelColor": "black", "dataDescriptor": { "maxSize": 20, "data": { "type": [ "INTEGER", "BIG_INTEGER", "FLOAT", "BIG_DECIMAL" ], "dimensions": [ 1, 10 ] }, "label": { "type": [ "ANY" ], "dimensions": [ 1, 1 ] } }, "variant": "grouped", "groupGapInPercent": 20, "fontSize": "10", "fontName": "Verdana", "labelLength": "100", "colorScheme": "categorical", "isBarChart": true, "showPoints": true, "enableTooltips": true, "xAxisSkipCount": "0", "labelOrientation_text": "Diagonal", "colorScheme_text": "Categorical", "transpose": false, "marginRight": 75.11, "marginTop": 10, "marginBottom": 150.22, "marginLeft": 75.11 }, { "backgroundType": "without", "backgroundImagePlacement": "full", "backgroundImageFixed": "center", "backgroundImageTile": "both", "type": { "name": "Text", "chart": "infographics/charts/text", "inspector": "infographics/views/text_inspector", "panelGroup": "other", "defaultWidth": 150, "defaultHeight": 50 }, "name": "Text", "inspectorName": "infographics/views/text_inspector", "left": 1103, "top": 206, "width": 167, "height": 23, "angle": 0, "isResizable": true, "isDraggable": true, "isLockedToBack": false, "z-index": 5, "id": "e0be8eb4-b29e-420b-8b83-858861e350b8", "showFrame": true, "opacity": 1, "fillColor": "black", "backColor": "transparent", "editMode": false, "textContent": "Total Traffic By Visitor", "fontSize": "16", "fontName": "Arial", "bold": false, "italic": false, "underline": false, "align": "left", "color": "black" } ] } ] }
Additional notes
<job-payload>.json
- The payload is a JSON representation of all information entered during the creation process using the web interface.
- An easy method of creating a payload is to use REST to read an import job, data link, or workbook and change the JSON that is returned.
Delete Infographic
Request method - DELETE
Description
Removes an infographic file from Datameer.
URI syntax
curl -u '<username>:<password>' -X DELETE 'http://<Datameer-serverIP>:<port-number>/rest/infographics/<infographics-configuration-id>'
Example response
No response for a successful action.
or
{ "reason": "Entity not found 25", "status": "failure" }
List All Infographics
Request method - GET
Description
Returns a list of all the infographics in Datameer.
URI syntax
curl -u '<username>:<password>' -X GET 'http://<Datameer-serverIP>:<port-number>/rest/infographics'
Example response
Click here to expand...
[{ "version": "2.1", "className": "datameer.dap.common.entity.infographic.Infographic", "links": { "self": "/rest/infographics/1" }, "file": { "uuid": "26be0e75-d191-4cc2-bc31-e5dbbfa356c3", "path": "/Examples/Basic Tutorial/Solution/Basic Infographic.ifg", "description": "A simple infographic that displays basic web traffic statistics, measuring clicks and traffic per visitor. This infographic is powered by the 'Basic Workbook' workbook.", "name": "Basic Infographic" }, "backgroundType": "color", "backgroundImagePlacement": "full", "backgroundImageFixed": "center", "backgroundImageTile": "both", "tabs": [ { "name": "Page 1", "order": 0, "id": "5dcde2b0-3f63-4132-961d-6230692e3d38", "widgets": [ { "backgroundType": "without", "backgroundImagePlacement": "full", "backgroundImageFixed": "center", "backgroundImageTile": "both", "type": { "name": "Pie Chart", "chart": "infographics/charts/pie_chart", "dataDescriptor": { "maxSize": 20, "data": { "type": [ "INTEGER", "BIG_INTEGER", "FLOAT", "BIG_DECIMAL" ], "dimensions": [ 1, 1 ] }, "label": { "type": [ "ANY" ], "dimensions": [ 1, 1 ] } }, "inspector": "infographics/views/piechart_inspector", "panelGroup": "chart" }, "name": "Pie Chart", "inspectorName": "infographics/views/piechart_inspector", "left": 340, "top": 229, "width": 513, "height": 439, "angle": 0, "isResizable": true, "isDraggable": true, "isLockedToBack": false, "z-index": 2, "id": "199edb02-f195-42ac-ba39-c6d602547dbd", "dataSet": { "maxSize": 20, "descriptor": { "data": { "type": [ "INTEGER", "BIG_INTEGER", "FLOAT", "BIG_DECIMAL" ], "dimensions": [ 1, 1 ] }, "label": { "type": [ "ANY" ], "dimensions": [ 1, 1 ] } }, "dataSeriesGroups": { "data": [ { "type": "INTEGER", "name": "Impressions", "index": 3, "id": "20771089-e7e1-4bfa-8548-e934a3b455fa", "dataSourceId": "V0JLOy9FeGFtcGxlcy9CYXNpYyBUdXRvcmlhbC9Tb2x1dGlvbi9CYXNpYyBXb3JrYm9vay53Yms7MWY3MzZlZWItMDQ4NC00OTU0LWE3YWQtMDNjZmFjOGUyOTBiOzA7MDtkZjRkZTVlNi0zOWVmLTRjMDQtYmE4MS0xZjY2MmY4MzY0ZmM", "dataSourceSpec": { "jobId": 3, "path": "/Examples/Basic Tutorial/Solution/Basic Workbook.wbk", "sheetId": "df4de5e6-39ef-4c04-ba81-1f662f8364fc", "dataType": "latest" } } ], "label": [ { "type": "STRING", "name": "Visitor", "index": 0, "id": "46a828fe-1b0f-4143-895c-1a10a06de02f", "dataSourceId": "V0JLOy9FeGFtcGxlcy9CYXNpYyBUdXRvcmlhbC9Tb2x1dGlvbi9CYXNpYyBXb3JrYm9vay53Yms7MWY3MzZlZWItMDQ4NC00OTU0LWE3YWQtMDNjZmFjOGUyOTBiOzA7MDtkZjRkZTVlNi0zOWVmLTRjMDQtYmE4MS0xZjY2MmY4MzY0ZmM", "dataSourceSpec": { "jobId": 3, "path": "/Examples/Basic Tutorial/Solution/Basic Workbook.wbk", "sheetId": "df4de5e6-39ef-4c04-ba81-1f662f8364fc", "dataType": "latest" } } ] }, "lastExecutionDate": "06/27/2012 05:32:59 PM", "isTruncated": false, "dataSourceId": "V0JLOy9FeGFtcGxlcy9CYXNpYyBUdXRvcmlhbC9Tb2x1dGlvbi9CYXNpYyBXb3JrYm9vay53Yms7MWY3MzZlZWItMDQ4NC00OTU0LWE3YWQtMDNjZmFjOGUyOTBiOzA7MDtkZjRkZTVlNi0zOWVmLTRjMDQtYmE4MS0xZjY2MmY4MzY0ZmM", "dataSourceSpec": { "jobId": 3, "path": "/Examples/Basic Tutorial/Solution/Basic Workbook.wbk", "sheetId": "df4de5e6-39ef-4c04-ba81-1f662f8364fc", "dataType": "latest" } }, "showFrame": true, "opacity": 1, "maxSize": "20", "fillColorList": [ "#1f77b4", "#ff7f0e", "#2ca02c", "#d62728", "#9467bd", "#8c564b", "#e377c2", "#7f7f7f", "#bcbd22", "#17becf" ], "strokeColor": "steelblue", "labelColor": "black", "colorScheme": "categorical", "isShadowVisible": true, "style": "glossy", "showLabels": true, "labelType": "percentage", "fontSize": 10, "fontName": "Verdana", "labelLength": 100, "enableTooltips": true, "labelReduction": "0", "style_text": "Glossy", "colorScheme_text": "Categorical", "marginTop": 184.38, "marginRight": 215.46, "marginBottom": 168.576, "marginLeft": 196.99200000000002 }, { "backgroundType": "without", "backgroundImagePlacement": "full", "backgroundImageFixed": "center", "backgroundImageTile": "both", "type": { "name": "Text", "chart": "infographics/charts/text", "inspector": "infographics/views/text_inspector", "panelGroup": "other", "defaultWidth": 150, "defaultHeight": 50 }, "name": "Text", "inspectorName": "infographics/views/text_inspector", "left": 530, "top": 205, "width": 153, "height": 20, "angle": 0, "isResizable": true, "isDraggable": true, "isLockedToBack": false, "z-index": 3, "id": "de8ac616-1c13-42c8-a46a-5dd1f7577569", "showFrame": true, "opacity": 1, "fillColor": "black", "backColor": "transparent", "editMode": false, "textContent": "Most Active Visitors", "fontSize": "16", "fontName": "Arial", "bold": false, "italic": false, "underline": false, "align": "left", "color": "black" }, { "backgroundType": "without", "backgroundImagePlacement": "full", "backgroundImageFixed": "center", "backgroundImageTile": "both", "type": { "name": "Multi bar chart", "chart": "infographics/charts/multi_bar_chart", "dataDescriptor": { "maxSize": 20, "data": { "type": [ "INTEGER", "BIG_INTEGER", "FLOAT", "BIG_DECIMAL" ], "dimensions": [ 1, 10 ] }, "label": { "type": [ "ANY" ], "dimensions": [ 1, 1 ] } }, "inspector": "infographics/views/multi_bar_chart_inspector", "panelGroup": "chart", "isBarChart": true }, "name": "Multi bar chart", "inspectorName": "infographics/views/multi_bar_chart_inspector", "left": 889.5, "top": 301, "width": 594, "height": 406, "angle": 0, "isResizable": true, "isDraggable": true, "isLockedToBack": false, "z-index": 4, "id": "4ab95e01-4f2b-4593-82e8-3630c6670b66", "dataSet": { "maxSize": 20, "descriptor": { "data": { "type": [ "INTEGER", "BIG_INTEGER", "FLOAT", "BIG_DECIMAL" ], "dimensions": [ 1, 10 ] }, "label": { "type": [ "ANY" ], "dimensions": [ 1, 1 ] } }, "dataSeriesGroups": { "data": [ { "type": "INTEGER", "name": "Traffic", "index": 2, "id": "a180f860-5af6-479b-b803-f950e10ada34", "dataSourceId": "V0JLOy9FeGFtcGxlcy9CYXNpYyBUdXRvcmlhbC9Tb2x1dGlvbi9CYXNpYyBXb3JrYm9vay53Yms7MWY3MzZlZWItMDQ4NC00OTU0LWE3YWQtMDNjZmFjOGUyOTBiOzA7MDtkZjRkZTVlNi0zOWVmLTRjMDQtYmE4MS0xZjY2MmY4MzY0ZmM", "dataSourceSpec": { "jobId": 3, "path": "/Examples/Basic Tutorial/Solution/Basic Workbook.wbk", "sheetId": "df4de5e6-39ef-4c04-ba81-1f662f8364fc", "dataType": "latest" } } ], "label": [ { "type": "STRING", "name": "Visitor", "index": 0, "id": "17be495e-c915-4acf-a449-5439ff18f008", "dataSourceId": "V0JLOy9FeGFtcGxlcy9CYXNpYyBUdXRvcmlhbC9Tb2x1dGlvbi9CYXNpYyBXb3JrYm9vay53Yms7MWY3MzZlZWItMDQ4NC00OTU0LWE3YWQtMDNjZmFjOGUyOTBiOzA7MDtkZjRkZTVlNi0zOWVmLTRjMDQtYmE4MS0xZjY2MmY4MzY0ZmM", "dataSourceSpec": { "jobId": 3, "path": "/Examples/Basic Tutorial/Solution/Basic Workbook.wbk", "sheetId": "df4de5e6-39ef-4c04-ba81-1f662f8364fc", "dataType": "latest" } } ] }, "lastExecutionDate": &quo