PaymentSetu UPI payment plugin for aMember Pro 6.x
Version 1.0.0 (29 Nov 2026)   https://paymentsetu.com/amember-plugin

Your customers pay with any UPI app (Google Pay, PhonePe, Paytm, BHIM) on the
PaymentSetu payment page. The money goes straight into your own UPI merchant
account. PaymentSetu checks the payment and tells aMember, which then marks the
invoice paid and gives the member access.

INSTALL
1. Upload the file
      application/default/plugins/payment/paymentsetu.php
   into the same folder of your aMember install, for example
      public_html/amember/application/default/plugins/payment/paymentsetu.php
2. aMember admin: Configuration > Setup/Configuration > Plugins.
   Tick "paymentsetu" under Payment Plugins and save.
3. Open the new "PaymentSetu (UPI)" tab, paste your PaymentSetu API key and save.
   The page shows your Webhook URL, like
      https://yoursite.com/amember/payment/paymentsetu/ipn
4. PaymentSetu dashboard: API Keys & Webhooks. Put that Webhook URL on the same
   API key.
5. Make sure your products are priced in INR.

HOW PAYMENTS ARE CONFIRMED
- Webhook: PaymentSetu calls the Webhook URL (signed with your API key) as soon
  as the payment is verified.
- Return: when the buyer comes back to your site, the plugin asks PaymentSetu
  for the order status, so access starts at once.
- Hourly check: unpaid invoices of the last 3 days are checked once an hour, in
  case a webhook was missed (needs the normal aMember cron).

NOTES
- One-time payments only; the plugin is hidden for recurring products.
- Amount Rs 1 to Rs 1,00,000 per invoice.
- Using one API key on more than one website? Set a different "Order ID prefix"
  on each site.
- Help: support@paymentsetu.com
