KosmoKrator

analytics

Healthchecks.io Lua API for KosmoKrator Agents

Agent-facing Lua documentation and function reference for the Healthchecks.io KosmoKrator integration.

Lua Namespace

Agents call this integration through app.integrations.healthchecks_io.*. Use lua_read_doc("integrations.healthchecks-io") inside KosmoKrator to discover the same reference at runtime.

Call Lua from the Headless CLI

Use kosmo integrations:lua when a shell script, CI job, cron job, or another coding CLI should run a deterministic Healthchecks.io workflow without starting an interactive agent session.

Inline Lua call
kosmo integrations:lua --eval 'dump(app.integrations.healthchecks_io.list({slug = "example_slug", tag = "example_tag"}))' --json
Read Lua docs headlessly
kosmo integrations:lua --eval 'print(docs.read("healthchecks-io"))' --json
kosmo integrations:lua --eval 'print(docs.read("healthchecks-io.list"))' --json

Workflow file

Put repeatable logic in a Lua file, then execute it with JSON output for the calling process.

workflow.lua
local healthchecks_io = app.integrations.healthchecks_io
local result = healthchecks_io.list({slug = "example_slug", tag = "example_tag"})

dump(result)
Run the workflow
kosmo integrations:lua workflow.lua --json
kosmo integrations:lua workflow.lua --force --json
Namespace note. integrations:lua exposes app.integrations.healthchecks_io, app.mcp.*, docs.*, json.*, and regex.*. Use app.integrations.healthchecks_io.default.* or app.integrations.healthchecks_io.work.* when you configured named credential accounts.

MCP-only Lua

If the script only needs configured MCP servers and does not need Healthchecks.io, use the narrower mcp:lua command.

MCP Lua command
# Use mcp:lua for MCP-only scripts; use integrations:lua for this integration namespace.
kosmo mcp:lua --eval 'dump(mcp.servers())' --json

Agent-Facing Lua Docs

This is the rendered version of the full Lua documentation exposed to agents when they inspect the integration namespace.

Healthchecks.io Integration

Use the healthchecks-io integration to manage Healthchecks.io checks and to send ping signals from agents or scripts.

The package covers the official Management API v3 documented at https://healthchecks.io/docs/api/ and the Pinging API documented at https://healthchecks.io/docs/http_api/.

Common Tools

  • healthchecks_io_list_checks, healthchecks_io_get_check, healthchecks_io_create_check, healthchecks_io_update_check, healthchecks_io_pause_check, healthchecks_io_resume_check, and healthchecks_io_delete_check manage checks.
  • healthchecks_io_list_pings, healthchecks_io_get_ping_body, and healthchecks_io_list_flips inspect ping history and status changes.
  • healthchecks_io_list_channels, healthchecks_io_list_badges, and healthchecks_io_get_status cover project integrations, badges, and service health.
  • healthchecks_io_ping_success_uuid, healthchecks_io_ping_start_uuid, healthchecks_io_ping_fail_uuid, healthchecks_io_ping_log_uuid, and healthchecks_io_ping_exit_status_uuid send UUID-based ping signals.
  • healthchecks_io_ping_success_slug, healthchecks_io_ping_start_slug, healthchecks_io_ping_fail_slug, healthchecks_io_ping_log_slug, and healthchecks_io_ping_exit_status_slug send slug-based ping signals using a ping_key and slug.

Request Shape

Management API tools use the configured project API key as X-Api-Key. POST management tools accept a body object with Healthchecks.io fields such as name, slug, tags, desc, timeout, grace, schedule, and tz.

Ping tools default to POST but accept http_method = "HEAD", "GET", or "POST". For POST ping tools, use body_text to send diagnostic text. Slug ping tools accept create = 1 for auto-provisioning where the Healthchecks.io Pinging API supports it.

Return Shape

JSON responses are returned as decoded arrays/objects. Text responses, including Pinging API OK responses and ping body retrieval, return { body = <text>, status = <http_status>, content_type = <content_type> }.

Examples

local checks = app.integrations["healthchecks-io"].list_checks({ tag = { "backup", "prod" } })

local created = app.integrations["healthchecks-io"].create_check({
  body = {
    name = "Database Backup",
    slug = "database-backup",
    tags = "backup prod",
    timeout = 3600,
    grace = 600
  }
})

local ping = app.integrations["healthchecks-io"].ping_success_slug({
  ping_key = "example-ping-key",
  slug = "database-backup",
  create = 1,
  body_text = "backup completed"
})

