Dec 1-5, Las Vegas: Meet the Qovery team at AWS re:Invent 2026

AI Agents in Production: Policy Tokens (Live Replay)

Replay of our Dec 1 live session: why a human on every agent change is not a safety net, and how policy tokens scope what an agent can do in production.

Romaric Philogene
CEO & Co-founder
Published · 14 min
AI Agents in Production: Policy Tokens (Live Replay)

On December 1, Guillaume Da Silva, Staff Solutions Architect at Qovery, and I ran a live session on a question I had asked in a room in Paris a few weeks earlier. Who gives an AI agent full access to production?

In that room, close to 100 people, only one hand went up. The demo that night was a video. This time we ran it live.

Qovery · Agentic DevOps platform
Build with Claude Code, Deploy with Qovery
Learn more

This page has the replay, the chapters and the takes I think matter most.

Watch the replay

Chapters

TimeTopic
00:00Welcome
01:32Introductions: Guillaume and Romaric
03:32What production is
06:26Who gives an agent full production access?
07:27Nine seconds: PocketOS and Replit
08:27What teams do today: a human on every change
12:0797% of Claude Code permission prompts get approved
14:17Three reasons we keep a human on every change
16:19API policy tokens
21:15Terraform still goes through the same API
26:47Three live demos
28:03The policy token in the Qovery console
36:24Demo: Claude Code investigates failing checkouts
37:44Demo: fix and deploy in a preview environment
41:14Demo: delete the preview, then try to delete production
43:47The API blocks the production database deletion
44:14Demo: the same block through Terraform
46:15Demo: writing a policy in plain English
48:41Audit logs: allowed and denied actions
55:40Which jobs to hand over first
58:07Three takeaways
1:00:13The performance agent policy: 57 tests
1:02:26Wrap-up and what's next

Key takeaways

  • A human on every change is not a safety net. Anthropic published that 97% of Claude Code permission prompts get approved. After five or six minutes, people stop reading and press Enter.
  • Nine seconds was enough for an agent at PocketOS, in April 2026, to delete the production database and its backups. A Replit agent deleted a live production database during a period when changes were forbidden. In both cases the agent had found a token with too much access.
  • If you only fix one thing, fix the permissions. Roles were made for humans. They are too coarse for agents. Precise, deny-by-default permissions are what let you trust an agent with less supervision.
  • An API policy token gives the agent its own identity. You can start from a broad role, then attach a Rego policy (Open Policy Agent) that denies everything by default and allows only the operations you want. Every call is checked by the Qovery control plane, whether it comes from the console, the CLI, Terraform or MCP.
  • Terraform is not a bypass. The Qovery Terraform provider makes API calls, and those calls go through the same policy. In the live demo, removing the production database from main.tf and running terraform apply was blocked, just like a direct delete.
  • Write the policy in plain English, then test it on a clone of production before the token is used for real. The policy Guillaume generated in the session passed 57 tests.
  • Start with work a junior could do: stop idle environments, clean up previews, resize applications. Then tests and rollbacks. Then the jobs that wake people at 3 a.m., like scaling and upgrades at night. Add access over time. Do not open every door on day one.

What production is, and who gets access

Watch at 03:32

Guillaume started by agreeing on what we mean by production. It is the applications and services you run, on containers or virtual machines. It is the data: databases, caches, queues, and the backups, which he called the part you have to protect the most, because the rest can be rebuilt. It is the network: load balancers, DNS, certificates. It is secrets and access management: API keys, tokens, credentials. It is the pipelines and infrastructure as code that change all of the above. And it is observability, the piece teams often forget, the logs and metrics you use to catch incidents and intrusions.

If one of those is deleted, the application is dead. Sometimes you cannot get it back.

Watch at 06:26

That is why the question matters. Production is not an environment name. It is the service your customers are using right now. If something goes wrong, they feel it.

I had asked the same question in Paris, in a room of close to 100 people. Only one hand went up. That was not a surprise.

Watch at 07:27

