Increase.Cards (Increase v1.0.0)

Copy Markdown View Source

Cards may operate on credit, debit, or prepaid BINs. They’ll immediately work for online purchases after you create them. All cards work on a good funds model, and maintain a maximum limit of 100% of the Account’s available balance at the time of transaction. Funds are deducted from the Account upon transaction settlement.

See https://increase.com/documentation/api/cards for the full API reference for this resource.

Summary

Functions

Sensitive details for a Card include the primary account number, expiry, card verification code, and PIN.

Create an iframe URL for a Card to display the card details. More details about styling and usage can be found in the [documentation].

Functions

create(client, params \\ %{}, opts \\ [])

@spec create(Increase.Client.t() | keyword() | nil, map() | keyword(), keyword()) ::
  {:ok, Increase.Cards.Card.t()} | {:error, Increase.Error.t()}

Create a Card

POST /cards

details(client, card_id, opts \\ [])

@spec details(Increase.Client.t() | keyword() | nil, String.t(), keyword()) ::
  {:ok, Increase.Cards.CardDetails.t()} | {:error, Increase.Error.t()}

Sensitive details for a Card include the primary account number, expiry, card verification code, and PIN.

GET /cards/{card_id}/details

list(client, params \\ %{}, opts \\ [])

@spec list(Increase.Client.t() | keyword() | nil, map() | keyword(), keyword()) ::
  {:ok, Increase.Page.t()} | {:error, Increase.Error.t()}

List Cards

Returns a %Increase.Page{} whose data is a list of %__MODULE__. Card{} structs. Page through results with Increase.Page.auto_paging_stream/1 or Increase.Page.auto_paging_each/2.

GET /cards

new_details_iframe(client, card_id, params \\ %{}, opts \\ [])

@spec new_details_iframe(
  Increase.Client.t() | keyword() | nil,
  String.t(),
  map() | keyword(),
  keyword()
) :: {:ok, Increase.Cards.CardIframeURL.t()} | {:error, Increase.Error.t()}

Create an iframe URL for a Card to display the card details. More details about styling and usage can be found in the [documentation].

POST /cards/{card_id}/create_details_iframe

retrieve(client, card_id, opts \\ [])

@spec retrieve(Increase.Client.t() | keyword() | nil, String.t(), keyword()) ::
  {:ok, Increase.Cards.Card.t()} | {:error, Increase.Error.t()}

Retrieve a Card

GET /cards/{card_id}

update(client, card_id, params \\ %{}, opts \\ [])

@spec update(
  Increase.Client.t() | keyword() | nil,
  String.t(),
  map() | keyword(),
  keyword()
) ::
  {:ok, Increase.Cards.Card.t()} | {:error, Increase.Error.t()}

Update a Card

PATCH /cards/{card_id}

update_pin(client, card_id, params \\ %{}, opts \\ [])

@spec update_pin(
  Increase.Client.t() | keyword() | nil,
  String.t(),
  map() | keyword(),
  keyword()
) :: {:ok, Increase.Cards.CardDetails.t()} | {:error, Increase.Error.t()}

Update a Card's PIN

POST /cards/{card_id}/update_pin