From 1f28fc46c12bcb3fdc0c4a4dd2a184dbf884d803 Mon Sep 17 00:00:00 2001 From: apinator-dev Date: Sat, 17 Oct 2026 13:22:38 +0200 Subject: [PATCH] docs: document cache channels Add a Cache Channels section to the README covering the cache-, private-cache- and presence-cache- prefixes, the 30-minute TTL and a fallback for when nothing is cached. --- README.md | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/README.md b/README.md index 022fda6..11209d1 100644 --- a/README.md +++ b/README.md @@ -41,6 +41,21 @@ client.trigger( ) ``` +## Cache Channels + +Publish to a channel named `cache-`, `private-cache-` or `presence-cache-` and Apinator keeps +the last event for 30 minutes, so a client that subscribes after the publish still receives it. +Nothing else changes: trigger as usual, and authorize private and presence cache channels like +any other private or presence channel. + +```python +client.trigger( + "job-finished", + '{"status": "done"}', + channel=f"private-cache-job-{job_id}", +) +``` + ## Channel Authentication For private and presence channels, your backend must provide an auth endpoint: