Summary
The automated incident-response circuit breaker (merged in PR #259) is fully wired server-side but invisible in the UI. An admin monitoring a pool can see security alerts on the admin security page, but there is no screen to review an incident, act on it (resolve / resume / record the on-chain hash), or pre-authorise / revoke the automatic on-chain pause.
The backend already exists and is complete:
GET /api/admin/incidents?poolId=&callerAddress= — review queue
POST /api/admin/incidents/[id] — resolve, resume, record_onchain
GET/POST /api/admin/pause-authorizations — register, list, revoke (armed status)
There is no frontend for any of it. When the breaker auto-pauses a pool the admin receives a notification, but has nowhere to open it from.
Requirements
- Incident review screen under the existing
/dashboard/admin/security area: list incidents for a pool, showing severity, alert count, trigger rules, the decision reason, executed/dry-run state, onchain_status, cooldown/skip_reason, and timestamps — surfaced from GET /api/admin/incidents.
- Act on an incident: resolve (required note), resume (platform → active, flagging when
onchainUnpauseRequired so the admin knows the contract stays paused), and record the tx hash of the on-chain pause/unpause they signed. Wire to POST /api/admin/incidents/[id], using the existing signMessage proof helper where the endpoint expects a wallet action.
- Pause-authorization panel: show
armed state per pool, list each authorization with its status (active/used/expired/revoked) and ledger expiry, sign a new one in-browser via signPauseAuthorization (reuse frontend/lib/pause-authorization.ts and @/components/web3-provider's kit), and revoke with the SEP-53 message proof (signRevokeProof).
- Primary CTA: make the pool-paused notification/deep-link land on this review screen, and show a banner (mirroring
archived-pool-banner.tsx) when a pool is in paused status with a pause_reason, telling members what happened.
- i18n: add EN + ES strings under the existing admin namespace (
frontend/messages/en.json, es.json).
Notes / context
- Follow the existing
admin/security/page.tsx and security-alert-card.tsx conventions (data fetching, layout, accessibility).
- The API routes already do server-side auth (creator check) and rate limiting — the UI should pass
callerAddress and handle 403s gracefully.
- The entry XDR is never returned by
GET; the UI must not try to display it.
- Component tests would be valuable here (the codebase uses Vitest + RTL, e.g.
frontend/__tests__/deposit-calendar.test.tsx), covering the incident status mapping and the authorization armed/status rendering.
Acceptance criteria
Summary
The automated incident-response circuit breaker (merged in PR #259) is fully wired server-side but invisible in the UI. An admin monitoring a pool can see security alerts on the admin security page, but there is no screen to review an incident, act on it (resolve / resume / record the on-chain hash), or pre-authorise / revoke the automatic on-chain pause.
The backend already exists and is complete:
GET /api/admin/incidents?poolId=&callerAddress=— review queuePOST /api/admin/incidents/[id]—resolve,resume,record_onchainGET/POST /api/admin/pause-authorizations— register, list, revoke (armedstatus)There is no frontend for any of it. When the breaker auto-pauses a pool the admin receives a notification, but has nowhere to open it from.
Requirements
/dashboard/admin/securityarea: list incidents for a pool, showing severity, alert count, trigger rules, the decision reason,executed/dry-run state,onchain_status, cooldown/skip_reason, and timestamps — surfaced fromGET /api/admin/incidents.onchainUnpauseRequiredso the admin knows the contract stays paused), and record the tx hash of the on-chainpause/unpausethey signed. Wire toPOST /api/admin/incidents/[id], using the existingsignMessageproof helper where the endpoint expects a wallet action.armedstate per pool, list each authorization with its status (active/used/expired/revoked) and ledger expiry, sign a new one in-browser viasignPauseAuthorization(reusefrontend/lib/pause-authorization.tsand@/components/web3-provider's kit), and revoke with the SEP-53 message proof (signRevokeProof).archived-pool-banner.tsx) when a pool is inpausedstatus with apause_reason, telling members what happened.frontend/messages/en.json,es.json).Notes / context
admin/security/page.tsxandsecurity-alert-card.tsxconventions (data fetching, layout, accessibility).callerAddressand handle 403s gracefully.GET; the UI must not try to display it.frontend/__tests__/deposit-calendar.test.tsx), covering the incident status mapping and the authorizationarmed/status rendering.Acceptance criteria
pause_reason, and notifications link to the review screen