Reference

Endpoint Get Customers


Name

get_customers

Description

Gets a list of customers. [API reference]

Related Tables

Customers

Parameters

Parameter Required Options
Name: ids

Label: Customer Id(s) - Comma separated

Restrict results to records specified by a comma-separated list of IDs. Max IDs per request controlled by BatchSize property (found in PaginationParams)
Name: since_id

Label: Since Customer Id

Restrict results to those created after the specified customer ID.
Name: limit

Label: Page Size

The maximum number of records to show.
Name: fields

Label: Only Fields to Show

Limit data retrieval to only the selected customer-related fields.
Option Value
id id
email email
accepts_marketing accepts_marketing
created_at created_at
updated_at updated_at
first_name first_name
last_name last_name
orders_count orders_count
state state
total_spent total_spent
last_order_id last_order_id
note note
verified_email verified_email
multipass_identifier multipass_identifier
tax_exempt tax_exempt
tags tags
last_order_name last_order_name
currency currency
phone phone
accepts_marketing_updated_at accepts_marketing_updated_at
marketing_opt_in_level marketing_opt_in_level
sms_marketing_consent sms_marketing_consent
admin_graphql_api_id admin_graphql_api_id
Name: created_at_max

Label: Created Before

Restrict results to records created before a specified date. (format: 2014-04-25T16:15:47). Supported options are the following: now|today|yesterday|weekstart|weekend|monthstart|monthend|yearstart|yearend and supported intervals for add/subtract are ms|s|sec|min|h|hour|y|year|d|day|m|month|y|year. Example monthstart-3d (subtract 3 days from month start)
Option Value
today today
yesterday yesterday
monthstart monthstart
monthend monthend
yearstart yearstart
yearend yearend
weekstart weekstart
weekend weekend
yearstart-1y yearstart-1y
yearend-1y yearend-1y
monthstart-1d monthstart-1d
monthend+1d monthend+1d
2014-04-25T16:15:47 2014-04-25T16:15:47
2014-04-25T16:15:47-04:00 2014-04-25T16:15:47-04:00
Name: created_at_min

Label: Created After

Restrict results to records created after a specified date. (format: 2014-04-25T16:15:47). Supported options are the following: now|today|yesterday|weekstart|weekend|monthstart|monthend|yearstart|yearend and supported intervals for add/subtract are ms|s|sec|min|h|hour|y|year|d|day|m|month|y|year. Example monthstart-3d (subtract 3 days from month start)
Option Value
today today
yesterday yesterday
monthstart monthstart
monthend monthend
yearstart yearstart
yearend yearend
weekstart weekstart
weekend weekend
yearstart-1y yearstart-1y
yearend-1y yearend-1y
monthstart-1d monthstart-1d
monthend+1d monthend+1d
2014-04-25T16:15:47 2014-04-25T16:15:47
2014-04-25T16:15:47-04:00 2014-04-25T16:15:47-04:00
Name: updated_at_max

Label: Updated Before

Restrict results to records last updated before a specified date. (format: 2014-04-25T16:15:47). Supported options are the following: now|today|yesterday|weekstart|weekend|monthstart|monthend|yearstart|yearend and supported intervals for add/subtract are ms|s|sec|min|h|hour|y|year|d|day|m|month|y|year. Example monthstart-3d (subtract 3 days from month start)
Option Value
today today
yesterday yesterday
monthstart monthstart
monthend monthend
yearstart yearstart
yearend yearend
weekstart weekstart
weekend weekend
yearstart-1y yearstart-1y
yearend-1y yearend-1y
monthstart-1d monthstart-1d
monthend+1d monthend+1d
2014-04-25T16:15:47 2014-04-25T16:15:47
2014-04-25T16:15:47-04:00 2014-04-25T16:15:47-04:00
Name: updated_at_min

Label: Updated After

Restrict results to records last updated after a specified date. (format: 2014-04-25T16:15:47). Supported options are the following: now|today|yesterday|weekstart|weekend|monthstart|monthend|yearstart|yearend and supported intervals for add/subtract are ms|s|sec|min|h|hour|y|year|d|day|m|month|y|year. Example monthstart-3d (subtract 3 days from month start)
Option Value
today today
yesterday yesterday
monthstart monthstart
monthend monthend
yearstart yearstart
yearend yearend
weekstart weekstart
weekend weekend
yearstart-1y yearstart-1y
yearend-1y yearend-1y
monthstart-1d monthstart-1d
monthend+1d monthend+1d
2014-04-25T16:15:47 2014-04-25T16:15:47
2014-04-25T16:15:47-04:00 2014-04-25T16:15:47-04:00

Output Columns