Use fake UUIDs, slugs, ping keys, check names, and diagnostic text in tests and examples. Do not store real ping keys, project API keys, customer details, or production incident logs in fixtures or Lua examples.

Raw agent markdown
# Healthchecks.io Integration

Use the `healthchecks-io` integration to manage Healthchecks.io checks and to send ping signals from agents or scripts.

The package covers the official Management API v3 documented at `https://healthchecks.io/docs/api/` and the Pinging API documented at `https://healthchecks.io/docs/http_api/`.

## Common Tools

- `healthchecks_io_list_checks`, `healthchecks_io_get_check`, `healthchecks_io_create_check`, `healthchecks_io_update_check`, `healthchecks_io_pause_check`, `healthchecks_io_resume_check`, and `healthchecks_io_delete_check` manage checks.
- `healthchecks_io_list_pings`, `healthchecks_io_get_ping_body`, and `healthchecks_io_list_flips` inspect ping history and status changes.
- `healthchecks_io_list_channels`, `healthchecks_io_list_badges`, and `healthchecks_io_get_status` cover project integrations, badges, and service health.
- `healthchecks_io_ping_success_uuid`, `healthchecks_io_ping_start_uuid`, `healthchecks_io_ping_fail_uuid`, `healthchecks_io_ping_log_uuid`, and `healthchecks_io_ping_exit_status_uuid` send UUID-based ping signals.
- `healthchecks_io_ping_success_slug`, `healthchecks_io_ping_start_slug`, `healthchecks_io_ping_fail_slug`, `healthchecks_io_ping_log_slug`, and `healthchecks_io_ping_exit_status_slug` send slug-based ping signals using a `ping_key` and `slug`.

## Request Shape

Management API tools use the configured project API key as `X-Api-Key`. POST management tools accept a `body` object with Healthchecks.io fields such as `name`, `slug`, `tags`, `desc`, `timeout`, `grace`, `schedule`, and `tz`.

Ping tools default to POST but accept `http_method = "HEAD"`, `"GET"`, or `"POST"`. For POST ping tools, use `body_text` to send diagnostic text. Slug ping tools accept `create = 1` for auto-provisioning where the Healthchecks.io Pinging API supports it.

## Return Shape

JSON responses are returned as decoded arrays/objects. Text responses, including Pinging API `OK` responses and ping body retrieval, return `{ body = <text>, status = <http_status>, content_type = <content_type> }`.

## Examples

```lua
local checks = app.integrations["healthchecks-io"].list_checks({ tag = { "backup", "prod" } })

local created = app.integrations["healthchecks-io"].create_check({
  body = {
    name = "Database Backup",
    slug = "database-backup",
    tags = "backup prod",
    timeout = 3600,
    grace = 600
  }
})

local ping = app.integrations["healthchecks-io"].ping_success_slug({
  ping_key = "example-ping-key",
  slug = "database-backup",
  create = 1,
  body_text = "backup completed"
})
```

Use fake UUIDs, slugs, ping keys, check names, and diagnostic text in tests and examples. Do not store real ping keys, project API keys, customer details, or production incident logs in fixtures or Lua examples.
Metadata-derived Lua example
local result = app.integrations.healthchecks_io.list({slug = "example_slug", tag = "example_tag"})
print(result)

Functions

list Read

List existing checks Official Healthchecks.io endpoint: GET https://healthchecks.io/api/v3/checks/.

Lua path
app.integrations.healthchecks_io.list
Full name
healthchecks-io.healthchecks_io_list_checks
ParameterTypeRequiredDescription
slug string no slug query parameter
tag string no tag query parameter
get Read

Get a single check by UUID or unique key Official Healthchecks.io endpoint: GET https://healthchecks.io/api/v3/checks/{check_id}.

Lua path
app.integrations.healthchecks_io.get
Full name
healthchecks-io.healthchecks_io_get_check
ParameterTypeRequiredDescription
check_id string yes check id path parameter
create Write

Create a new check Official Healthchecks.io endpoint: POST https://healthchecks.io/api/v3/checks/.

Lua path
app.integrations.healthchecks_io.create
Full name
healthchecks-io.healthchecks_io_create_check
ParameterTypeRequiredDescription
body object no JSON request body matching the official Healthchecks.io Management API parameters.
update Write

Update an existing check Official Healthchecks.io endpoint: POST https://healthchecks.io/api/v3/checks/{uuid}.

