Customers
Retrieves a list of customers.
Table-Specific Information
Select
The component uses the Shopify API to process WHERE clause conditions built with the following columns and operators. The component processes other filters client-side within the component.
- Id supports the '=,IN' comparison operators.
- Email supports the '=,!=' comparison operators.
- Phone supports the '=,!=' comparison operators.
- State supports the '=,!=' comparison operators.
- CreatedAt supports the '=,!=,<,>,>=,<=' comparison operators.
- UpdatedAt supports the '=,!=,<,>,>=,<=' comparison operators.
- AmountSpentAmount supports the '=,!=' comparison operators.
For example, the following queries are processed server side:
SELECT * FROM Customers
SELECT * FROM Customers WHERE Id = 'Val1'
SELECT * FROM Customers WHERE Email = 'Val1'
SELECT * FROM Customers WHERE Phone = 'Val1'
SELECT * FROM Customers WHERE State = 'Val1'
SELECT * FROM Customers WHERE CreatedAt = '2023-01-01 11:10:00'
SELECT * FROM Customers WHERE UpdatedAt = '2023-01-01 11:10:00'
SELECT * FROM Customers WHERE AmountSpentAmount = '100.00'
Insert
The following columns can be used to create a new record:
FirstName, LastName, Email, Locale, Note, Phone, Tags, TaxExempt, TaxExemptions, DefaultAddressFirstName, DefaultAddressLastName, DefaultAddressAddress1, DefaultAddressAddress2, DefaultAddressCity, DefaultAddressCompany, DefaultAddressCountry, DefaultAddressPhone, DefaultAddressProvince, DefaultAddressZip, DefaultAddressProvinceCode, DefaultAddressCountryCodeV2, SmsMarketingConsentMarketingState, SmsMarketingConsentMarketingOptInLevel, SmsMarketingConsentConsentUpdatedAt
Update
The following columns can be updated:
FirstName, LastName, Email, Locale, Note, Phone, Tags, TaxExempt, TaxExemptions, DefaultAddressFirstName, DefaultAddressLastName, DefaultAddressAddress1, DefaultAddressAddress2, DefaultAddressCity, DefaultAddressCompany, DefaultAddressCountry, DefaultAddressPhone, DefaultAddressProvince, DefaultAddressZip, DefaultAddressProvinceCode, DefaultAddressCountryCodeV2, SmsMarketingConsentMarketingState, SmsMarketingConsentMarketingOptInLevel, SmsMarketingConsentConsentUpdatedAt
Delete
You can delete entries by specifying the following column:
Id
Columns
Name | Type | ReadOnly | References | Description |
Id [KEY] | String | True |
A globally-unique ID. | |
MultipassIdentifier | String | True |
A unique identifier for the customer that's used with Multipass login. | |
LegacyResourceId | String | True |
The ID of the corresponding resource in the REST Admin API. | |
ValidEmailAddress | Bool | True |
Whether the email address is formatted correctly. Returns 'true' when the email is formatted correctly and belongs to an existing domain. This doesn't guarantee that the email address actually exists. | |
DisplayName | String | True |
The full name of the customer, based on the values for first_name and last_name. If the first_name and last_name are not available, then this falls back to the customer's email address, and if that is not available, the customer's phone number. | |
FirstName | String | False |
The customer's first name. | |
LastName | String | False |
The customer's last name. | |
String | False |
The customer's email address. | ||
Locale | String | False |
The customer's locale. | |
Note | String | False |
A note about the customer. | |
Phone | String | False |
The customer's phone number. | |
State | String | True |
The state of the customer's account with the shop. | |
Tags | String | False |
A comma separated list of tags that have been added to the customer. | |
CanDelete | Bool | True |
Whether the merchant can delete the customer from their store. A customer can be deleted from a store only if they have not yet made an order. After a customer makes an order, they can't be deleted from a store. | |
LifetimeDuration | String | True |
The amount of time since the customer was first added to the store. Example: 'about 12 years'. | |
TaxExempt | Bool | False |
Whether the customer is exempt from being charged taxes on their orders. | |
TaxExemptions | String | False |
The list of tax exemptions applied to the customer. | |
UnsubscribeUrl | String | True |
The URL to unsubscribe the customer from the mailing list. | |
VerifiedEmail | Bool | True |
Whether the customer has verified their email address. Defaults to 'true' if the customer is created through the Shopify admin or API. | |
HasTimelineComment | Bool | True |
Whether the timeline subject has a timeline comment. If true, then a timeline comment exists. | |
NumberOfOrders | String | True |
The number of orders that the customer has made at the store in their lifetime. | |
ProductSubscriberStatus | String | True |
Possible subscriber states of a customer defined by their subscription contracts. | |
CreatedAt | Datetime | True |
The date and time when the customer was added to the store. | |
UpdatedAt | Datetime | True |
The date and time when the customer was last updated. | |
AmountSpentAmount | Decimal | True |
Decimal money amount. | |
AmountSpentCurrencyCode | String | True |
Currency of the money. | |
DefaultAddressId | String | True |
A globally-unique ID. | |
DefaultAddressCoordinatesValidated | Bool | True |
Whether the address coordinates are valid. | |
DefaultAddressName | String | True |
The full name of the customer, based on firstName and lastName. | |
DefaultAddressFirstName | String | False |
The first name of the customer. | |
DefaultAddressLastName | String | False |
The last name of the customer. | |
DefaultAddressAddress1 | String | False |
The first line of the address. Typically the street address or PO Box number. | |
DefaultAddressAddress2 | String | False |
The second line of the address. Typically the number of the apartment, suite, or unit. | |
DefaultAddressCity | String | False |
The name of the city, district, village, or town. | |
DefaultAddressCompany | String | False |
The name of the customer's company or organization. | |
DefaultAddressCountry | String | False |
The name of the country. | |
DefaultAddressLatitude | Double | True |
The latitude coordinate of the customer address. | |
DefaultAddressLongitude | Double | True |
The longitude coordinate of the customer address. | |
DefaultAddressPhone | String | False |
A unique phone number for the customer. Formatted using E. 164 standard. For example, _+16135551111_. | |
DefaultAddressProvince | String | False |
The region of the address, such as the province, state, or district. | |
DefaultAddressZip | String | False |
The zip or postal code of the address. | |
DefaultAddressFormattedArea | String | True |
A comma-separated list of the values for city, province, and country. | |
DefaultAddressProvinceCode | String | False |
The two-letter code for the region. For example, ON. | |
DefaultAddressCountryCodeV2 | String | False |
The two-letter code for the country of the address. For example, US. | |
EmailMarketingConsentMarketingState | String | True |
The current email marketing state for the customer. | |
EmailMarketingConsentMarketingOptInLevel | String | True |
The marketing subscription opt-in level, as described by the M3AAWG best practices guidelines, that the customer gave when they consented to receive marketing material by email. | |
EmailMarketingConsentConsentUpdatedAt | Datetime | True |
The date and time at which the customer consented to receive marketing material by email. The customer's consent state reflects the consent record with the most recent 'consent_updated_at' date. If no date is provided, then the date and time at which the consent information was sent is used. | |
ImageId | String | True |
A unique ID for the image. | |
ImageWidth | Int | True |
The original width of the image in pixels. Returns 'null' if the image is not hosted by Shopify. | |
ImageAltText | String | True |
A word or phrase to share the nature or contents of an image. | |
ImageHeight | Int | True |
The original height of the image in pixels. Returns 'null' if the image is not hosted by Shopify. | |
ImageUrl | String | True |
The location of the image as a URL. | |
LastOrderId | String | True |
A globally-unique ID. | |
MarketId | String | True |
A globally-unique ID. | |
MergeableReason | String | True |
The reason why the customer can't be merged with another customer. | |
MergeableErrorFields | String | True |
The list of fields preventing the customer from being merged. | |
MergeableIsMergeable | Bool | True |
Whether the customer can be merged with another customer. | |
MergeableMergeInProgressJobId | String | True |
The UUID of the merge job. | |
MergeableMergeInProgressResultingCustomerId | String | True |
The ID of the customer resulting from the merge. | |
MergeableMergeInProgressStatus | String | True |
The status of the customer merge request. | |
SmsMarketingConsentMarketingState | String | False |
The current SMS marketing state for the customer. | |
SmsMarketingConsentConsentCollectedFrom | String | True |
The source from which the SMS marketing information for the customer was collected. | |
SmsMarketingConsentMarketingOptInLevel | String | False |
The marketing subscription opt-in level that was set when the customer consented to receive marketing information. | |
SmsMarketingConsentConsentUpdatedAt | Datetime | False |
The date and time when the customer consented to receive marketing material by SMS. If no date is provided, then the date and time when the consent information was sent is used. | |
StatisticsPredictedSpendTier | String | True |
The predicted spend tier of a customer with a shop. |