Forum Academy Marketplace Showcase Pricing Features

Create a Stripe refund


I need to have a refund function with Stripe in my app, but The standard Stripe from Bubble does not have the action as I can see and I want to be able to use the Bubble Connector for this but fail miserably in my attempt.

I have read the docs and I do not understand what to put in the fields after authenticating:

If anyone could show me the first steps to adding such a function I would really appreciate it!

What I am looking for is:
Create a refund based on Charge ID, amount, currency.


Hi @kris,

Set your Authentication method to Private Key in Header.

Key Name = Authorization
Key Value = Bearer [Your Live SK key]

Dev Value = Bearer [Your Test SK key]

Gaby at Coaching No Code Apps

Courses, Private Coaching, and Custom App Development

Start Building Today :hammer_and_wrench:

Thanks again, @romanmg

I have now corrected the authentication. Now how do I execute a refund off a previously successfull charge?

I want to be able to create a refund with an amount field so I can subract a cancellation fee in a workflow.

All the best,

I have tried so many combinations of this,

I always get errors like:


That particular error is coming up because you don’t have the right header added to your API Call. In the call, add a header with the following:

Key = content-type
Value = application/x-www-form-urlencoded

Example (with a different endpoint… just look at the header):

So, to create a refund for an existing charge, you’ll need to save the Charge ID whenever the charge is created. That way you can insert that ID into the parameter in the Create Refund call. Make sure to uncheck “private” on the charge ID parameter within the Create Refund call - this will allow you to insert a dynamic ID (in other words, an ID you’ve previously saved in your database) in the workflow action settings.

If this is your first time diving into APIs, I have a whole video series that walks you through a bunch of API features including the API Connector. I’m also happy to walk you through this in a coaching session. Hopefully this gets you moving forward!

@romanmg I see you have no available sessions until late June, let me know if you get a cancellation! I would love to book a session with you to get me to understanding the API/Bubble connector thing, but I need to get this refund thing going as soon as possible.

I still dont know what to do after authentication, but thanks for getting me that far :slight_smile:
If I may ask, what are the steps after authentication? Do I add a new parameter under that first authentication? (tried that) Do I add a New API call, is GET or POST? (tried that too) I really need to learn this, to be self sufficient. There are so many options that makes this hard to just -test until it works - kind of thing. I usually learn very fast by examples so any would be appreciated.


Try adding the parameter to the query string


This information is really helpful. However, i have a couple of questions.

  1. In the first image do we add the word Bearer in the field and then the key? Is there a space required between bearer and sk? which is also shown in the image by @romanmg you

  2. In the image by @badger you have two value inputs - where did you get these from to include?

These have not been set up in my app as yet.

@levon @ZeroqodeSupport

Hello, @Fiano
Thanks for tagging us here.

Please note that the configuration of the Stripe payment system should be finished by yourself (keys or APIs). That’s why it is not set in your application :pray:

As it was mentioned in the first message of the thread, The standard Stripe from Bubble does not have the action for refund.
Please check the screenshots, provided earlier in this thread (the space between the Bearer and sk is required):

Also, please allow to recommend you to check the documentation for the Bubble Stripe plugin:

Also, please find this official documentation for the Refunding and Canceling payments in Stripe:

Please check this first and let us know about the result.
Best regards,
Zeroqode Support team