How to query another metaobject inside a metaobject?

Shopify Partner
6 0 0

I have 2 metaobjects, call meta1 and meta2 for example. The meta1 object will contain a list/array of meta2 object, and meta2 object will have some fields such as title, images, ...


I'm retrieving the meta1 object using this graphql query:





  query getHomeSlider($handle: String!) {
    metaobject(handle: { handle: $handle, type: "slider" }) {
      fields {





and inside the response i got this array that contain the id of all the meta2 objects that are added to the meta1 object.





fields: [
  key: 'slider_items',
  value: '["gid://shopify/Metaobject/30423908585", ...]'
} , ...






So my question is, is there any way to include the meta2 object field in the response? (instead of array of id, i want an array of object with all the fields of meta2 object)

Replies 0 (0)