Customers¶
The Customers pull reads the customers created or updated since its last run, for a customer or contact record in the target system. Each customer record carries the default address, marketing consent and metafields, with every address the customer holds beneath it.
On a reader, select Customers as the Shopify Entity.
Reader Options¶
The pull reads the customers that Shopify updated inside its time window. Creating a customer counts as an update.
- A preview or refresh in the Designer reads the customers updated in the span that Orders placed in the last gives, such as
30d. The option names orders, but sets the span for this pull too. The Designer needs a span, and reports an error without one. - A run outside the Designer reads the customers updated since its last run. The first run reads every customer.
The pull reads through Shopify's GraphQL Admin API only. Leave API empty or set it to GraphQL. The Designer reports an error for REST. Timestamps applies as it does to Orders. The status, id and payment options have no effect.
The pull asks Shopify only for the fields the transform maps.
Records¶
The pull returns a Customer record for each customer, with an Addresses record for each of the customer's addresses.
Customer¶
id, the numeric Shopify customer id;email,phone,first_name,last_nameanddisplay_name;state,verified_email,note,tagsandlocale;tax_exemptandtax_exemptions;orders_count,total_spentandcurrency, withlast_order_idandlast_order_name;email_marketing_state,email_marketing_opt_in_levelandemail_marketing_updated_at, with the matchingsms_marketing_fields;def_fields, the default address, such asdef_address1,def_city,def_zipanddef_country_code;created_atandupdated_at.
metafield_1_ to metafield_25_ hold the customer's first 25 metafields. Each set has namespace, key, type and value.
Addresses¶
Each Addresses record holds one of the customer's addresses: id, first_name, last_name, company, address1, address2, city, province, province_code, zip, country, country_code and phone.
Running from a Schedule¶
The pull keeps its last run time as the Orders pull does, in the same lookup table. See Running from a Schedule to reset it. A run reads each customer once, however often it changed since the last run. A customer that changes again comes in again on a later run. The 15-minute overlap in the last run time can also bring a customer in on two runs in a row. Match the customer in the target system on its Shopify id or email, and update rather than create.
Access Scopes¶
The pull needs read_customers. See Access Scopes.
Shopify Reference¶
Customer in Shopify's GraphQL Admin API reference.