PayPal.Payments.Sales (pay_pal v0.0.7)
Documentation for PayPal.Payments.Sales
A sale is a completed payment.
Summary
Functions
@spec refund(String.t(), map()) :: {:ok, map() | :not_found | :no_content | nil} | {:error, :unauthorised | :bad_network | any()}
Refund a sale
Possible returns:
{:ok, sale}
{:error, refund}
Examples
iex> PayPal.Payments.Sales.refund(sale_id, %{
amount: %{
total: "1.50",
currency: "USD"
}
})
@spec show(String.t()) :: {:ok, map() | :not_found | :no_content} | {:error, :unauthorised | :bad_network | any()}
Show a sale
Possible returns:
{:ok, sale}
{:error, reason}
Examples
iex> PayPal.Payments.Sales.show(sale_id)