API Healthcheck (JSON) -> Discord Alert
Saves ~25 min13 credits
Ping a JSON API endpoint, validate status + JSON syntax, and post a concise health report (or alert) to Discord.
1 use
Step 1 of 5
Prompt1
Collect Endpoint + Expectations
Collect: URL, method (default GET), auth (none/bearer/basic/header), expected HTTP status (default 200), timeout, and what "healthy" means (required JSON keys, regex, or specific fields). Also collect Discord webhook_url for alerts.
Tool2
Webhook - HTTP Request
Call the endpoint. If auth needed, set auth_type and token/headers. Use response_mode=json when possible. Keep max_response_bytes reasonable (<=1MB unless needed).

Tool3
Data Format Validation (JSON Syntax)
Validate the response body is valid JSON (or capture the parse error). If the endpoint is not expected to return JSON, skip this check and focus on status + headers.

Workflow preview
What the agent will follow (tools, prompts, and workflow steps).
1. Apply the following prompt: Collect: URL, method (default GET), auth (none/bearer/basic/header), expected HTTP status (default 200), timeout, and what "healthy" means (required JSON keys, regex, or specific fields). Also collect Discord webhook_url for alerts.
2. Call tool: Webhook - HTTP Request (Webhook - HTTP Request).
Instructions:
Call the endpoint. If auth needed, set auth_type and token/headers. Use response_mode=json when possible. Keep max_response_bytes reasonable (<=1MB unless needed).
Parameters:
{"action":"request","method":"GET","response_mode":"auto","timeout_seconds":30}
3. Call tool: Data Format Validation (Data Format Validation (JSON Syntax)).
Instructions:
Validate the response body is valid JSON (or capture the parse error). If the endpoint is not expected to return JSON, skip this check and focus on status + headers.
Parameters:
{"action":"validate-json-syntax"}
4. Apply the following prompt: Evaluate: status code, latency (if available), and JSON validity + required keys. Produce: (1) PASS/FAIL line, (2) key metrics, (3) suspected cause, (4) next action. If FAIL, keep the alert under ~1200 chars.
5. Call tool: Post On Discord Channel (Post On Discord Channel).
Instructions:
Post the PASS/FAIL report to the provided webhook_url. Use a stable username like 'API Healthcheck'. Use discord URL {INSERT URL HERE}
Parameters:
{"action":"send"}