View Source ExTier

Build Status Coverage Status hex.pm version

ExTier is an elixir client for Tier.run, documentation can be found at https://hexdocs.pm/ex_tier.

installation

Installation

The package can be installed by adding ex_tier to your list of dependencies in mix.exs:

def deps do
  [
    {:ex_tier, "~> 0.11"}
  ]
end

versioning

Versioning

ExTier follows Tier's major and minor versions, but reserves minor versions for ExTier's patch updates. So Tier's v0.6 version will map to ExTier 0.6.x version.

configuration

Configuration

url

URL

You need to specify where the Tier server is reachable at:

config :ex_tier, url: "http://localhost:8080"

tier-cloud

Tier Cloud

You can use tier cloud by using the following configuration:

config :ex_tier,
  url: "https://api.tier.run",
  stripe_api_key: "your-stripe-api-key"

test-clocks

Test Clocks

To use test clocks, pass the clock_id in the configuration:

config :ex_tier, clock_id: "clock_1xTl3FbwSFVVY4blLTlXv2CY"

tesla

Tesla

ExTier depends on Tesla to perform HTTP requests. You are required to specify which Tesla adapter you want to use.

config :ex_tier, adapter: Tesla.Adapter.Httpc,

You can also configure an adapter's options via:

config :ex_tier, adapter: {Tesla.Adapter.Finch, name: ExTier}

compatibility

Compatibility

ExTierTierErlang/OTPElixir
>= 0.0.0>= 0.0.0>= 23.0.0>= 1.14.0

license

License

ExTier is released under the Apache License 2.0 - see the LICENSE file.