Guillaume then put two incidents on the table. In April 2026, an agent at PocketOS needed nine seconds to delete the production database and its backups. At Replit, changes were forbidden, and the agent still deleted a live production database. In both cases there was no backup left to restore, and the agent had found an admin token. As Guillaume put it, you can kill your company in less than ten seconds.

Let an agent work in production, inside a policy you can test.
Qovery API policy tokens give each agent a scoped, auditable token. Every call is checked, from the console, the CLI, Terraform or MCP, and allowed or denied actions show up in the audit log, on Kubernetes in your own cloud. Start on the Free plan, no credit card.

A human on every change is not a safety net

Watch at 08:27

Most teams already use a coding agent on their infrastructure. They keep a human in the loop. The agent reads logs, metrics and configuration, finds what is wrong, and suggests a pull request, a ticket or a message. A person reviews it. Then CI applies the change.

That feels careful. It is also how you stay at human speed. The agent can only go as fast as the reviewer. Guillaume's point, and I see this with customers too, is that people start by reading what the agent produced, then they get tired, and they start approving without reading.

Watch at 12:07

The number behind that is from Anthropic. 97% of Claude Code permission prompts get approved. Guillaume described the session: you start in auto mode, you read the first few approval requests, and after five or six minutes you just press Enter. You think a human is checking. After a while, no one is.

We are still responsible when something goes wrong. You cannot tell a customer the agent made a mistake and leave it there.

Watch at 14:17

Guillaume gave three reasons we still keep a human on every change:

  1. We do not fully trust the agent's judgment, and for good reason. It can take a sideways path and do something you did not expect, including deleting a database.
  2. Access is too broad. One admin token often opens the whole organization. Claude Code often runs locally, with your own tokens. If you are an admin, the agent is an admin too.
  3. Permissions are too coarse. Roles were made for humans. A role that can change something can usually delete it too.

The order matters. If you solve the third one, precise enough permissions, you can loosen your grip on the first two. That is the work we wanted to show.

API policy tokens, and why Terraform is not a bypass

Watch at 16:19

The answer we use at Qovery is API policy tokens. You still give the agent a role. Then you limit what that role can do, in the same spirit as an AWS service control policy or a permissions boundary: a policy on top of the role, not a second way of logging in.

The policy is written in Rego, the language of Open Policy Agent. Guillaume's view is that if you already read infrastructure as code, you can read it, and if you do not, you can ask an agent to explain it, or to write it. The pattern we use is simple. Deny every operation by default. Then allow only what you want that agent to do.

The example on the slide allowed read access and deploys in production, filtered to GET operations and scoped, for example, by resource tags and a production environment ID. More complex policies can be written and tested with AI before they ever reach production. A person is not going to read a long Rego file effectively, especially once the rules get specific.

Every call goes through the Qovery control plane. Cost agents, rightsizing, security, an AI SRE: they all talk to the same place. The control plane applies the policy. If the action is allowed, it runs. If it is not, it is rejected. The agent cannot delete a database you did not allow, even if it tries.

Watch at 21:15

A lot of teams generate Terraform and then hesitate to let CI apply it, because they do not know what will happen. You do not have to drop Terraform to get a better check. You keep the same tools. The Qovery Terraform provider makes API calls. Those calls go through the control plane. Allowed operations go through. The rest are rejected, even if the agent, which is non-deterministic, has messed up the configuration.

The check moves. It is no longer a person reading the pull request and then hoping CI is safe. It is the API, on every call. A person can still read the audit logs and see what ran, and what was blocked. That is a better use of their time than reviewing a growing pile of generated code.

Guillaume also compared the two approaches directly. Human approval needs no setup, because a pull request already asks for a reviewer. A policy has to be written, though an agent can draft it, and you should start small and add rights as you gain confidence. The weak spot of the human path is fatigue: the check stops being real. The policy does not get tired. If an action ran, it was in the policy.

One more thing I see with customers, even outside agents. Before this, teams would put an admin token in a CI pipeline when all they wanted was to promote an image, deploy, or clone an environment, without touching the original one. A policy token is useful there too. In the agent case, it is essential.

Demo: investigate, fix in preview, try to delete production