Label Data Type (SSIS) Data Type (SQL) Length Description
Id DT_I8 bigint
Email DT_WSTR nvarchar(255) 255
AcceptsMarketing DT_BOOL bit
CreatedAt DT_DBTIMESTAMP datetime
UpdatedAt DT_DBTIMESTAMP datetime
FirstName DT_WSTR nvarchar(255) 255
LastName DT_WSTR nvarchar(255) 255
OrdersCount DT_I4 int
State DT_WSTR nvarchar(255) 255
TotalSpent DT_WSTR nvarchar(50) 50
LastOrderId DT_I8 bigint
Note DT_WSTR nvarchar(4000) 4000
VerifiedEmail DT_BOOL bit
MultipassIdentifier DT_WSTR nvarchar(255) 255
TaxExempt DT_BOOL bit
TaxExemptions DT_WSTR nvarchar(4000) 4000
Tags DT_WSTR nvarchar(4000) 4000
LastOrderName DT_WSTR nvarchar(255) 255
Currency DT_WSTR nvarchar(20) 20
Phone DT_WSTR nvarchar(30) 30
AcceptsMarketingUpdatedAt DT_DBTIMESTAMP datetime
MarketingOptInLevel DT_WSTR nvarchar(255) 255
SMSMarketingConsent DT_WSTR nvarchar(255) 255
AdminGraphQLApiId DT_WSTR nvarchar(255) 255
DefaultAddressId DT_WSTR nvarchar(255) 255
DefaultAddressCustomerId DT_WSTR nvarchar(255) 255
DefaultAddressFirstName DT_WSTR nvarchar(255) 255
DefaultAddressLastName DT_WSTR nvarchar(255) 255
DefaultAddressCompany DT_WSTR nvarchar(255) 255
DefaultAddressAddress1 DT_WSTR nvarchar(255) 255
DefaultAddressAddress2 DT_WSTR nvarchar(255) 255
DefaultAddressCity DT_WSTR nvarchar(255) 255
DefaultAddressProvince DT_WSTR nvarchar(255) 255
DefaultAddressCountry DT_WSTR nvarchar(255) 255
DefaultAddressZip DT_WSTR nvarchar(255) 255
DefaultAddressPhone DT_WSTR nvarchar(255) 255
DefaultAddressName DT_WSTR nvarchar(255) 255
DefaultAddressProvinceCode DT_WSTR nvarchar(255) 255
DefaultAddressCountryCode DT_WSTR nvarchar(255) 255
DefaultAddressCountryName DT_WSTR nvarchar(255) 255
EmailMarketingConsentState DT_WSTR nvarchar(255) 255
EmailMarketingConsentOptInLevel DT_WSTR nvarchar(255) 255
EmailMarketingConsentUpdatedAt DT_DBTIMESTAMP datetime
If the column you are looking for is missing, consider customizing Shopify Connector.

Input Columns

Label Data Type (SSIS) Data Type (SQL) Length Description
CustomerId DT_I8 bigint
Required columns that you need to supply are bolded.

Examples

SSIS

Use Shopify Connector in API Source or in API Destination SSIS Data Flow components to read or write data.

API Source

This Endpoint belongs to the Customers table, therefore it is better to use it, instead of accessing the endpoint directly:

API Source - Shopify
Shopify Connector can be used to integrate Shopify REST API in your App / BI Tools. You can read/write data about Customers, Orders, OrderItems, Products and more.
Shopify
Customers
Optional Parameters
Customer Id(s) - Comma separated
SSIS API Source - Read from table or endpoint

API Destination

This Endpoint belongs to the Customers table, therefore it is better to use it, instead of accessing the endpoint directly. Use this table and table-operation pair to get customers:

API Destination - Shopify
Shopify Connector can be used to integrate Shopify REST API in your App / BI Tools. You can read/write data about Customers, Orders, OrderItems, Products and more.
Shopify
Customers
Select, Lookup
Optional Parameters
Customer Id(s) - Comma separated
SSIS API Destination - Access table operation

ODBC application

Use these SQL queries in your ODBC application data source:

Get list of customers

SELECT * FROM Customers

Get multiple specific customers by their IDs

SELECT * FROM Customers
WITH (ids='1111111111111,2222222222222,3333333333333')

Get a specific customer by its ID

SELECT * FROM Customers Where Id=12345

get_customers endpoint belongs to Customers table(s), and can therefore be used via those table(s).

SQL Server

Use these SQL queries in SQL Server after you create a data source in Data Gateway:

Get list of customers

DECLARE @MyQuery NVARCHAR(MAX) = 'SELECT * FROM Customers';

EXEC (@MyQuery) AT [LS_TO_SHOPIFY_IN_GATEWAY];

Get multiple specific customers by their IDs

DECLARE @MyQuery NVARCHAR(MAX) = 'SELECT * FROM Customers
WITH (ids=''1111111111111,2222222222222,3333333333333'')';

EXEC (@MyQuery) AT [LS_TO_SHOPIFY_IN_GATEWAY];

Get a specific customer by its ID

DECLARE @MyQuery NVARCHAR(MAX) = 'SELECT * FROM Customers Where Id=12345';

EXEC (@MyQuery) AT [LS_TO_SHOPIFY_IN_GATEWAY];

get_customers endpoint belongs to Customers table(s), and can therefore be used via those table(s).