BACK TO DIRECTORY

Donation Router for GiveWP & PayPal – Route Donations by Donor Country

by Al Amin Ahamed

0.0
(0 ratings)

Donation Router for GiveWP & PayPal extends the GiveWP PayPal Donations gateway so that a single WordPress installation can accept donations through several PayPal Business accounts, automatically routing each transaction to the correct account based on the donor’s declared country.

This plugin is an independent, third-party extension. It is not affiliated with, endorsed by, or sponsored by GiveWP (StellarWP) or PayPal. The names “GiveWP” and “PayPal” appear here solely to describe compatibility with those products.

You need at least two PayPal Business accounts and one GiveWP donation form per country for this plugin to do anything. With a single PayPal account there is nothing to route, and GiveWP’s own PayPal Donations setup already covers you.

This plugin is designed for organisations that operate two or more legally distinct charity entities — for example a US 501(c)(3) and a Canadian CRA-registered charity — that share a single donation website but must process payments through separate PayPal accounts and issue separate tax receipts.

Key features:

  • Multi-account admin panel — Add and manage any number of PayPal Business accounts under Donation Forms PayPal Accounts. Each account stores legal entity details (name, tax ID, address, country) alongside AES-256-GCM encrypted API credentials.
  • Country routing rules — Define which PayPal account and GiveWP form handles donations from each country. One active rule per country, fully configurable from the admin.
  • Country selector popup — A donor-facing modal popup (shortcode [ador_country_selector]) asks donors to identify their country before proceeding to checkout. Selection is stored in sessionStorage to avoid repeated prompts.
  • Runtime credential routing — The plugin intercepts GiveWP’s IoC container at payment time, substituting the correct PayPal credentials transparently. No GiveWP core files are modified.
  • Per-account webhook handling — Each PayPal account receives its own webhook endpoint (/wp-json/ador/v1/webhook/{account_id}) with independent HMAC signature verification.
  • Per-entity email tags — Seven GiveWP email template tags populate receipt emails with the correct legal entity name, address, tax ID, tax-deductibility statement, and a unique per-entity receipt number.
  • PDF receipts — Optional on-demand PDF receipt download on the GiveWP success page, generated by dompdf.
  • Connect with PayPal — Onboard any number of PayPal Business accounts through GiveWP’s own approved-partner flow. No separate PayPal app to configure, and no pasting client secrets by hand.
  • Import GiveWP’s existing account — One click adopts the PayPal account GiveWP is already connected to, reusing its stored credentials, so it becomes routable and receipt-customisable without a second OAuth.
  • Live and sandbox side by side — Every account carries an environment. Routing only applies an account whose environment matches GiveWP’s current mode, so a sandbox account can never take a live donation.
  • Setup readiness panel — The Accounts screen reports whether donations are actually routing: missing rules, accounts in the wrong environment, rules pointing at deactivated accounts or unpublished forms, missing webhooks, and donations that bypassed routing. It collapses to a single line once nothing needs attention.
  • Per-account webhook registration — Register each account’s webhook and its event subscriptions at PayPal from the admin, using that account’s own credentials.
  • Security-first design — AES-256-GCM credential storage, nonce protection, capability checks, webhook signature verification, and $wpdb->prepare() throughout.

How it works

  1. A donor lands on your donation page and the country selector asks which country they are giving from. Their answer is remembered for the rest of the visit.
  2. The plugin looks up the routing rule for that country to find the donation form and the PayPal Business account that should receive the gift.
  3. When the donor pays, the correct account’s credentials are substituted into GiveWP’s PayPal gateway for that request only. PayPal charges the right legal entity — nothing is transferred between accounts afterwards.
  4. The donation records which account processed it and which country the donor selected.
  5. PayPal notifies the site on that account’s own webhook endpoint, and the capture, denial or refund is recorded against the donation.
  6. The receipt email renders that entity’s registered name, address, tax ID, tax-deductibility statement and its own receipt number.

If a country has no routing rule, nothing breaks: the donation proceeds through GiveWP’s default PayPal account, and the readiness panel reports that it happened.

More from us

Other free plugins by the same author, all on WordPress.org.

For any site

  • Swift Menu Duplicator – Duplicate menus in one click, snapshot revisions, export and import, WP-CLI and REST.
  • Author Profile Blocks – Author and team profiles as Gutenberg blocks — grid, carousel, list and single.

For the WordPress AI Client

External services

This plugin sends data to PayPal’s REST API to authenticate with PayPal Business accounts and to verify the HMAC-SHA256 signatures of inbound webhook events.

PayPal REST API (https://api-m.paypal.com, https://api-m.sandbox.paypal.com, https://api.paypal.com, https://api.sandbox.paypal.com)

  • What is sent: PayPal Client ID and Client Secret (decrypted in memory at request time, never stored in plaintext) are exchanged for OAuth 2.0 bearer tokens during donation checkout. Webhook event payloads are forwarded to PayPal’s /v1/notifications/verify-webhook-signature endpoint for signature verification.
  • When it is sent: Only when a donation is being processed through a PayPal Business account configured in this plugin, or when PayPal sends a webhook event to this site.
  • Service terms: PayPal User Agreement | PayPal Privacy Statement

Screenshots

PayPal accounts — every configured PayPal Business account with its legal entity, mode, and Active/Inactive status, plus per-row Edit, Deactivate and Delete actions.

PayPal accounts — every configured PayPal Business account with its legal entity, mode, and Active/Inactive status, plus per-row Edit, Deactivate and Delete actions.

Connect an account — the Connect with PayPal onboarding flow, which saves each connected Business account as its own managed account rather than overwriting a single global one.

Connect an account — the Connect with PayPal onboarding flow, which saves each connected Business account as its own managed account rather than overwriting a single global one.

Country routing — the rules mapping each donor country to the donation form and PayPal account that should receive it. One active rule per country.

Country routing — the rules mapping each donor country to the donation form and PayPal account that should receive it. One active rule per country.

Webhook setup — the unique per-account webhook URL to register in PayPal, with one-click copy and the list of event types to subscribe to.

Webhook setup — the unique per-account webhook URL to register in PayPal, with one-click copy and the list of event types to subscribe to.

Choose your country — the donor-facing modal (shortcode [ador_country_selector]), naming the legal entity that will receive the gift and its tax treatment.

Choose your country — the donor-facing modal (shortcode [ador_country_selector]), naming the legal entity that will receive the gift and its tax treatment.

Plugin settings — the country selector popup, geolocation provider, PDF receipts, and the legal-review acknowledgement.

Plugin settings — the country selector popup, geolocation provider, PDF receipts, and the legal-review acknowledgement.

Receipts and legal details — per-account legal entity details and the tax-deductibility statement editor, with the email tags that resolve to this account's name, tax ID, address and receipt number.

Receipts and legal details — per-account legal entity details and the tax-deductibility statement editor, with the email tags that resolve to this account's name, tax ID, address and receipt number.

Plugin Details

Active Installs
0
Total Downloads
360
Version
1.2.0
Requires WP
6.4
Requires PHP
8.1
Tested Up To
7.0.4
Added
2026-05-19
Last Updated
2026-08-17 8:08am GMT

Ratings

5
0
4
0
3
0
2
0
1
0