ShaBaas Pay MCP Server

Created By
ShaBaas Pay2 months ago
Remote MCP server for initiating and managing real time payment workflows using ShaBaas Pay. Developers can create payment agreements, initiate payments and automate settlement workflows through AI agents using the Model Context Protocol.
Overview

ShaBaas AI hero

ShaBaas AI

This repo is the one-stop shop for building AI-powered products and workflows on top of ShaBaasPay.

It contains SDKs and integration assets to connect ShaBaasPay with LLMs and agent frameworks, including:

  • @shabaaspay/agent-toolkit - for integrating ShaBaasPay APIs with popular agent frameworks through function calling (TypeScript).
  • API artifacts: MCP contract under openapi/, public REST spec for ReadMe under restapi/.

Model Context Protocol (MCP)

ShaBaasPay supports MCP integrations for agent clients.

Remote MCP endpoints:

  • Staging: https://mcp-staging.shabaas.com/mcp
  • Production: https://mcp.shabaas.com/mcp

Local toolkit and MCP examples are available below and in tools/typescript/packages/agent-toolkit/README.md.

Agent Toolkit

ShaBaasPay's Agent Toolkit enables frameworks such as LangChain and Vercel's AI SDK to call ShaBaasPay APIs through function-calling tools.

Installation

You don't need this source code unless you want to modify the package. If you just want to use the package run:

npm install @shabaaspay/agent-toolkit

Requirements

  • Node 22+

Usage

The library needs to be configured with your account's API key, available in the ShaBaas Developer Dashboard. We strongly recommend using a restricted API key for better security and granular permissions. Tool availability is determined by the permissions configured for that key.

import { ShabaasAgentToolkit } from '@shabaaspay/agent-toolkit';

const toolkit = new ShabaasAgentToolkit({
  apiKey: process.env.SHABAAS_API_KEY!,
  environment: 'sandbox'
});

Tools

The toolkit works with LangChain and Vercel's AI SDK and can be passed as a list/map of tools.

const tools = toolkit.getTools();
const getAuthTokenTool = tools.find((t) => t.name === 'get_auth_token');

const result = await getAuthTokenTool?.execute({
  include_token_in_response: false
});

Context

In some cases you may want to set defaults shared across calls. Currently, the toolkit supports environment-level defaults through toolkit initialization.

const toolkit = new ShabaasAgentToolkit({
  apiKey: process.env.SHABAAS_API_KEY!,
  environment: 'sandbox'
});

LangChain

import { ShabaasAgentToolkitLangChain } from '@shabaaspay/agent-toolkit/langchain';

const toolkit = new ShabaasAgentToolkitLangChain({
  apiKey: process.env.SHABAAS_API_KEY!,
  environment: 'sandbox'
});

const tools = await toolkit.getLangChainTools();

Vercel AI SDK

import { ShabaasAgentToolkitAiSdk } from '@shabaaspay/agent-toolkit/ai-sdk';
import { generateText } from 'ai';

const toolkit = new ShabaasAgentToolkitAiSdk({
  apiKey: process.env.SHABAAS_API_KEY!,
  environment: 'sandbox'
});

const tools = await toolkit.getAiSdkTools();

const response = await generateText({
  model: yourModel,
  tools,
  prompt: 'Retrieve details for payment agreement pa_123'
});

Model Context Protocol (Toolkit)

import { StdioMcpServer, HttpMcpServer } from '@shabaaspay/agent-toolkit/modelcontextprotocol';
import { StdioServerTransport } from '@modelcontextprotocol/sdk/server/stdio.js';

const server = new StdioMcpServer({
  apiKey: process.env.SHABAAS_API_KEY!,
  environment: 'sandbox'
});

await server.connect(new StdioServerTransport());

Troubleshooting

  • Missing SHABAAS_API_KEY: set your API key before running examples.
    • export SHABAAS_API_KEY=your_key
  • LangChain adapter requires @langchain/core:
    • npm install @langchain/core
  • AI SDK adapter requires the "ai" package:
    • npm install ai
  • Cannot find module '@shabaaspay/agent-toolkit/*' in local development:
    • run npm install and npm run build from tools/typescript.

Quick Start (Repository)

cd tools/typescript
npm install
npm run build

OpenAPI

  • OpenAPI
  • Includes MCP OpenAPI coverage for the toolkit tools: auth, payment agreement (create/get), and payment initiation (create/get).

REST API

  • RestAPI
  • Includes REST OpenAPI coverage for auth, agreements, initiations, webhooks, PayID collections, and invoice endpoints.

Server Config

{
  "mcpServers": {
    "shabaaspay": {
      "url": "https://mcp-staging.shabaas.com/mcp",
      "transport": "http",
      "headers": {
        "Authorization": "<YOUR_API_KEY>"
      }
    }
  }
}
Project Info
Created At
2 months ago
Updated At
a month ago
Author Name
ShaBaas Pay
Star
-
Language
-
License
-
Category

Recommend Servers

View All
Bring your real authenticated browser session to AI coding agents. Local-first MCP server + Chrome MV3 extension. No cloud. No telemetry.
@Cubenest

peek records the user's actual logged-in browser (DOM via rrweb, console events, network metadata, optional response bodies via opt-in Deep capture) through a Chrome MV3 extension. The extension ships events through a native-messaging stdio bridge to a local MCP server (peek-mcp), which persists them to a SQLite database at ~/.peek/sessions.db. AI coding agents (Claude Code, Cursor, Cline, Windsurf) read sessions from the database via 10 MCP tools: Tool What it does list_recent_sessions List recently recorded sessions (id, origin, ts, event count). get_session_summary LLM-readable narrative summary of a session. get_session_console_errors Console errors recorded in a session. get_session_network_errors Failed/notable network requests in a session. get_user_action_before_error Last N user actions before a console error. generate_playwright_repro Generate a runnable Playwright test from a session. get_dom_snapshot Reconstruct the DOM at a given timestamp. query_dom_history Timeline of attribute/text changes for a selector. request_authorization Side-panel consent for write actions (Level 3). execute_action Dispatch a UI action (gated by permission level + destructive blocklist). Why local-first matters Every other "browser session for AI" tool ships to a vendor cloud. peek's SQLite + extension live on the user's machine — no remote endpoints, no telemetry. The privacy policy (docs/peek/PRIVACY_POLICY.md) is the source of truth. Install # 1. Add the MCP server to Claude Code claude mcp add peek -- npx -y @peekdev/mcp # 2. Install the Chrome extension from the Chrome Web Store # (link added once the CWS listing is approved)

a day ago