Nuevo Billing

Added Stripe test teams for trying payments on the live site

Website admins can make a team a Stripe test team on /admin/stripe-test-teams. Its plan, Store, Supporters, paid Forms, invoice payments and connected account then use Stripe's test keys and move no money.

A website admin can make a team a Stripe test team on Admin › Stripe test teams. Every Stripe call Magpie makes for that team uses Stripe's test keys: its own Pro or Team plan, its Store, Supporters, paid Forms, invoice card payments and connecting its Stripe account. Nothing moves money and Stripe's test cards work. Every other team keeps using the live keys.

A team is made a test team before it has anything in Stripe, and stays one while it has a customer, a subscription or a connected account there. The team's Plan and billing and Payments pages say that Stripe is in test mode, and offer codes cannot be used on a test team.

The server needs the STRIPE_TEST_* settings; tools/stripe/setup-test-mode.php makes the test prices, portals and webhook endpoints with the Stripe CLI and prints them.