Cashfree Payment Gateway - Payment Links

Create, share, and reconcile Cashfree hosted payment links via REST APIs and webhooks.

Updated Sep 8, 2026
One-click install
npx skills add https://github.com/dasara-varun/orange --skill cashfree-payment-gateway-payment-links-dasara-varun
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: Cashfree Payment Gateway - Payment Links
Source: https://github.com/dasara-varun/orange/tree/main/.cursor/cashfree-skills/pg/payment-links
Command: npx skills add https://github.com/dasara-varun/orange --skill cashfree-payment-gateway-payment-links-dasara-varun

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve? Merchants often need to collect payments without building an integrated checkout — for invoices, rent, tuition, B2B collections, or freelance work. This Skill guides developers through creating Cashfree hosted payment links, sharing them via SMS, email, WhatsApp, or QR code, and tracking payment status programmatically. ## Core Features & Use Cases - Link Lifecycle Management: Create, fetch, and cancel payment links via POST /pg/links, GET /pg/links/{link_id}, and the cancel endpoint, with support for expiry times, auto-reminders, and SMS/email notifications. - Partial Payments & Reconciliation: Enable installment collection with link_partial_payments, list underlying PG orders with ?status=ALL, and refund individual orders through the refunds API. - Webhook Handling: Process PAYMENT_LINK_EVENT webhooks with correct payload parsing (flat data fields, null order on CANCELLED/EXPIRED) and dedupe on (cf_link_id, link_status, link_amount_paid). - Use Case: A freelancer generates a link for invoice 4402 with a 30-day expiry and auto-reminders, shares the link_url over WhatsApp, and closes the invoice in their accounting system when the webhook reports link_status: "PAID". ## Quick Start Ask the AI to create a Cashfree payment link for a 5000 INR invoice with SMS notification and wire up the PAYMENT_LINK_EVENT webhook handler.

Frequently Asked Questions about Cashfree Payment Gateway - Payment Links

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I create a Cashfree payment link via API?▼

Send a POST request to /pg/links with link_amount, link_currency, link_purpose, and customer_details.customer_phone, authenticated with x-client-id and x-client-secret headers. The response returns a link_url you can share with the customer, plus a base64 QR code.

How do I handle the PAYMENT_LINK_EVENT webhook?▼

Verify the HMAC signature using the raw body and x-webhook-timestamp header, then read link fields flat under data — there is no data.link wrapper. Dedupe on (cf_link_id, link_status, link_amount_paid) since delivery is at-least-once, and note that data.order is null for CANCELLED and EXPIRED transitions.

Can Cashfree payment links accept partial payments?▼

Yes, set link_partial_payments to true and optionally link_minimum_partial_amount. Each installment creates a separate PG order, and the link status moves from PARTIALLY_PAID to PAID once link_amount_paid equals link_amount.

How do I refund a payment made through a payment link?▼

Refund the underlying PG order, not the link itself. Call GET /pg/links/{link_id}/orders?status=ALL to find paid order_ids, then POST to /pg/orders/{order_id}/refunds and listen for the REFUND_STATUS_WEBHOOK.

Why is my Cashfree payment link SMS not sending in sandbox?▼

SMS notifications are disabled in the Cashfree sandbox environment by design; only email notifications fire there. Test SMS delivery in production using a small link_amount and a disposable customer_phone number.

When should I use payment links instead of a Cashfree checkout integration?▼

Use payment links for one-off or ad-hoc collections like invoices, rent, or freelance fees where building a checkout is overkill. For high-volume integrated website or app checkouts, use the core PG APIs and SDKs; for recurring billing, use subscriptions instead.