Code and Slack: JSON Health Endpoint Parser Alert Template
A scheduled Spojit workflow that polls a service health endpoint, parses its nested status fields, and pings Slack only when a dependency is degraded or down.
What It Builds
A Schedule trigger fires on a cron interval. A Connector node in Direct mode uses the http connector to fetch your health endpoint's JSON, then a Connector node running the code connector walks the nested dependencies structure and flags anything not reporting healthy. A Condition node gates the run so a Connector node posts to Slack only when a real problem is found, keeping the channel quiet on healthy checks.
The Prompt
Paste this into Miraxa and it builds the workflow, connecting the tools for you:
Every 5 minutes, fetch the JSON from my service health endpoint at https://status.example.com/health, parse the nested dependencies object to find any that report a status of "degraded" or "down", and if at least one is unhealthy, post a Slack message to #ops-alerts listing each affected dependency name and its status. Stay silent when everything is healthy.
Connectors Used
- Schedule trigger - runs the check on a 5-field cron interval in your timezone.
- http connector - fetches the health endpoint JSON.
- code connector - parses nested status fields and builds the unhealthy list.
- Slack connector - posts the alert to your chosen channel.
Customize It
Change the URL, the interval (for example every minute), the channel name, and the status values that count as a problem (add maintenance or timeout). You can also adjust the message format right in the prompt so it lists latency or last-checked time per dependency.
Tips
- Keep the Slack post node in Direct mode so it always targets the same channel with no AI cost.
- If your endpoint needs an auth header or API key, mention it in the prompt so the http connector sends it.
- Add a quiet-hours Condition if you do not want overnight pages for non-critical dependencies.