Search documentation of polar_express

# PolarExpress.Services.CustomerPortal.CustomersService (polar_express v0.1.5)

Copy Markdown View Source

Customers

Customers API operations.

## Summary

### Functions

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

Add Customer Payment Method

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

Confirm Customer Payment Method

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

Delete Customer Payment Method

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

Get Customer

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

List Customer Payment Methods

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

Update Customer

## Functions

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

    @spec add_customer_payment_method(PolarExpress.Client.t(), map(), keyword()) ::
      {:ok, PolarExpress.Schemas.CustomerPaymentMethodCreateResponse.t()}
      | {:error, PolarExpress.Error.t()}

Add Customer Payment Method

Add a payment method to the authenticated customer.

See `PolarExpress.Params.CustomerPortal.CustomersAddCustomerPaymentMethodParams` for parameter details.

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

    @spec confirm_customer_payment_method(PolarExpress.Client.t(), map(), keyword()) ::
      {:ok, PolarExpress.Schemas.CustomerPaymentMethodCreateResponse.t()}
      | {:error, PolarExpress.Error.t()}

Confirm Customer Payment Method

Confirm a payment method for the authenticated customer.

See `PolarExpress.Params.CustomerPortal.CustomersConfirmCustomerPaymentMethodParams` for parameter details.

# delete_customer_payment_method(client, id, params \\ %{}, opts \\ [])

    @spec delete_customer_payment_method(
      PolarExpress.Client.t(),
      String.t(),
      map(),
      keyword()
    ) ::
      {:ok, term()} | {:error, PolarExpress.Error.t()}

Delete Customer Payment Method

Delete a payment method from the authenticated customer.

See `PolarExpress.Params.CustomerPortal.CustomersDeleteCustomerPaymentMethodParams` for parameter details.

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

    @spec get_customer(PolarExpress.Client.t(), map(), keyword()) ::
      {:ok, PolarExpress.Schemas.CustomerPortalCustomer.t()}
      | {:error, PolarExpress.Error.t()}

Get Customer

Get authenticated customer.

Scopes: `customer_portal:read` `customer_portal:write`

See `PolarExpress.Params.CustomerPortal.CustomersGetCustomerParams` for parameter details.

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

    @spec list_customer_payment_methods(PolarExpress.Client.t(), map(), keyword()) ::
      {:ok, PolarExpress.ListObject.t()} | {:error, PolarExpress.Error.t()}

List Customer Payment Methods

Get saved payment methods of the authenticated customer.

See `PolarExpress.Params.CustomerPortal.CustomersListCustomerPaymentMethodsParams` for parameter details.

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

    @spec update_customer(PolarExpress.Client.t(), map(), keyword()) ::
      {:ok, PolarExpress.Schemas.CustomerPortalCustomer.t()}
      | {:error, PolarExpress.Error.t()}

Update Customer

Update authenticated customer.

See `PolarExpress.Params.CustomerPortal.CustomersUpdateCustomerParams` for parameter details.