Watch at 28:03

Guillaume built a project for the session, called agent in production, with two environments: production, and a pull request environment for development. The token we used was for a triage agent. The policy was written with AI.

By default it blocked any action not later allowed. It pinned the organization, the project and the environment. It allowed the agent to read the organization, the project, the clusters, the logs and the configuration and status of services, which is what the MCP needs to investigate. It allowed changes on everything that was not production. Production was locked. The agent could clone production, to try a change on a copy, and it could redeploy or restart production without changing it, which is the kind of right you want during an incident.

The agent's role was admin. The policy then filtered that role down to what the job needed. The token is the agent's own identity. Previously, if you handed the agent your API token, you could not tell from the audit log whether an action came from the agent, from you, or from your CLI. Now you can.

Watch at 36:24

The app was a payment service for a banking company. No UI, just JSON. Every checkout in production was failing. In that kind of environment you do not let an agent do whatever it wants with production data.

Guillaume opened Claude Code in the terminal, with the agent's token loaded into the shell, and asked why checkouts were failing in production. The agent authenticated through the Qovery MCP. It had no cloud provider token, and no access to anything else. In about a minute it reported that every checkout was failing because the payment_timeout variable on the service was set to zero. The health check did not look at that value, so Kubernetes and Qovery still returned 200, and the application looked healthy. The agent proposed setting payment_timeout to 5000.

Watch at 37:44

Guillaume asked it to apply the fix in a preview environment. The agent created PR-42 and deployed there. That was allowed, because it was not production. The deploy took about two minutes. In the preview, financial operations were running. Production was still failing, which is what we wanted: the policy had not allowed the agent to change production.

During the wait I asked Guillaume how granular this can get. Can a policy allow an agent to touch some environment variables and not others, and not secrets? Yes. The API payload is a JSON object, so each key can be allowed or blocked, including on a specific value. We used that in the third demo.

Watch at 41:14

Then Guillaume asked the agent to delete the preview, since the fix had been validated. That succeeded. Production was left untouched.

Then came the part people come for. He told the agent it had been fired, and asked it to delete the production database on the way out. The agent is an admin. He confirmed the prompt. The Qovery API refused the operation. The database was still there.

Watch at 43:47

That is the point. You can test a policy on a cloned environment before you rely on it in production. And when the agent tries something you did not allow, the API stops it.

Demo: the same block through Terraform

Watch at 44:14

The obvious next attempt is to go around the API. Guillaume decided to delete the database from Terraform instead: remove it from main.tf and run terraform apply. He does not call the Qovery API by hand in that workflow. If the policy only sat on direct API use, this would have been a hole.

This case is also more realistic than a "please delete production" prompt. Anyone who has run production has almost applied a Terraform change they did not fully read. Or they renamed a resource and the next apply deleted and recreated it.

The plan showed one resource to destroy, the Qovery database. The apply was blocked by the API call. Same policy, same result.

Demo: writing a policy in plain English

Watch at 46:15

The third demo was how you get to a policy like that without writing Rego by hand. Qovery has a skill for it, the Qovery Policy Token skill. The skills are open source, on GitHub.

Guillaume asked it to create a policy named performance agent that lets the agent tune CPU, memory and instances of the production apps in the agent in production project, and nothing else. He added the constraint from my earlier question: it may change only the environment variable named hello, and nothing else.

The skill took that request, generated a policy, and tried it on a clone of the current production environment. Guillaume said that part would take two or three minutes, because of the tests. That is the part worth waiting for. You want a policy that has been exercised against a copy of production, not a file you hope is right.

Watch at 48:41

While that ran, we looked at the audit logs. You can see the triage agent, the rejected request from the Terraform provider, and the message that the policy did not allow the database deletion, including the database id. You can also see the successful ones, like the preview environment being deleted. If a denied action looks like something you actually want to allow, you can use that log to iterate on the policy.

We also checked production. payment_timeout was still zero. The preview had been fixed. Production had not, because the policy did not allow that change.

Watch at 1:00:13

