> ## Documentation Index
> Fetch the complete documentation index at: https://docs.cloudthinker.io/llms.txt
> Use this file to discover all available pages before exploring further.

# Checkmk

> Connect a Checkmk site with an automation user so agents check hosts and services, then acknowledge problems or set downtime.

Connect a Checkmk site so [CloudThinker](https://docs.cloudthinker.io/guide/agents/overview.md) can check hosts, services, problems, and downtimes, and, if you allow it, acknowledge a problem or set downtime. The connection signs in to the Checkmk REST API with an automation user and its secret, and can do only what that user's role allows.

## Prerequisites

* A Checkmk site that CloudThinker can reach over HTTPS. For a private address, follow [Reaching private services](https://docs.cloudthinker.io/guide/connections/overview.md#reaching-private-services).
* A Checkmk administrator who can create users and assign roles.
* The **Admin** role in your CloudThinker workspace. See [Roles](https://docs.cloudthinker.io/guide/security/roles.md).

## Setup

**1. Create an automation user**

In Checkmk, go to **Setup → Users → Users** and add a user with a clear name, such as `cloudthinker`. In the **Security** section, choose **Automation secret for machine accounts** and generate a secret. Copy the secret. See [Checkmk's user guide](https://docs.checkmk.com/latest/en/wato_user.html).

**2. Choose its role**

Give the user a role that can see the hosts and services agents should check. See [Required permissions](#required-permissions) to pick one.

**3. Connect in CloudThinker**

Open **Settings → Workspace → Connections**, open the **Discover** tab, and select **Checkmk**. Click **Connect**, fill in the fields below, then click **Connect** in the dialog.

**Success state:** the connection shows a **Connected** status with your Checkmk version. CloudThinker then opens a chat that takes a read-only deep look at the connection ("Often takes about 15 min. You can leave the chat."). To run it again later, open the card's **More** menu and choose **Try in chat**.

## Connection details

| Field | Required | Description |
| - | - | - |
| **Site URL** | Yes | The HTTPS address of your Checkmk site, including the site name, such as `https://monitor.example.com/mysite`. Leave off `/check_mk`, credentials, query strings, and fragments |
| **Automation user** | Yes | The user name of the automation user |
| **Automation secret** | Yes | The automation secret of that user |
| **CA certificate (optional)** | No | The PEM of the private certificate authority that issued the Checkmk certificate. Leave it empty to use public trust. CloudThinker always checks the certificate and hostname |

CloudThinker refuses redirects, so enter the exact site address Checkmk answers at.

## Required permissions

The user's role decides which hosts and services agents see and whether they can acknowledge problems and set downtimes. Checkmk ships three roles:

| Checkmk role | What agents get |
| - | - |
| **Guest user** | Sees everything, changes nothing. Agents can investigate but every change fails |
| **Normal monitoring user** | Sees only the hosts and services the user is a contact for |
| **Administrator** | Sees everything and can acknowledge problems and set downtimes, but also holds every other Checkmk permission |

For changes without full admin rights, clone a role under **Setup → Users → Roles & permissions** and keep only the permissions agents need. See [Checkmk's REST API guide](https://docs.checkmk.com/latest/en/rest_api.html).

> [!TIP]
>
> Start with **Guest user**. Agents can still investigate every host, and no approval, mistaken or automatic, can change anything in Checkmk.

## Agent capabilities

| Capability | What agents can do |
| - | - |
| **Overview** | Report the site version, host totals and hosts not up, service problems by state, unhandled problems, and downtimes |
| **Problems** | List hosts not up and services in a problem state, worst first, with how long and the check output. Acknowledged problems and problems in downtime are left out unless you ask |
| **One host** | Read a host's state, address, and output, its services worst first, and its downtimes |
| **Changes** | Acknowledge one host or service problem or remove its acknowledgement, set downtime on one host or service, or end one downtime |

Reads run without asking. Each change targets one host or service, and the agent reads it again afterwards to confirm the change. A downtime starts at once and lasts from 1 minute to 7 days. Before it asks, the agent says that a downtime on a host covers every service on that host.

Agents cannot change hosts, rules, or folders, or activate changes. Make those changes in Checkmk.

Writes also need **Allow writes** on, which starts on. To lock writes in CloudThinker, open **Checkmk** in **Settings → Workspace → Connections** and turn off the **Allow writes** switch on its detail panel.

Every change an agent makes goes through your workspace's [Approvals](https://docs.cloudthinker.io/guide/approvals/overview.md) first. On the default **Auto · Rules + AI · Ask me** mode, AI judgment can let a safe change run without asking — and an Allow [Rule](https://docs.cloudthinker.io/guide/approvals/rules.md) can too. Choose **Manual** to approve every change yourself.

### Verify the connection

```text theme={null}
Give me a Checkmk overview: site version, hosts not up, service problems by state, and current downtimes
```

Expect your site version with real host and service names. A failed section is unavailable data, not zero problems.

### Example prompts

```text theme={null}
Which Checkmk hosts are down and which services are CRIT right now?
How is app-prod-02 doing in Checkmk? Show its services worst first
Acknowledge the filesystem problem on db-prod-01 with the comment "disk cleanup in progress"
```

## Troubleshooting

> [accordion] Checkmk rejected the automation user or its secret.
>
> Check the user name and secret. If needed, generate a new automation secret for the user in Checkmk, then edit the connection and paste it.

> [accordion] The automation user signed in, but its role cannot use the REST API.
>
> Give the user a role that allows REST API access, then connect again. If hosts are missing later, the role sees only hosts the user is a contact for.

> [accordion] That address has no Checkmk REST API. Check the site name in the URL, such as [https://monitor.example.com/mysite](https://monitor.example.com/mysite).
>
> The site name in the address is wrong or missing. Enter the address up to and including the site name, and leave off `/check_mk`.

> [accordion] Checkmk answered with a redirect. Use the exact https site address, such as [https://monitor.example.com/mysite](https://monitor.example.com/mysite).
>
> Enter the final HTTPS site address Checkmk serves directly, not an address that forwards to it.

> [accordion] The Checkmk certificate is not trusted.
>
> Install a certificate from a trusted authority, or paste the issuing CA certificate into **CA certificate (optional)**. If CloudThinker says the CA certificate is not valid PEM, paste the full certificate, including its `BEGIN` and `END` lines.

> [accordion] Could not reach Checkmk over HTTPS. Check the URL and that the sandbox can reach it.
>
> CloudThinker could not open a connection to that address. Confirm the URL starts with `https://` and that your firewall lets CloudThinker reach the site. Browser access from your laptop alone is not enough.

> [accordion] An agent says the Checkmk write tool is off
>
> **Allow writes** is off on this connection, so the change was refused and nothing changed. Turn it on in the connection's detail panel, or make the change in Checkmk.

## Security

* **Least privilege** — grant only the permissions the agents need for your use case; start read-only and widen later.
* **Read-only by default** — use read-only credentials unless you want agents to make changes through this connection.
* **Rotate credentials** — rotate keys and tokens on your normal schedule; CloudThinker picks up the new value when you update the connection.
* **Revoke on offboarding** — remove the credential at the provider when you delete a connection or a teammate leaves.

- Use a dedicated automation user for CloudThinker, so you can change its secret or remove it without touching other integrations.
- Avoid the **Administrator** role. A custom role with only the permissions agents need limits what a leaked secret can do.

## Related

> [card] [Approval rules](https://docs.cloudthinker.io/guide/approvals/rules.md)
>
> Decide which Checkmk changes run, wait for a person, or are refused.

> [card] [Icinga](https://docs.cloudthinker.io/guide/connections/icinga.md)
>
> Check hosts and services in Icinga 2, then acknowledge or recheck one.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.