stripity_stripe v2.0.0-alpha.6 Stripe.Plan

Work with Stripe plan objects.

You can:

  • Create a plan
  • Retrieve a plan
  • Update a plan
  • Delete a plan

Does not yet render lists or take options.

Stripe API reference: https://stripe.com/docs/api#plan

Summary

Types

t()
t :: %Stripe.Plan{amount: term, created: term, currency: term, id: term, interval: term, interval_count: term, livemode: term, metadata: term, name: term, object: term, statement_descriptor: term, trial_period_days: term}

Functions

create(changes, opts \\ [])
create(map, Keyword.t) ::
  {:ok, t} |
  {:error, Stripe.api_error_struct}

Create a plan.

delete(id, opts \\ [])
delete(binary, list) :: :ok | {:error, Stripe.api_error_struct}

Delete a plan.

retrieve(id, opts \\ [])
retrieve(binary, Keyword.t) ::
  {:ok, t} |
  {:error, Stripe.api_error_struct}

Retrieve a plan.

update(id, changes, opts \\ [])
update(binary, map, list) ::
  {:ok, t} |
  {:error, Stripe.api_error_struct}

Update a plan.

Takes the id and a map of changes.