Razorpay MCP server for AI agents

Live

API KEY

PAYMENTS

Accounting & Finance

Razorpay gives your agent payments for your business: create orders, payment links, and UPI QR codes, capture and refund payments, run invoices and subscriptions, handle disputes, and reconcile settlements.

  • Per-user credentials: each call uses the actual user's API key, never a shared bot.
  • Encrypted per-tenant vault: AES-256, resolved at request time, never in LLM context.
  • Scoped before every call: pre-call scope check, 90-day SIEM-exportable audit chain.
Razorpay
agent · Acme Q3
Run
Which settlements reached our bank account this week, and what were the fees?
S
razorpay_list_settlements
108ms
Payments agent
4 settlements reached your bank account this week, totaling ₹18,42,500 with ₹36,850 in fees and tax.
Sources: Razorpay settlements, 4 records
razorpay
4 settlements
18:29
Message Claude...

Tools your payments agent reaches for on Razorpay, scoped per user.

CALL ANY TOOL
83 tools for payments in Razorpay: create orders, payment links, and UPI QR codes, capture and refund payments, issue invoices, manage subscriptions and plans, contest or accept disputes, and reconcile settlements.
razorpay_accept_dispute
Accept dispute
Accept a dispute, which gives up the disputed amount to the customer. Returns the dispute with status lost. This cannot be undone. Use contest_dispute to fight the dispute instead.
Parameters
Name
Type
Required
Description
dispute_id
string
Required
ID of the dispute to accept. Example: disp_AHfqOvkldwsbqt.
razorpay_add_virtual_account_receiver
Add virtual account receiver
razorpay_cancel_invoice
Cancel invoice
razorpay_cancel_subscription_pending_update
Update cancel subscription pending
razorpay_close_virtual_account
Close virtual account
razorpay_create_customer
Create customer
razorpay_create_order
Create order
razorpay_create_qr_code
Create qr code
razorpay_create_subscription_addon
Create subscription addon
razorpay_delete_invoice
Delete invoice
razorpay_get_customer
Get customer
razorpay_get_instant_settlement
Get instant settlement
razorpay_get_order
Get order
razorpay_get_payment_link
Get payment link
razorpay_get_qr_code
Get qr code
razorpay_get_settlement_recon
Get settlement recon
razorpay_get_subscription_pending_update
Update get subscription pending
razorpay_list_customers
List customers
razorpay_list_instant_settlements
List instant settlements
razorpay_list_order_payments
List order payments
razorpay_list_payment_refunds
List payment refunds
razorpay_list_plans
List plans
razorpay_list_qr_codes
List qr codes
razorpay_list_subscription_addons
List subscription addons
razorpay_list_transfer_reversals
List transfer reversals
razorpay_pause_subscription
Pause subscription
razorpay_send_invoice_notification
Send invoice notification
razorpay_update_invoice
Update invoice
razorpay_update_payment
Update payment
razorpay_update_subscription
Update subscription

For more tools, view docs.

Build your Agent
Same auth pattern across LangChain, OpenAI, Anthropic, and Google ADK.
Python · LlamaIndex
import { ScalekitClient } from "@scalekit-sdk/node";
import { createReactAgent } from "@langchain/langgraph/prebuilt";

const sk = new ScalekitClient(env.SCALEKIT_ENV_URL, env.SCALEKIT_CLIENT_ID, env.SCALEKIT_CLIENT_SECRET);

// Razorpay tools scoped to this user
const { tools } = await sk.tools.listScopedTools("user_123", {
  filter: { connectionNames: ["razorpay"], toolNames: [
    "razorpay_create_payment_link",
    "razorpay_send_payment_link_notification",
    "razorpay_list_payments"] },
  pageSize: 100,
});

const agent = createReactAgent({ llm, tools });
await agent.invoke({ messages: [{ role: "user", content: "Create a ₹2,500 payment link for the workshop and email it to the customer" }] });
import OpenAI from "openai";
import { ScalekitClient } from "@scalekit-sdk/node";

