Tiny POST-JSON helper used by every form/action site in the UI. * * Why: four components (compose modal, add-agent modal, reply box, * action panel) all did the same fetch + json-with-fallback + error * extraction dance — same shape, slightly different copy. This * centralises: * - the heade
| 12 | * Callers get a single `result.errMsg` string that's safe to render. */ |
| 13 | |
| 14 | interface ErrorShape { |
| 15 | ok?: boolean; |
| 16 | error?: string; |
| 17 | detail?: string; |
| 18 | } |
| 19 | |
| 20 | export interface PostJsonResult<T> { |
| 21 | ok: boolean; |
nothing calls this directly
no outgoing calls
no test coverage detected