Skip to content
  • There are no suggestions because the search field is empty.

Inbound Integrations, Alert Ingestion and Heartbeats with the AlertOps SDKs

Create AlertOps inbound integrations, send alerts from any system and monitor scheduled jobs with heartbeats, all from code with the AlertOps SDKs.

Overview

Relevant for Developers connecting monitoring tools and services to AlertOps

An inbound integration is how alerts get into AlertOps. Each one has its own ingest URL, an escalation policy or response play, and the groups to notify. With the AlertOps SDKs you can create integrations, send alerts from your own services, tune how events become alerts, and watch scheduled jobs with heartbeats.

Key benefits:

  • One-call setup — inbound.create_api creates a Custom API integration and returns its ingest URL.
  • Simple ingestion — ingest.post_to_integration sends an alert to any integration; the ingest URL is all a sender needs.
  • Full control — filters, grouping, override rules and dynamic recipient groups are all available from code.
  • Heartbeats — know when a backup, batch job or agent stops checking in.

Create an integration and send an alert

Relevant for Developers adding a new alert source

Create the integration with a unique source name, an escalation policy and the groups to notify, then post an alert to it.

Python

integration = ao.inbound.create_api("Payments Monitoring", source="paymentsprod",
escalation_policy_id=12345, recipient_groups=["NOC"])
request_id = ao.ingest.post_to_integration(integration["inbound_integration_id"],
{"subject": "Disk full on db-01", "description": "92% used on /var"})

TypeScript

const integration = await ao.inbound.createApi("Payments Monitoring", {
source: "paymentsprod", escalation_policy_id: 12345, recipient_groups: ["NOC"],
});
const requestId = await ao.ingest.postToIntegration(integration.inbound_integration_id,
{ subject: "Disk full on db-01", description: "92% used on /var" });

Go

integration, err := ao.Inbound.CreateAPI(ctx, "Payments Monitoring", alertops.M{
"source": "paymentsprod", "escalation_policy_id": 12345, "recipient_groups": []any{"NOC"},
})
if err != nil {
return err
}
requestID, err := ao.Ingest.PostToIntegration(ctx, alertops.Get(integration, "inbound_integration_id"),
alertops.M{"subject": "Disk full on db-01", "description": "92% used on /var"})

Java

JsonNode integration = ao.inbound().createApi("Payments Monitoring", Map.of(
"source", "paymentsprod", "escalation_policy_id", 12345, "recipient_groups", List.of("NOC")));
JsonNode requestId = ao.ingest().postToIntegration(integration.get("inbound_integration_id"),
Map.of("subject", "Disk full on db-01", "description", "92% used on /var"));

.NET

var integration = await ao.Inbound.CreateApiAsync("Payments Monitoring", new Kwargs
{
["source"] = "paymentsprod", ["escalation_policy_id"] = 12345, ["recipient_groups"] = new[] { "NOC" },
});
var requestId = await ao.Ingest.PostToIntegrationAsync(integration!["inbound_integration_id"]!,
new JsonObject { ["subject"] = "Disk full on db-01", ["description"] = "92% used on /var" });

The integration's api_url ends with its source name, so give every integration its own source. To route to a response play, pass response_play_id instead of escalation_policy_id. If you already have the URL, ingest.post_to_url posts to it directly.

An SDK-ingested alert

Figure 1. An alert posted through an SDK-created integration. The Summary panel shows the integration's source, the escalation policy and the three users notified.

Tune how events become alerts

Relevant for On-call admins reducing noise and routing alerts

GoalOperations
Map payload fields to alert fieldsinbound.mapping.update
Drop noisy events before they open alertsClassic filter sets and rule filters under inbound
Group alerts that arrive close togetherinbound.delaying_grouping.group_within
Send one notification every few minutesinbound.delaying_grouping.delay_every
Switch the escalation policy when conditions matchOverride rules under inbound
Notify a different group based on alert datainbound.dynamic_recipients.set
Clone an integration with its own URLinbound.clone_unique
Send a test alertinbound.test

Read the inbound log

Relevant for Developers confirming what happened to a payload

The inbound log shows every message an integration received, what it did (for example, opened a new alert or appended to an open one) and the alert it produced.

  • inbound.log.recent(integration_id, days=1) returns the recent messages for one integration.
  • inbound.log.get(message_id) returns one message with its body and recipients.

Heartbeats

Relevant for Developers monitoring jobs that must check in on a schedule

A heartbeat raises an alert when a job doesn't check in within its interval, so you hear about silent failures in backups, batch jobs and agents.

TaskOperation
Create a heartbeat groupheartbeats.groups.create
Create a heartbeat (name, interval in minutes, escalation policy)heartbeats.create
Check in from your jobheartbeats.ping
See its current statusheartbeats.status
See uptime across heartbeatsheartbeats.uptime
Report uptime over a date rangeheartbeats.analytics

Each heartbeat has its own check-in URL, so a job can also ping it with a plain HTTP request.

Best Practices

Relevant for Teams adding alert sources at scale

  • One source per integration — a unique source name keeps every alert on the right integration.
  • Test after setup — send one alert and check the inbound log to confirm the mapping.
  • Group bursts — use grouping for noisy sources so responders get one alert, not dozens.

Related Articles

Need help?

Email support@alertops.com or contact your AlertOps representative.