sq_update_customer: Update Customer

Description Usage Arguments Details Value Examples

View source: R/customers.R

Description

Updates the details of an existing customer.

Usage

1
sq_update_customer(customer_id, input_data, verbose = FALSE)

Arguments

customer_id

character; the Square ID assigned to each unique customer. This can be found using sq_list_customers

input_data

list; data used for creating or updating an object.

verbose

logical; do you want informative messages?

Details

The ID of the customer may change if the customer has been merged into another customer. Required permissions: CUSTOMERS_WRITE

Value

tbl_df of the updated customer record

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
 
## Not run: 
updated_cust_data <- list(family_name = "API Test Test Test",
                          note = "This customer was updated by the API as a test.")
updated_customer <- sq_update_customer(customer_id="ThisIsATestCustomerId",
                                       updated_cust_data)
# you can confirm the update by retrieving the customer
this_customer <- sq_get_customer(updated_customer$id[1])

## End(Not run)

StevenMMortimer/squareupr documentation built on July 12, 2019, 1:45 a.m.