Scheduled API digest by email
Every weekday morning pull a JSON summary from your API, have an LLM turn it into three bullet points and email the team.
Drag to pan, pinch to zoom. This is the real graph the template installs.
Purpose
Every weekday morning pull a JSON summary from your API, have an LLM turn it into three bullet points and email the team.
How it works
What it does
- Cron
0 8 * * 1-5(Europe/London) → GET your metrics endpoint →ai.llmwrites three bullets → email.
Nodes 4
- 01Weekdays 08:00trigger.scheduleTrigger
- 02GET /metrics/summaryhttp.requestHTTP
- 03Write the digestai.llmAI
- 04Email the teammail.sendDestination
View template JSON
{
"format": "mantle-workflow/v1",
"id": "util-scheduled-report-email",
"name": "Scheduled API digest by email",
"graph": {
"nodes": [
{
"id": "schedule",
"type": "trigger.schedule",
"label": "Weekdays 08:00",
"config": {
"cron_expr": "0 8 * * 1-5",
"timezone": "Europe/London"
},
"worker_type": "generic-worker",
"position": {
"x": 60,
"y": 220
}
},
{
"id": "fetch_metrics",
"type": "http.request",
"label": "GET /metrics/summary",
"config": {
"method": "GET",
"url": "https://example.com/metrics/summary",
"timeout_seconds": 20
},
"worker_type": "generic-worker",
"position": {
"x": 380,
"y": 220
}
},
{
"id": "summarise",
"type": "ai.llm",
"label": "Write the digest",
"config": {
"model": "claude-haiku-4-5",
"temperature": 0.3,
"max_tokens": 400,
"system_prompt": "You write terse operational digests. Output exactly three bullet points, no preamble.",
"user_prompt": "Yesterday's metrics as JSON:\n{{ steps.fetch_metrics.body }}"
},
"worker_type": "ai-worker",
"position": {
"x": 700,
"y": 220
}
},
{
"id": "send_digest",
"type": "mail.send",
"label": "Email the team",
"config": {
"to": [
"team@example.com"
],
"subject": "Daily digest — {{ $today }}",
"body_text": "{{ steps.summarise.response }}"
},
"worker_type": "generic-worker",
"position": {
"x": 1020,
"y": 220
}
}
],
"edges": [
{
"from": "schedule",
"to": "fetch_metrics"
},
{
"from": "fetch_metrics",
"to": "summarise"
},
{
"from": "summarise",
"to": "send_digest"
}
]
}
}Requirements
The connections and permissions each step needs, from the node contracts in the catalog.
- AnthropicAPI key
Used by Write the digest.
Credential: {"api_key"}
- The provider adapter is chosen from the connection; `model` must belong to it.
- SendGridAPI key
Used by Email the team.
Credential: {"api_key"} or {"username", "password"}
Setup
- Change the metrics
url, the recipients, and pick AI + SendGrid/SMTP connections.
Sample input and output
Synthetic examples: node-contract samples or placeholders, never customer data.
Input
Runs on the cron schedule 0 8 * * 1-5 (Europe/London). There is no incoming payload: the first step fetches the data.
Output
Email the team mail.send
{
"body": null,
"message_id": "",
"provider": "",
"sent": true,
"status_code": 0,
"thread_id": ""
}Failure handling
What the graph does when a step fails, read from its retry settings, error branches and error policies.
- GET /metrics/summary: the request times out after 20 s.
- A step that fails, after any retries, fails the run. The failed step is kept with its input and error.
See it run, then make it yours.
Templates install as drafts. Edit any step, and Workflow Health re-checks the graph on every save.