Peacemaker.Orders.AllAccess (Peacemaker v3.3.5-rc.7) View Source

Link to this section Summary

Link to this section Types

Specs

all_access_params() :: %{
  ipAddress: String.t(),
  creditCardNumber: String.t(),
  creditCardType: String.t(),
  expirationDate: String.t(),
  firstName: String.t(),
  lastName: String.t(),
  email: String.t(),
  phone: String.t(),
  shippingAddress1: String.t(),
  shippingCity: String.t(),
  shippingCountry: String.t(),
  shippingState: String.t(),
  shippingZip: String.t(),
  CVV: String.t()
}

Specs

all_access_return() ::
  {:error, String.t()} | {:ok, Peacemaker.Orders.NewOrderToken.t()}

Link to this section Functions

Link to this function

add_permissibles(token_tuple)

View Source
Link to this function

cancel_previous_order(token_tuple)

View Source

Specs

do_place_order(all_access_params()) :: all_access_return()
Link to this function

find_or_create_account(token, full_params)

View Source

Specs

find_or_create_account(
  Peacemaker.Orders.NewOrderToken.t() | {:error, String.t()},
  all_access_params()
) ::
  {:error, String.t()}
  | {Peacemaker.Orders.NewOrderToken.t(), Peacemaker.Account.t()}

Specs

place_order(all_access_params()) :: all_access_return()
Link to this function

place_order(conn, params)

View Source

Specs

Link to this function

place_order_with_token(conn, params, token)

View Source
Link to this function

report_analytics(error, conn)

View Source

Specs

report_analytics(
  {Peacemaker.Orders.NewOrderToken.t(), Peacemaker.Account.t()},
  Plug.Conn.t()
) :: {:ok, Peacemaker.Orders.NewOrderToken.t()}
report_analytics({:error, String.t()}, Plug.Conn.t()) :: {:error, String.t()}