The Shopify Admin component is designed to connect to the Shopify GraphQL Admin API.
Tested with API version: 2023-01.
To use this component, you need to create a custom app:
App and sales channel settings.Develop apps for your store.Create an app button.Create app.Configure Admin API scopes.Save.Install app button in the API credentials section or in the top-right corner.Admin API access token by selecting Reveal token once. This token is required for the component’s credentials configuration.API secret key if you plan to use webhooks.

Component credentials configuration fields:

2023-01, but it is designed to work with any available version.Webhook trigger to verify requests with an HMAC header.Notes:
- The
Admin API access tokenis shown only once.- To rotate the API credentials for a custom app created in the Shopify admin, you must uninstall and reinstall the app.
Shopify objects can be deleted using the Execute Mutation action.
To do this, filter the list of available mutation types in the Mutation type configuration field using keywords like Delete or Remove.

In most cases, you will receive one input metadata field for the object identifier.

{
"input": {
"id": "gid://shopify/Customer/6657016299696"
}
}
{
"companyIds": ["gid://shopify/Company/68616368"]
}
{
"search": "query=name:\"#D12\""
}
Shopify objects can be created using the Execute Mutation action.
To do this, filter the list of available mutation types in the Mutation type configuration field using the Create keyword.

The input metadata will represent all the fields required to create the object.
{
"input": {
"firstName": "NewUser"
}
}
Shopify objects can be updated using the Execute Mutation action.
To do this, filter the list of available mutation types in the Mutation type configuration field using the Update keyword.

The input metadata will represent all the fields required to update the object.
{
"input": {
"firstName": "NewUser2",
"id": "gid://shopify/Customer/6664472461488"
}
}
Updates an existing record or creates a new one if no match is found.
Customers are supported. customer {
addresses {
city
}
}
Please Note: You must select basic fields or provide additional fields for the resulting object to execute the mutation.
Dynamically generated fields based on the chosen Object type.
The resulting object from the upsert operation.
Executes any mutation available in the selected API version. This action can be used to Create, Update, or Delete objects and perform any other operations affecting Shopify data.
Customer Create). customer {
metafields(first: 2) {
edges {
node {
namespace
key
value
}
}
}
addresses {
address1
country
}
}
Please Note: You must select basic fields or provide additional fields for the resulting object to execute the mutation.
Dynamically generated fields based on the chosen Mutation type.
The resulting object from the executed mutation.
Lookup a set of objects based on defined criteria. Results can be emitted in multiple ways.
Customers). addresses {
address1
country
}
Emit page or Emit individually.customers:
{
"data": {
"customers": [
{
"id": "gid://shopify/Customer/2444144115794",
"firstName": "Willy"
},
{
"id": "gid://shopify/Customer/2444144148562",
"firstName": "Tobi"
},
{
"id": "gid://shopify/Customer/2444144181330",
"firstName": "Mathilde"
}
]
},
"extensions": {
"cost": {
"requestedQueryCost": 5,
"actualQueryCost": 5,
"throttleStatus": {
"maximumAvailable": 1000,
"currentlyAvailable": 40,
"restoreRate": 50
}
}
}
}
{
"results": [
{
"id": "gid://shopify/Customer/2444144115794",
"firstName": "Willy"
},
{
"id": "gid://shopify/Customer/2444144148562",
"firstName": "Tobi"
},
{
"id": "gid://shopify/Customer/2444144181330",
"firstName": "Mathilde"
}
]
}
Number of search terms configuration field.
Number of search terms is empty or 0, additional fields will not be generated.Number of search terms = 1, one search term will be added.Number of search terms > 1, the corresponding number of search terms and logical operators will be created.Each search term consists of:
Please Note: Use the
-sign for theNOTmodifier (see Shopify documentation).
AND).Dynamically generated fields based on the chosen Object type and selected fields.
For Emit Page mode: An object with a results key containing an array.
For Emit Individually mode: Each object is emitted as a separate message.
To execute the following Shopify query:
query{
customers(first:10 query:"country:Canada AND -state:DISABLED"){
edges{
node{
id
state
firstName
addresses{
country
}
}
}
}
}
Customers in Object type.Select basic fields dropdown, select id, state, and firstName.addresses{country}) in the Additional fields section.Emit Individually for Emit Behavior.Number of search terms to 2.Continue and proceed to metadata mapping.First to 10.Field name = country, Condition = :, Field value = Canada.Logical operator to AND.Field name = -state, Condition = :, Field value = DISABLED.Continue to retrieve a sample and finish configuration.Retrieves a single object by its ID.
Customer). addresses {
address1
country
}
Dynamically generated fields based on the chosen Object type and selected fields.
Executes a custom HTTP request.
There is no configuration fields in this action.
https://{store_name}.myshopify.com/admin/api/{api_version}/) or a full URL.GET, POST, PUT, PATCH, DELETE).Please Note: Both GraphQL and REST API endpoints are supported.
/graphql.json.POST.{"query": "query { products(first: 10) { edges { node { id title } } } }"}./products.json?fields=id,title.POST.{}.Retrieves all updated or created objects within a specified time range.
Customers).Last Modified or Created dates.edges.node.
metafields(first: 2) {
edges {
node {
namespace
key
value
}
}
}
addresses {
address1
country
}
Emit individually (default) or Emit page.There is no input metadata.
The resulting object represents the content from the path data\{Object Type}\edges\node. Output depends on the selected Object Type, fields, and Emit behavior.
Creates webhook subscriptions for selected topics to receive real-time events.
There is no input metadata.
The event data from the subscription topic.
Retrieve sample functionality."Throttled" error will be thrown.Click here to learn more about the elastic.io iPaaS