Documentation
¶
Index ¶
- Constants
- func IsReservedCommandEnvironmentKey(key string) bool
- func IsReservedPluginEnvironmentKey(key string) bool
- func IsReservedSkillEnvironmentKey(key string) bool
- func PluginDataDir(cfg Config, pluginName string) (string, error)
- func PluginSkillDataDir(cfg Config, pluginName, skill string) (string, error)
- func PluginSkillDataRoot(cfg Config, pluginName string) (string, error)
- func SkillDataDir(cfg Config, skill string) (string, error)
- func SkillDir(cfg Config) string
- func ValidateOAuthAccessTokenTTL(value string) error
- type ACPProfile
- type Config
Constants ¶
const ( ProtocolVersion = "2026-08-11" ServerName = "agentdock" PathModel = "host" RecallTimeoutMS = 30000 )
const ( SkillDataDirEnvKey = "SKILL_DATA_DIR" PluginDataDirEnvKey = "PLUGIN_DATA_DIR" )
Variables ¶
This section is empty.
Functions ¶
func IsReservedCommandEnvironmentKey ¶ added in v0.9.0
IsReservedCommandEnvironmentKey covers every runtime-owned command variable.
func IsReservedPluginEnvironmentKey ¶ added in v0.9.0
IsReservedPluginEnvironmentKey reports whether a variable is owned by the Plugin runtime and cannot be supplied through user environment config.
func IsReservedSkillEnvironmentKey ¶ added in v0.9.0
IsReservedSkillEnvironmentKey reports whether a variable is owned by the AgentDock Skill runtime and cannot be supplied through user environment config.
func PluginDataDir ¶ added in v0.9.0
PluginDataDir returns the private persistent-data directory assigned to one installed Plugin. The path is version-independent so updates preserve data.
func PluginSkillDataDir ¶ added in v0.9.0
PluginSkillDataDir returns the private persistent-data directory assigned to one Skill inside a Plugin. It is independent from the shared Plugin data root.
func PluginSkillDataRoot ¶ added in v0.9.0
PluginSkillDataRoot returns the version-independent data namespace for all Skills owned by one Plugin. The hidden .plugin segment cannot collide with a valid standalone Skill name.
func SkillDataDir ¶ added in v0.9.0
SkillDataDir returns the private persistent-data directory assigned to one managed Skill. It validates the Skill identity itself so callers cannot turn a data-directory lookup into an arbitrary path join.
func SkillDir ¶ added in v0.9.0
SkillDir returns the managed Skill root. Each child directory is the current installed content for one standalone managed Skill.
func ValidateOAuthAccessTokenTTL ¶ added in v0.7.7
ValidateOAuthAccessTokenTTL validates an explicit access-token lifetime using the same syntax and bounds as AGENTDOCK_OAUTH_ACCESS_TOKEN_TTL.
Types ¶
type ACPProfile ¶ added in v0.9.0
type ACPProfile struct {
ID string `json:"id"`
DisplayName string `json:"display_name,omitempty"`
Kind string `json:"kind"`
Command string `json:"command"`
Args []string `json:"args,omitempty"`
EnvFromEnv map[string]string `json:"env_from_env,omitempty"`
Enabled bool `json:"enabled"`
}
ACPProfile 表示一个可独立运行、独立持久化会话的 ACP 实例。 内置类型使用固定 ID(codex/claude/grok)保持单实例;custom 使用自定义 ID 支持多个实例。
type Config ¶
type Config struct {
AgentDockHome string
AgentDockDefaultDir string
CommandEnvFromEnv map[string]string
Host string
Port int
AuthToken string
OAuthEnabled bool
OAuthServerURL string
OAuthAccessTokenTTLSeconds int64
OAuthAccessTokenNeverExpires bool
LogLevel string
NexusEndpoint string
NexusDeviceToken string
MCPAppsEnabled bool
BrowserEnabled bool
BrowserExecutablePath string
BrowserCDPURL string
BrowserReuseExistingCDP bool
ACPEnabled bool
ACPProfiles []ACPProfile
ACPDefaultProfile string
ACPMaxPrompts int
ACPInteractionMS int
Stdio bool
TrustedProxyCIDRs []string
}
func (Config) AuthRequired ¶
func (Config) EffectiveACPDefaultProfile ¶ added in v0.9.0
func (Config) EffectiveACPProfiles ¶ added in v0.9.0
func (c Config) EffectiveACPProfiles() []ACPProfile
EffectiveACPProfiles 返回 Runtime 实际需要启动的 ACP profile。