For general information about accepting payments in Planyo see
Q121: I'd like to accept credit card payments for the reservations.
Which Stripe integration should I choose?
Show
In Planyo we currently offer four Stripe integration methods.
In most cases you should use Stripe Checkout. Checkout uses a prebuilt Stripe-hosted payment page your customer is redirect
to for quick purchases. In addition to standard credit card transactions, Checkout also supports other payment methods, like giropay, eps or bancontact.
Checkout fully supports the new European SCA regulation.
Stripe Legacy is a predecessor of Checkout. This version doesn't support the new European SCA regulation which can affect your business if it is based in the European Economic Area or
you serve customers in the EEA.
Stripe Sofort is a real-time bank transfer payment method available for customers from Austria, Belgium, Germany, Italy, Netherlands and Spain.
Stripe PaymentIntent is an advanced integration method that allows collecting payments on your website. This method also supports the new European SCA regulation.
First, select
Stripe Checkout in the
Payment processing site option on the site settings page.
In the next field, enter your Stripe API secret key followed by slash, by your API publishable key, by another slash and webhook secret (see the Webhook section below). For example:
sk_live_BQokikJOvBiI2HlWgH4olfQ2 / pk_live_6pRNASCoBOKtIshFeQd4XMUh / whsec_Yq3Tc6fP4556XLdfgM9WHmjmo1r2
You can find the API credentials in your Stripe Dashboard, in the
API section:
In the place of a secret key (sk_live_...) you can also use a restricted key (rk_live_...) which you can create in your
Stripe Dashboard. Using a restricted key allows you to limit access to certain areas of your account data for greater security.
Note that the restricted key needs to have the
Write permission for
All Checkout resources and
Charges.
For test transactions, you should enter the test API secret and publishable keys. Note that test credentials start with sk_test_.... (or rk_test_...) and pk_test_.... Webhooks are also enabled for test and live modes separately.
Make sure to change the credentials and webhook secret to live values when you want to start receiving real payments.
Optionally, you can add another slash and enter comma-separated switches to customize the payment process. Type 'email' to prefill the customer's email address field in the Stripe form with the address entered in Planyo.
Note that when the address is prefilled, Stripe doesn't allow to change it anymore on their website. Without this option, no email address will be passed to Stripe and the customer will be able to
enter their email address during the payment process.
Another switch is 'billing-address'. This tells Stripe Checkout to collect the customer's billing address.
sk_live_BQokikJOvBiI2HlWgH4olfQ2 / pk_live_6pRNASCoBOKtIshFeQd4XMUh / whsec_Yq3Tc6fP4556XLdfgM9WHmjmo1r2 / email,billing-address
In addition to standard credit card transactions, you can turn on additional payment methods in your
Stripe Dashboard. Stripe will present the most relevant payment methods for each customer based on their location and currency used.
Webhook
You need to set up a Stripe webhook pointing to a script in our system. This way we will receive updates on your transactions and add payment information to your Planyo reservations.
You can set up the webhook in the
Webhooks section of your Stripe Dashboard:
When you click
Add endpoint, a pop-up window appears where you can enter the webhook settings.
In the
Endpoint URL field enter:
https://www.planyo.com/payment-stripe-checkout-ipn.php
In the
Events to send section, add the following events:
checkout.session.completed,
payment_intent.succeeded,
payment_intent.payment_failed and
charge.refunded.
If you are going to use any delayed realization payment methods (currently this includes Bacs Direct Debit, Boleto, Canadian pre-authorized debits, OXXO, SEPA Direct Debit and SOFORT), additionally add
payment_intent.processing,
checkout.session.async_payment_succeeded and
checkout.session.async_payment_failed.
Note that for this kind of payment methods there can be a 2-14 day delay in payment confirmation.
Once you click the
Add endpoint button to submit the settings, the
Signing secret section appears below
Webhook details (see the picture below).
Click the
Click to reveal button to see the webhook secret and copy the value.
Next, go back to the
Online payments page in your Planyo panel. Go to the
Stripe secret key / publishable key / webhook secret field and enter the webhook secret as the third value.
The webhook secret is necessary for authenticating events coming from Stripe to our system.
Note:
Stripe Checkout requires that your Stripe Account has the name set up in Dashboard. Go to your Stripe admin panel and make sure your account has a name specified in the top-left corener of the page.