New daemon architecture

This commit is contained in:
2026-02-06 13:47:06 -03:00
commit cbe18da598
18 changed files with 2435 additions and 0 deletions

22
internal/ipc/protocol.go Normal file
View File

@@ -0,0 +1,22 @@
package ipc
// JSONL request/response protocol shared by bleh and blehd.
type Request struct {
ID string `json:"id"`
Method string `json:"method"`
Params map[string]any `json:"params,omitempty"`
}
type Error struct {
Code string `json:"code"`
Message string `json:"message"`
}
type Response struct {
ID string `json:"id,omitempty"`
OK bool `json:"ok"`
Result any `json:"result,omitempty"`
Error *Error `json:"error,omitempty"`
Event string `json:"event,omitempty"`
}