const sk = new ScalekitClient(env.SCALEKIT_ENV_URL, env.SCALEKIT_CLIENT_ID, env.SCALEKIT_CLIENT_SECRET);
const openai = new OpenAI();

const { tools } = await sk.tools.listScopedTools("user_123", {
  filter: { connectionNames: ["razorpay"] }, pageSize: 100,
});

const res = await openai.chat.completions.create({
  model: "gpt-5",
  messages: [{ role: "user", content: "Create a ₹2,500 payment link for the workshop and email it to the customer" }],
  tools,
});

// Execute the tool call with the user's vaulted Razorpay API key
await sk.tools.executeTool(res.choices[0].message.tool_calls[0], "user_123");
import Anthropic from "@anthropic-ai/sdk";
import { ScalekitClient } from "@scalekit-sdk/node";

const sk = new ScalekitClient(env.SCALEKIT_ENV_URL, env.SCALEKIT_CLIENT_ID, env.SCALEKIT_CLIENT_SECRET);
const anthropic = new Anthropic();

const { tools } = await sk.tools.listScopedTools("user_123", {
  filter: { connectionNames: ["razorpay"] }, pageSize: 100,
});

const msg = await anthropic.messages.create({
  model: "claude-sonnet-5",
  max_tokens: 1024,
  messages: [{ role: "user", content: "Create a ₹2,500 payment link for the workshop and email it to the customer" }],
  tools,
});

// Tool call runs with the user's vaulted Razorpay API key
await sk.tools.executeTool(msg.content, "user_123");
import { Agent } from "@google/adk/agents";
import { ScalekitClient } from "@scalekit-sdk/node";

const sk = new ScalekitClient(env.SCALEKIT_ENV_URL, env.SCALEKIT_CLIENT_ID, env.SCALEKIT_CLIENT_SECRET);

const { tools } = await sk.tools.listScopedTools("user_123", {
  filter: { connectionNames: ["razorpay"] }, pageSize: 100,
});

const agent = new Agent({
  name: "payments_agent",
  model: "gemini-2.5-pro",
  instruction: "Razorpay tools scoped to this user",
  tools,
});

await agent.run("Create a ₹2,500 payment link for the workshop and email it to the customer");
Try these prompts
Copy any prompt into your agent. Each maps directly to a Razorpay tool. Click to copy, paste into your agent, done.
Payments
Copy the prompt
Copied
Create a ₹2,500 payment link for the workshop and send it to priya@example.com.
Copy the prompt
Copied
Refund ₹500 of this payment.
Copy the prompt
Copied
Capture this authorized payment.
Invoices and subscriptions
Copy the prompt
Copied
Create an invoice for Rahul Mehta for 3 consultation sessions.
Copy the prompt
Copied
Pause this subscription.
Copy the prompt
Copied
List subscriptions on the Pro Monthly plan.
Disputes and settlements
Copy the prompt
Copied
List open disputes and the date each one needs a response by.
Copy the prompt
Copied
Contest this dispute with the delivery proof document.
Copy the prompt
Copied
Show the settlement reconciliation for last month.
SEE HOW AUTH WORKS
Each user connects their own Razorpay API key once, and Scalekit sends it with every call. Keys stay vaulted, every call is scope checked, and every action is logged.
1
Authorize
Your user connects
Razorpay
once. We tie it to their identity and the meetings they approved — no shared bot account, no org-wide access
Who:
user ‘A’
when:
Once per user
access:
Limited to user
2
Store
Their
Razorpay
token lives in a vault scoped to them. User A's meetings are never reachable by an agent acting for user B, even on the same connection
vault:
encrypted
scope:
per-user
tokens:
auto-refreshed
3
Resolve
When your agent calls a
Razorpay
tool, we fetch the right token server-side. It never touches your agent, never appears in the LLM context, never shows up in your logs
speed:
~40ms
check:
before every call
seen by:
nobody
4
Audit
Every
Razorpay
tool call is logged — who triggered it, which meeting was fetched, what came back. 90 days of history, tied to the user who authorized it
history:
90 days
export:
SIEM-ready
logged:
every call
Test other agents
See the same per-user auth pattern across other accounting and finance connectors.
GTM and RevOps Teams
Revenue forecast commentary
Pulls open pipeline from Salesforce and HubSpot, calculates coverage against quota, flags at-risk stages, posts commentary to Slack, and logs every snapshot to Google Sheets.
GTM and RevOps Teams
CRM AI agent
Reads the Granola transcript after every call, extracts next steps and updates the HubSpot record, drafts the follow-up in Gmail, and confirms in Slack, all on the rep's own delegated OAuth.
Test other agents
See the same per-user auth pattern across other accounting and finance connectors.
GTM
Revenue forecast agent
Score pipeline coverage against quota across Salesforce and HubSpot, post forecast commentary to Slack, log snapshots to Sheets.
GTM
CRM AI agent
Turn each Granola call transcript into a HubSpot record update, a drafted Gmail follow-up, and a Slack recap.
Why Scalekit
Secure your agent's access. Connectors ship in minutes
01.
Shared tokens break per-user analytics
A shared Razorpay API key looks fine in a demo. In production every refund and payment link looks like one service account, and you cannot tell which user triggered it. Scalekit resolves the credential of the actual user who triggered the agent, never a shared bot.
// shared key
audit → bot_service_account

