REST API Administrator Information
INFO
Add the following command after the username and password to receive more meaningful HTTP errors:
-w"\n%{http_code}\n"This command can be added to each call.
Data Volume Limit
Request Method | GET |
Description | Returns the volume size of a job (in bytes). |
URI Syntax | curl -u '<username>:<password>' -X GET 'http://<Datameer-serverIP>:<port-number>/rest/job-configuration/volume-report/<job-configuration-id>' |
Example Response | {
"id": 187,
"jobStatus": "COMPLETED",
"importedVolume": 56765,
"type": "NORMAL"
},
{
"id": 186,
"jobStatus": "COMPLETED",
"importedVolume": 4098,
"type": "NORMAL"
} |
Global Volume and License Information
Request Method | GET |
Description | Returns information on your Datameer X product. This information includes the product ID, version, license holder, license type, start date of license, expiration of license, volume period, volume limit (in bytes), and total volume consumed (in bytes). |
URI Syntax | curl -u '<username>:<password>' -X GET 'http://<Datameer-serverIP>:<port-number>/rest/license-details' |
Example Response | {
"ProductId": "4c4038ba-3250-4844-b432-7c8f64d85807",
"ProductVersion": "10.1.2",
"LicenseHolder": "CN=John Doe,O=Datameer X STREET=Unknown,L=Unknown Unknown,ST=Unknown,C=Unknown",
"LicenseType": "Enterprise",
"LicenseStartDate": "Jan 23, 2020 5:20:10 PM",
"LicenseExpirationDate": "Mar 25, 2020 5:20:10 PM",
"LicenseVolumePeriodInMonths": 1,
"LicenseVolumelimitInBytes": 214748364800,
"TotalVolumeConsumedInBytes": 38758720
} |
Upload License File
Request Method | POST |
Description | Uploads a license file to Datameer. |
URI Syntax | curl -u '<username>:<password>' -X POST --form "file=@<license path>" http://<Datameer-serverIP>:<port-number>/license/upload |
Example Response | If the license is accepted VALIDIf the license is not accepted INVALID |
Product ID
Request Method | GET |
Description | Returns the product ID and product version. |
URI Syntax | curl -u '<username>:<password>' -X GET 'http://<Datameer-serverIP>:<port-number>/license/product-id' |
Example Response | 4b4038ba-3550-4844-b432-4c6f64d80807das-test:Datameer-2.1.3-1.0.3 |
Metrics
Request Method | GET |
Description | Viewing the metrics in JSON format. |
URI Syntax | curl -s -S -u '<username>:<password>' -X GET 'http://<Datameer-serverIP>:<port-number>/rest/monitor/'
curl -s -S -u '<username>:<password>' -X GET 'http://<Datameer-serverIP>:<port-number>/rest/monitor/prependLabel' |
Additional Notes | An HTML table of the metrics for the current collection interval can be viewed with the following command: curl -s -S -u '<username>:<password>' -X GET 'http://<Datameer-serverIP>:<port-number>/rest/monitor/html' |
JAMon
Request Method | PUT |
Description | Allows clients to enable or disable JAMon at runtime. |
URI Syntax | INFO: If your file name includes curl -s -S -u '<username>:<password>' -X PUT 'http://<Datameer-serverIP>:<port-number>/rest/monitor/enable'
curl -s -S -u '<username>:<password>' -X PUT 'http://<Datameer-serverIP>:<port-number>/rest/monitor/disable' |