Skip to content

Instantly share code, notes, and snippets.

@adamjstevenson
Created October 20, 2017 21:35
Show Gist options
  • Save adamjstevenson/1d5de5889d46f603e9838a141ae98c13 to your computer and use it in GitHub Desktop.
Save adamjstevenson/1d5de5889d46f603e9838a141ae98c13 to your computer and use it in GitHub Desktop.
Create a refund on a connected account
# Refund a charge
refund = Stripe::Refund.create(
{
charge: "ch_1BAkyv2jy8PDLWD6E4t2XxPX", # The ID of the charge to refund
refund_application_fee: true # Optionally give your platform commission back to the user
},
{
stripe_account: "acct_j1cXUEAksEpalsjc3Xl3" # The ID of the Stripe account connected to your platform
}
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment