pay_pal v0.0.5 PayPal.Payments.Authorizations

Documentation for PayPal.Payments.Authorizations

https://developer.paypal.com/docs/api/payments/#authorization

Link to this section Summary

Functions

Capture an authorization

Show an authorization

Void an authorization

Link to this section Functions

Link to this function capture(authorization_id, params)
capture(String.t(), map()) :: {atom(), any()}

Capture an authorization

docs

Possible returns:

  • {:ok, capture}
  • {:error, reason}

Examples

iex> PayPal.Payments.Authorizations.capture(authorization_id, %{

amount: %{
  currency: "USD",
  amount: "4.54"
},
is_final_capture: true

})

Link to this function reauthorize(authorization_id, params)
reauthorize(String.t(), map()) :: {atom(), any()}

Reauthorize a payment

docs

Possible returns:

  • {:ok, authorization}
  • {:error, reason}

Examples

iex> PayPal.Payments.Authorizations.capture(authorization_id, %{

amount: %{
  currency: "USD",
  amount: "4.54"
}

})

Link to this function show(authorization_id)
show(String.t()) :: {atom(), any()}

Show an authorization

docs

Possible returns:

  • {:ok, authorization}
  • {:error, reason}

Examples

iex> PayPal.Payments.Authorizations.show(authorization_id)

Link to this function void(authorization_id)
void(String.t()) :: {atom(), any()}

Void an authorization

docs

Possible returns:

  • {:ok, authorization}
  • {:error, reason}

Examples

iex> PayPal.Payments.Authorizations.void(authorization_id)