Skip to main content
Yuno’s Agent Toolkit enables AI agents to interact with Yuno’s payment orchestration platform through function calling. Built for TypeScript, it connects to Yuno’s remote MCP server and exposes payment tools that work across five AI frameworks — use one integration to access 300+ payment providers globally.

Overview

The Yuno Agent Toolkit is available as an npm package (@yuno-payments/agent-toolkit) and provides:
  • Framework Integrations — Vercel AI SDK, Google Genkit, LangChain, OpenAI Chat, and OpenAI Agents SDK. Import only the adapter you need.
  • Multi-provider Orchestration — Access 300+ payment providers globally through a single integration. Your AI agent inherits Yuno’s smart routing, multi-provider failover, and market-specific payment methods.
  • Type-Safe — Full TypeScript with comprehensive types and Zod-validated schemas.
  • Modular — Import only the tool categories you need (customers, payments, subscriptions, etc.) and filter actions granularly.

Quick Start

Installation

npm install @yuno-payments/agent-toolkit

Requirements

  • Node.js: Version 18 or higher.
  • Yuno Account: A Yuno account with API credentials.

Credentials

Get your API credentials from the Yuno Dashboard and set them as environment variables:
YUNO_ACCOUNT_CODE=your_account_code
YUNO_PUBLIC_API_KEY=your_public_api_key
YUNO_PRIVATE_SECRET_KEY=your_private_secret_key

Supported AI Frameworks

The toolkit provides specialized adapters for major AI frameworks. Choose the one that fits your stack:
Import the adapter using @yuno-payments/agent-toolkit/ai-sdk.
import { generateText } from "ai";
import { openai } from "@ai-sdk/openai";
import { createYunoAgentToolkit } from "@yuno-payments/agent-toolkit/ai-sdk";

const toolkit = await createYunoAgentToolkit({
  accountCode: process.env.YUNO_ACCOUNT_CODE!,
  publicApiKey: process.env.YUNO_PUBLIC_API_KEY!,
  privateSecretKey: process.env.YUNO_PRIVATE_SECRET_KEY!,
});

const { text } = await generateText({
  model: openai("gpt-4o"),
  tools: toolkit.getTools(),
  prompt: "Create a customer named Maria Garcia with email maria@example.com",
});

await toolkit.close();

Configuration

Action Filtering

You can granularly control which tools are available to the agent:
const toolkit = await createYunoAgentToolkit({
  // ...credentials
  actions: {
    customers: { create: true, retrieve: true },
    payments: { retrieve: true, refund: true },
  },
});
To enable all available tools, you can use the ALL_TOOLS_ENABLED constant:
import { ALL_TOOLS_ENABLED } from "@yuno-payments/agent-toolkit/ai-sdk";

const toolkit = await createYunoAgentToolkit({
  // ...credentials
  actions: ALL_TOOLS_ENABLED,
});