* feat: support reading Brave API key from a file * chore: add secret file template and gitignore local keys * docs: document optional Docker Compose secrets workflow * fix: trim whitespace API keys and exclude secrets from Docker build * docs: clarify container paths for BRAVE_API_KEY_FILE * test: cover API key file config and expand Docker build context ignores * test: isolate getOptions tests from local env vars * docs: clarify optional use of BRAVE_API_KEY_FILE * docs: document BRAVE_API_KEY_FILE in AWS Marketplace catalog template
119 lines
10 KiB
JSON
119 lines
10 KiB
JSON
{
|
|
"Catalog": "AWSMarketplace",
|
|
"ChangeSet": [
|
|
{
|
|
"ChangeType": "AddDeliveryOptions",
|
|
"Entity": {
|
|
"Type": "ContainerProduct@1.0",
|
|
"Identifier": "prod-ixigokshzjrpw"
|
|
},
|
|
"DetailsDocument": {
|
|
"Version": {
|
|
"ReleaseNotes": "",
|
|
"VersionTitle": ""
|
|
},
|
|
"DeliveryOptions": [
|
|
{
|
|
"DeliveryOptionTitle": "Brave Search MCP Server",
|
|
"Details": {
|
|
"EcrDeliveryOptionDetails": {
|
|
"UsageInstructions": "The Brave Search MCP Server provides a powerful REST API proxy to access Brave Search capabilities through a standardized interface. This container allows you to integrate Brave's comprehensive search services into your AI applications, with features ranging from web search to image search and summarization.\n\n\n\n## Key Features\n- Brave LLM Context API delivers pre-extracted, relevance-scored web content optimized for grounding LLM responses in real-time search results.\n- Web search with comprehensive results and metadata\n- Local business and location search\n- Image and video search capabilities\n- News search for current events and trending stories\n- AI-optimized results with extra snippets\n- Content summarization across search results\n\n\n\n## Usage and limits\n- Cost: $5 CPM (cost per thousand) / $0.005 per request\n- Rate: Maximum of 50 requests per second\n- Volume: Unlimited requests\n\n\n\n## Getting started\n\n### Prerequisites\n1. **Brave Search API Key**: Create an AWS Marketplace Subscription for [Brave Search API](https://aws.amazon.com/marketplace/pp/prodview-qjlabherxghtq) \n2. **Container Configuration**: Configure your MCP Server with the required environment variables \n\n#### Container Configuration\n\n##### Environment Variables\n\nProvide the Brave Search API key using either `BRAVE_API_KEY` or `BRAVE_API_KEY_FILE`. When `BRAVE_API_KEY_FILE` is set, it must point to a path inside the container (for example a mounted secret at `/run/secrets/brave_api_key`) and takes precedence over `BRAVE_API_KEY`.\n\n```json\n\"environmentVariables\": { \"BRAVE_API_KEY\": \"<YOUR_BRAVE_API_KEY>\", \"BRAVE_MCP_TRANSPORT\": \"http\", \"BRAVE_MCP_STATELESS\": \"true\", \"BRAVE_MCP_PORT\": \"8000\", \"BRAVE_MCP_HOST\": \"0.0.0.0\" }\n```\n\nExample using a mounted secret file instead of an inline API key:\n\n```json\n\"environmentVariables\": { \"BRAVE_API_KEY_FILE\": \"/run/secrets/brave_api_key\", \"BRAVE_MCP_TRANSPORT\": \"http\", \"BRAVE_MCP_STATELESS\": \"true\", \"BRAVE_MCP_PORT\": \"8000\", \"BRAVE_MCP_HOST\": \"0.0.0.0\" }\n```\n\n##### Network Configuration \n```json\n\"networkConfiguration\": { \"networkMode\": \"PUBLIC\" }\n```\n\n##### Protocol Configuration\n```json\n\"protocolConfiguration\": { \"serverProtocol\": \"MCP\" }\n```\n\n\n\n## Example\n\n### [`brave_web_search`](https://api.search.brave.com/res/v1/web/search)\n\nPerforms general web searches with rich metadata. Best for general information queries, research, and finding diverse content types.\n\n#### Example\n\n```json\n{\n \"query\": \"climate change solutions\",\n \"count\": 10,\n \"extra_snippets\": true\n}\n```\n\n\n\n\nReference documentation for additional endpoints:\n\n- [`brave_local_search`](https://api-dashboard.search.brave.com/documentation/services/place-search)\n- [`brave_image_search`](https://api-dashboard.search.brave.com/documentation/services/image-search)\n- [`brave_video_search`](https://api-dashboard.search.brave.com/documentation/services/video-search)\n- [`brave_news_search`](https://api-dashboard.search.brave.com/documentation/services/news-search)\n- [`brave_summarizer`](https://api-dashboard.search.brave.com/documentation/services/summarizer)\n\n\n\n## Best Practices\n1. Use specific queries to get more relevant results\n2. Leverage `extra_snippets` for AI applications that need more context\n3. Use appropriate `result_filter` values to focus on specific content types\n4. Consider `safesearch` settings based on your application's audience\n5. Utilize the summarizer for efficient information extraction\n\n## Support\nFor detailed API documentation, visit the [Brave Search API Documentation](https://api-dashboard.search.brave.com/app/documentation/web-search/get-started). For all general inquiries and support, please contact us at searchapi-support@brave.com.",
|
|
"AgenticType": [
|
|
"MCP_SERVER"
|
|
],
|
|
"CompatibleServices": [
|
|
"Bedrock-AgentCore"
|
|
],
|
|
"Description": "",
|
|
"DeploymentResources": [
|
|
{
|
|
"Url": "https://brave-marketplace-artifacts-prod.s3.us-west-2.amazonaws.com/brave-search-mcp-server/MCP_Server_Usage_Instructions_md.md",
|
|
"Name": "Brave Search MCP Usage Instructions"
|
|
}
|
|
],
|
|
"ContainerImages": "",
|
|
"EnvironmentVariables": [
|
|
{
|
|
"Name": "BRAVE_API_KEY",
|
|
"Description": "*Required unless BRAVE_API_KEY_FILE is set* Brave Search API Key. Obtain Brave Search API Key through AWS Marketplace Product (https://aws.amazon.com/marketplace/pp/prodview-qjlabherxghtq)"
|
|
},
|
|
{
|
|
"Name": "BRAVE_API_KEY_FILE",
|
|
"Description": "*Optional* Path inside the container to a file containing the Brave Search API Key. When set, takes precedence over BRAVE_API_KEY. Use with mounted secrets (for example ECS task secrets or Kubernetes secret volumes)."
|
|
},
|
|
{
|
|
"DefaultValue": "http",
|
|
"Name": "BRAVE_MCP_TRANSPORT",
|
|
"Description": "MCP protocol transport mode. Supported values are \"http\" or \"stdio\", however Bedrock Agentcore only supports \"http\" (reference https://docs.aws.amazon.com/marketplace/latest/userguide/bedrock-agentcore-runtime.html#agentcore-container-requirements)."
|
|
},
|
|
{
|
|
"DefaultValue": "8000",
|
|
"Name": "BRAVE_MCP_PORT",
|
|
"Description": "HTTP server port (default: 8000). Mandatory port for Bedrock Agentcore is 8000 (reference https://docs.aws.amazon.com/marketplace/latest/userguide/bedrock-agentcore-runtime.html#agentcore-container-requirements)."
|
|
},
|
|
{
|
|
"DefaultValue": "0.0.0.0",
|
|
"Name": "BRAVE_MCP_HOST",
|
|
"Description": "HTTP server host (default: 0.0.0.0). Mandatory host value is 0.0.0.0 for Bedrock Agentcore (reference https://docs.aws.amazon.com/marketplace/latest/userguide/bedrock-agentcore-runtime.html#agentcore-container-requirements)."
|
|
},
|
|
{
|
|
"DefaultValue": "info",
|
|
"Name": "BRAVE_MCP_LOG_LEVEL",
|
|
"Description": "MCP supported logging level (reference https://modelcontextprotocol.io/specification/2025-03-26/server/utilities/logging#log-levels)"
|
|
},
|
|
{
|
|
"Name": "BRAVE_MCP_ENABLED_TOOLS",
|
|
"Description": "*Optional* When used, specifies a whitelist for supported tools"
|
|
},
|
|
{
|
|
"Name": "BRAVE_MCP_DISABLED_TOOLS",
|
|
"Description": "*Optional* When used, specifies a blacklist for supported tools"
|
|
},
|
|
{
|
|
"DefaultValue": "true",
|
|
"Name": "BRAVE_MCP_STATELESS",
|
|
"Description": "Sets HTTP Stateless mode (default: true). When deploying on Bedrock Agentcore, this should be set to true."
|
|
}
|
|
]
|
|
}
|
|
}
|
|
},
|
|
{
|
|
"DeliveryOptionTitle": "Docker Image",
|
|
"Details": {
|
|
"EcrDeliveryOptionDetails": {
|
|
"UsageInstructions": "",
|
|
"CompatibleServices": [
|
|
"ECS",
|
|
"ECS-Anywhere",
|
|
"EKS",
|
|
"EKS-Anywhere"
|
|
],
|
|
"Description": "",
|
|
"DeploymentResources": [],
|
|
"ContainerImages": ""
|
|
}
|
|
}
|
|
}
|
|
]
|
|
}
|
|
}
|
|
],
|
|
"ChangeSetName": "",
|
|
"ClientRequestToken": "",
|
|
"ChangeSetTags": [
|
|
{
|
|
"Key": "Release",
|
|
"Value": ""
|
|
},
|
|
{
|
|
"Key": "CostEntity",
|
|
"Value": "SEZC"
|
|
},
|
|
{
|
|
"Key": "IPGroup",
|
|
"Value": "KY BAT Ledger Service"
|
|
}
|
|
]
|
|
}
|