Documentation ¶
Overview ¶
Package refund provides the /refunds APIs
Index ¶
- func Cancel(id string, params *stripe.RefundCancelParams) (*stripe.Refund, error)
- func Get(id string, params *stripe.RefundParams) (*stripe.Refund, error)
- func New(params *stripe.RefundParams) (*stripe.Refund, error)
- func Update(id string, params *stripe.RefundParams) (*stripe.Refund, error)
- type Client
- func (c Client) Cancel(id string, params *stripe.RefundCancelParams) (*stripe.Refund, error)
- func (c Client) Get(id string, params *stripe.RefundParams) (*stripe.Refund, error)
- func (c Client) List(listParams *stripe.RefundListParams) *Iter
- func (c Client) New(params *stripe.RefundParams) (*stripe.Refund, error)
- func (c Client) Update(id string, params *stripe.RefundParams) (*stripe.Refund, error)
- type Iter
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Cancel ¶
Cancels a refund with a status of requires_action.
You can't cancel refunds in other states. Only refunds for payment methods that require customer action can enter the requires_action state.
func New ¶
func New(params *stripe.RefundParams) (*stripe.Refund, error)
When you create a new refund, you must specify a Charge or a PaymentIntent object on which to create it.
Creating a new refund will refund a charge that has previously been created but not yet refunded. Funds will be refunded to the credit or debit card that was originally charged.
You can optionally refund only part of a charge. You can do so multiple times, until the entire charge has been refunded.
Once entirely refunded, a charge can't be refunded again. This method will raise an error when called on an already-refunded charge, or when trying to refund more money than is left on a charge.
Types ¶
type Client ¶
Client is used to invoke /refunds APIs.
func (Client) Cancel ¶
Cancels a refund with a status of requires_action.
You can't cancel refunds in other states. Only refunds for payment methods that require customer action can enter the requires_action state.
func (Client) List ¶
func (c Client) List(listParams *stripe.RefundListParams) *Iter
Returns a list of all refunds you created. We return the refunds in sorted order, with the most recent refunds appearing first. The 10 most recent refunds are always available by default on the Charge object.
func (Client) New ¶
When you create a new refund, you must specify a Charge or a PaymentIntent object on which to create it.
Creating a new refund will refund a charge that has previously been created but not yet refunded. Funds will be refunded to the credit or debit card that was originally charged.
You can optionally refund only part of a charge. You can do so multiple times, until the entire charge has been refunded.
Once entirely refunded, a charge can't be refunded again. This method will raise an error when called on an already-refunded charge, or when trying to refund more money than is left on a charge.
type Iter ¶
Iter is an iterator for refunds.
func List ¶
func List(params *stripe.RefundListParams) *Iter
Returns a list of all refunds you created. We return the refunds in sorted order, with the most recent refunds appearing first. The 10 most recent refunds are always available by default on the Charge object.
func (*Iter) RefundList ¶
func (i *Iter) RefundList() *stripe.RefundList
RefundList returns the current list object which the iterator is currently using. List objects will change as new API calls are made to continue pagination.