Skip to content

Commit 340f058

Browse files
Merge branch 'master' into convert-typescript
2 parents 0e1d743 + 269c62a commit 340f058

File tree

1,432 files changed

+70439
-13501
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

1,432 files changed

+70439
-13501
lines changed
Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
2+
3+
[Home](./index.md) &gt; [kibana-plugin-core-server](./kibana-plugin-core-server.md) &gt; [AuditableEvent](./kibana-plugin-core-server.auditableevent.md)
4+
5+
## AuditableEvent interface
6+
7+
Event to audit.
8+
9+
<b>Signature:</b>
10+
11+
```typescript
12+
export interface AuditableEvent
13+
```
14+
15+
## Remarks
16+
17+
Not a complete interface.
18+
19+
## Properties
20+
21+
| Property | Type | Description |
22+
| --- | --- | --- |
23+
| [message](./kibana-plugin-core-server.auditableevent.message.md) | <code>string</code> | |
24+
| [type](./kibana-plugin-core-server.auditableevent.type.md) | <code>string</code> | |
25+
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
2+
3+
[Home](./index.md) &gt; [kibana-plugin-core-server](./kibana-plugin-core-server.md) &gt; [AuditableEvent](./kibana-plugin-core-server.auditableevent.md) &gt; [message](./kibana-plugin-core-server.auditableevent.message.md)
4+
5+
## AuditableEvent.message property
6+
7+
<b>Signature:</b>
8+
9+
```typescript
10+
message: string;
11+
```
Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,11 @@
1+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
2+
3+
[Home](./index.md) &gt; [kibana-plugin-core-server](./kibana-plugin-core-server.md) &gt; [AuditableEvent](./kibana-plugin-core-server.auditableevent.md) &gt; [type](./kibana-plugin-core-server.auditableevent.type.md)
4+
5+
## AuditableEvent.type property
6+
7+
<b>Signature:</b>
8+
9+
```typescript
10+
type: string;
11+
```
Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
2+
3+
[Home](./index.md) &gt; [kibana-plugin-core-server](./kibana-plugin-core-server.md) &gt; [Auditor](./kibana-plugin-core-server.auditor.md) &gt; [add](./kibana-plugin-core-server.auditor.add.md)
4+
5+
## Auditor.add() method
6+
7+
Add a record to audit log. Service attaches to a log record: - metadata about an end-user initiating an operation - scope name, if presents
8+
9+
<b>Signature:</b>
10+
11+
```typescript
12+
add(event: AuditableEvent): void;
13+
```
14+
15+
## Parameters
16+
17+
| Parameter | Type | Description |
18+
| --- | --- | --- |
19+
| event | <code>AuditableEvent</code> | |
20+
21+
<b>Returns:</b>
22+
23+
`void`
24+
25+
## Example
26+
27+
How to add a record in audit log:
28+
29+
```typescript
30+
router.get({ path: '/my_endpoint', validate: false }, async (context, request, response) => {
31+
context.core.auditor.withAuditScope('my_plugin_operation');
32+
const value = await context.core.elasticsearch.legacy.client.callAsCurrentUser('...');
33+
context.core.add({ type: 'operation.type', message: 'perform an operation in ... endpoint' });
34+
35+
```
36+
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
2+
3+
[Home](./index.md) &gt; [kibana-plugin-core-server](./kibana-plugin-core-server.md) &gt; [Auditor](./kibana-plugin-core-server.auditor.md)
4+
5+
## Auditor interface
6+
7+
Provides methods to log user actions and access events.
8+
9+
<b>Signature:</b>
10+
11+
```typescript
12+
export interface Auditor
13+
```
14+
15+
## Methods
16+
17+
| Method | Description |
18+
| --- | --- |
19+
| [add(event)](./kibana-plugin-core-server.auditor.add.md) | Add a record to audit log. Service attaches to a log record: - metadata about an end-user initiating an operation - scope name, if presents |
20+
| [withAuditScope(name)](./kibana-plugin-core-server.auditor.withauditscope.md) | Add a high-level scope name for logged events. It helps to identify the root cause of low-level events. |
21+
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
2+
3+
[Home](./index.md) &gt; [kibana-plugin-core-server](./kibana-plugin-core-server.md) &gt; [Auditor](./kibana-plugin-core-server.auditor.md) &gt; [withAuditScope](./kibana-plugin-core-server.auditor.withauditscope.md)
4+
5+
## Auditor.withAuditScope() method
6+
7+
Add a high-level scope name for logged events. It helps to identify the root cause of low-level events.
8+
9+
<b>Signature:</b>
10+
11+
```typescript
12+
withAuditScope(name: string): void;
13+
```
14+
15+
## Parameters
16+
17+
| Parameter | Type | Description |
18+
| --- | --- | --- |
19+
| name | <code>string</code> | |
20+
21+
<b>Returns:</b>
22+
23+
`void`
24+
Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,22 @@
1+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
2+
3+
[Home](./index.md) &gt; [kibana-plugin-core-server](./kibana-plugin-core-server.md) &gt; [AuditorFactory](./kibana-plugin-core-server.auditorfactory.md) &gt; [asScoped](./kibana-plugin-core-server.auditorfactory.asscoped.md)
4+
5+
## AuditorFactory.asScoped() method
6+
7+
<b>Signature:</b>
8+
9+
```typescript
10+
asScoped(request: KibanaRequest): Auditor;
11+
```
12+
13+
## Parameters
14+
15+
| Parameter | Type | Description |
16+
| --- | --- | --- |
17+
| request | <code>KibanaRequest</code> | |
18+
19+
<b>Returns:</b>
20+
21+
`Auditor`
22+
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
2+
3+
[Home](./index.md) &gt; [kibana-plugin-core-server](./kibana-plugin-core-server.md) &gt; [AuditorFactory](./kibana-plugin-core-server.auditorfactory.md)
4+
5+
## AuditorFactory interface
6+
7+
Creates [Auditor](./kibana-plugin-core-server.auditor.md) instance bound to the current user credentials.
8+
9+
<b>Signature:</b>
10+
11+
```typescript
12+
export interface AuditorFactory
13+
```
14+
15+
## Methods
16+
17+
| Method | Description |
18+
| --- | --- |
19+
| [asScoped(request)](./kibana-plugin-core-server.auditorfactory.asscoped.md) | |
20+
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
2+
3+
[Home](./index.md) &gt; [kibana-plugin-core-server](./kibana-plugin-core-server.md) &gt; [AuditTrailSetup](./kibana-plugin-core-server.audittrailsetup.md)
4+
5+
## AuditTrailSetup interface
6+
7+
<b>Signature:</b>
8+
9+
```typescript
10+
export interface AuditTrailSetup
11+
```
12+
13+
## Methods
14+
15+
| Method | Description |
16+
| --- | --- |
17+
| [register(auditor)](./kibana-plugin-core-server.audittrailsetup.register.md) | Register a custom [AuditorFactory](./kibana-plugin-core-server.auditorfactory.md) implementation. |
18+
Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
<!-- Do not edit this file. It is automatically generated by API Documenter. -->
2+
3+
[Home](./index.md) &gt; [kibana-plugin-core-server](./kibana-plugin-core-server.md) &gt; [AuditTrailSetup](./kibana-plugin-core-server.audittrailsetup.md) &gt; [register](./kibana-plugin-core-server.audittrailsetup.register.md)
4+
5+
## AuditTrailSetup.register() method
6+
7+
Register a custom [AuditorFactory](./kibana-plugin-core-server.auditorfactory.md) implementation.
8+
9+
<b>Signature:</b>
10+
11+
```typescript
12+
register(auditor: AuditorFactory): void;
13+
```
14+
15+
## Parameters
16+
17+
| Parameter | Type | Description |
18+
| --- | --- | --- |
19+
| auditor | <code>AuditorFactory</code> | |
20+
21+
<b>Returns:</b>
22+
23+
`void`
24+

0 commit comments

Comments
 (0)