Skip to content

Commit

Permalink
Merge branch 'main' into bug-2025-workflow-execution
Browse files Browse the repository at this point in the history
  • Loading branch information
Kiryous authored Oct 29, 2024
2 parents e817716 + 0dbcd98 commit d78d02a
Show file tree
Hide file tree
Showing 87 changed files with 4,304 additions and 1,175 deletions.
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -115,6 +115,8 @@ Workflow triggers can either be executed manually when an alert is activated or
          
<img width=32 height=32 src="https://github.com/keephq/keep/blob/main/keep-ui/public/icons/grafana-icon.png?raw=true"/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<img width=32 height=32 src="https://github.com/keephq/keep/blob/main/keep-ui/public/icons/graylog-icon.png?raw=true"/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<img width=32 height=32 src="https://github.com/keephq/keep/blob/main/keep-ui/public/icons/prometheus-icon.png?raw=true"/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<img width=32 height=32 src="https://github.com/keephq/keep/blob/main/keep-ui/public/icons/sumologic-icon.png?raw=true"/>
Expand Down Expand Up @@ -209,6 +211,8 @@ Workflow triggers can either be executed manually when an alert is activated or
<img width=32 height=32 src="https://github.com/keephq/keep/blob/main/keep-ui/public/icons/grafana_incident-icon.png?raw=true"/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<img width=32 height=32 src="https://github.com/keephq/keep/blob/main/keep-ui/public/icons/webhook-icon.png?raw=true"/>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<img width=32 height=32 src="https://github.com/keephq/keep/blob/main/keep-ui/public/icons/checkmk-icon.png?raw=true"/>
</p>
<h3 align="center">Ticketing tools</h2>
<p align="center">
Expand Down
3 changes: 3 additions & 0 deletions docs/api-ref/alerts/get-alert-quality.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
---
openapi: get /alerts/quality/metrics
---
3 changes: 3 additions & 0 deletions docs/api-ref/incidents/add-comment.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
---
openapi: post /incidents/{incident_id}/comment
---
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
---
openapi: get /incidents/{incident_id}/future_incidents
---
3 changes: 3 additions & 0 deletions docs/api-ref/incidents/get-incident-workflows.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
---
openapi: get /incidents/{incident_id}/workflows
---
3 changes: 3 additions & 0 deletions docs/api-ref/incidents/get-incidents-meta.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
---
openapi: get /incidents/meta
---
3 changes: 3 additions & 0 deletions docs/api-ref/incidents/merge-incidents.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
---
openapi: post /incidents/merge
---
Binary file added docs/images/checkmk-provider_1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/images/checkmk-provider_2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/images/checkmk-provider_3.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added docs/images/checkmk-provider_4.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
12 changes: 10 additions & 2 deletions docs/mint.json
Original file line number Diff line number Diff line change
Expand Up @@ -122,6 +122,7 @@
"providers/documentation/bash-provider",
"providers/documentation/bigquery-provider",
"providers/documentation/centreon-provider",
"providers/documentation/checkmk-provider",
"providers/documentation/clickhouse-provider",
"providers/documentation/cloudwatch-provider",
"providers/documentation/console-provider",
Expand All @@ -140,6 +141,7 @@
"providers/documentation/grafana-provider",
"providers/documentation/grafana_incident-provider",
"providers/documentation/grafana_oncall-provider",
"providers/documentation/graylog-provider",
"providers/documentation/http-provider",
"providers/documentation/ilert-provider",
"providers/documentation/incidentio-provider",
Expand Down Expand Up @@ -330,7 +332,8 @@
"api-ref/alerts/unenrich-alert",
"api-ref/alerts/search-alerts",
"api-ref/alerts/get-alert-audit",
"api-ref/alerts/get-alerts"
"api-ref/alerts/get-alerts",
"api-ref/alerts/get-alert-quality"
]
},
{
Expand Down Expand Up @@ -365,7 +368,12 @@
"api-ref/incidents/get-incident-alerts",
"api-ref/incidents/add-alerts-to-incident",
"api-ref/incidents/delete-alerts-from-incident",
"api-ref/incidents/confirm-incident"
"api-ref/incidents/confirm-incident",
"api-ref/incidents/add-comment",
"api-ref/incidents/get-future-incidents-for-an-incident",
"api-ref/incidents/get-incident-workflows",
"api-ref/incidents/get-incidents-meta",
"api-ref/incidents/merge-incidents"
]
},
{
Expand Down
2 changes: 1 addition & 1 deletion docs/openapi.json

Large diffs are not rendered by default.

89 changes: 89 additions & 0 deletions docs/providers/documentation/checkmk-provider.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,89 @@
---
title: 'Checkmk'
sidebarTitle: 'Checkmk Provider'
description: 'Checkmk provider allows you to get alerts from Checkmk via webhooks.'
---

## Overview

The Checkmk provider enables seamless integration between Keep and Checkmk. It allows you to get alerts from Checkmk to Keep via webhooks making it easier to manage your infrastructure and applications in one place.

## Connecting Checkmk to Keep

To connect Checkmk to Keep, you need to configure it as a webhook from Checkmk. Follow the steps below to set up the integration:

1. Keep webhook script need to installed on the Checkmk server.

2. You can download the Keep webhook script using the following command:

```bash
wget -O webhook-keep.py https://github.com/keephq/keep/blob/main/keep/providers/checkmk_provider/webhook-keep.py?raw=true
```

3. Copy the downloaded script to the following path on the Checkmk server:

If you are using Checkmk Docker container, then copy it to the following path according to your docker volume mapping:

```bash
cp webhook-keep.py /omd/sites/<site_name>/local/share/check_mk/notifications/webhook-keep.py
cd /omd/sites/<site_name>/local/share/check_mk/notifications
```

If you are using Checkmk installed on the server, then copy it to the following path:

```bash
cp webhook-keep.py ~/local/share/check_mk/notifications/webhook-keep.py
cd ~/local/share/check_mk/notifications
```

4. Make the script executable:

```bash
chmod +x webhook-keep.py
```

5. Now go to the Checkmk web interface and navigate to Setup

<Frame
width="100"
height="200">
<img height="10" src="/images/checkmk-provider_1.png" />
</Frame>

6. Click on Notifications under Events

<Frame
width="100"
height="200">
<img height="10" src="/images/checkmk-provider_2.png" />
</Frame>

6. Click on Add rule

<Frame
width="100"
height="200">
<img height="10" src="/images/checkmk-provider_3.png" />
</Frame>

7. In the Notifications method method, select "webhook-keep" as the notification method.

<Frame
width="100"
height="200">
<img height="10" src="/images/checkmk-provider_4.png" />
</Frame>

8. Configure the Rule properties, Contact selections, and Conditions according to your requirements.

9. The first parameter is the Webhook URL of Keep which is `https://api.keephq.dev/alerts/event/checkmk`.

10. The second parameter is the API Key of Keep which you can generate in the [Keep settings](https://platform.keephq.dev/settings?selectedTab=users&userSubTab=api-keys).

11. Click on Save to save the configuration.

12. Now you will start receiving alerts from Checkmk to Keep via webhooks when the configured conditions are met.

## Useful Links

- [Checkmk](https://checkmk.com/)
59 changes: 59 additions & 0 deletions docs/providers/documentation/graylog-provider.mdx
Original file line number Diff line number Diff line change
@@ -0,0 +1,59 @@
---
title: "Graylog Provider"
sidebarTitle: "Graylog Provider"
description: "The Graylog provider enables webhook installations for receiving alerts in Keep"
---

## Overview

The **Graylog Provider** facilitates receiving alerts from Graylog by setting up Webhook connections. It allows seamless integration with Graylog to receive notifications about events and alerts through Keep.

## Authentication Parameters

- **Username** (required): Username for authenticating with Graylog's API.
- **Graylog Access Token** (required): Access token for authenticating with Graylog's API.
- **Deployment Url** (required): Deployment URL for connecting to the Graylog instance (e.g., `http://localhost:9000`).

## Scopes

- **authenticated**: Mandatory for all operations, ensures the user is authenticated.
- **authorized**: Mandatory for querying incidents and managing resources, ensures the user has `Admin` privileges.

## Connecting with the Provider

1. Obtain the **username** and **access token** from your Graylog instance by following [Graylog's API Access Documentation](https://go2docs.graylog.org/current/setting_up_graylog/rest_api_access_tokens.htm?tocpath=Set%20up%20Graylog%7CGet%20Started%20with%20Graylog%7CREST%C2%A0API%7C_____3#CreateanAccessToken).
2. Set the **deployment URL** to your Graylog instance's base URL (e.g., `http://127.0.0.1:9000`).
3. Ensure the user has the **Admin** role in Graylog.

## Features

The **Graylog Provider** supports the following key features:

- **Webhook Setup**: Configures webhooks to send alerts to Keep.
- **Alerts Retrieval**: Fetches and formats alerts from Graylog based on specified search parameters (only a maximum of 10000 most recent alerts)

## Inputs for Query
- **events_search_parameters**: Takes in a python dict
Example:
```
{
"filter": {"alerts": "only"},
"page": 1,
"per_page": 1000,
"query": "",
"timerange": {"range": 86400, "type": "relative"},
}
```
- You can modify this to fetch either alerts, events or both.

---

**Note**: Ensure that the product of `page` and `per_page` does not exceed 10,000.

---

## Useful Links

- [Graylog API Documentation](https://go2docs.graylog.org/current/what_is_graylog/what_is_graylog.htm?tocpath=What%20Is%20Graylog%253F%7C_____0)
- [Graylog Access Token](https://go2docs.graylog.org/current/setting_up_graylog/rest_api_access_tokens.htm?tocpath=Set%20up%20Graylog%7CGet%20Started%20with%20Graylog%7CREST%C2%A0API%7C_____3#CreateanAccessToken)
- [Quick Setup for Graylog & Integration with Keep](https://github.com/keephq/keep/keep/providers/graylog_provider/README.md)
16 changes: 16 additions & 0 deletions docs/providers/overview.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -172,6 +172,14 @@ By leveraging Keep Providers, users are able to deeply integrate Keep with the t
}
></Card>

<Card
title="Checkmk"
href="/providers/documentation/checkmk-provider"
icon={
<img src="https://img.logo.dev/checkmk.com?token=pk_dfXfZBoKQMGDTIgqu7LvYg" />
}
></Card>

<Card
title="Coralogix"
href="/providers/documentation/coralogix-provider"
Expand Down Expand Up @@ -268,6 +276,14 @@ By leveraging Keep Providers, users are able to deeply integrate Keep with the t
}
></Card>

<Card
title="Graylog"
href="/providers/documentation/graylog-provider"
icon={
<img src="https://github.com/keephq/keep/blob/main/keep-ui/public/icons/graylog-icon.png?raw=true" />
}
></Card>

<Card
title="HTTP"
href="/providers/documentation/http-provider"
Expand Down
2 changes: 2 additions & 0 deletions keep-ui/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ pids
*.pid
*.seed

!lib

# Directory for instrumented libs generated by jscoverage/JSCover
lib-cov

Expand Down
Loading

0 comments on commit d78d02a

Please sign in to comment.