# Builder.io MCP for AI Agents MCP

> Builder.io gives your AI agents full control over your visual CMS and headless content. You fetch entries, update model data, execute complex GraphQL queries, and manage assets—all from a single conversation with your favorite AI client.

## Overview
- **Category:** developer-tools
- **Price:** Free
- **Tags:** visual-cms, graphql, content-api, asset-management, digital-experience

## Description

Managing a modern digital experience means coordinating content across multiple systems. Instead of jumping between the Builder dashboard and separate API tools, this MCP connects your entire visual CMS directly to your agent. You can use natural language instructions to interact with your headless content models. Need to check if a specific landing page has been updated? Your agent runs a query against the Content API. Want to push out five new blog posts? You tell your agent to create or update those records programmatically, bypassing the manual UI steps entirely. This integration lets you treat your entire CMS—from core content models to media assets—like another function within your workflow. Connecting through Vinkius means all your existing AI clients get immediate access to this full suite of content tools.

## Tools

### admin_graphql
Requires a private key. Executes any administrative GraphQL query or mutation against the CMS.

### create_content
Requires a private key. Builds and publishes an entirely new content entry into a model.

### delete_asset_by_url
Removes media assets from your digital library using only the asset's URL.

### delete_content
Requires a private key. Completely removes an existing content entry or model record.

### get_content
Retrieves specific data entries from any defined Builder.io content model.

### get_html
Generates and returns the final, ready-to-use HTML markup for a given component or model.

### query_graphql
Runs flexible GraphQL queries to pull specific data points from your content structure.

### update_content
Requires a private key. Modifies the existing fields and data of an already published content entry.

### upload_asset
Requires a private key. Uploads new media files, such as images or videos, to your asset library.

## Prompt Examples

**Prompt:** 
```
What are the latest 3 articles published in the 'finance' model? Can you give me their IDs and author names?
```

**Response:** 
```
**Latest Articles Found**

| ID | Title | Author |
| :--- | :--- | :--- |
| abc-123 | Q4 Earnings Report Analysis | Jane Doe |
| def-456 | Crypto Market Prediction for 2024 | John Smith |
| ghi-789 | Best Practices in Tax Writeoffs | Sarah Lee |

I pulled this data using the Content API. Let me know if you want the full text body for any of these.
```

**Prompt:** 
```
I need to update a component on the homepage. The image URL is broken, and I also want to change the main headline.
```

**Response:** 
```
**✅ Updates Complete**

1.  **Image Updated:** Successfully uploaded the new hero shot (URL: `cdn.builder.io/image/...`).
2.  **Content Patch:** The 'Homepage Header' entry was updated with the text: 'New Service Launching Next Month!'

The change is live in your Builder space.
```

**Prompt:** 
```
Run a query to find all content models that reference assets from the old marketing folder.
```

**Response:** 
```
**Query Results:**

I found 14 entries referencing assets tagged 'old_marketing'. Three of these are in the 'Case Study' model, and eleven are in the 'About Us' section. Would you like me to list the specific asset IDs or delete those references?
```

## Capabilities

### Read specific content entries
Your agent retrieves data for any specified model, allowing you to see current drafts or published versions.

### Get pre-rendered HTML output
It fetches the final, usable HTML code for components, letting you inspect how content will look before deployment.

### Create and modify content records
You instruct your agent to write new content entries or update existing models with a simple command.

### Execute advanced graph queries
The agent runs complex GraphQL operations against the full Content API, handling detailed data structures and admin tasks.

### Manage digital assets
You can tell your agent to upload new images or videos, or delete old ones by their URL.

## Use Cases

### Auditing a global campaign's landing pages
A marketing manager needs to check if the 'Sale Ends Soon' banner is live on 20 different regional pages. Instead of opening 20 tabs, they prompt their agent: 'Check the rendered HTML for all content entries in the 'banner' model and confirm the current sale date.' The agent uses `get_html` and reports back instantly.

### Debugging a multi-model data dependency
A developer finds that blog posts aren't linking to the correct author profile. They ask their agent to run a complex GraphQL query via `query_graphql` across both 'article' and 'author' models, immediately pinpointing the broken relationship in the database structure.

### Responding to urgent content changes
A PR crisis requires changing a temporary notice site-wide. The operations team instructs their agent: 'Update all entries in the 'announcement' model with ID X and Y to read 'New messaging.''. This uses `update_content` for immediate, controlled deployment.

### Onboarding a new content contributor
A copywriter needs to test how their text looks across three different component types. They use the agent to call `get_html` on sample components, receiving instant, verifiable HTML output for quick sign-off.

## Benefits

- Stop switching between tools. You keep all your content operations—querying, updating, uploading assets—inside the chat window.
- Verify complex component layouts instantly. Use the `get_html` function to pull pre-rendered HTML for SEO checks or client review.
- Automate data migrations and bulk writes. Need to change a field across 50 models? Your agent handles it with one prompt, using tools like `update_content`.
- Full GraphQL access means no guesswork. You execute precise queries via `query_graphql`, going deeper than the basic content fetching functions.
- Maintain clean digital assets by giving your agent permission to both upload new media (`upload_asset`) and delete obsolete files (`delete_asset_by_url`).

## How It Works

The bottom line is that you manage content directly through conversation, without ever leaving your AI chat interface.

1. Subscribe to this MCP and provide your Builder.io Public Key (and Private Key if you need write access).
2. Your agent connects using the provided keys, establishing a direct pipeline between your AI client and your CMS.
3. You simply ask your agent natural language questions—for example, 'Give me the latest five blog posts'—and it executes the necessary API calls.

## Frequently Asked Questions

**How can I use Builder.io with my AI agents using the Builder.io MCP?**
You connect your preferred AI client and give it permission to access your CMS data. This lets you manage content, read entries, and execute complex queries directly through natural conversation.

**Do I need to know GraphQL to use the Builder.io MCP?**
No, you don't. While the tool uses GraphQL internally for advanced querying (`query_graphql`), you just ask your agent in plain English what data you need.

**Can this MCP help me with SEO checks on my content?**
Yes. You can use the MCP to retrieve pre-rendered HTML markup for specific components, which is essential for manually checking how search engines will view your finished page.

**What if I need to make bulk changes across multiple pages in Builder.io?**
You can instruct the agent to run batch operations using tools like `update_content`. This lets you change a global element, such as a footer disclaimer, on dozens of models at once.

**Is this MCP only for content, or can I manage media files too?**
It handles both. You can upload new images and videos using `upload_asset` and even delete old assets by their URL to keep your digital library clean.

**Can my AI agent connect this MCP to other tools I use?**
Yes, because it's hosted on Vinkius, your agent gains access to the entire catalog. This means you can link content data from Builder.io with inputs from other specialized services.