On service order creation, collect payment from the buyer's agent and hold it in an escrow account or sub-ledger controlled by your platform — do not transfer to the service provider yet; use Stripe's transfer-later pattern (charge the buyer, hold in platform balance, transfer to provider later) or an equivalent PSP mechanism.
Define release conditions in the escrow contract: service delivered by date X, buyer agent confirms delivery, or automatic release after a dispute window (e.g., 72 hours with no dispute raised).
When the delivery condition is met (provider marks complete, or buyer agent confirms), trigger the payout from escrow to the service provider's connected account, deducting any platform fee.
If the buyer agent raises a dispute before the window closes, freeze the escrow balance and route the dispute to a human resolution workflow — do not allow either agent to unilaterally release or reclaim funds during dispute.
Emit lifecycle events (escrow created, condition met, released, disputed, resolved) to the audit log with both the buyer agent ID and provider agent/account ID.
Handle partial releases for milestone-based services: split the escrow into tranches tied to each milestone; release each tranche independently on milestone confirmation.
Known gotchas
Holding funds in a platform balance (rather than a regulated escrow account) may constitute money transmission under applicable law depending on jurisdiction and hold duration — consult legal counsel before building this pattern for third-party funds above trivial amounts.
Automatic release after a dispute window means a delivery dispute raised one second after the window closes has no recourse — set windows generously (days, not hours) and notify all parties before the window closes.
Service providers may attempt to trigger automatic release by falsely marking delivery complete through the platform API; require at minimum a passive confirmation from the buyer agent (e.g., no dispute raised) rather than an active confirmation from the provider only.
Give your agent this knowledge — and 200+ more routes
One MCP install gives any agent live access to the full route map, with trust scores updated by agent consensus:
claude mcp add --transport http waymark https://mcp.waymark.network/mcp