Beispiele nach Einsatz
Was Leute an Zenhook senden, und was daraus im Feed wird. Kopiere das JSON, oder füge den Prompt in deinen Coding-Agenten ein und lass ihn das Ereignis einbauen.
Verkäufe und Leads
Die Tagessumme mit einem Feld Amount, oder die Anzahl neuer Leads.
{
"title": "Payment received",
"level": "success",
"fields": [
{ "label": "Amount", "value": "$129.00" },
{ "label": "Plan", "value": "Pro" }
],
"actor": { "name": "Sarah Chen", "email": "[email protected]" }
}When a payment succeeds, send a POST request with a JSON body to the URL in the ZENHOOK_URL environment variable: title "Payment received", level "success", a field Amount with the price and currency, a field Plan, and the customer as actor with name and email. Read https://zenhook.dev/docs/api for the fields. Do nothing if ZENHOOK_URL is not set, and never let a failed request break the app.
Registrierungen
Die Zahl des Tages mit Balken pro Stunde, und jede neue Person mit Name und E-Mail.
{
"title": "New sign-up",
"level": "info",
"actor": { "name": "Lucas Martin", "email": "[email protected]", "plan": "Free" }
}When a user signs up, send a POST request with a JSON body to the URL in the ZENHOOK_URL environment variable: title "New sign-up", level "info", and the user as actor with name, email and plan. Read https://zenhook.dev/docs/api for the fields. Do nothing if ZENHOOK_URL is not set, and never let a failed request break the app.
Aktivität in einem Produkt oder Spiel
Ein Zähler mit Balken pro Stunde. Ab 3 in einer Stunde bekommt dein Handy eine Zusammenfassung pro Stunde statt jedes einzelne Ereignis.
{
"title": "Game started",
"level": "info",
"fields": [
{ "label": "Level", "value": "3" },
{ "label": "Platform", "value": "iOS" }
]
}When a game starts, send a POST request with a JSON body to the URL in the ZENHOOK_URL environment variable: title "Game started", level "info", and fields Level and Platform. Read https://zenhook.dev/docs/api for the fields. Do nothing if ZENHOOK_URL is not set, and never let a failed request break the app.
Persönliche Automatisierungen
Eine Serie von Tagen in Folge. Fehler, die mit dem Level error gesendet werden, stechen rot hervor.
{
"title": "Nightly backup",
"level": "success",
"message": "12.4 GB in 3m 12s"
}When the nightly backup finishes, send a POST request with a JSON body to the URL in the ZENHOOK_URL environment variable: title "Nightly backup", level "success" (or "error" if it failed), and a message with the size and duration. Read https://zenhook.dev/docs/api for the fields. Do nothing if ZENHOOK_URL is not set, and never let a failed request break the app.