# Cosmic MCP for AI Agents AI Agent Connect

> Cosmic MCP gives your AI agent direct access to your headless CMS. You can list and create objects, audit schema types, handle media assets, and manage buckets through natural conversation. It replaces manual dashboard navigation with a conversational interface for your content workflows.

## Overview
- **Category:** developer-tools
- **Price:** Free
- **Endpoint:** https://edge.vinkius.com/vk_preview_8AgjmeIFMLOZAgK2CfQoBzmnSYL11jJUw3E3Nh4a/ai-agent-connect
- **Tags:** api-first, content-modeling, digital-assets, schema-management, json-api, web-development

## Description

Managing a headless CMS usually means jumping between browser tabs, hunting for the right bucket, and manually typing into fields. This Connector changes that by letting you handle your content through a chat interface. You can tell your agent to create new drafts, update existing metadata, or pull specific schema details without ever leaving your workspace. It works by connecting your Cosmic bucket to your AI client, turning complex content modeling into a simple conversation. If you're tired of the friction of manual data entry, you can find this Connector in the Vinkius catalog to give your agent a direct line to your backend. You can move through different content models, inspect your media assets, and even wipe out old data to keep your storage clean. It's built for people who want to treat their content like data, moving it around and auditing it as fast as they can think of the instructions. Instead of clicking through menus, you just describe the change you want to see and let the agent execute the updates across your digital content workflow.

## Tools

### get_schema_details
Extract the properties and rules for your active fields. Use this to understand exactly what data a content type requires.

### create_cms_object
Create new Cosmic drafts by providing a JSON payload. This helps you populate your CMS with structured data quickly.

### wipe_media_asset
Remove specific media files from your bucket. Use this to clean up storage and manage your asset library.

### wipe_cms_object
Irreversibly delete specific app nodes from your CMS. Use this to drop live document rows and clear database allocations.

### get_media_asset
Retrieve the structural data for a specific media ID. This helps you verify the exact details of your uploaded assets.

### get_single_object
Fetch the full payload for a specific object ID. This lets you see the complete metadata for any entry in your bucket.

### list_uploaded_media
View all uploaded media in your bucket. This helps you keep track of your picture limits and asset counts.

### list_schema_types
List all the structured rules and content types in your environment. Use this to see the full scope of your CMS model.

### list_bucket_objects
Identify all objects within your headless CMS environments. This helps you navigate different routing spaces easily.

### patch_cms_object
Update draft values for an existing object using its ID. This allows you to mutate global CRM boundaries without a full rewrite.

## Prompt Examples

**Prompt:** 
```
Can you check the schema for our 'products' type?
```

**Response:** 
```
I've pulled the schema for **products**. Here are the active fields:

| Field | Type | Description |
| :--- | :--- | :--- |
| name | Text | The display name of the product |
| price | Number | The retail price |
| description | HTML | The long-form product description |
| image | File | The primary product image |

Would you like me to check any specific validation rules for these fields?
```

**Prompt:** 
```
Create a new draft for a blog post called 'Summer Sale' in the 'posts' bucket.
```

**Response:** 
```
I've created a new draft for you. 

**Object Details:**
- **Type:** posts
- **Title:** Summer Sale
- **Status:** Draft

I've mapped the metadata and it's ready for review in your Cosmic bucket. Let me know if you'd like to add a description or more tags.
```

**Prompt:** 
```
List all the media assets we have uploaded.
```

**Response:** 
```
Here are the media assets currently in your bucket:

*   `hero_banner_01.jpg` (imgix endpoint: `https://imgix.cosmicjs.com/...`)
*   `product_shot_v2.png` (imgix endpoint: `https://imgix.cosmicjs.com/...`)
*   `footer_logo.svg` (imgix endpoint: `https://imgix.cosmicjs.com/...`)

I can provide more specific metadata for any of these if you need.
```

## Capabilities

### Create CMS drafts
Generate new content objects by providing a JSON payload for your agent to process.

### Update content metadata
Modify existing draft values and titles using specific object IDs.

### Audit content schemas
Retrieve the exact fields and structural rules for your active content types.

### Manage media assets
Inspect your uploaded images and resolve specific file metadata.

### Clear bucket storage
Irreversibly remove specific app nodes and media assets to manage your quota.

## Use Cases

### Bulk updating content titles
A content editor needs to update 50 blog posts. Instead of clicking 50 times, they ask the agent to use patch_cms_object to update the titles based on a provided list.

### Verifying schema for a new component
A developer is building a new product card. They ask the agent to use get_schema_details for 'products' to see exactly which fields are mandatory.

### Cleaning up old media assets
A product manager notices the storage is getting full. They ask the agent to list_uploaded_media and then use wipe_media_asset to remove files from a retired campaign.

### Rapidly prototyping content models
A growth lead wants to test a new 'events' content type. They ask the agent to list_schema_types to see current rules and then draft a new model via natural language.

## Benefits

- Update content without the UI. Use patch_cms_object to modify draft values and titles instantly without navigating to a web dashboard.
- Audit schemas instantly. Use get_schema_details to see exactly what fields and metadata rules are required for your content types.
- Clean up bucket storage. Use wipe_cms_object and wipe_media_asset to remove old nodes and images to keep your storage costs down.
- Manage media assets at scale. Use list_uploaded_media to inspect your entire library and resolve specific file metadata in one go.
- Prototype models with natural language. Use list_schema_types to see your current rules and then ask your agent to help you draft new ones.
- Faster data entry. Use create_cms_object to turn your JSON data into live Cosmic drafts with a single command.

## How It Works

The bottom line is you get a direct line from your chat interface to your headless CMS backend.

1. Subscribe to this Connector through the Vinkius platform.
2. Provide your Cosmic Bucket Slug and API Write Key from your account settings.
3. Start managing your content directly from Claude, Cursor, or your preferred AI client.

## Frequently Asked Questions

**Can the Cosmic MCP help me manage my headless CMS content?**
Yes, it allows you to create, list, and update content objects directly through your AI client. You can manage your drafts and metadata without having to navigate the web dashboard.

**How do I use the Cosmic MCP to update my content?**
You can simply tell your AI agent to update a specific piece of content. For example, asking it to change a title or patch a metadata value will trigger the update automatically.

**Can I use the Cosmic MCP to manage my images and media?**
Yes, it gives you the ability to list all uploaded media and see their specific details. You can also use it to remove old assets to save on storage space.

**Does the Cosmic MCP support schema auditing?**
It does. You can ask your agent to show you the requirements for any content type, and it will retrieve the exact fields and rules for you.

**Can I delete content using the Cosmic MCP?**
You can use it to remove specific app nodes or media assets. This is helpful for cleaning up your bucket and managing your storage quotas.

**Is the Cosmic MCP good for developers?**
It is excellent for developers who need to quickly verify schema details or fetch object payloads while they are working in their code editor.

**Can my agent create new content objects in Cosmic?**
Yes. Use the 'create_cms_object' tool. Provide the type slug, title, and a JSON object for metadata. The agent will command the backend to generate a new entry in your specified bucket.

**How do I audit the schema of an existing Object Type?**
Provide the type slug to the 'get_schema_details' tool. Your agent will analyze the specific localized variables and decode the native boundaries, showing you exactly which fields and metadata parameters the schema requires.

**Can I permanently delete media assets via the agent?**
Absolutely. The 'wipe_media_asset' tool allows you to irreversibly remove physical media from your Cosmic buckets. This is a powerful way to manage your storage quotas and cleanup dangling files directly from the chat.