Documentation
¶
Index ¶
- Constants
- func CollectEnvKeys(v any, out map[string]struct{})
- func DecryptSecretsFile(data []byte, key []byte) (map[string]string, error)
- func EncryptSecretsFile(entries map[string]string, key []byte) ([]byte, error)
- func EnvKey(ref string) string
- func ManifestFromAPIIndex(data []byte) (map[string]map[string]struct{}, error)
- func ManifestFromMCPFile(data []byte) (map[string]map[string]struct{}, error)
- func MergeEncryptedSecretsFile(existing []byte, key []byte, updates map[string]string) ([]byte, error)
- func MergeManifests(parts ...map[string]map[string]struct{}) map[string]map[string]struct{}
- func ParseSecretsMasterKey(raw string) ([]byte, error)
- func ScopedStorageKey(scope, storageKey string) string
- func SecretFromContext(ctx context.Context, ref string) (capscredentials.Secret, bool)
- func ValidateIntegrationScope(scope string) error
- func WithSecrets(ctx context.Context, secrets map[string]string) context.Context
Constants ¶
const SecretsMasterKeyEnv = "AGENTKIT_SECRETS_KEY"
SecretsMasterKeyEnv is the environment / credentials.config.env key for the AES-256 key used to encrypt secrets.enc.json. It is not subject to Prefix.
Variables ¶
This section is empty.
Functions ¶
func CollectEnvKeys ¶ added in v0.3.11
CollectEnvKeys walks JSON-decoded values and records env: variable names.
func DecryptSecretsFile ¶ added in v0.3.4
DecryptSecretsFile parses and decrypts all entries in data.
func EncryptSecretsFile ¶ added in v0.3.4
EncryptSecretsFile serializes entries to encrypted JSON.
func ManifestFromAPIIndex ¶ added in v0.3.11
ManifestFromAPIIndex maps each apis key (scope) to allowed env keys.
func ManifestFromMCPFile ¶ added in v0.3.11
ManifestFromMCPFile maps each mcpServers key to allowed env keys under scope mcp.<name>.
func MergeEncryptedSecretsFile ¶ added in v0.3.4
func MergeEncryptedSecretsFile(existing []byte, key []byte, updates map[string]string) ([]byte, error)
MergeEncryptedSecretsFile decrypts existing (if any), applies updates, and re-encrypts.
func MergeManifests ¶ added in v0.3.11
MergeManifests unions scope maps; later maps overwrite key sets for the same scope.
func ParseSecretsMasterKey ¶ added in v0.3.4
ParseSecretsMasterKey derives a 32-byte AES key via SHA-256(passphrase).
func ScopedStorageKey ¶ added in v0.3.12
ScopedStorageKey names an integration secret entry in secrets.enc.json or dotenv.
func SecretFromContext ¶
SecretFromContext returns a secret when ctx carries an override for ref.
func ValidateIntegrationScope ¶ added in v0.3.12
ValidateIntegrationScope reports whether scope is a non-empty mcp.* or openapi.* credential scope.
Types ¶
This section is empty.