Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
var DefaultCommand = []string{"uvx", "awslabs.aws-api-mcp-server@latest"}
DefaultCommand is the command used to launch an upstream AWS API MCP server when the config does not override it. See https://github.com/awslabs/mcp/tree/main/src/aws-api-mcp-server
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
// Command launches the upstream AWS API MCP server. Defaults to DefaultCommand.
Command []string `yaml:"command,omitempty"`
Profiles []*ProfileConfig `yaml:"profiles"`
}
Config is the awsapimcproxy configuration file.
func LoadConfig ¶
LoadConfig reads and validates the config file at path.
The file content is passed through os.ExpandEnv so that values can be referenced as ${ENV_VAR} instead of being written literally.
func (*Config) Profile ¶
func (config *Config) Profile(name string) *ProfileConfig
Profile returns the config for the named profile, or nil if it is not configured.
func (*Config) ProfileNames ¶
ProfileNames returns the configured profile names in file order.
type Options ¶
type Options struct {
Config string `kong:"required,short='c',env='AWSAPIMCPROXY_CONFIG',help='Config file path.'"`
}
Options holds the command-line options.
type ProfileConfig ¶
type ProfileConfig struct {
Name string `yaml:"name"`
AWSProfile string `yaml:"aws_profile,omitempty"`
Region string `yaml:"region,omitempty"`
Env map[string]string `yaml:"env,omitempty"`
}
ProfileConfig selects the AWS identity for one upstream AWS API MCP server.
Each profile launches its own upstream process. AWSProfile is passed as AWS_API_MCP_PROFILE_NAME and Region as AWS_REGION; Env adds or overrides any other environment variables for that process.
type Proxy ¶
type Proxy struct {
// contains filtered or unexported fields
}
Proxy is a multi-profile MCP proxy in front of the AWS API MCP server.
It launches one upstream AWS API MCP server process per AWS profile, exposes the upstream tools over stdio, and injects a required "profile" argument into each tool. On a tool call the profile selects the matching upstream process, and the call is forwarded to it.