- URL:
- https://<logs-url>/query
- Methods:
GET
- Required Capability:
- Administrator or Create and Edit ArcGIS Notebooks
- Version Introduced:
- 10.7
Description
The query
operation provides a way to aggregate, filter, and page through logs across the ArcGIS Notebook Server site.
JSON request parameters
Parameter | Details |
---|---|
| The minimum log level for which to query. It returns only records with a log level at or more severe than this level. The default level is Values: |
| The most recent time to query. If left blank, the query will include logs up to the present time. |
| The oldest time to include in the result set. You can use this to limit the query to the last few minutes or hours as needed. If left blank, the query will include all logs recorded since logging began. |
| Specifies whether the filter parameter is formatted as JSON. If this operation is performed in the ArcGIS Notebook Server Admin Directory UI, this parameter will be automatically added to the request when executed. |
| Filtering provides flexibility and specificity by combining any of the filter properties, each given as a comma-separated list. For more information on individual properties, see the Filter properties section below. |
| The maximum number of log records to be returned by this query. The default messages per page is 1000. The limit is 10000 records. |
| The response format. The default format is Values: |
Filter properties
Parameter | Details |
---|---|
| One or a range of log codes assigned to a log message. |
| One or multiple users (separated by commas) whose related log messages to query. |
| Specifies an ID assigned to a specific server request. |
| Specifies whether to query all machines or a specific machine in your server site. The default value is |
| The source of logged events. The default value is |
HTML request parameters
Parameter | Details |
---|---|
| The minimum log level for which to query. It returns only records with a log level at or more severe than this level. The default level is Values: |
| The source of logged events. The default value is |
| The most recent time to query. If left blank, the query will include logs up to the present time. |
| The oldest time to include in the result set. You can use this to limit the query to the last few minutes or hours as needed. If left blank, the query will include all logs recorded since logging began. |
| One or a range of log codes assigned to a log message. |
| One or multiple users (separated by commas) whose related log messages to query. |
| Specifies an ID assigned to a specific server request. |
| Specifies whether to query all machines or a specific machine in your server site. The default value is |
| The maximum number of log records to be returned by this query. The limit is 10,000 records. The default value is 1,000. |
| The response format. The default format is Values: |
Example usage
Below is a sample request for the query
operation:
https://notebookserver.domain.com:port/arcgis/admin/logs/query?level=WARNING&startTime=&endTime=&filterType=json&filter={"codes":[], "users":[], "requestIds":[], "machines": "*", "source": "*"}&pageSize=1000&f=html
JSON Response example
{
"hasMore": false,
"startTime": 1549431957539,
"endTime": 1549417558390,
"logMessages": [
{
"elapsed": "",
"process": "6880",
"code": 1065,
"machine": "NOTEBOOKSERVER.DOMAIN.COM",
"methodName": "",
"time": 1549417890408,
"source": "Admin",
"thread": "1",
"type": "WARNING",
"message": "Failed to log in. Invalid username 'admin' or password specified.",
"user": ""
}
]
}