Menu
metaobjectCreate
Creates a metaobject entry based on an existing MetaobjectDefinition. The type must match a definition that already exists in the shop.
Use it in a workflow
- Add a step and choose the Shopify connector.
- Pick the metaobjectCreate action (under Metaobject).
- Fill in the fields below, then reference the result from later steps as
{{metaobjectcreate.response.data}}.
Query
This is the mutation the action sends by default. Edit it in the step's Query field to change which fields come back.
mutation MetaobjectCreate($metaobject: MetaobjectCreateInput!) {
metaobjectCreate(metaobject: $metaobject) {
metaobject {
capabilities {
onlineStore
publishable
}
createdAt
createdBy {
apiKey
appStoreAppUrl
appStoreDeveloperUrl
availableAccessScopes
banner
description
developerName
developerType
developerUrl
embedded
failedRequirements
features
feedback
handle
icon
id
installUrl
installation
isPostPurchaseAppInUse
launchUrl
navigationItems
optionalAccessScopes
previouslyInstalled
pricingDetails
pricingDetailsSummary
privacyPolicyUrl
publicCategory
published
requestedAccessScopes
screenshots
shopifyDeveloped
title
uninstallMessage
uninstallUrl
webhookApiVersion
}
createdByApp {
apiKey
appStoreAppUrl
appStoreDeveloperUrl
availableAccessScopes
banner
description
developerName
developerType
developerUrl
embedded
failedRequirements
features
feedback
handle
icon
id
installUrl
installation
isPostPurchaseAppInUse
launchUrl
navigationItems
optionalAccessScopes
previouslyInstalled
pricingDetails
pricingDetailsSummary
privacyPolicyUrl
publicCategory
published
requestedAccessScopes
screenshots
shopifyDeveloped
title
uninstallMessage
uninstallUrl
webhookApiVersion
}
createdByStaff {
accountType
active
email
exists
firstName
id
initials
isShopOwner
lastName
locale
name
phone
privateData
}
definition {
access
capabilities
createdAt
createdByApp
createdByStaff
description
displayNameKey
fieldDefinitions
hasThumbnailField
id
metaobjectsCount
name
standardTemplate
type
updatedAt
}
displayName
fields {
definition
jsonValue
key
reference
thumbnail
type
value
}
handle
id
staffMember {
accountType
active
email
exists
firstName
id
initials
isShopOwner
lastName
locale
name
phone
privateData
}
thumbnailField {
definition
jsonValue
key
reference
thumbnail
type
value
}
type
updatedAt
values
}
userErrors {
code
elementIndex
elementKey
field
message
}
}
}
Variables
Pass these as a JSON object in the step's Variables field.
{
"metaobject": {
"type": "string",
"handle": "string",
"fields": [
{
"key": "string",
"value": "string"
}
],
"capabilities": {
"publishable": {
"status": "string"
},
"onlineStore": {
"templateSuffix": "string"
}
},
"values": "string"
}
}
Response
Read the result with {{metaobjectcreate.response.data.data.metaobjectCreate}}. If the API returns errors, the step fails and they are at {{metaobjectcreate.response.data.errors}}.
Need more? See the Shopify guide for connection setup and behaviour shared by every action.
Was this page helpful?