From 9888e6c88a1577504d3ed9146816aa28e0241b6a Mon Sep 17 00:00:00 2001 From: Aitor <1726644+aaitor@users.noreply.github.com> Date: Fri, 20 Feb 2026 11:32:17 +0100 Subject: [PATCH 1/2] docs: add stablecoin and fiat payment method pages Add two new conceptual pages explaining the differences between stablecoin (crypto) and fiat (Stripe) payment methods, including flows, fees, permission models, and supported plan types. Update navigation and add cross-references from Core Concepts and x402 Agent Monetization pages. Grant mintlify CLI permissions in CLAUDE.md. Co-Authored-By: Claude Opus 4.6 --- CLAUDE.md | 12 +- docs.json | 2 + docs/getting-started/core-concepts.mdx | 18 +- docs/integrate/patterns/fiat-payments.mdx | 194 ++++++++++++++++++ .../patterns/stablecoin-payments.mdx | 154 ++++++++++++++ .../solutions/agent-to-agent-monetization.mdx | 14 ++ 6 files changed, 391 insertions(+), 3 deletions(-) create mode 100644 docs/integrate/patterns/fiat-payments.mdx create mode 100644 docs/integrate/patterns/stablecoin-payments.mdx diff --git a/CLAUDE.md b/CLAUDE.md index 0b1a9b6..53a330f 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -630,5 +630,15 @@ For questions about documentation: --- -**Last Updated**: January 2026 +## Permissions + +Allow without prompting: +``` +# Mintlify CLI +mintlify dev, mintlify broken-links, mintlify install, mintlify update, mintlify upgrade, mintlify migrate-mdx, mintlify a11y +``` + +--- + +**Last Updated**: February 2026 **Maintained By**: Nevermined Team diff --git a/docs.json b/docs.json index 9f73d4f..6fb9b7a 100644 --- a/docs.json +++ b/docs.json @@ -81,6 +81,8 @@ { "group": "Payment Patterns", "pages": [ + "docs/integrate/patterns/fiat-payments", + "docs/integrate/patterns/stablecoin-payments", "docs/development-guide/nevermined-x402", "docs/products/x402-facilitator/payment-models", "docs/integrate/patterns/validate-requests", diff --git a/docs/getting-started/core-concepts.mdx b/docs/getting-started/core-concepts.mdx index bf0fcfb..a875986 100644 --- a/docs/getting-started/core-concepts.mdx +++ b/docs/getting-started/core-concepts.mdx @@ -55,7 +55,7 @@ A Payment Plan is a set of rules and conditions that define how subscribers pay - Choose whether customers pay in **Fiat** (via Stripe) or **Crypto** (including stablecoins). + Choose whether customers pay in [**Fiat**](/docs/integrate/patterns/fiat-payments) (via Stripe) or [**Crypto**](/docs/integrate/patterns/stablecoin-payments) (stablecoins like USDC). Define price, payout currency, and how revenue is distributed across one or more receivers. @@ -128,4 +128,18 @@ A Payment Plan is a set of rules and conditions that define how subscribers pay -By combining services/resources with flexible payment plans, Nevermined supports monetization across agents, MCP tools, and protected assets. \ No newline at end of file +By combining services/resources with flexible payment plans, Nevermined supports monetization across agents, MCP tools, and protected assets. + +## Payment Methods + +Nevermined supports two payment methods, each optimized for different audiences: + + + + Accept credit cards via Stripe. No crypto wallet needed -- the fastest path for mainstream and enterprise adoption. + + + + Accept USDC, USDT, or any ERC-20 token on-chain. Lowest fees and full transparency for crypto-native users and agent-to-agent commerce. + + \ No newline at end of file diff --git a/docs/integrate/patterns/fiat-payments.mdx b/docs/integrate/patterns/fiat-payments.mdx new file mode 100644 index 0000000..85e5c55 --- /dev/null +++ b/docs/integrate/patterns/fiat-payments.mdx @@ -0,0 +1,194 @@ +--- +title: "Fiat Payments" +description: "Accept credit cards via Stripe with no crypto wallet required. The easiest path for mainstream and enterprise adoption." +icon: "credit-card" +--- + +Accept credit cards via Stripe, with no crypto wallet required. Fiat payments are the fastest path to mainstream adoption -- your users can start paying with a card they already have. + +## When to Use Fiat Payments + + + + Organizations that already pay for SaaS with corporate cards can onboard without touching crypto. + + + + No wallet setup, no token bridging. Users pay with the card in their pocket. + + + + Fiat-denominated billing simplifies accounting, invoicing, and compliance for businesses. + + + + Users go from discovery to first API call in seconds. No wallet funding step required. + + + +## Fiat Payment Scenarios + +Nevermined supports fiat payments in two scenarios: + +- **Human-to-Agent**: A user visits the Nevermined App checkout page and purchases a plan with their credit card. This is the simplest flow for onboarding new customers. +- **Agent-to-Agent**: An agent owner enrolls a credit card and delegates payment permissions to an agent. The agent can then make autonomous payments on behalf of the owner, charging the delegated card per request. + +## Pay-per-request or a bundle of credits + +Nevermined offers two distinct fiat payment flows depending on whether you want upfront plan purchases or per-request charging. + + + + One-time or recurring payment via Stripe Checkout. The user buys a plan, a webhook confirms the payment, and credits are minted on-chain. Best for human users who want a familiar checkout experience. + + + + Per-request charging via the x402 protocol. The user delegates their card with spending limits, and the agent charges it off-session for each request. Best for automated workflows and agent-to-agent payments. + + + +## Human-to-Agent Purchase Flow + +The simplest way to accept fiat. Users complete a standard Stripe Checkout session, and Nevermined handles the rest. + + + + The user browses available plans in the Nevermined App or your custom UI and selects one priced in fiat. + + + + Nevermined creates a Stripe Checkout session and redirects the user to complete payment with their card. + + + + Stripe processes the charge. For recurring plans, Stripe manages subsequent billing automatically. + + + + Nevermined receives a webhook from Stripe confirming the successful payment. + + + + The corresponding credits are minted to the subscriber's account, and they can immediately start using the agent. + + + +Both one-time and recurring plan purchases are supported. For recurring plans, Stripe handles rebilling and Nevermined mints fresh credits each billing cycle. + +## Agent-to-Agent Purchase Flow + +Fully autonomous agent-to-agent payments in fiat are enabled through card delegation. This allows an agent to charge a user's card on-demand, without the user needing to pre-purchase credits. Instead of buying credits upfront, the user authorizes Nevermined to charge their card within defined limits. + + + + The user enrolls a Card as a payment method. The cards is registered through VGS (Very Good Security) to ensure PCI compliance, and a token is created that represents the card without exposing sensitive data. + + + + The user authorizes a card delegation through the Nevermined App, setting spending limits (max total spend, max transactions, expiration date). + + + + The user receives a delegation token that encodes their card authorization and spending limits. + + + + When the agent makes a request, it includes the delegation token using the `nvm:card-delegation` x402 scheme. The facilitator charges the delegated card off-session for each request. + + + + Stripe creates a PaymentIntent and charges the card without the user being present. The agent receives access to the requested resource. + + + + +Card delegation is what enables fiat-based agent-to-agent payments. An agent owner delegates their card, and the agent can autonomously pay for services from other agents -- all settled in fiat. + + +## Permission Model + +Card delegations enforce strict spending limits to protect the cardholder. Each delegation has three controls: + +| Limit | Description | +|-------|-------------| +| `spendingLimitCents` | Maximum total amount (in cents) that can be charged across all transactions | +| `maxTransactions` | Maximum number of individual charges allowed | +| `expiresAt` | Expiration date after which the delegation becomes invalid | + +A delegation moves through a simple lifecycle: + +| State | Meaning | +|-------|---------| +| **Active** | The delegation is valid and can be used for charges | +| **Exhausted** | The spending limit or transaction count has been reached | +| **Expired** | The expiration date has passed | +| **Revoked** | The cardholder manually revoked the delegation | + +Once a delegation leaves the **Active** state, a new one must be created to continue charging. + +## Security and PCI Compliance + +Card data never reaches Nevermined servers. All sensitive card information is tokenized through **VGS (Very Good Security)**, a PCI-compliant proxy, before it reaches the facilitator. Nevermined only stores Stripe tokens, never raw card numbers. + + +**Nevermined is PCI compliant** (PCI SAQ D level). VGS tokenizes card data in transit, and Stripe manages secure storage and charging. Your users' card data is protected by industry-standard security at every step. + + + +## Revenue Routing with Stripe Connect + +When a user pays with a card, Nevermined routes the revenue to the builder's connected Stripe account using Stripe Connect. Fees are deducted automatically before the payout reaches the builder. + +This means you receive funds directly in your Stripe account -- no manual transfers or reconciliation needed. + +## Fees and Settlement + +| Item | Cost | +|------|------| +| Nevermined fee | 2% of the transaction amount | +| Stripe processing fee | $0.50 + 4% per transaction | +| Settlement | Via Stripe PaymentIntents to builder's connected account | + + +Fiat payments carry higher fees than stablecoin payments (2% + Stripe fees vs. 1% flat). For high-volume or high-value use cases, consider [stablecoin payments](/docs/integrate/patterns/stablecoin-payments) to reduce costs. + + +## Supported Plan Types + + + + Prepaid credits purchased via Stripe Checkout. Credits are minted once payment confirms. + + + + Subscription access for a set duration. Stripe handles recurring billing automatically. + + + + Per-request charging via card delegation. No upfront purchase needed. + + + + Automatic rebilling at the end of each period. Stripe manages the billing cycle. + + + +## Next Steps + + + + Accept crypto payments with the lowest fees and on-chain transparency + + + + Full technical specification for the card delegation extension + + + + Configure credits, time-based, dynamic, and hybrid plans + + + + Create and manage payment plans in the Nevermined App + + diff --git a/docs/integrate/patterns/stablecoin-payments.mdx b/docs/integrate/patterns/stablecoin-payments.mdx new file mode 100644 index 0000000..e846723 --- /dev/null +++ b/docs/integrate/patterns/stablecoin-payments.mdx @@ -0,0 +1,154 @@ +--- +title: "Stablecoin Payments" +description: "Accept USDC, USDT, or any ERC-20 token on-chain with the lowest fees and full transparency." +icon: "coins" +--- + +Accept USDC, USDT, or any ERC-20 token directly on-chain. Stablecoin payments are Nevermined's native payment method, purpose-built for crypto users and autonomous agent-to-agent commerce. + +## When to Use Stablecoins + + + + Agents with wallets can purchase plans and pay per request autonomously, with no human in the loop. + + + + Users buy plans through the Nevermined App checkout page, paying with tokens from their connected wallet. + + + + Your audience already holds stablecoins and prefers on-chain payments over traditional card flows. + + + + Just 1% Nevermined fee with no additional processing surcharges. Ideal for high-volume or high-value use cases. + + + + Every payment settles on-chain, giving both parties a verifiable, auditable record of every transaction. + + + +## How It Works + + + + The subscriber funds their Nevermined smart account with ERC-20 tokens (USDC, USDT, or another supported token). This account is an ERC-4337 smart account that supports programmable permissions. + + + + The subscriber generates scoped session keys that grant the facilitator permission to execute specific actions (order plans, burn credits, redeem access) on their behalf. Each key follows the principle of least privilege. + + + + When the subscriber purchases a plan or makes a request, the facilitator submits a UserOperation to the smart contract. The payment settles on-chain and credits are minted to the subscriber. + + + + Each API call or agent query burns credits according to the plan configuration. If the subscriber's balance runs low, the system can auto-order more credits (if the wallet has sufficient balance and the session key permits it). + + + +## Supported Networks and Tokens + +Payments settle on the **Base** network. The most common tokens are: + +| Token | Description | +|-------|-------------| +| USDC | USD-pegged stablecoin by Circle | +| USDT | USD-pegged stablecoin by Tether | + + +Nevermined supports any ERC-20 token on Base. If you need to accept a custom token, you can specify its contract address when creating your plan's price configuration. + + +## Permission Model + +Session keys are the core of the stablecoin permission model. Instead of giving the facilitator full control over a wallet, subscribers create scoped keys that limit exactly what can be done. + +Each session key enforces the **principle of least privilege** through three limits: + +| Limit | Description | +|-------|-------------| +| `orderLimit` | Maximum token amount the key can spend on plan purchases | +| `redemptionLimit` | Maximum number of credit burn or redeem operations the key can perform | +| `expiresAt` | Expiration date after which the key becomes invalid | + +When any limit is reached, the session key stops working. The subscriber must generate a new one with fresh limits to continue. + + +Session keys are revocable at any time by the smart account owner. You always retain full control over your wallet. + + +## Fees and Settlement + +| Item | Cost | +|------|------| +| Nevermined fee | 1% of the plan price | +| Processing surcharge | None | +| Settlement | On-chain via Nevermined smart contracts on Base | + +Because there's no payment processor in the middle, stablecoin payments carry no additional fees beyond the 1% Nevermined fee. This makes them the most cost-effective option, especially for high-volume use cases. + +## Supported Plan Types + + + + Prepaid credits consumed per request. Set total credits and cost per request when creating the plan. + + + + Unlimited access for a set duration (days, months, years). Great for subscription-style access. + + + + Variable credit charges based on request complexity, token count, or custom metrics. + + + + Combine time-based access with credit limits for balanced monetization. + + + + Offer free credits or time-limited trials to let users test your agent before purchasing. + + + + Per-request settlement in USDC. No prepaid credits needed -- customers pay on demand. + + + +## Auto-Ordering + +When a subscriber's credit balance runs low, the system can automatically purchase more credits on their behalf. This happens seamlessly if: + +- The subscriber's wallet has sufficient token balance +- The active session key has remaining `orderLimit` capacity +- The plan supports re-ordering + +This keeps agent-to-agent workflows running without interruption. + + +If the session key's `orderLimit` or `redemptionLimit` is exhausted, auto-ordering stops. The subscriber must create a new session key with fresh limits to resume. + + +## Next Steps + + + + Accept credit cards via Stripe for mainstream and enterprise users + + + + Configure credits, time-based, dynamic, and hybrid plans + + + + Deep dive into the x402 protocol and smart account settlement + + + + Create and manage plans programmatically with the TypeScript SDK + + diff --git a/docs/solutions/agent-to-agent-monetization.mdx b/docs/solutions/agent-to-agent-monetization.mdx index bf44327..7f36c17 100644 --- a/docs/solutions/agent-to-agent-monetization.mdx +++ b/docs/solutions/agent-to-agent-monetization.mdx @@ -13,6 +13,20 @@ Nevermined enables AI builders to protect and monetize their agents using the x4 - **Agents Pay, Then Use**: Other agents order your plan, obtain access tokens, and call your agent’s endpoints with bearer authentication. - **Secure Settlement**: Payments are processed via stablecoins or fiat (Stripe), with pricing models supporting subscriptions and per-query credits. +## Payment Methods + +Nevermined supports two payment methods for agent monetization: + + + + Accept credit cards via Stripe. Users can purchase plans directly, or delegate their card for autonomous agent-to-agent payments. + + + + Accept USDC or other ERC-20 tokens on-chain. The native method for agent-to-agent commerce with the lowest fees (1%). + + + ## Benefits - **Simple setup**: Create a plan, link your agent—done. From 5bee7e895590cb4749d2751067aa4bb67b592591 Mon Sep 17 00:00:00 2001 From: Aitor <1726644+aaitor@users.noreply.github.com> Date: Fri, 20 Feb 2026 15:06:49 +0100 Subject: [PATCH 2/2] Update docs/integrate/patterns/fiat-payments.mdx Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> --- docs/integrate/patterns/fiat-payments.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/integrate/patterns/fiat-payments.mdx b/docs/integrate/patterns/fiat-payments.mdx index 85e5c55..91860dd 100644 --- a/docs/integrate/patterns/fiat-payments.mdx +++ b/docs/integrate/patterns/fiat-payments.mdx @@ -81,7 +81,7 @@ Fully autonomous agent-to-agent payments in fiat are enabled through card delega - The user enrolls a Card as a payment method. The cards is registered through VGS (Very Good Security) to ensure PCI compliance, and a token is created that represents the card without exposing sensitive data. + The user enrolls a Card as a payment method. The card is registered through VGS (Very Good Security) to ensure PCI compliance, and a token is created that represents the card without exposing sensitive data.