Tools: MCP & Browser

Extend the agent's capabilities with MCP servers and the Browser subagent

MCP: Model Context Protocol

MCP (Model Context Protocol) is a standard that connects the AI agent with external tools and data sources. Think of it as β€œplugins” for the agent.

What MCP Enables

Without MCP, the agent can only read files and run commands. With MCP, it can:

  • Query databases directly (Supabase, PostgreSQL)
  • Deploy functions to cloud platforms
  • Search documentation in real-time
  • Manage infrastructure (create projects, configure services)
  • Access APIs (GitHub, Jira, Slack)

Configuring MCP Servers

MCP servers are configured in your project settings. Each server provides specific tools:

{
  "mcp": {
    "servers": {
      "supabase": {
        "command": "npx",
        "args": ["supabase-mcp-server"]
      },
      "context7": {
        "command": "npx",
        "args": ["@context7/mcp-server"]
      }
    }
  }
}

Real Example: Supabase MCP

With the Supabase MCP server, you can say:

You: "Create a users table with email, name, and avatar columns"

Agent uses MCP to:
1. apply_migration β†’ Creates the table
2. execute_sql β†’ Verifies it exists
3. generate_typescript_types β†’ Updates TypeScript types
4. get_advisors β†’ Checks for security issues (RLS)

No switching between your code and the Supabase dashboard. Everything happens in one conversation.

Real Example: Context7 MCP

Context7 provides up-to-date documentation for any library:

You: "How do I set up authentication in Next.js 16?"

Agent uses Context7 to:
1. resolve-library-id β†’ Finds Next.js docs
2. query-docs β†’ Gets latest auth patterns
3. Responds with current, accurate information

This solves the β€œstale training data” problem β€” the agent always gets fresh docs.

Browser Subagent

The Browser subagent gives the AI the ability to interact with web pages β€” clicking, typing, scrolling, and taking screenshots.

What It Can Do

  • Navigate to URLs and read page content
  • Click buttons and links
  • Type into forms and search fields
  • Take screenshots for visual verification
  • Record browser sessions as video

When to Use Browser vs URL Reading

ScenarioTool
Read static docsread_url_content (faster)
Interact with web appsBrowser subagent
Fill forms, click buttonsBrowser subagent
Take screenshots for proofBrowser subagent
Test your deployed appBrowser subagent

Real Example: Visual Testing

You: "Check if the login page looks correct on mobile"

Agent:
1. Opens browser to your dev server
2. Resizes window to mobile dimensions
3. Takes a screenshot
4. Analyzes the layout
5. Reports any visual issues

Chrome Extension

Antigravity includes a Chrome Extension for browsing:

  • Allowlist/Denylist β€” Control which sites the agent can access
  • Separate Chrome Profile β€” Isolate agent browsing from your personal browsing
  • Session management β€” The agent can use authenticated sessions

Combining MCP + Browser

The real power emerges when you combine tools:

You: "Set up a Supabase project and deploy my app"

Agent combines:
β”œβ”€β”€ Supabase MCP
β”‚   β”œβ”€β”€ Create project
β”‚   β”œβ”€β”€ Set up database schema
β”‚   β”œβ”€β”€ Configure RLS policies
β”‚   └── Get API keys
β”œβ”€β”€ Terminal
β”‚   β”œβ”€β”€ Install dependencies
β”‚   β”œβ”€β”€ Build the app
β”‚   └── Deploy to Cloudflare
└── Browser
    β”œβ”€β”€ Navigate to deployed URL
    β”œβ”€β”€ Test the login flow
    └── Screenshot the result

One conversation. Multiple tools. Complete workflow.

Best Practices

  1. Start with minimal MCP β€” Add servers as you need them
  2. Use allowlists β€” Limit browser access to necessary sites
  3. Combine tools β€” The agent shines when tools work together
  4. Verify outputs β€” Always review MCP mutations (DB changes, deployments)
  5. Document your MCP setup β€” Include in project README for team members

What’s Next

Now let’s explore Artifacts β€” the documents the agent creates to communicate its work, preserve knowledge, and provide proof of what it did.