Back to blog
6 min read

Introducing Kontext: Trust Layer for Agentic Stablecoin Transactions

AI agents are moving real money. They are paying vendors, settling invoices, and executing trades autonomously. But who is watching the agents? Today we are open-sourcing Kontext -- a compliance and trust SDK built for the agent economy.

Launch
GENIUS Act
USDC

The agent economy is here

In the past twelve months, we have watched the agent economy go from demo to production. Companies are deploying AI agents to handle procurement, treasury management, vendor payments, and customer refunds. These agents are not just making recommendations -- they are executing transactions.

The dollar amounts are not trivial. Agents are moving thousands, sometimes millions, through stablecoins like USDC on Base and Ethereum. New protocols like x402 enable HTTP-native micropayments. Google's UCP and A2A protocols formalize agent-to-agent commerce. Stripe is adding agentic commerce capabilities.

The infrastructure for agents to move money is maturing fast. The infrastructure for agents to move money safely has not kept up.

The trust gap

When a human employee processes a $10,000 payment, there is an approval chain. There is a paper trail. Someone reviews the invoice, someone approves the payment, and someone can audit the whole thing after the fact. These processes exist because we have learned, over centuries of commerce, that moving money requires trust infrastructure.

When an AI agent does the same thing? In most deployments today, the answer is: console logs. Maybe a webhook to Slack. Perhaps a database entry if the team was thorough.

This is not going to work as agents handle more money with more autonomy. The regulatory environment is also evolving -- the GENIUS Act in the United States is creating new compliance requirements for stablecoin transactions. Teams need real infrastructure, not afterthoughts.

What Kontext does

Kontext is a TypeScript SDK that provides compliance and trust infrastructure for agentic workflows. It sits between your agents and the actions they take, providing:

  • Action logging -- an immutable audit trail for every agent action, with full context and metadata
  • Trust scoring -- real-time trust scores computed from agent history, transaction patterns, and context
  • Anomaly detection -- configurable rules that automatically flag unusual patterns (velocity, amounts, behavior)
  • Task confirmation -- human-in-the-loop approval for high-value or sensitive actions
  • Audit export -- compliance-ready reports in JSON, CSV, or PDF format

All of this works in five lines of code:

agent.tstypescript
import { Kontext } from 'kontext-sdk';

const ctx = new Kontext({ chain: 'base' });

const result = await ctx.verify({
  action: 'transfer',
  amount: '5000.00',
  currency: 'USDC',
  agent: 'payment-agent-v2',
});

// result.trustScore  -> 0.94
// result.flagged     -> false
// result.auditId     -> 'aud_abc123'

Built for the GENIUS Act era

The Guiding and Establishing National Innovation for U.S. Stablecoins Act is reshaping how stablecoin transactions are regulated. While the full implications are still being worked out, the direction is clear: stablecoin transactions will require better tracking, reporting, and compliance infrastructure.

Kontext does not replace your legal or compliance team. What it does is give your engineering team the tools to build compliance into your agent architecture from day one, rather than bolting it on later when a regulator comes knocking.

Transaction logging, audit trails, anomaly detection, and trust scoring -- these are the building blocks of regulatory compliance for the agent economy. Kontext provides all of them through a clean, developer-friendly API.

First-class protocol support

Kontext includes integration guides and optimized paths for the protocols driving agentic commerce:

  • USDC on Base and Ethereum -- verify transfers before execution, log results after confirmation
  • x402 Protocol -- middleware for HTTP-native payment verification
  • Google UCP / A2A -- trust scoring for agent-to-agent transactions
  • Stripe Agentic Commerce -- verify agent payments with audit IDs attached to Stripe metadata

Open source, with a Pro tier

The core Kontext SDK is open source under the MIT license. This includes action logging, basic anomaly detection, local audit export, and single-chain support. You can run it entirely self-hosted with no usage limits and no API key required.

For teams that need more, Kontext Pro ($99/month) adds a cloud dashboard, ML-powered anomaly detection, historical trust scoring, compliance report templates, multi-chain support, and email support. Enterprise plans are available for organizations with custom compliance requirements.

Getting started

Install the SDK and add compliance to your first agent in under five minutes:

Terminalbash
npm install kontext-sdk

Then check out the documentation for the full quick start guide, API reference, and integration examples.

What comes next

This is day one. The SDK is stable enough for production use, but there is a lot more coming:

  • Cloud dashboard for Pro users (coming in weeks, not months)
  • ML-powered anomaly detection models trained on agent patterns
  • Pre-built compliance templates for common regulatory frameworks
  • More chain support beyond EVM
  • Webhook integrations for real-time alerting

If you are building with agentic commerce and stablecoins, I would love to hear from you. Star the repo, open an issue, or reach out on X. Let us build the trust layer for the agent economy together.