// scalekit
audit → user_abc ✓
02.
Authentication is not authorization
03.
Multi-tenancy is architectural
04.
Razorpay today. Ten connectors tomorrow.
“Our agents act across Salesforce, Gong, Google Drive, and more, on behalf of every customer. Scalekit behind the scenes meant we can keep adding tools without ever rebuilding how credentials or tool calling work.”
Venu Madhav Kattagoni
Head of Engineering / Von
FAQs
Frequently Asked Questions
Does the agent access Razorpay as the user or through a shared API key?
As the user. Each user connects their own Razorpay API key once, and Scalekit sends it with every call. Audit logs attribute every payment link, refund, and dispute response to that user, not a shared service account.
Where is the Razorpay API key stored?
In Scalekit's managed AES-256 token vault, namespaced per tenant. To rotate it, the user reconnects with a new API key. Revocation is a single dashboard action. Credentials never appear in prompts, logs, or LLM context.
Can I limit what the agent does in Razorpay?
Yes. Filter by tool name in listScopedTools to expose only what you want, for example the list and get tools without razorpay_accept_dispute, which gives up the disputed amount to the customer, or razorpay_delete_invoice, which permanently deletes a draft invoice. Scalekit also enforces scope checks before every API call.
What happens when a user revokes Razorpay access?
The connection is invalidated on the next tool call. Subsequent requests for that user fail closed with a clear error. Other users in the tenant remain unaffected. The event is logged for audit.
Does the agent support UPI payments?
Yes. razorpay_create_qr_code creates a UPI QR code customers scan to pay, razorpay_create_payment_link can create a UPI-only link, and razorpay_create_virtual_account creates a Smart Collect virtual bank account or UPI ID for a customer.
Start in your coding agent
Up and running in one command
Install the Scalekit skill in your editor of choice. Connector, auth, tools, prompt, all wired up
Claude Code REPL
/plugin marketplace add scalekit-inc/claude-code-authstack
/plugin install agentkit@scalekit-auth-stack
Cursor Code REPL
# ~/.cursor/mcp.json
{
""mcpServers"": {
""razorpay"": {
""url"": ""https://mcp.scalekit.com/razorpay"",
""headers"": { ""Authorization"": ""Bearer $SCALEKIT_TOKEN"" }
}
}
}
Codex Code REPL
# ~/.codex/config.toml
[mcp_servers.razorpay]
url = ""https://mcp.scalekit.com/razorpay""
auth_env = ""SCALEKIT_TOKEN""
Copilot Code REPL
# .vscode/mcp.json
{
""servers"": {
""razorpay"": {
""url"": ""https://mcp.scalekit.com/razorpay"",
""type"": ""http""
}
}
}