Lua path
app.integrations.healthchecks_io.update
Full name
healthchecks-io.healthchecks_io_update_check
ParameterTypeRequiredDescription
uuid string yes uuid path parameter
body object no JSON request body matching the official Healthchecks.io Management API parameters.
pause Write

Pause monitoring of a check Official Healthchecks.io endpoint: POST https://healthchecks.io/api/v3/checks/{uuid}/pause.

Lua path
app.integrations.healthchecks_io.pause
Full name
healthchecks-io.healthchecks_io_pause_check
ParameterTypeRequiredDescription
uuid string yes uuid path parameter
resume Write

Resume monitoring of a check Official Healthchecks.io endpoint: POST https://healthchecks.io/api/v3/checks/{uuid}/resume.

Lua path
app.integrations.healthchecks_io.resume
Full name
healthchecks-io.healthchecks_io_resume_check
ParameterTypeRequiredDescription
uuid string yes uuid path parameter
delete Write

Delete a check Official Healthchecks.io endpoint: DELETE https://healthchecks.io/api/v3/checks/{uuid}.

Lua path
app.integrations.healthchecks_io.delete
Full name
healthchecks-io.healthchecks_io_delete_check
ParameterTypeRequiredDescription
uuid string yes uuid path parameter
list_pings Read

List a check's logged pings Official Healthchecks.io endpoint: GET https://healthchecks.io/api/v3/checks/{uuid}/pings/.

Lua path
app.integrations.healthchecks_io.list_pings
Full name
healthchecks-io.healthchecks_io_list_pings
ParameterTypeRequiredDescription
uuid string yes uuid path parameter
get_ping_body Read

Get a ping's logged body Official Healthchecks.io endpoint: GET https://healthchecks.io/api/v3/checks/{uuid}/pings/{n}/body.

Lua path
app.integrations.healthchecks_io.get_ping_body
Full name
healthchecks-io.healthchecks_io_get_ping_body
ParameterTypeRequiredDescription
uuid string yes uuid path parameter
n number yes n path parameter
list_flips Read

List a check's status changes Official Healthchecks.io endpoint: GET https://healthchecks.io/api/v3/checks/{check_id}/flips/.

Lua path
app.integrations.healthchecks_io.list_flips
Full name
healthchecks-io.healthchecks_io_list_flips
ParameterTypeRequiredDescription
check_id string yes check id path parameter
seconds number no seconds query parameter
start number no start query parameter
end number no end query parameter
list_channels Read

List existing integrations/channels Official Healthchecks.io endpoint: GET https://healthchecks.io/api/v3/channels/.

Lua path
app.integrations.healthchecks_io.list_channels
Full name
healthchecks-io.healthchecks_io_list_channels
ParameterTypeRequiredDescription
No parameters.
list_badges Read

List project's badges Official Healthchecks.io endpoint: GET https://healthchecks.io/api/v3/badges/.

Lua path
app.integrations.healthchecks_io.list_badges
Full name
healthchecks-io.healthchecks_io_list_badges
ParameterTypeRequiredDescription
No parameters.
get_status Read

Check Healthchecks.io database connectivity Official Healthchecks.io endpoint: GET https://healthchecks.io/api/v3/status/.

Lua path
app.integrations.healthchecks_io.get_status
Full name
healthchecks-io.healthchecks_io_get_status
ParameterTypeRequiredDescription
No parameters.
ping_success_uuid Read

Send a success uuid ping signal Official Healthchecks.io endpoint: POST https://hc-ping.com/{uuid}.

Lua path
app.integrations.healthchecks_io.ping_success_uuid
Full name
healthchecks-io.healthchecks_io_ping_success_uuid
ParameterTypeRequiredDescription
uuid string yes uuid path parameter
rid string no rid query parameter
http_method string no Ping request method: HEAD, GET, or POST. Defaults to POST.
body_text string no Optional diagnostic text body for POST ping requests.
ping_start_uuid Read

Send a start uuid ping signal Official Healthchecks.io endpoint: POST https://hc-ping.com/{uuid}/start.

Lua path
app.integrations.healthchecks_io.ping_start_uuid
Full name
healthchecks-io.healthchecks_io_ping_start_uuid
ParameterTypeRequiredDescription
uuid string yes uuid path parameter
rid string no rid query parameter
http_method string no Ping request method: HEAD, GET, or POST. Defaults to POST.
body_text string no Optional diagnostic text body for POST ping requests.
ping_fail_uuid Read

Send a fail uuid ping signal Official Healthchecks.io endpoint: POST https://hc-ping.com/{uuid}/fail.

