Conekta.Customers (Conekta v1.1.0) View Source

Functions for retrieving and managing information about clients.

We can create, update, find, delete and get all customers:

Endpoint: https://api.conekta.io/customers

Link to this section Summary

Functions

Create a new Conekta client Conekta Documenation

Create a new shipping contact for a customer Conekta Documenation

Get Conekta clients information. Conekta Documenation

Delete a Conekta client by passing the unique conekta ID. Conekta Documenation

Get Conekta client information identified by their unique conekta ID.

Get the client payment sources Conekta Documenation

Get the client shipping contacts Conekta Documenation

Get the client subscriptions Conekta Documenation

Update a Conekta client by passing a %Conekta.Customer{} struct with the new values

Link to this section Functions

Create a new Conekta client Conekta Documenation

Method: POST

Conekta.Customers.create(%Conekta.Customer{})
# => { :ok, %Conekta.Customer{}}
Link to this function

create_payment_source(client_id, payment_source)

View Source

Create a new payment source Conekta Documenation

Method: POST

Conekta.Customers.create_payment_source(client_id, %Conekta.PaymentSource{})
# => { :ok, %Conekta.CustomerCreatePaymentSourceResponse{}}
Link to this function

create_shipping_contact(client_id, shipping_contact)

View Source

Create a new shipping contact for a customer Conekta Documenation

Method: POST

Conekta.Customers.create_shipping_contact(client_id, %Conekta.ShippingContact{})
# => { :ok, %Conekta.CustomerCreateShippingContactResponse{}}

Get Conekta clients information. Conekta Documenation

Method: GET

Conekta.Customers.customers()
# => { :ok, %Conekta.CustomersResponse{}}

Delete a Conekta client by passing the unique conekta ID. Conekta Documenation

Method: DELETE

Conekta.Customers.delete(client_id)
# => { :ok, %Conekta.CustomerDeleteResponse{}}
Link to this function

delete_payment_source(client_id, payment_source_id)

View Source

Delete a payment source from a client Conekta Documenation

Method: DELETE

Conekta.Customers.delete_payment_source(client_id, payment_source_id)
# => { :ok, %Conekta.CustomerDeletePaymentSourceResponse{}}
Link to this function

delete_shipping_contact(client_id, shipping_contact_id)

View Source

Delete a shipping contact from a customer Conekta Documenation

Method: DELETE

Conekta.Customers.delete_shipping_contact(client_id, shipping_contact_id)
# => { :ok, %Conekta.CustomerDeleteShippingContactResponse{}}

Get Conekta client information identified by their unique conekta ID.

Method: GET

Conekta.Customers.find(client_id)
# => { :ok, %Conekta.CustomerFindResponse{}}
Link to this function

payment_sources(client_id)

View Source

Get the client payment sources Conekta Documenation

Method: GET

Conekta.Customers.payment_sources(client_id)
# => { :ok, %Conekta.CustomerPaymentSourcesResponse{}}
Link to this function

shipping_contacts(client_id)

View Source

Get the client shipping contacts Conekta Documenation

Method: GET

Conekta.Customers.shipping_contacts(client_id)
# => { :ok, %Conekta.CustomerShippingContactsResponse{}}

Get the client subscriptions Conekta Documenation

Method: GET

Conekta.Customers.subscription(client_id)
# => { :ok, %Conekta.CustomerSubscriptionResponse{}}
Link to this function

update(client_id, customer)

View Source

Update a Conekta client by passing a %Conekta.Customer{} struct with the new values

Conekta Documenation

Method: PUT

Conekta.Customers.update(client_id, %Conekta.Customer{})
# => { :ok, %Conekta.CustomerDeleteResponse{}}
Link to this function

update_shipping_contact(client_id, shipping_contact_id, shipping_contact)

View Source

Update shipping contact for a customer Conekta Documenation

Method: PUT

Conekta.Customers.update_shipping_contact(client_id, shipping_contact_id, %Conekta.ShippingContact{})
# => { :ok, %Conekta.CustomerUpdateShippingContactResponse{}}