sample-agents-with-nova-act-and
Discover how to build agents that can perform actions on websites by combining Amazon Nova Act with Model Context Protocol (MCP).
claude mcp add --transport stdio aws-samples-sample-agents-with-nova-act-and-mcp python mcp_examples/nova_act_mcp_server.py \ --env AWS_REGION="your_aws_region" \ --env NOVA_ACT_API_KEY="your_nova_act_api_key" \ --env AWS_ACCESS_KEY_ID="your_aws_access_key_id" \ --env AWS_SECRET_ACCESS_KEY="your_aws_secret_access_key"
How to use
This MCP server exposes Nova Act capabilities through MCP so an MCP host (like Claude Desktop or another MCP client) can remotely control web automation tasks via Nova Act. The server implements a bridge that translates MCP requests into Nova Act actions such as starting browser automation, navigating web pages, performing searches, extracting data, taking screenshots, and managing browser sessions. Use cases include building intelligent agents that can browse, extract product details, compare options, fill forms, and verify results across multiple web pages. Clients connect 1:1 with this server to invoke Nova Act features and return structured results to the LLM.
To use it, start the server using the configured command in the MCP configuration. Ensure NOVA_ACT_API_KEY is set (and AWS credentials if Bedrock access is required for your workflow). From the MCP host, invoke actions like launching a browser, performing a search, selecting results, extracting data, and retrieving screenshots or session metadata. The integration supports parallel tasks and structured data responses, enabling complex agent workflows with Bayes-like decision making driven by the LLM and Nova Act automation.
How to install
Prerequisites
- Python 3.8+ (the repository examples mention Python-based MCP server and Nova Act integration)
- Nova Act account and API key
- Optional: AWS credentials and Bedrock access if your workflow relies on Bedrock models
Installation steps
-
Clone the repository git clone https://github.com/aws-samples/sample-agents-with-nova-act-and-mcp.git cd sample-agents-with-nova-act-and-mcp
-
Create a Python virtual environment and install dependencies python -m venv venv source venv/bin/activate # on macOS/Linux
Windows: venv\Scripts\activate
pip install -r requirements.txt
-
Configure environment variables
Set your Nova Act API key and AWS credentials as needed
export NOVA_ACT_API_KEY="your_api_key" export AWS_ACCESS_KEY_ID="your_aws_access_key_id" export AWS_SECRET_ACCESS_KEY="your_aws_secret_access_key" export AWS_REGION="your_aws_region"
-
Run the MCP server (as defined in the mcp_config) python mcp_examples/nova_act_mcp_server.py
-
Run the MCP client (example shows how to connect to the server) python mcp_examples/nova_act_mcp_client.py nova_act_mcp_server.py
Additional notes
Tips and considerations:
- Ensure NOVA_ACT_API_KEY is kept secure and not committed to version control.
- For Bedrock-enabled workflows, ensure AWS credentials and region are properly configured.
- Use the MCP client to test 1:1 connections with the server before deploying in production.
- When automating long-running tasks, enable headless mode for faster executions and easier logging.
- Structure responses with schemas to improve parsing by the LLM and downstream tools.
- Regularly close browser sessions after tasks complete to free resources and avoid leaks.
Related MCP Servers
lihil
2X faster ASGI web framework for python, offering high-level development, low-level performance.
ReActMCP
ReActMCP is a reactive MCP client that empowers AI assistants to instantly respond with real-time, Markdown-formatted web search insights powered by the Exa API.
jmeter
✨ JMeter Meets AI Workflows: Introducing the JMeter MCP Server! 🤯
example
A ready-to-use MCP (Model Context Protocol) server template for extending Cursor IDE with custom tools. Deploy your own server to Heroku with one click, create custom commands, and enhance your Cursor IDE experience. Perfect for developers who want to add their own tools and commands to Cursor IDE without complex setup.
pfsense
pfSense MCP Server enables security administrators to manage their pfSense firewalls using natural language through AI assistants like Claude Desktop. Simply ask "Show me blocked IPs" or "Run a PCI compliance check" instead of navigating complex interfaces. Supports REST/XML-RPC/SSH connections, and includes built-in complian
cloudwatch-logs
MCP server from serkanh/cloudwatch-logs-mcp