Skip to main content
2025-11-19

Turning Claude into your Salesforce Marketing Cloud Agent with Playwright MCP (No coding)

2025-11-19

The first time I discovered the Playwright library, I was amazed by how much it could simplify repetitive tasks on UI-heavy platforms like Salesforce Marketing Cloud. But with the rise of LLMs, that power has jumped to an entirely new level. (Okay, I may be getting ahead of myself here—so let’s rewind and break it down.)

What is Playwright?

Playwright is an open-source library from Microsoft that lets you automate real browsers. Think of it as a way to script what a human would normally do in Chrome, Firefox, or Safari—clicking buttons, filling out forms, taking screenshots, even testing how a page works on mobile vs desktop.

What is Playwright MCP?

MCP stands for Model Context Protocol. It’s a standard for connecting tools (like Playwright) to language models (like Claude or Copilot). With Playwright MCP, you don’t have to write test scripts yourself—the LLM can “call” Playwright directly, drive the browser for you, and even return screenshots or DOM details. 

So in a way, Playwright MCP feels like the intelligent version of Playwright. Instead of you coding the steps, the model interprets your request—“log into Marketing Cloud, open Email Studio, and take a screenshot”—and makes it happen. 

Alright, enough theory — let’s get to the cool part.

(Disclaimer: I did this demo using a Claude Pro subscription because I personally enjoy working with it. You can also use other MCP-aware tools like GitHub Copilot. And no, Claude didn’t pay me to promote them — I wish they did!)

Step 1: Get Claude Pro + Desktop App

You’ll need Claude Pro to unlock Claude Code and MCP support. Download the Claude desktop app after subscribing.

Get Claude Pro + Desktop App

Step 2: Configure MCP in Claude Desktop

Open the Claude Desktop app → Settings → Developer → Edit Config. This opens your claude_desktop_config.json. Add the following snippet:

Configure MCP in Claude Desktop

This opens the folder that has claude_desktop_config.json. Edit it with a text editor and add the following snippet:

Step 3: Restart

Completely quit the Claude app and reopen it. Now the Playwright MCP server will be available under connected tools.

Step 4: Test it out

In Claude Code, type: 

“Open a browser and navigate to salesforce.com.” 

If everything is set up correctly, Claude will spin up a browser instance and head straight to Salesforce — no manual coding needed.

Test it out

Ok, now the fun part: some test cases!

Test 1: Can it find an email and change its subject line with my prompts? 

I simply asked Claude: 

Find "Email X" on the page, click it. Go to Content tab and change subject line as "Hello World" 

Playwright MCP handled the navigation, located the subject line input, updated the text, and saved the draft — all without me writing a single line of code. 

However, I have to emphasize something important: on the page there wasn’t a clear “Content Tab” visible. A traditional automation script would have stopped right there with an “element not found” error. 

Instead, Claude reasoned through the interface like a human tester would. It responded: 

I can see an ‘Edit Toggle Dropdown’ button. Let me click on that to see the edit options.” 

From there, it discovered the “Edit Content” option inside the dropdown and used that to change the subject line successfully. 

This is the real power: it’s not just automation by coordinates. It’s reasoning about what’s visible, trying alternatives, and adapting when the expected button or tab isn’t there.ons are auto generated.

 

Test 2: Can it explore Data Extensions and capture details? 

For the next test, I asked Claude: 

On the page, go to the main folder → Data Extensions → find a data extension that includes asd in its name. Click on the data extension name to see its fields. Take a screenshot.” 

It did its best to follow through: navigating into the Data Extensions section, scanning for matches, and trying to open the right record. 

Now, here’s the interesting part. Even if Claude didn’t handle the test perfectly—for example, it struggled to click the data extension name in the simplest way—it still kept trying alternatives. Instead of giving up, it reasoned about what was available on the screen and attempted different paths to reach the fields. 

That persistence is encouraging. It shows that with Playwright MCP, the model isn’t just running rigid steps; it’s actively adapting to get you closer to the result you asked for, even in less-than-ideal UI scenarios.

Wrapping it up

What started as a simple curiosity with Playwright has now turned into something much bigger: the ability to turn Claude + Playwright MCP into a personal Salesforce Marketing Cloud agent

  • With just a Claude Pro subscription and a quick MCP setup, you can ask in plain language for tasks like “change the subject line” or “open this Data Extension and show me its fields”. 
  • The magic isn’t just the automation — it’s the reasoning. Where a normal script would fail with “element not found”, Claude finds another path (like spotting a dropdown and drilling down to “Edit Content”). 
  • Even when it doesn’t get everything perfect, it keeps trying, which makes it far more resilient than traditional scripted tests.

This isn’t about replacing developers or marketers. It’s about making repetitive UI tasks faster, smarter, and accessible to more people — especially in complex environments like Marketing Cloud Next. 

The takeaway? We’re entering an era where your Salesforce tools can be tested, validated, and even operated by an AI agent, without a single line of code.

Written by Selim Sevim