How to obtain keys and enable webhooks for Stripe

To accept payments through Stripe in the booking widget, you’ll need to authorize your account by providing your API keys.

Add Stripe Secret and Public keys

Here is how to find them:

  1. Go to your Stripe Dashboard.
  2. Locate your Stripe Secret and Public keys on the screen. If either key is missing, press the “Create key” button.
     
  3. Enable Stripe and add your Publishable and Secret keys to their corresponding fields in your BNBForms account.
     
  4. Scroll down and save the changes.

Testing Stripe Integration

Optionally, use test mode with test card numbers to test your Stripe integration before going live with payments.

Use test API Keys and enable Sandbox Mode in your BNBForms account.

Note: don’t forget to switch to Live mode, update fields with live API Keys and disable Sandbox Mode in your BNBForms account after tests.

Configure Stripe Payment Methods

In our latest update, we’ve introduced a new Stripe integration that should provide a more reliable checkout experience and allow you to offer additional payment methods available in your region. To use it, you’ll need to complete a few steps:

  1. Create a Payment Method Configuration in your Stripe Dashboard: https://dashboard.stripe.com/settings/payment_methods.
    Create a Payment Method Configuration in your Stripe Dashboard
  2. Enable the payment methods you want to offer.
    Enable the payment methods you want to offer
  3. Copy the Configuration ID from Stripe.
    Copy the Configuration ID from Stripe
  4. Paste the Configuration ID into the Stripe settings in your BNBForms account.
    Paste the Configuration ID into the Stripe settings in your BNBForms account

Once configured, BNBForms will use the payment methods enabled in your Stripe account.

How to set up webhooks

To connect webhooks, follow the steps in the “Setting up webhooks” tutorial.

To add a new endpoint, in your Stripe account, go to Developers > Webhooks > + Add endpoint.

Webhook Secret – This is your Webhook ID that you can find in the upper right corner of the endpoint page.

Webhook-secret-ID

Endpoint URL – The URL in Stripe settings of your BNBForms dashboard. It is displayed when Stripe is turned on (check the box “Enable “Pay by card (Stripe)”, then save the changes).

webhook destination URL

You need to choose these event types when setting up webhook endpoints:

charge.failed
charge.succeeded
source.canceled
source.chargeable
source.failed