gateway

package
v0.0.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 17, 2026 License: Apache-2.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type App

type App struct {
	// Providers lists the configured LLM providers.
	ProvidersRaw caddy.ModuleMap `json:"providers,omitempty" caddy:"namespace=llm.providers inline_key=provider_type"`
	// ConfigStore configures persistent admin/auth state storage.
	ConfigStoreRaw caddy.ModuleMap `json:"config_store,omitempty" caddy:"namespace=agent_gateway.config_store_backends"`
	// Routes lists statically configured gateway routes from the Caddyfile app block.
	Routes []routepkg.AgentRoute `json:"routes,omitempty"`
	// Models lists statically configured managed concrete models derived from the Caddyfile app block.
	Models []modelcatalog.ManagedModel `json:"models,omitempty"`
	// contains filtered or unexported fields
}

App is the Caddy app module for the Agent Gateway. It manages providers, MCP clients, memory stores, and configuration.

func GetApp

func GetApp(ctx caddy.Context) (*App, error)

GetApp retrieves the agent gateway app from the Caddy context.

func (*App) AgentGateway

func (a *App) AgentGateway() *runtimegateway.AgentGateway

AgentGateway returns the gateway instance owned by this app. It returns nil if called before Provision completes.

func (*App) CLIAuthManager

func (a *App) CLIAuthManager() *cliauth.Manager

CLIAuthManager returns the CLI authenticator manager shared across the gateway.

func (*App) CLIAuthRefresher

func (a *App) CLIAuthRefresher() *cliauth.AutoRefresher

CLIAuthRefresher returns the CLI credential refresher shared across the gateway.

func (App) CaddyModule

func (App) CaddyModule() caddy.ModuleInfo

CaddyModule returns the Caddy module information.

func (*App) ConfigStore

func (a *App) ConfigStore() configstore.ConfigStoreBackend

func (*App) CredentialManager

func (a *App) CredentialManager() *credentialmgr.Manager

CredentialManager returns the shared upstream credential manager.

func (*App) Provider

func (a *App) Provider(name string) (provider.Provider, bool)

Provider returns a configured provider by name.

func (*App) Provision

func (a *App) Provision(ctx caddy.Context) error

Provision sets up the app.

func (*App) Start

func (a *App) Start() error

Start starts the app.

func (*App) Stop

func (a *App) Stop() error

Stop stops the app.

func (*App) Validate

func (a *App) Validate() error

Validate validates the app configuration.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL