Skip to the content
Documentation
Help Start
Reading in:
  • German: 9,199 of 9,199 pages
About the help in other languages
All help pages

Payments

Owner decisions: card through Stripe (with Apple Pay and Google Pay), PayPal, crypto on the TRON network; no invoice and no bank transfer. The buyer is charged in the seller's currency; the provider converts. Every…

Download as PDF

Address: https://doc.exponential.earth/exphelp/viewer/ext/exp_app_market/PAYMENTS.md

On this page

Payments

Owner decisions: card through Stripe (with Apple Pay and Google Pay), PayPal, crypto on the TRON network; no invoice and no bank transfer. The buyer is charged in the seller's currency; the provider converts. Every provider runs a hosted payment page, so no card or wallet data ever reaches the store.

Stripe

  • Checkout Sessions (mode=payment or mode=subscription with subscription_data.trial_period_days); Apple Pay and Google Pay come with Checkout. The return URL carries session_id.
  • Confirmation reads the session with payment_intent.latest_charge.balance_transaction expanded: the real fee.
  • Webhooks: checkout.session.completed (paid), invoice.paid with billing_reason=subscription_cycle (renewed), customer.subscription.deleted (ended), charge.refunded. Stripe-Signature is checked (HMAC-SHA256 of <t>.<body>, 300 s tolerance).
  • Refunds: POST /v1/refunds on the payment intent. Cancelling sets cancel_at_period_end.
  • Seller payouts: Connect transfers to the seller's acct_ account.

PayPal

  • One-time: Orders v2 (intent=CAPTURE), approve on PayPal, capture on return; the fee from seller_receivable_breakdown.paypal_fee.
  • Subscriptions: a product and a plan per app and price (idempotent request ids), then a subscription; renewals by PAYMENT.SALE.COMPLETED.
  • Webhooks are verified by PayPal (/v1/notifications/verify-webhook-signature with [Provider_paypal] WebhookID).
  • Refunds of a capture (or a subscription's sale); seller payouts with Payouts to the seller's PayPal e-mail.

Crypto on TRON

  • TRC-20 stablecoin (USDT by default) to the store's receiving address; the store only watches it through TronGrid, no wallet key is on the server.
  • The amount is the price converted (Rate[<currency>], USD per unit; USD = 1 for USDT) plus purchase id mod 1000 in the coin's smallest unit, so a transfer identifies its purchase. The payment page asks the chain every 15 s; the daily run checks open payments too.
  • The sending address is kept: a refund goes back to it, in the same coin, for the amount paid (owner decision). The operator sends it from the store wallet and records the transaction (refund-sent), which is checked on the chain.
  • No auto-renewal: a reminder with a payment link before the period ends. Free trials need a renewing method.
  • Note: the existing extension called tron is Exponential's MCP layer and has no crypto features; the TRON-network payment provider lives here (expAppMarketTronPay).

Test mode and the local sandbox

Until launch every provider runs with Mode=test: Stripe test keys (sk_test_), the PayPal sandbox, the TRON Nile testnet. tests/sandbox/provider-sandbox.php is a local simulator of the three APIs for end-to-end tests on a throwaway store (doc/TESTING.md); it accepts only test keys and plays the buyer on the hosted pages.

Something wrong on this page? Report an error

Documentation license

This page is part of the documentation of the extension exp_app_market and is distributed under the license of that extension.