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. |
This REST API call has been deprecated as of Datameer v7.0 and is scheduled to be removed before the release of Datameer v8.0. It is replaced by the call Read Workbook v2. |
Request method - GET
Returns information on a specified workbook within Datameer including version number, class name, file information (uuid, path, description, name), run schedule, custom properties, and sheet data.
curl -u <username>:<password> -X GET 'http://<Datameer-serverIP>:<port-number>/rest/workbook/<workbook-configuration-id>'
|
Request method - GET
Reads a workbook based on a JSON representation for the workbooks using the Git versioning plug-in.
curl -u <username>:<password> -X GET 'http://<Datameer-serverIP>:<port-number>/api/workbooks/<file-id>'
|
This REST API call has been deprecated as of Datameer v7.0 and is scheduled to be removed before the release of Datameer v8.0. It is replaced by the call Create Workbook v2. |
Request method - POST
Adds a workbook in Datameer.
curl -u <username>:<password> -X POST -d @<file name>.json 'http://<Datameer-serverIP>:<port-number>/rest/workbook'
{ "configuration-id": 48, "status": "success" } |
<file name>.json
Request method - POST
Creates a workbook based on a JSON representation for workbooks using the Git versioning plug-in.
curl -u <username>:<password> -X POST -H "Content-Type:application/json" -d @<file name>.json 'http://<Datameer-serverIP>:<port-number>/api/workbooks'
If the request is successful, there is no output.
<file name>.json
This REST API call has been deprecated as of Datameer v7.0 and is scheduled to be removed before the release of Datameer v8.0. It is replaced by the call Update Workbook v2. |
Request method - PUT
Edits an existing workbook in Datameer.
curl -u <username>:<password> -X PUT -d @<file name>.json 'http://<Datameer-serverIP>:<port-number>/rest/workbook/<workbook-configuration-id>'
{"status": "success"} |
<file name>.json
Request method - PUT
Updates an existing workbook using the Git versioning plug-in.
curl -u <username>:<password> -X PUT -H "Content-Type:application/json" -d @<file name>.json 'http://<Datameer-serverIP>:<port-number>/api/workbooks/<file-id>
If the request is successful, there is no output.
<file name>.json
Request method - DELETE
Removes a workbook from Datameer.
curl -u <username>:<password> -X DELETE 'http://<Datameer-ServerIP>:<Port>/rest/workbook/<workbook-configuration-id>'
{"status": "success"} |
Request method - GET
Returns data on the workbook including the path, number of records, time stamp, and ID.
curl -u <username>:<password> -X GET 'http://<Datameer-serverIP>:<port-number>/rest/data/workbook/{configuration-id}
[ { "path": "/Data/ImportJobs/DatameerImport.imp", "record-count": 20, "datas": [ { "timestamp": "Mar 5, 2013 10:44:59 AM", "record-count": 20, "id": 19372 } ] |
Request method - GET
Returns the column names and records of the workbook.
The default limit for number of rows to download is 100,000, as this functionality is intended for small aggregated data sets. To adjust the record download limit, change the |
curl -u <username>:<password> -X GET 'http://<Datameer-serverIP>:<port-number>/rest/data/workbook/{configuration-id}/{sheet-name}/download curl -u <username>:<password> -X GET 'http://<Datameer-serverIP>:<port-number>/rest/data/workbook/{configuration-id}/{sheet-name}/download?dataId={data-id}
"ID","NAME","Email","Status","Check" "1","""admin""","""admin@datameer.com""","0","true" "2","""Ajay""","""Ajay@datameer.com""","2","true" "3","""analyst""","""analyst@datameer.com""","1","true" "4","""Bob""","""Bob@datameer.com""","2","false" "5","""Alice""","""Alice@datameer.com""","2","false" "6","""John""","""John@datameer.com""","2","false" "7","""Andreas""","""Andreas@datameer.com""","2","true" "8","""Arthur""","""Arthur@datameer.com""","2","true" "9","""Dagmar""","""Dagmar@datameer.com""","2","false" "10","""Frank""","""Frank@datameer.com""","2","true" "11","""Johannes""","""Johannes@datameer.com""","2","true" "12","""Marko""","""Marko@datameer.com""","2","true" "13","""Marlon""","""Marlon@datameer.com""","2","true" "14","""Mike""","""Mike@datameer.com""","2","true" "15","""Orlando""","""Orlando@datameer.com""","2","true" "16","""Peter""","""Peter@datameer.com""","2","true" "17","""Ralf""","""Ralf@datameer.com""","2","false" "18","""Shirish""","""Shirish@datameer.com""","2","true" "19","""Stefan""","""Stefan@datameer.com""","2","true" "20","""Teresa""","""Teresa@datameer.com""","2","true" |
Request method - GET
Returns the column names and data type of a workbook.
curl -u <username>:<password> -X GET 'http://<Datameer-serverIP>:<port-number>/rest/sheet-details/<workbook-configuration-id>/<sheet-name>'
curl -u <username>:<password> -X GET 'http://<Datameer-serverIP>:<port-number>/rest/sheet-details?file=<path-to-workbook>.wbk&sheetName=<sheet-name>'
{ "columns": [ { "name": "remoteHost", "type": "STRING" }, { "name": "remoteUser", "type": "STRING" }, { "name": "timeEnglishFormat", "type": "DATE" }, { "name": "request", "type": "STRING" }, { "name": "status", "type": "INTEGER" }, { "name": "bytesSent", "type": "INTEGER" } ], "file": { "path": "/Examples/Basic Tutorial/Solution/Basic Workbook.wbk", "uuid": "c02c5f10-2d30-4320-b2ec-52f89550bfe5" }, "sheetId": "SheetId[_id=2c87ddad-fea4-441a-8475-6ce4cbb5def4]", "sheetName": "Clickstream_Data", "sheetType": "das.internal.DataSourceSheetType" } |
Request method - GET
Returns a list of all the workbooks in Datameer. This list displays the description, ID number, name, and the path of the workbooks.
curl -u <username>:<password> -X GET 'http://<Datameer-serverIP>:<port-number>/rest/workbook'
[ { "description": "", "id": 388, "name": "Workbook_copy5", "path": "/Workbooks/Andreas/Workbook_copy5.wbk" }, { "description": "", "id": 393, "name": "wb 1605 twitter", "path": "/Workbooks/tester/wb 1605 twitter.wbk" }, { "description": "", "id": 396, "name": "wbk_ext_reference", "path": "/Workbooks/wbk_ext_reference.wbk" }, { "description": "", "id": 397, "name": "wbk_ext_ref_2", "path": "/Workbooks/wbk_ext_ref_2.wbk" } |
Request method - POST
Runs a workbook.
curl -u <username>:<password> -X POST 'http://<Datameer-serverIP>:<port-number>/rest/job-execution?configuration=<workbook-configuration-id>'
{ "job-execution-id": 1, "job-execution-trigger": "RESTAPI", "job-execution-user": "admin", "status": "success" } |
This API requires enabling Datameer's Advanced Governance plug-in. |
Request method - GET
Returns the hierarchy of up- and downstream dependencies for a given workbook.
curl -u <username>:<password> -X GET 'http://<server>:<port>/api/workbook/[configurationID]/dependencies[?direction=<upstream | downstream>][&level=<number>]'
{ "dependencies": [ { "id": 22, "file": { "path": "/Users/admin/ImportJobTest", "name": "ImportJobTest", "type": "imp", "description": "", "uuid": "b8f258f5-90c9-451d-9058-9d3a8c9b2c5d" } }, { "id": 2, "file": { "path": "/Data/Connections/Datameer server filesystem", "name": "Datameer server filesystem", "type": "dst", "description": "A data store for the local filesystem where Datameer is running. Note, this works ONLY for Datameer Personal, Workgroup, and Trial editions.\n", "uuid": "78a2fb59-375e-4eae-b338-956ef806f7b1" } } ], "fileCountWithNoReadPermission": 0, "_links": { "self": { "href": "http://localhost:8088/api/workbook/23/dependencies" } } |
Path parameters:
Query parameters:
If left blank, shows all levels
Request method - GET
Returns a list of all the workbook's permission settings.
curl -u <username>:<password> -X GET 'http://<Datameer-serverIP>:<port-number>/api/workbooks/<FileID>/permission'
{ "readableForOthers": true, "_links": { "file": { "href": "/api/filesystem/files/43" }, "groups": { "href": "/api/filesystem/files/43/permission/groups" }, "self": { "href": "/api/workbooks/43/permission" }, "others": { "href": "/api/filesystem/files/43/permission/others" } }, "_embedded": { "groups": [ { "readable": true, "name": "IT-Dept.", "_links": { "self": { "href": "/api/filesystem/files/43/permission/groups/IT-Dept." }, "permission": { "href": "/api/filesystem/files/43/permission" } } } ] } |
Returns a list of the workbook's permission settings for "Others".
curl -u <username>:<password> -X GET 'http://<Datameer-serverIP>:<port-number>/api/workbooks/<FileID>/permission/others'
Returns a list of the workbook's permission settings for all "Groups".
curl -u <username>:<password> -X GET 'http://<Datameer-serverIP>:<port-number>/api/workbooks/<FileID>/permission/groups'
Returns the workbook's permission settings for a selected "Group".
curl -u <username>:<password> -X GET 'http://<Datameer-serverIP>:<port-number>/api/workbooks/<FileID>/permission/groups/<group-name>'
Request method - PUT
Rolls back a workbook to a previous state using the Git versioning plug-in. If the workbook exists, it is overwritten. If it doesn't exist, a new one is created. This REST API must be used in conjunction with other version 2 REST APIs.
curl -u <username>:<password> -X PUT -H "Content-Type:application/json" -d @wbk.json 'http://<Datameer-serverIP>:<port-number>/api/workbooks/rollback'
If the request is successful, there is no output.