Lua path
app.integrations.healthchecks_io.ping_fail_uuid
Full name
healthchecks-io.healthchecks_io_ping_fail_uuid
ParameterTypeRequiredDescription
uuid string yes uuid path parameter
rid string no rid query parameter
http_method string no Ping request method: HEAD, GET, or POST. Defaults to POST.
body_text string no Optional diagnostic text body for POST ping requests.
ping_log_uuid Read

Send a log uuid ping signal Official Healthchecks.io endpoint: POST https://hc-ping.com/{uuid}/log.

Lua path
app.integrations.healthchecks_io.ping_log_uuid
Full name
healthchecks-io.healthchecks_io_ping_log_uuid
ParameterTypeRequiredDescription
uuid string yes uuid path parameter
rid string no rid query parameter
http_method string no Ping request method: HEAD, GET, or POST. Defaults to POST.
body_text string no Optional diagnostic text body for POST ping requests.
ping_exit_status_uuid Read

Send a exit status uuid ping signal Official Healthchecks.io endpoint: POST https://hc-ping.com/{uuid}/{exit_status}.

Lua path
app.integrations.healthchecks_io.ping_exit_status_uuid
Full name
healthchecks-io.healthchecks_io_ping_exit_status_uuid
ParameterTypeRequiredDescription
uuid string yes uuid path parameter
exit_status number yes exit status path parameter
rid string no rid query parameter
http_method string no Ping request method: HEAD, GET, or POST. Defaults to POST.
body_text string no Optional diagnostic text body for POST ping requests.
ping_success_slug Read

Send a success slug ping signal Official Healthchecks.io endpoint: POST https://hc-ping.com/{ping_key}/{slug}.

Lua path
app.integrations.healthchecks_io.ping_success_slug
Full name
healthchecks-io.healthchecks_io_ping_success_slug
ParameterTypeRequiredDescription
ping_key string yes ping key path parameter
slug string yes slug path parameter
rid string no rid query parameter
create string no create query parameter
http_method string no Ping request method: HEAD, GET, or POST. Defaults to POST.
body_text string no Optional diagnostic text body for POST ping requests.
ping_start_slug Read

Send a start slug ping signal Official Healthchecks.io endpoint: POST https://hc-ping.com/{ping_key}/{slug}/start.

Lua path
app.integrations.healthchecks_io.ping_start_slug
Full name
healthchecks-io.healthchecks_io_ping_start_slug
ParameterTypeRequiredDescription
ping_key string yes ping key path parameter
slug string yes slug path parameter
rid string no rid query parameter
create string no create query parameter
http_method string no Ping request method: HEAD, GET, or POST. Defaults to POST.
body_text string no Optional diagnostic text body for POST ping requests.
ping_fail_slug Read

Send a fail slug ping signal Official Healthchecks.io endpoint: POST https://hc-ping.com/{ping_key}/{slug}/fail.

Lua path
app.integrations.healthchecks_io.ping_fail_slug
Full name
healthchecks-io.healthchecks_io_ping_fail_slug
ParameterTypeRequiredDescription
ping_key string yes ping key path parameter
slug string yes slug path parameter
rid string no rid query parameter
create string no create query parameter
http_method string no Ping request method: HEAD, GET, or POST. Defaults to POST.
body_text string no Optional diagnostic text body for POST ping requests.
ping_log_slug Read

Send a log slug ping signal Official Healthchecks.io endpoint: POST https://hc-ping.com/{ping_key}/{slug}/log.

Lua path
app.integrations.healthchecks_io.ping_log_slug
Full name
healthchecks-io.healthchecks_io_ping_log_slug
ParameterTypeRequiredDescription
ping_key string yes ping key path parameter
slug string yes slug path parameter
rid string no rid query parameter
create string no create query parameter
http_method string no Ping request method: HEAD, GET, or POST. Defaults to POST.
body_text string no Optional diagnostic text body for POST ping requests.
ping_exit_status_slug Read

Send a exit status slug ping signal Official Healthchecks.io endpoint: POST https://hc-ping.com/{ping_key}/{slug}/{exit_status}.

Lua path
app.integrations.healthchecks_io.ping_exit_status_slug
Full name
healthchecks-io.healthchecks_io_ping_exit_status_slug
ParameterTypeRequiredDescription
ping_key string yes ping key path parameter
slug string yes slug path parameter
exit_status number yes exit status path parameter
rid string no rid query parameter
create string no create query parameter
http_method string no Ping request method: HEAD, GET, or POST. Defaults to POST.
body_text string no Optional diagnostic text body for POST ping requests.