Documentation
¶
Overview ¶
Package server provides the HTTP API server (Fiber v3) and route handlers.
Index ¶
- Constants
- Variables
- func ChatAgentService() *chatagent.Service
- func NewPipelineStepCallback(client *redis.Client) pipeline.StepCallback
- func RegisterAgentLLMRoutes(a *fiber.App)
- func RegisterChatAgentRoutes(a *fiber.App, svc *chatagent.Service)
- func RegisterChatAgentSignedMediaRoute(a *fiber.App)
- func RegisterGatewayRoutes(a *fiber.App)
- func RunHomelabScan(cfg config.Homelab) error
- func RunServer(lc fx.Lifecycle, app *fiber.App, shutdowner fx.Shutdowner, _ store.Adapter, ...)
- func SetCacheStore(s *cache.RedisStore)
- func WireAccessTokenStore()
- func WireFileMetaStore()
- func WireMessageDestinations()
- func WireModuleDataStore()
- func WireNotifyStores()
- func WireOAuthTokenStore()
- type Controller
Constants ¶
const DataEventTopic = "pipeline:data_event"
Variables ¶
var MediaModules = fx.Options( fx.Invoke( WireFileMetaStore, fs.Register, minio.Register, ), )
var Modules = fx.Options( flog.FxModule, metrics.Module(), modules.Modules, NotifyModules, MediaModules, OAuthModules, ReexecModules, fx.Provide( config.NewConfig, cache.NewCache, rdb.NewClient, cache.NewRedisStore, event.NewRouter, event.NewSubscriber, event.NewPublisher, slack.NewDriver, trace.NewTracerProvider, newController, newDatabaseAdapter, newHTTPServer, newAuditor, ), fx.Invoke( setServerCacheStore, setRouteAuditor, WireAccessTokenStore, WireModuleDataStore, WireMessageDestinations, setAgentMetricsCollector, handleRoutes, handleEvents, initPipeline, initWorkflow, initFunctions, initAgentAbility, initClipAbility, initGatewayAbility, initChatAgentScheduler, handleModules, handlePlatform, RunServer, profiling.NewProfiler, initPageDataCleanup, ), )
var NotifyModules = fx.Options( fx.Invoke( messagepusher.Register, ntfy.Register, pushover.Register, slack.Register, inapp.Register, WireNotifyStores, initNotificationGateway, ), )
var OAuthModules = fx.Options( fx.Invoke( WireOAuthTokenStore, github.Register, slack.Register, dropbox.Register, ), )
OAuthModules registers all OAuth provider factories via fx.
ReexecModules registers all reexec handlers via fx.
Functions ¶
func ChatAgentService ¶ added in v0.98.2
ChatAgentService returns the process-wide chatagent Service, creating and binding it once on first use.
func NewPipelineStepCallback ¶ added in v0.92.0
func NewPipelineStepCallback(client *redis.Client) pipeline.StepCallback
NewPipelineStepCallback creates a callback backed by the Redis client. Returns nil if rdb is nil.
func RegisterAgentLLMRoutes ¶ added in v0.99.0
RegisterAgentLLMRoutes mounts the OpenAI-compatible LLM proxy for flowbot-agent.
func RegisterChatAgentRoutes ¶ added in v0.93.0
RegisterChatAgentRoutes wires Chat Agent REST endpoints for HTTP clients.
func RegisterChatAgentSignedMediaRoute ¶ added in v0.98.2
RegisterChatAgentSignedMediaRoute serves HMAC-signed FS media for LLM providers.
func RegisterGatewayRoutes ¶ added in v0.99.0
RegisterGatewayRoutes mounts local-CLI gateway worker APIs (not notification gateway).
func RunHomelabScan ¶ added in v0.92.0
RunHomelabScan executes a full homelab scan + probe + registry update cycle. It walks the configured apps directory, discovers compose files, runs the probe engine for endpoint/auth discovery, and replaces the default registry. Exported for use by the homelab web handler to support manual rescan.
func SetCacheStore ¶ added in v0.92.0
func SetCacheStore(s *cache.RedisStore)
SetCacheStore sets the cache store for server functions.
func WireAccessTokenStore ¶ added in v0.99.0
func WireAccessTokenStore()
WireAccessTokenStore injects the store-backed access token adapter into route.
func WireFileMetaStore ¶ added in v0.99.0
func WireFileMetaStore()
WireFileMetaStore injects the store-backed file metadata adapter into media.
func WireMessageDestinations ¶ added in v0.99.0
func WireMessageDestinations()
WireMessageDestinations injects the store-backed message destinations adapter into event.
func WireModuleDataStore ¶ added in v0.99.0
func WireModuleDataStore()
WireModuleDataStore injects the store-backed module data adapter into module.
func WireNotifyStores ¶ added in v0.99.0
func WireNotifyStores()
WireNotifyStores injects store-backed notify adapters into pkg/notify.
func WireOAuthTokenStore ¶ added in v0.99.0
func WireOAuthTokenStore()
WireOAuthTokenStore injects the store-backed OAuth token adapter into providers.
Types ¶
type Controller ¶ added in v0.31.1
type Controller struct {
// contains filtered or unexported fields
}
Source Files
¶
- access_token_store.go
- agent.go
- agent_ability.go
- agent_llm_http.go
- agent_llm_openai.go
- capability.go
- chat.go
- chatagent_bootstrap.go
- chatagent_handler.go
- chatagent_http.go
- chatagent_http_approval.go
- chatagent_http_messages.go
- chatagent_http_permissions.go
- chatagent_http_resources.go
- chatagent_http_scheduled.go
- chatagent_http_sessions.go
- chatagent_scheduler.go
- chatagent_signed_media.go
- clip_ability.go
- core_exec.go
- core_kv.go
- database.go
- error.go
- event.go
- file_meta_store.go
- func.go
- functions.go
- fx.go
- gateway_ability.go
- gateway_http.go
- globals.go
- homelab.go
- http.go
- hub.go
- init.go
- media.go
- message.go
- message_destinations.go
- message_direct.go
- metrics_auth.go
- module.go
- module_data_store.go
- notify.go
- notify_store.go
- oauth_token_store.go
- outbox_redeliver.go
- page_data.go
- pipeline.go
- platform.go
- providers.go
- readyz.go
- reexec.go
- registration.go
- router.go
- server.go
- webhook.go
- workflow.go
Directories
¶
| Path | Synopsis |
|---|---|
|
Package chatagent orchestrates the Flowbot chat assistant: session lifecycle, harness pooling, SSE streaming, tool confirmations, permissions, and scheduled tasks.
|
Package chatagent orchestrates the Flowbot chat assistant: session lifecycle, harness pooling, SSE streaming, tool confirmations, permissions, and scheduled tasks. |
|
tools/clip
Package clip provides agent tools for creating and reading shareable markdown clips.
|
Package clip provides agent tools for creating and reading shareable markdown clips. |
|
tools/gateway
Package gateway provides the chatagent tool that delegates to CapGateway (local CLI workers).
|
Package gateway provides the chatagent tool that delegates to CapGateway (local CLI workers). |
|
tools/notify
Package notify provides the chatagent tool for Gateway notification pushes.
|
Package notify provides the chatagent tool for Gateway notification pushes. |