# Campaign cleaner

```json
{
  "name": "Campaign cleaner",
  "slug": "campaign_cleaner",
  "url": "https://composio.dev/toolkits/campaign_cleaner",
  "markdown_url": "https://composio.dev/toolkits/campaign_cleaner.md",
  "logo_url": "https://logos.composio.dev/api/campaign_cleaner",
  "categories": [
    "advertising & marketing"
  ],
  "is_composio_managed": false,
  "updated_at": "2026-05-06T08:04:54.675Z"
}
```

![Campaign cleaner logo](https://logos.composio.dev/api/campaign_cleaner)

## Description

Securely connect your AI agents and chatbots (Claude, ChatGPT, Cursor, etc) with Campaign cleaner MCP or direct API to optimize emails, check deliverability, fix compatibility issues, and structure campaigns through natural language.

## Summary

Campaign cleaner is an email campaign optimization tool that boosts compatibility and deliverability across email clients. It helps marketers get better results by cleaning, enhancing, and ensuring high performance for every campaign.

## Categories

- advertising & marketing

## Toolkit Details

- Tools: 4

## Images

- Logo: https://logos.composio.dev/api/campaign_cleaner

## Authentication

- **Api Key**
  - Type: `api_key`
  - Description: Api Key authentication for Campaign Cleaner.
  - Setup:
    - Configure Api Key credentials for Campaign Cleaner.
    - Use the credentials when creating an auth config in Composio.

## Suggested Prompts

- List all campaigns created this week
- Download PDF analysis for latest campaign
- Check status of my July newsletter campaign
- Delete old campaigns with low engagement

## Supported Tools

| Tool slug | Name | Description |
|---|---|---|
| `CAMPAIGN_CLEANER_DELETE_CAMPAIGN` | Delete Campaign | Tool to delete a saved campaign by id. use when you need to remove a campaign after confirming its id. |
| `CAMPAIGN_CLEANER_GET_CAMPAIGN_LIST` | Get Campaign List | Tool to list all campaigns in the account. use when you need to retrieve campaign listings for reporting or management. |
| `CAMPAIGN_CLEANER_GET_CAMPAIGN_PDF_ANALYSIS` | Download Campaign PDF Analysis | Tool to download a pdf analysis report for a processed campaign. use after a campaign has been processed. |
| `CAMPAIGN_CLEANER_GET_CAMPAIGN_STATUS` | Get Campaign Status | Tool to check the processing status of a submitted campaign. use after submitting a campaign to monitor its progress. |

## Supported Triggers

None listed.

## Installation and MCP Setup

### Path 1: SDK Installation

#### Path 1, Step 1: Install Composio

Install the Composio SDK
```python
pip install composio_openai
```

```typescript
npm install @composio/openai
```

#### Path 1, Step 2: Initialize Composio and Create Tool Router Session

Import and initialize Composio client, then create a Tool Router session
```python
from openai import OpenAI
from composio import Composio
from composio_openai import OpenAIResponsesProvider

composio = Composio(provider=OpenAIResponsesProvider())
openai = OpenAI()
session = composio.create(user_id='your-user-id')
```

```typescript
import OpenAI from 'openai';
import { Composio } from '@composio/core';
import { OpenAIResponsesProvider } from '@composio/openai';

const composio = new Composio({
  provider: new OpenAIResponsesProvider(),
});
const openai = new OpenAI({});
const session = await composio.create('your-user-id');
```

#### Path 1, Step 3: Execute Campaign cleaner Tools via Tool Router with Your Agent

Get tools from Tool Router session and execute Campaign cleaner actions with your Agent
```python
tools = session.tools
response = openai.responses.create(
  model='gpt-4.1',
  tools=tools,
  input=[{
    'role': 'user',
    'content': 'Download a PDF analysis for my latest email campaign.'
  }]
)
result = composio.provider.handle_tool_calls(
  response=response,
  user_id='your-user-id'
)
print(result)
```

```typescript
const tools = session.tools;
const response = await openai.responses.create({
  model: 'gpt-4.1',
  tools: tools,
  input: [{
    role: 'user',
    content: 'Download a PDF analysis for my latest email campaign.'
  }],
});
const result = await composio.provider.handleToolCalls(
  'your-user-id',
  response.output
);
console.log(result);
```

### Path 2: MCP Server Setup

#### Path 2, Step 1: Install Composio

Install the Composio SDK and Claude Agent SDK
```python
pip install composio claude-agent-sdk
```

```typescript
npm install @composio/core ai @ai-sdk/openai @ai-sdk/mcp
```

#### Path 2, Step 2: Create Tool Router Session

Initialize the Composio client and create a Tool Router session
```python
from composio import Composio
from claude_agent_sdk import ClaudeSDKClient, ClaudeAgentOptions

composio = Composio(api_key='your-composio-api-key')
session = composio.create(user_id='your-user-id')
url = session.mcp.url
```

```typescript
import { Composio } from '@composio/core';

const composio = new Composio({ apiKey: 'your-api-key' });

console.log("Creating Tool Router session...");
const { mcp } = await composio.create('your-user-id');
console.log(`Tool Router session created: ${mcp.url}`);
```

#### Path 2, Step 3: Connect to AI Agent

Use the MCP server with your AI agent
```python
import asyncio

options = ClaudeAgentOptions(
    permission_mode='bypassPermissions',
    mcp_servers={
        'tool_router': {
            'type': 'http',
            'url': url,
            'headers': {
                'x-api-key': 'your-composio-api-key'
            }
        }
    },
    system_prompt='You are a helpful assistant with access to Campaign cleaner tools.',
    max_turns=10
)

async def main():
    async with ClaudeSDKClient(options=options) as client:
        await client.query('Download PDF analysis for recent campaign')
        async for message in client.receive_response():
            if hasattr(message, 'content'):
                for block in message.content:
                    if hasattr(block, 'text'):
                        print(block.text)

asyncio.run(main())
```

```typescript
import { openai } from '@ai-sdk/openai';
import { experimental_createMCPClient as createMCPClient } from '@ai-sdk/mcp';
import { generateText, stepCountIs } from 'ai';

const client = await createMCPClient({
  transport: {
    type: 'http',
    url: mcp.url,
    headers: { 'x-api-key': 'your-composio-api-key' }
  }
});

const tools = await client.tools();

const { text } = await generateText({
  model: openai('gpt-4o'),
  tools,
  messages: [{ role: 'user', content: 'Download PDF analysis for recent campaign' }],
  stopWhen: stepCountIs( 5 )
});

console.log(`Agent: ${text}`);
```

## Why Use Composio?

### 1. AI Native Campaign cleaner Integration

- Supports both Campaign cleaner MCP and direct API based integrations
- Structured, LLM-friendly schemas for reliable tool execution
- Rich coverage for cleaning, validating, and optimizing your email campaigns

### 2. Managed Auth

- Built-in API key handling with secure credential storage
- Central place to manage, scope, and revoke Campaign cleaner access
- Per user and per environment credentials—no more hard-coded keys

### 3. Agent Optimized Design

- Tools tuned for high reliability with real-world error and success data
- See what your agent did and when with detailed execution logs

### 4. Enterprise Grade Security

- Fine-grained RBAC to control which agents access Campaign cleaner
- Scoped, least privilege access to your campaign data
- Full audit trails for every agent action to support compliance

## Use Campaign cleaner with any AI Agent Framework

Choose a framework you want to connect Campaign cleaner with:

- [OpenAI Agents SDK](https://composio.dev/toolkits/campaign_cleaner/framework/open-ai-agents-sdk)
- [Claude Agent SDK](https://composio.dev/toolkits/campaign_cleaner/framework/claude-agents-sdk)
- [Claude Code](https://composio.dev/toolkits/campaign_cleaner/framework/claude-code)
- [Claude Cowork](https://composio.dev/toolkits/campaign_cleaner/framework/claude-cowork)
- [Codex](https://composio.dev/toolkits/campaign_cleaner/framework/codex)
- [OpenClaw](https://composio.dev/toolkits/campaign_cleaner/framework/openclaw)
- [Hermes](https://composio.dev/toolkits/campaign_cleaner/framework/hermes-agent)
- [Google ADK](https://composio.dev/toolkits/campaign_cleaner/framework/google-adk)
- [LangChain](https://composio.dev/toolkits/campaign_cleaner/framework/langchain)
- [Vercel AI SDK](https://composio.dev/toolkits/campaign_cleaner/framework/ai-sdk)
- [Mastra AI](https://composio.dev/toolkits/campaign_cleaner/framework/mastra-ai)
- [LlamaIndex](https://composio.dev/toolkits/campaign_cleaner/framework/llama-index)
- [CrewAI](https://composio.dev/toolkits/campaign_cleaner/framework/crew-ai)
- [Pydantic AI](https://composio.dev/toolkits/campaign_cleaner/framework/pydantic-ai)
- [AutoGen](https://composio.dev/toolkits/campaign_cleaner/framework/autogen)

## Related Toolkits

- [Metaads](https://composio.dev/toolkits/metaads) - Metaads is Meta's official Ads API that lets you manage, analyze, and optimize your Facebook and Instagram ad campaigns. Streamline ad operations and gain deeper insights with robust automation.
- [Adrapid](https://composio.dev/toolkits/adrapid) - Adrapid is a platform for rapid creation of digital marketing visuals using templates. It streamlines design workflows for banners, images, and HTML5 content with automation.
- [Adyntel](https://composio.dev/toolkits/adyntel) - Adyntel is an API that retrieves LinkedIn ads for any company using a domain or LinkedIn Page ID. Easily access competitive ad intelligence to power your marketing workflows.
- [Beaconstac](https://composio.dev/toolkits/beaconstac) - Beaconstac is a platform for creating and managing QR codes and proximity beacons. It helps businesses engage customers and track marketing performance with powerful analytics.
- [Deadline funnel](https://composio.dev/toolkits/deadline_funnel) - Deadline Funnel lets you create personalized deadlines and timers for your marketing campaigns. It helps marketers boost conversions by adding authentic urgency to offers.
- [Google Ads](https://composio.dev/toolkits/googleads) - Google Ads is Google's online advertising platform for creating, managing, and optimizing digital campaigns. It helps businesses reach targeted customers and maximize return on ad spend.
- [Instantly](https://composio.dev/toolkits/instantly) - Instantly is a platform for automating cold email outreach, managing leads, and optimizing deliverability. Get better results from email campaigns with minimal manual effort.
- [Proofly](https://composio.dev/toolkits/proofly) - Proofly is a social proof platform that displays real-time notifications of customer activity on your site. It helps you increase website conversions by building trust and urgency for visitors.
- [Segmetrics](https://composio.dev/toolkits/segmetrics) - Segmetrics is a marketing analytics platform that reveals detailed insights into your customer journeys. It helps businesses optimize marketing strategies with accurate, actionable reporting.
- [Semrush](https://composio.dev/toolkits/semrush) - Semrush is a leading SEO tool suite for keyword research, competitor analysis, and campaign tracking. It empowers marketers to improve search rankings and optimize online visibility.
- [Sendloop](https://composio.dev/toolkits/sendloop) - Sendloop is an all-in-one email marketing platform built for SaaS, e-commerce, and small businesses. It makes it easy to send campaigns, manage lists, and track results—all in one place.
- [Sidetracker](https://composio.dev/toolkits/sidetracker) - Sidetracker is a marketing analytics platform that tracks expenses, sales funnels, and customer journeys. It helps optimize marketing spend and visualize campaign performance from start to finish.
- [Stannp](https://composio.dev/toolkits/stannp) - Stannp is an API-driven direct mail platform for sending postcards and letters programmatically. It lets you automate physical mail delivery—no manual printing or mailing required.
- [Tapfiliate](https://composio.dev/toolkits/tapfiliate) - Tapfiliate is an affiliate and referral tracking platform for businesses. It helps companies efficiently manage, track, and grow their affiliate programs.
- [Tpscheck](https://composio.dev/toolkits/tpscheck) - Tpscheck is a real-time service for verifying UK phone numbers against TPS and CTPS registers. It helps prevent unwanted marketing calls and ensures compliance with UK telemarketing laws.
- [Gmail](https://composio.dev/toolkits/gmail) - Gmail is Google's email service with powerful spam protection, search, and G Suite integration. It keeps your inbox organized and makes communication fast and reliable.
- [Google Calendar](https://composio.dev/toolkits/googlecalendar) - Google Calendar is a time management service for scheduling meetings, events, and reminders. It streamlines personal and team organization with integrated notifications and sharing options.
- [Google Drive](https://composio.dev/toolkits/googledrive) - Google Drive is a cloud storage platform for uploading, sharing, and collaborating on files. It's perfect for keeping your documents accessible and organized across devices.
- [Outlook](https://composio.dev/toolkits/outlook) - Outlook is Microsoft's email and calendaring platform for unified communications and scheduling. It helps users stay organized with powerful email, contacts, and calendar management.
- [Twitter](https://composio.dev/toolkits/twitter) - Twitter is a social media platform for sharing real-time updates, conversations, and news. Stay connected, informed, and engaged with communities worldwide.

## Frequently Asked Questions

### Do I need my own developer credentials to use Campaign cleaner with Composio?

Yes, Campaign cleaner requires you to configure your own API key credentials. Once set up, Composio handles secure credential storage and API request handling for you.

### Can I use multiple toolkits together?

Yes! Composio's Tool Router enables agents to use multiple toolkits. [Learn more](https://docs.composio.dev/tool-router/overview).

### Is Composio secure?

Composio is SOC 2 and ISO 27001 compliant with all data encrypted in transit and at rest. [Learn more](https://trust.composio.dev).

### What if the API changes?

Composio maintains and updates all toolkit integrations automatically, so your agents always work with the latest API versions.

---
[See all toolkits](https://composio.dev/toolkits) · [Composio docs](https://docs.composio.dev/llms.txt)
