Skip to main content
Glama
lakshitha0526

PayHere MCP Server

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
PAYHERE_MODEYessandbox or live
PAYHERE_APP_IDYesFrom Settings → Business Apps
PAYHERE_APP_SECRETYesApp secret paired with PAYHERE_APP_ID
PAYHERE_MERCHANT_IDYesFrom PayHere dashboard → Settings → Integrations
PAYHERE_MERCHANT_SECRETYesDomain-specific secret

Instructions

Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.

This server publishes no instructions, or was last inspected before Glama recorded them.

Capabilities

Features and capabilities supported by this server

Protocol revision2025-11-25

CapabilityDetails
tools
{
  "listChanged": true
}

Tools

Functions exposed to the LLM to take actions

NameDescription
create_checkout_payloadA

Generates the form data needed to POST a checkout request to PayHere, including the MD5 hash. Returns action URL, form fields, and an HTML snippet.

get_paymentA

Returns all payment attempts (success, refunded, chargedback) associated with the given order_id. PayHere does not support listing by date range or status — only by order_id.

issue_refundA

Refunds a payment by payment_id. Omit amount for a full refund, or set it for a partial refund. Returns the PayHere refund status.

generate_signatureA

Computes a PayHere MD5 hash for either checkout submission (mode='checkout') or notify URL validation (mode='notify'). For notify mode, pass expectedMd5Sig to verify an incoming signature in one shot. Uses the merchant secret from the server's environment — never include the secret in tool arguments.

verify_credentialsA

Health check that confirms env vars are loaded and (once implemented) that the App credentials can fetch an OAuth token. Useful first call when setting up an integration.

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

TDQS

A4.2/5.0

Scored across 5 tools

Disambiguation5/5

Each tool serves a distinct purpose: creating checkout payloads, generating signatures, retrieving payments by order ID, issuing refunds, and verifying credentials. No overlapping responsibilities.

Naming Consistency5/5

All tool names follow a consistent verb_noun pattern in snake_case (e.g., create_checkout_payload, issue_refund), making the API predictable and easy to navigate.

Tool Count5/5

With 5 tools covering checkout creation, signature generation, payment retrieval, refunds, and credential verification, the number is well-scoped for a payment gateway integration without unnecessary clutter.

Completeness4/5

Covers essential payment operations: creating checkouts, refunding, retrieving payment status by order ID, and signature validation. Missing list payments endpoint aligns with PayHere's API limitations, but a tool for direct payment retrieval by payment_id would enhance completeness.

Maintenance

ActivityInactive
ResponsivenessNo issues