Integrations
Metoro
Overview
This document provides a detailed, step-by-step guide to integrating Metoro with Callgoose SQIBS for real-time incident creation, update, and automated resolution. The integration uses Metoro Webhooks to forward alert events to Callgoose, where API Filters convert those events into incidents and perform auto-resolution when alerts clear.
This guide follows the exact structure of the chosen template and uses only the Metoro template variable names published in Metoro’s documentation.
Prerequisites
Before beginning, ensure you have the following:
- A Callgoose SQIBS account with permissions to create API Filters and access the integration endpoint.
- A Metoro account with permission to create Alerts and Webhooks.
- A valid Callgoose API token and the API Endpoint (kept secret).
- A test Metoro alert rule you can use to validate webhook delivery and payloads.
1. Prepare Callgoose: Obtain Endpoint and Token
1.1 Retrieve Callgoose API Endpoint
Generate or locate your Callgoose process endpoint. Use a masked example (replace placeholders with your token):
https://****.callgoose.com/v1/process?from=Metoro&token=<API_TOKEN>
Store the API token securely and never commit it to source control.
2. Configure Metoro Webhook
This section shows the exact fields and template variables as published by Metoro. Use these verbatim in the Metoro UI to avoid mismatches.
2.1 Create a Webhook in Metoro
- In Metoro: go to Integrations → Add Webhook.
- Fill the form exactly as follows:
- Name (required): free text (example: Callgoose-Integration)
- URL (required): your Callgoose endpoint (the POST target). You may include template variables in the URL if you wish.
- HTTP Method: POST
- Headers: Content-Type: application/json is added by default. Add any custom headers your receiver expects (e.g., Authorization) if you prefer header auth over query token.
- Body Template (optional): leave empty to use Metoro’s default JSON or paste a custom JSON using Metoro template variables (template and examples are shown below).
- Save the webhook.
- When creating/editing an Alert Rule, select the webhook as a notification target.
Operational note: Metoro exposes webhook delivery logs under its Logs UI — use those logs to inspect the exact JSON sent.
2.2 Metoro Template Variables
Use only these documented variables when building a Body Template or placing variables in the URL:
- $alert_name
- $alert_description
- $alert_uuid
- $alert_fire_uuid
- $alert_state — values: "firing" or "resolved"
- $deep_link
- $fired_at
- $resolved_at
- $metric_name
- $breaching_datapoint_value
- $breaching_datapoint_time
- $attributes
These variable names are verbatim from Metoro documentation and will be substituted by Metoro at send time.
2.3 Recommended Body Template
Use the JSON below as the Body Template in Metoro to produce a predictable payload for Callgoose mapping:{
"alert_name": "$alert_name",
"alert_description": "$alert_description",
"alert_uuid": "$alert_uuid",
"alert_fire_uuid": "$alert_fire_uuid",
"alert_state": "$alert_state",
"deep_link": "$deep_link",
"fired_at": "$fired_at",
"resolved_at": "$resolved_at",
"metric_name": "$metric_name",
"breaching_datapoint": {
"value": "$breaching_datapoint_value",
"time": "$breaching_datapoint_time"
},
"attributes": "$attributes"
}
- Leave the Body Template blank if you prefer Metoro’s default JSON; but if you use a custom template, ensure every variable used is from the list in section 2.2.
3. Example Metoro Payloads
Below are concrete example payloads showing how Metoro will populate the documented variables when the Body Template in section 2.3 is used. These examples show realistic values but do not invent additional fields — they only populate the documented variables.
Important: always confirm the actual webhook JSON in Metoro’s delivery logs and copy those field names into Callgoose filters (Metoro may include or omit some fields depending on alert type and grouping).
3.1 Trigger (firing) payload — example
{
"alert_name": "High CPU Usage - production",
"alert_description": "CPU usage > 85% for 5m on grouped hosts",
"alert_uuid": "0f8fad5b-d9cb-469f-a165-70867728950e",
"alert_fire_uuid": "a12b3c4d-5678-90ef-1112-333444555666",
"alert_state": "firing",
"deep_link": "https://app.metoro.io/alerts/0f8f.../fires/a12b...",
"fired_at": "1696158300",
"resolved_at": "",
"metric_name": "system.cpu.user",
"breaching_datapoint": {
"value": "87.5",
"time": "1696158240"
},
"attributes": "host: app-server-02\nregion: us-east-1\nservice: payments"
}
3.2 Resolve (recovered) payload — example
{
"alert_name": "High CPU Usage - production",
"alert_description": "CPU usage > 85% for 5m on grouped hosts",
"alert_uuid": "0f8fad5b-d9cb-469f-a165-70867728950e",
"alert_fire_uuid": "a12b3c4d-5678-90ef-1112-333444555666",
"alert_state": "resolved",
"deep_link": "https://app.metoro.io/alerts/0f8f.../fires/a12b...",
"fired_at": "1696158300",
"resolved_at": "1696158720",
"metric_name": "system.cpu.user",
"breaching_datapoint": {
"value": "78.2",
"time": "1696158700"
},
"attributes": "host: app-server-02\nregion: us-east-1\nservice: payments"
}
- alert_state uses Metoro’s documented state names (firing / resolved) — use these exact strings when building Callgoose filters.
4. Create API Filters in Callgoose SQIBS
Callgoose API Filters convert incoming Metoro webhook payloads into Callgoose incidents. Configure two filters: Trigger and Resolve.
Use the exact payload key names from the Metoro template above when creating filters (alert_state, alert_fire_uuid, alert_name, alert_description, etc.).
4.1 Trigger Filter — Create Incident
- Payload JSON Key: "alert_state"
- Key Value Contains: firing
- Map Incident With: "alert_fire_uuid" (recommended for per-firing correlation)
- Incident Title: "alert_name"
- Incident Description: leave empty to include the full JSON or set to alert_description
This filter creates a new incident when Metoro sends a firing event.
4.2 Resolve Filter — Auto-Resolve Incident
- Payload JSON Key: alert_state
- Key Value Contains: resolved
- Incident Mapped With: alert_fire_uuid (same mapping field used in Trigger Filter)
When Metoro sends a resolved event using the same alert_fire_uuid, Callgoose will auto-resolve the corresponding incident. Refer to the API Filter Instructions and FAQ for more details.
5. Verify and Test the Integration
5.1 Test Initial Delivery
- From Metoro, use the webhook Test function or trigger a test alert in your alert rule.
- In Callgoose, open API Logs → verify the request arrives and inspect the raw JSON.
- Confirm the payload keys match the keys used in your API Filters.
5.2 Inspect Exact Payload
Always copy field names directly from Callgoose API Logs (the live webhook) — this prevents mismatches if Metoro omits or renames a field for your alert type.
5.3 Final Verification
- Trigger an alert in Metoro → verify an incident is created in Callgoose.
- Clear the alert condition in Metoro → verify the incident resolves in Callgoose.
- Confirm alert_fire_uuid correlation across create & resolve events.
6. Troubleshooting
- Incoming Payload Not Received
- Check Metoro webhook delivery logs (filter service.name=metoro-webhooks).
- Verify Callgoose endpoint URL and token.
- Confirm no network egress restrictions block Metoro from posting to Callgoose.
- Incidents Not Auto-Resolving
- Confirm Metoro sent "alert_state": "resolved".
- Ensure the same alert_fire_uuid (or chosen mapping field) exists in both firing and resolved payloads.
- Confirm the Resolve Filter in Callgoose is using the same mapping field.
- Wrong or Missing Payload Fields
- Inspect the exact webhook JSON in Metoro and Callgoose logs. Update API Filters to match the exact key names.
- Authentication / 401 Errors
- If using query token auth, ensure the token in the URL is correct and not expired.
- If using header auth, ensure headers are included and correctly configured in Metoro webhook.
7. Conclusion
Integrating Metoro with Callgoose SQIBS provides automated incident generation and lifecycle management for monitoring signals produced by Metoro. By using Metoro’s documented template variables and mapping them exactly in Callgoose API Filters, teams achieve reliable alert → incident translation and automatic resolution when alerts clear.
For further customization or advanced use cases, refer to the official documentation for both Metoro and Callgoose SQIBS:
