Skip to content

belloq/visa_checkout_elixir

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Visa Checkout for Elixir

A Visa Checkout library for Elixir.

Documentation

Installation

Add visa_checkout_elixir to your list of dependencies in mix.exs:

def deps do
  [
    {:visa_checkout_elixir, "~> 1.0"}
  ]
end

Configuration

To make API calls, it's necessary to configure your Visa Checkout keys.

Add to your config:

config :visa_checkout_elixir,
  api_key: "YOUR_API_KEY",
  secret: "YOUR_SECRET"

or add to your environment:

export VISA_CHECKOUT_API_KEY=YOUR_API_KEY
export VISA_CHECKOUT_SECRET=YOUR_SECRET

If you want to use it in sandbox mode:

config :visa_checkout_elixir, sandbox: true

Api

Get payment data

VisaCheckout.get_payment_data("call_id")

Update payment info

VisaCheckout.update_payment_info("call_id", %{orderInfo: ...})