LangChain Launches Restock to Let AI Agents Pay via Stripe
LangChain has introduced Restock, a sample agent running on Managed Deep Agents that integrates with Stripe's Link to allow AI systems to securely purchase physical goods.

LangChain has released Restock, an open-source sample agent designed to safely execute real-world purchases. Operating within Slack on LangChain's Managed Deep Agents (MDA) platform, the system demonstrates how developers can build AI assistants that handle financial transactions without exposing sensitive payment credentials to the underlying language model. The sample code, available in the langchain-samples/restock-agent repository, can run on models like OpenAI's gpt-5.6-sol.
To bypass fragile browser-based checkouts, Restock utilizes the Machine Payments Protocol (MPP) via the Zinc retail API, alongside Stripe's Link consumer wallet. In a demonstrated test case, a user requests a 12-pack of blue pens under a $25 budget. Restock calculates the costs and requests a $23 upfront payment. Zinc takes a $1 base fee, leaving a $22 allowance. The actual order totals $21.18—comprising $14.99 for the pens, $1.20 in tax, and $4.99 for shipping—resulting in a final charge of $22.18 and an automatic refund of $0.82 to the user.
For developers, this architecture solves the critical security challenge of agentic payments. The model itself never accesses financial secrets; instead, the Link session is isolated within a user-owned MDA Connection inside a managed sandbox. The agent cannot bypass human oversight, as it pauses for a manual Slack approval before generating a Link payment URL. As the developers note, "nothing the model writes into a tool call can approve" a transaction, keeping the user in complete control of the budget.
Restock supports three operational modes to help developers safely test their setups: rehearsal, which uses simulated approvals and fictional products; link-test, which connects to real Zinc searches and Link approvals without executing a purchase; and live, which processes actual retail orders. Currently, the sample is limited to US deliveries, USD transactions, and single-office deployments.
This is our own summary of reporting by LangChain Blog


