Nevermined can be used in a variety of ways to enable AI-native payment infrastructure and to track the usage of your AI agents. On this page, we show some examples of how to integrate Nevermined with AI agents.
All examples are created for educational purposes and focus on the integration, not on the use case or the AI model itself.
If you just want to see all the examples in action, you can check the Examples page or go directly to the GitHub repositories.

Basic example: Finance Agent

The “Finance Agent” is a simple AI agent that answers financial queries—such as balances or recent activity—and demonstrates the following concepts:
  • Simplicity - how easy it is to integrate the Nevermined Payments Library with an AI agent and monetize it.
  • Accept fiat payments - the agent can be accessed by users who have purchased access using fiat (USD).
  • Access control - the agent validates that only subscribed users can query it.
  • Licensing - subscribers get credits that are redeemed when they use the agent.
  • TypeScript - the agent is implemented using TypeScript.
  • Observability - LLM usage is tracked and logged using Nevermined Observability.

Finance Agent Steps:
  1. The user opens the Finance App and requests information.
  2. The system checks for a subscription; if none, the user is sent to checkout.
  3. The user pays by card and receives credits. Use the test card 4242 4242 4242 4242 with any future date and CVC.
  4. The user returns to the Finance App.
  5. Credits are verified and the request is sent to the Finance Agent.
  6. The agent validates with NVM, processes the request, and redeems credits.
  7. The response is delivered to the user.
The full code for this example is available in the GitHub repository.

MCP Integration: Weather Agent

The “Weather Agent” is a simple AI agent connected through the Model Context Protocol (MCP) to deliver real-time weather updates and forecasts, illustrating seamless pay-per-query access and demonstrating the following concepts:
  • MCP - how Nevermined can be integrated with AI agents using the Model Context Protocol (MCP).
  • Accept fiat payments - the MCP agent can be accessed by users who have purchased access using fiat (USD).
  • Access control - the agent validates that only subscribed users can query it.
  • Licensing - subscribers get credits that are redeemed when they use the agent.
  • TypeScript & Python - the agent is implemented in TypeScript and Python.
  • Observability - LLM usage is tracked and logged using Nevermined Observability.

Weather Agent Steps:
  1. The user opens the Weather App and requests a forecast for a specific location.
  2. The app verifies whether the user is a subscriber and, if not, redirects to checkout.
  3. The user pays by card and receives credits. Use the test card 4242 4242 4242 4242 with any future date and CVC.
  4. The user returns to the Weather App.
  5. The app confirms credits and forwards the prompt to the Weather MCP.
  6. The MCP validates the request with NVM, processes it, and redeems credits.
  7. The forecast is returned to the user.
The full code for this example is available in the GitHub repository.