Log Explorer URL Parameters
Log Explorer supports several URL parameters that allow context to be passed to the application. In Log Explorer, click Actions and select Copy query URL to get a link that reloads the page exactly as it is currently displayed.
Visualization and Query Parameters
Visualization and query parameters allow integrators to communicate to the Log Explorer what default visualization and query filters must be used when the page loads.
Parameter | Description | Supported Values | Example |
---|---|---|---|
viz | Sets the visualization |
|
Url:
Result: Logging Analytics loads with the Records with Histogram chart and the default query which is appropriate for this visualization. |
search | Updates the search clause of the query | - |
|
filters | Updates the query with the field/value checks
specified. Filters are specified with field name, value and an
optional comparator. By default, the EQUALS comparator is
used.
The delimiters for filters are |
Supported Comparators:
|
|
encodedQuery |
Decodes the base64 encoded query from the URL and updates the query in the Log Explorer. In javascript, you can build the encodedQuery using window.btoa(query). Decode using window.atob(encodedQuery). This prevents the firewall from flagging certain
characters in the query. For example, this query will get
flagged by the firewall using the unencoded query parameters:
|
- |
URL With encoded query: Url:
Example:
Decoded query is Then the Problem Priority parameter is added
to the search resulting in: |
Global Context Parameters
When Logging Analytics runs a query, only a subset of log records are considered. The set of log records is determined by taking into account the global context. This includes settings such as compartment and time.
Parameter | Description | Supported Values | Example |
---|---|---|---|
startTime | The start time, UTC in Milliseconds, is used in conjunction with endTime. If both are provided on the URL, a custom time frame is set in the console. | Date in UTC Milliseconds |
For example, if you run the following in the console, you will get two numbers - start time and end time. You can plug them into the URL and see data for the last 30 minutes:
Sample URL with Start and End Time:
The result is custom time in Log Explorer with these values set as the start and end time. Time is also supported in the following format:
|
endTime | The end time, UTC in Milliseconds, is used in conjunction with startTime. If both are provided on the URL, a custom time frame is set in the console. | Date in UTC Milliseconds | See startTime. |
timeNum | Log Explorer supports relative times, like
Last 7 days . To specify a relative time set
timeNum to a number and timeUnit to the required
time frame.
|
A number greater than 0 | /loganalytics/explorer?timeNum=42&timeUnit=minutesor/loganalytics/explorer?timeNum=1&timeUnit=day |
timeUnit | Log Explorer supports relative times, like
Last 7 days . To specify a relative time, set
timeNum to a number and timeUnit to the required
time frame.
|
|
See timeNum. |
scopeFilters | This parameter allows scope filters like log group compartment, entity, and log set to be passed. |
where:
|
/loganalytics/explorer?&scopeFilters=lg:root,true;en:root,true,ocid1...;rs:root,true;lfe:Severity,ZXJyb3I=;rg:us-phoenix-1 |