# Cometly MCP MCP

> Cometly connects your AI agent directly to ad attribution data from Meta, Google, TikTok, and more. It lets you track purchases, leads, and custom events instantly. You can pull campaign stats, see which ads drive the best conversions, and list all connected ad accounts—all without logging into a dashboard.

## Overview
- **Category:** marketing-automation
- **Price:** Free
- **Tags:** ad-attribution, roas, conversion-tracking, marketing-analytics, campaign-management, cpa-tracking

## Description

Cometly is your direct line to performance marketing data across major ad platforms. Instead of manually pulling reports from multiple dashboards, your AI agent handles the heavy lifting. You can ask it to check campaign stats for ROAS or find out which specific ads are driving high-value conversions. The system tracks everything—from initial clicks to final purchases and leads—and provides a unified view of performance metrics. Need to track an event? Just tell your agent, and it sends the conversion data right into Cometly. It’s like having all your ad platform reports compiled and searchable within your AI client. Because this MCP sits on Vinkius, you can access this powerful attribution layer alongside hundreds of other tools, making your entire marketing stack accessible from one place.

## Tools

### get_campaign_stats
Retrieves the total spend, conversions, and ROAS for a specific advertising campaign.

### list_ad_accounts
Provides an inventory of all connected ad accounts from platforms like Meta and Google.

### list_campaigns
Gathers a comprehensive list of every active ad campaign you are currently tracking.

### list_contacts
Shows a history of contacts, detailing their entire customer journey and attributed touchpoints.

### list_events
Retrieves a complete list of every custom or standard event recorded in Cometly.

### track_event
Sends a general conversion event (like 'viewed product') to Cometly for attribution tracking.

### track_lead
Quickly records a new lead event, attributing it back to the source ad campaign.

### track_purchase
Records a completed purchase event, including revenue and order details, for attribution.

## Prompt Examples

**Prompt:** 
```
Track a purchase of $99.90 for 'customer@example.com' with order 'ORD-123'.
```

**Response:** 
```
Purchase tracked! Order: ORD-123, $99.90. Attributed to Facebook Ad 'Summer Sale' (camp-4x2k). Syncing to Meta and Google in ~15 min.
```

**Prompt:** 
```
Get performance stats for campaign 'camp-xxxx' over the last 30 days.
```

**Response:** 
```
Campaign 'camp-xxxx' (30 days): Spend $4,200 | 186 conversions | Revenue $18,540 | ROAS 4.41x | CPA $22.58. Top ad set: 'Lookalike US' (62%).
```

**Prompt:** 
```
List the top 3 best performing active campaigns by ROAS.
```

**Response:** 
```
Top 3 Active Campaigns by ROAS:
1. 'Retargeting Q3' (Google) - ROAS: 6.2x
2. 'Lookalike 1%' (Meta) - ROAS: 4.8x
3. 'Brand Search' (Google) - ROAS: 4.5x
```

## Capabilities

### Track Conversion Events
Send specific events like Purchases or Leads to Cometly for accurate performance tracking.

### Analyze Campaign Performance
Get detailed stats, including ROAS and CPA, for any ad campaign you list.

### List Ad Accounts
Retrieve a current inventory of all connected advertising accounts across different platforms.

### View Attributed Contacts
Get lists of contacts and their entire customer journey, showing where they came from.

### Monitor Event History
Check a log of all tracked events to understand the breadth of your data capture.

## Use Cases

### Need to audit a campaign's performance?
The marketing lead asks, 'What was the ROAS for our Q3 Retargeting ads?' The agent runs `get_campaign_stats` against 'Retargeting Q3', returning immediate numbers that show exactly where budget needs moving.

### A sales rep just got a great lead from chat.
The rep tells the agent, 'We just spoke to John Doe.' The agent uses `track_lead` with John's info. This logs him immediately and links his initial touchpoint back to the ad source.

### An e-commerce manager needs to verify tracking.
The manager asks, 'Did our last order get logged?' The agent calls `track_purchase` with the order details. This confirms attribution and updates all performance metrics simultaneously.

### Need a quick overview of active campaigns?
The team lead types, 'List all active ad campaigns.' The agent runs `list_campaigns`, giving them an immediate checklist to ensure nothing is being missed or overlooked.

## Benefits

- Stop digging through dashboards. You can ask your agent to run `get_campaign_stats` and get ROAS and CPA metrics instantly for any campaign.
- Don't lose track of leads. Use `track_lead` or `list_contacts` to immediately log a new prospect and see their full journey history.
- Keep your data current. Calling `list_ad_accounts` gives you an immediate inventory check of every connected ad platform, confirming setup status.
- Capture revenue instantly. Instead of manual reporting, just use `track_purchase` to send order details right when they happen.
- See the full picture. Running `list_campaigns` lets your agent know exactly what campaigns exist so you can analyze them all at once.

## How It Works

The bottom line is that you talk to your agent naturally, and Cometly handles all the API calls behind the scenes.

1. Add the Cometly integration to your AI toolset and supply your API Key in the account settings.
2. Ask your agent to perform a task, like 'Show me ROAS for Q3 campaigns' or 'Track a new purchase of $150'.
3. The MCP executes the request by calling the relevant underlying tools and returns clean, actionable data directly into your chat window.

## Frequently Asked Questions

**How do I get performance stats for a campaign using get_campaign_stats?**
You tell your agent which campaign you want statistics for. It pulls data like ROAS and CPA, showing you exactly how that specific ad unit performed over the time period you specify.

**Is `list_ad_accounts` necessary before running any report?**
Yes. Running `list_ad_accounts` first confirms to your agent which platforms (Meta, Google, etc.) are connected and available for data retrieval, preventing incomplete reports.

**What is the difference between track_lead and track_event?**
Use `track_lead` when a contact has clearly become a prospect. Use `track_event` for general actions that happen during the funnel, like viewing a product page or downloading a guide.

**Can I use list_contacts to see where a user came from?**
Yes. The `list_contacts` tool retrieves not just contact details, but also their full customer journey history and the source that originally attributed them.

**When I run `list_ad_accounts`, what data points should I expect to see for each connected platform?**
It returns the unique ID, name, and current status of all linked ad accounts. This list confirms which Meta, Google, or TikTok platforms are active and ready for reporting.

**If I use `track_event` but don't provide full attribution metadata, will my conversion still be recorded?**
Yes, the event tracks the core action (Purchase/Lead), but you lose critical context. The record won't show which ad or campaign drove the traffic, making ROAS calculations difficult.

**How can I use `list_campaigns` to narrow down my search for a specific type of ad campaign?**
You pass filters like 'active status' or 'platform' directly into the tool call. This lets you quickly pull only the campaigns you care about, avoiding massive lists.

**What happens if I try to run `get_campaign_stats` too frequently?**
The system enforces rate limits. If you query performance stats too often in a short window, your agent will receive an error code and pause calls until the limit resets.

**How do I get my Cometly API key?**
Log in to Cometly, go to **Account Settings > API Keys**, copy your key, and paste it below.

**Is this the same as Meta Conversions API (CAPI)?**
No. Cometly acts as a bridge: it receives events, attributes them, and syncs data back to Meta, Google, TikTok, etc.

**What event types are supported?**
Standard events: Purchase, Lead, Add To Cart, Initiate Checkout. You can also use custom event names.