Push notifications #16#28
Open
goncharik wants to merge 33 commits into
Open
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Push Notifications
Notify the iOS app when the self-hosted agent needs the user, even while backgrounded.
Architecture (3 components, this PR is the iOS app only)
PushClientdependency client, app-delegate token/tap bridge, registration lifecycle, tap deep-link + nav-aware foreground suppression + approval badge, Settings toggle + "Send test notification", a plugin-readiness onboarding flow (below), and the push entitlement (aps-environmentper-config) +remote-notificationbackground mode.goncharik/hermes-mobile-push-gateway(private): stateless Cloudflare Worker holding the APNs.p8, mints the ES256 JWT, forwards to APNs.goncharik/hermes-mobile-push-plugin(public): standalone pip plugin using hermes-agent's public plugin API (hermes-agent is not modified).Privacy: only a generic title/body +
session_idtransit the gateway; content is fetched in-app over the private network. Plugin↔gateway HMAC is a shared secret.Triggers (all four, via real plugin hooks — CLI + gateway)
pre_approval_requestpre_tool_callfiltered to theclarifytool (before the user is prompted; not duration-gated; suppresses that turn's trailing complete)post_llm_call(gated to ~>10s turns via apre_llm_callstart anchor + dedup)on_session_end(genuine failures only; not success/interrupt)Onboarding flow
GET /api/dashboard/plugins/hub(ready / not-ready / unknown).Tests
578 HermesKit tests + all snapshots green; app builds. (Gateway/plugin suites — 77 + 110 — live in their own repos.)
Before it works on a device (manual)
Apple: enable Push capability + create the APNs
.p8. Gateway: set secrets +wrangler deploy, then point the plugin at the URL + shared HMAC secret. On-device E2E in both sandbox (Debug) and production (TestFlight).