Skip to content

Stripe - Create Refund

This module allows you to create refunds for previously completed payments. It can be a full or partial refund, with the option to specify the reason.

  • Secret Key: Stripe secret key
ParameterTypeRequiredDescription
credentials_idcredentialYesStripe credentials
payment_intent_idstringYes*Payment Intent ID (pi_xxx)
charge_idstringYes*Charge ID (ch_xxx) - alternative
amountnumberNoAmount to refund (empty = full)
reasonselectNoRefund reason
metadatastringNoAdditional metadata (JSON)

*Either payment_intent_id or charge_id is required

  • duplicate: Duplicate payment
  • fraudulent: Fraudulent payment
  • requested_by_customer: Requested by the customer
{
"success": true,
"refund": {...},
"refund_id": "re_3MtwBwLkdIwHu7ix28a3tqPa",
"status": "succeeded",
"amount": 99.99,
"currency": "usd",
"message": "Reembolso re_3MtwBw... creado (succeeded)"
}
  • pending: Pending
  • succeeded: Successful
  • failed: Failed
  • canceled: Canceled
{
"payment_intent_id": "pi_3MtwBwLkdIwHu7ix28a3tqPa"
}
{
"payment_intent_id": "pi_3MtwBwLkdIwHu7ix28a3tqPa",
"amount": 25.00,
"reason": "requested_by_customer"
}
{
"charge_id": "ch_3MtwBwLkdIwHu7ix28a3tqPa",
"reason": "duplicate",
"metadata": "{\"ticket_id\": \"SUPPORT-123\"}"
}
  • If no amount is specified, the full amount is refunded
  • Partial refunds can be made multiple times
  • The amount is automatically converted to cents
  • Refunds may take 5-10 days to appear in the customer’s account
  • StripeGetPaymentIntents - Get the Payment Intent to refund
  • StripeCreatePaymentIntent - Create payments that can later be refunded
  • StripeGetCustomers - Get payment customer data