- Affected version
- 2.1.10
Hello , we are trying to enable stripe to handle recurring payments on our forum but seems Xenforo implementation of stripe subscriptions is broken .
and charges one-off payment instead of charging the fake trial subscription which is left with no attached payment method and cannot be charged for future payments.
The recurring payment integration looks like a scam and completely done in the wrong way
- Xenforo creates customer before getting card token .. resulting in customer with no attached payment method .. it doesn't try to update the customer and attach payment method .
- Xenforo creates a fake trial subscription that ends by subscription end date.
$subscription = \Stripe\Subscription::create([
'customer' => $customer->id,
'items' => [
['plan' => $plan->id]
],
'trial_end' => strtotime("+ {$purchase->lengthAmount} {$purchase->lengthUnit}"),
'metadata' => $this->getTransactionMetadata($purchase)
]);
and charges one-off payment instead of charging the fake trial subscription which is left with no attached payment method and cannot be charged for future payments.
"object": "subscription",
"application_fee_percent": null,
"billing": "charge_automatically",
"billing_cycle_anchor": 1627926814,
"billing_thresholds": null,
"cancel_at": null,
"cancel_at_period_end": false,
"canceled_at": null,
"collection_method": "charge_automatically",
"created": 1596390814,
"current_period_end": 1627926814,
"current_period_start": 1596390814,
"customer": "cus_HlHxfROc90hpUo",
"days_until_due": null,
"default_payment_method": null,
"default_source": null,
"default_tax_rates": [
],
The recurring payment integration looks like a scam and completely done in the wrong way