okta-sdk-nodejs

okta.SystemLogApi

All URIs are relative to https://subdomain.okta.com

Method HTTP request Description
getLogs GET /api/v1/logs List all System Log Events

getLogs

Array getLogs()

The Okta System Log API provides read access to your organization’s system log. This API provides more functionality than the Events API

Example

import { okta } from '@okta/okta-sdk-nodejs';
import * as fs from 'fs';

const configuration = okta.createConfiguration();
const apiInstance = new okta.SystemLogApi(configuration);

let body:okta.SystemLogApiGetLogsRequest = {
  // Date (optional)
  since: new Date('1970-01-01T00:00:00.00Z'),
  // Date (optional)
  until: new Date('1970-01-01T00:00:00.00Z'),
  // string (optional)
  filter: "filter_example",
  // string (optional)
  q: "q_example",
  // number (optional)
  limit: 100,
  // string (optional)
  sortOrder: "ASCENDING",
  // string (optional)
  after: "after_example",
};

apiInstance.getLogs(body).then((data:any) => {
  console.log('API called successfully. Returned data: ' + data);
}).catch((error:any) => console.error(error));

Parameters

Name Type Description Notes
since [Date]   (optional) defaults to undefined
until [Date]   (optional) defaults to undefined
filter [string]   (optional) defaults to undefined
q [string]   (optional) defaults to undefined
limit [number]   (optional) defaults to 100
sortOrder [string]   (optional) defaults to ‘ASCENDING’
after [string]   (optional) defaults to undefined

Return type

**Array**

Authorization

API_Token, OAuth_2.0

HTTP request headers

HTTP response details

| Status code | Description | Response headers | |————-|————-|——————| 200 | Success | - | 403 | Forbidden | - | 429 | Too Many Requests | - |

[Back to top] [Back to API list] [Back to Model list] [Back to README]