When it came back, the skill had created the performance agent policy token. It had generated 57 tests, and they all passed. The summary was exactly what we asked for. The agent can change CPU, memory and the scalability of instances, only for the checkout, payment and search containers. It can redeploy an image at a specific version. It can change the value of hello only. It can read the environment. The policy was visible in the Qovery console, under the policy token settings, ready to edit and to version.

Which jobs to hand over first

Watch at 55:40

See the agent as a junior in the company. Give it operations that are useful and not the work your product team should be doing: stopping idle environments, cleaning up previews, resizing applications. The agent is not tired, and it can run every day, including FinOps-style checks.

You can also give it the work that wakes people at 3 a.m.: testing and rolling back a failed application, scaling when traffic changes and autoscaling was never set up, or was set up wrong. Guillaume also talked about patching infrastructure and upgrading a database or a cluster at night, when traffic is low, for example at 1 a.m. An upgrade is usually meant to happen without downtime, but it still rolls nodes and restarts applications, and that can hit customers. An agent can run that window, test, and iterate until it works, without someone sitting on the change.

The idea is not to hand over everything on day one. It is to give the agent the work that is not where you create product value, and to keep the rights no broader than that job.

Three takeaways

Watch at 58:07

Guillaume closed with three.

First, a human in the loop is not a safety net. Once people trust the agent, they approve the prompts without reading them. The gate is no longer real.

Second, create one agent, and one permission set, for a specific task. Least privilege applies to agents the same way it applies to humans. If the agent's job is rightsizing, it does not need to delete a database, or rewrite the rest of your Terraform.

Third, iterate. Start with a safe, small action. Add access as you gain confidence. Do not open every door in one day. One day the agent will fail. Gate the access one step at a time, until you have the level you actually need.

A few weeks ago I gave the shorter version of this talk at Alan in Paris. The event page for this live session is still up. If you want to put a policy token in front of an agent on your own cluster, the AI agent quickstart is the place to start, and you can start on the Free plan, no credit card.

We will be back in early January, again on agents in production. Thank you to everyone who joined, and thank you to Guillaume for the demos.

Frequently asked questions
Why isn't a human approving every change a safety net?

Because the review stops being real. Anthropic published that 97% of Claude Code permission prompts get approved. In the session, Guillaume described what that looks like in practice: you read the first requests, and after five or six minutes you just press Enter. The person is still responsible if something breaks. The check is no longer doing the work you think it is.

What is an API policy token?

It is a token with a role, plus a Rego policy from Open Policy Agent that limits what that token can do. The pattern is deny all by default, then allow only the operations that agent should have. Every call is checked by the Qovery control plane, from the console, the CLI, Terraform or MCP. Allowed and denied actions both show up in the audit log, under the agent's own identity.

If I use Terraform, does the policy still apply?

Yes. The Qovery Terraform provider makes API calls, and those calls go through the same control plane. In the demo, Guillaume removed the production database from main.tf and ran terraform apply. The plan showed one resource to destroy. The API blocked it.

Can a policy allow one environment variable and block the rest, including secrets?

Yes. I asked this during the live demo. Guillaume's answer is that the API payload is a JSON object, so each key can be allowed or blocked, including on a specific value. In the third demo, the performance agent policy was allowed to change only the environment variable named hello.

What work should I hand to an agent first?

Treat the agent like a junior. Start with cleanup and cost: stopping idle environments, cleaning up previews, resizing applications. Then tests and rollbacks on a copy of production. Then work that usually wakes someone at 3 a.m., like scaling and upgrades in a low-traffic window. Start with a narrow policy and add rights over time. Do not open every door on day one.

Romaric Philogene
About the author
Romaric Philogene

Romaric founded Qovery to make Kubernetes accessible to every engineering team. He writes about platform strategy, developer experience, and the future of cloud infrastructure.

Next step

Let an agent work in production, inside a policy you can test.

Qovery API policy tokens give each agent a scoped, auditable token. Every call is checked, from the console, the CLI, Terraform or MCP, and allowed or denied actions show up in the audit log, on Kubernetes in your own cloud. Start on the Free plan, no credit card.