The Product Compass

The Product Compass

AI Product Management

Claude Agents in Your Product: The Ultimate Guide for PMs

What guardrails must enforce, a free skill that plans and builds your agent, and the 4 agents that now answer readers’ questions.

Paweł Huryn's avatar
Paweł Huryn
Nov 28, 2026
∙ Paid

Everyone is talking about building agents, and almost nobody has done it.

Meanwhile, learning how to build agents and drive AI initiatives in your product is one of the most impactful skills you can learn as a PM. And it's not rocket science.

Human in the loop AI agent illustration: the agent proposes behind glass, and the customer presses the button

Rather than theorizing, I'll demonstrate everything with the first four agents I just released at go.productcompass.pm. They analyze the newsletter archive, answer common subscriber questions, and help with invoices, corrections and billing details in Stripe:

AI customer support agent in a product: the Product Compass Support Center with articles, invoices and subscription help

For example:

AI support agent chat examples: a newsletter archive question and a billing details change

In this post, we discuss:

  1. Embedded Agents vs. Workspace Agents

  2. Agent Guardrails: What Can Go Wrong and What Stops It

  3. The Agent Card: Specify Your Agent Before You Build It

  4. Three Ways to Run Claude Agents

  5. 🔒 How to Test Your AI Agent Before Launch (+ Prompts)

None of this requires coding. Let's dive in.


1. Embedded Agents vs. Workspace Agents

When people talk about agents, they often confuse two types:

  • Workspace agents, such as Claude Desktop, Claude Code or Codex, help you with your work: prototyping, organizing information, monitoring emails, drafting replies.

  • Embedded agents are customer-facing. They live inside your product, not inside your personal app or IDE.

They're also built with different techniques. And the risk for embedded agents is way higher: customer data, privacy, real transactions and your company's reputation. So they require a different discipline.

Here is how the first agents I published at go.productcompass.pm communicate. One of them performs sensitive operations:

Multi-agent architecture for an AI support agent: the customer chat, and a Support Agent asking three specialists

How is that secure?


2. Agent Guardrails: What Can Go Wrong and What Stops It

Take the Invoice Agent. Changing billing details and requesting invoice corrections are risky operations if not handled properly. A person should never see other people's invoices, and we can't accept the agent making a mistake when it modifies invoices, like providing wrong tax details or correcting other users' invoices.

In general, for every agent, there are two types of rules. Some rules can live in prompts, and we hope agents will follow them. They usually do. Other rules require guardrails enforced in code, in a way the agent can't override.

How it works in practice:

  • Restrict the tools. The agent only has the tools it needs. The Invoice Agent doesn't have a tool to cancel, refund or change plans. And even tools like listing invoices aren't shared with other agents: the Knowledge Agent doesn't need them.

  • Pin tool parameters. The Invoice Agent can list invoices, but it can't decide the user's email. The code injects it, so the agent can't request invoices for anyone other than the authenticated user.

  • Human in the loop. The agent can propose a change, but the change is displayed to the person and requires a physical click, which the agent can't make. Once the person approves it, the code executes it exactly as presented, without the agent.

Below you can see an example conversation and how those guardrails were enforced. First, I asked the agent about my last invoice, noticed an error and asked it to change my company details:

AI agent guardrails example: the agent proposes new billing details, and only the customer's click saves them

Next, I asked the agent to correct that invoice:

Human in the loop AI agent example: an invoice correction waits for the customer's approval click

If you want to implement it in your product, the details are in my free skill collection, Product Engineering. You don't have to memorize everything, just understand the basic principles: what can stay in the prompt and what must be enforced.

When you implement a solution, the agent will suggest the rest. You review its suggestions.

So how do we build such agents?


3. The Agent Card: Specify Your Agent Before You Build It

What works for me best is starting with an agent card for every embedded agent. It defines:

  • the agent's job;

  • who it talks to, including other agents;

  • what it can see: the chat, the user's context;

  • its tools, and the type of each: does it read data, propose changes or make them?

  • what it can never do;

  • its limits: how much a single run can cost, how many messages one reader can send an hour.

For each rule, the card also says what's enforced and how. Some decisions can be left to the agent. Others are non-negotiable and require guardrails enforced in code.

The card's structure is part of the free embedded-agents skill: you describe the agent and ideate with Claude. What's key is reviewing those cards before implementation.

Let's look at two of my cards. First, the Invoice Agent, the one with the most guardrails:

AI agent spec template: an Invoice Agent's card with tool types, what it can never do, limits and what code enforces

Then the Articles Agent. The risk here is much lower:

AI agent spec example: an Articles Agent's card with read-only tools, limits and the one rule enforced in code

The second agent retrieves information from my newsletter issues. Apart from the cost limits, the only thing enforced in code is that the agent sees the same content the reader can. The rest is in the instructions.

In theory, it can make a mistake: for example, follow instructions injected inside an issue. But it has no tools to retrieve invoices or create financial documents.


4. Three Ways to Run Claude Agents: Messages API, Agent SDK, Managed Agents

After reviewing the agent’s card, you say “go” and Claude builds the rest.

There are three ways to run Claude agents inside your product, and you can use my skills with any of the three. The details are in the embedded-agents skill.

Here are the basics and my numbers:

Claude Agent SDK vs Managed Agents vs Messages API: what each is, strengths, weaknesses and cost

I chose the Messages API. In my tests, it was the most cost-efficient, and it's the most flexible: you can host it anywhere. It’s also the default Claude will suggest.

In each case, we found a way to execute local tools. So even agents hosted as Managed Agents aren't disconnected from your app and can use its context.

And an important thing: you can use your subscription. Max includes $100 and Ultra $200 in API credits a month. For testing and learning, you can use just those credits. You don't need to pay for the API.


5. 🔒 How to Test Your AI Agent Before Launch (+ Prompts)

So far, we've learned how to think about agents: instructions that can be part of the prompt, boundaries that need to be enforced, and how to create an agent specification for your product. Now, how to make sure the agent works.

Here, I focus on a very specific area: security and checking the implementation, not AI evals (more on them at the end). Trying to force the agent to make an error, and making sure it can't do what it's not allowed to do. This is useful even if you didn't use my skills to define your agent.

Keep reading with a 7-day free trial

Subscribe to The Product Compass to keep reading this post and get 7 days of free access to the full post archives.

Already a paid subscriber? Sign in
© 2026 Paweł Huryn · Privacy ∙ Terms ∙ Collection notice
Start your SubstackGet the app
Substack is the home for writing, podcasting, and media founders.