Retrieve label of category metadata using GraphQl

Topic summary

A developer is attempting to retrieve category metadata labels for a product using Shopify’s GraphQL API. They have successfully assigned a color to a product via the Admin UI and can query the metafield data.

Current Issue:

  • The GraphQL query returns metaobject reference IDs (e.g., gid://shopify/Metaobject/74067444003) but not the human-readable labels associated with these values
  • The query retrieves the metafield structure including the “Color” definition name, but the actual color label/name is missing

Query Structure:
The developer is querying product metafields with nested definition data, attempting to access metafields within the definition itself. However, this approach isn’t returning the expected label information for the metaobject references.

Status: The question remains unanswered - the developer is seeking guidance on how to properly retrieve the display labels for metaobject reference values in their GraphQL query.

Summarized with AI on October 27. AI used: claude-sonnet-4-5-20250929.

I have created a product and assign a color in the category metadata on the Admin UI. I am trying to retrieve that information using GraphQL.

Query in the form:

query {
product(id: “gid://shopify/Product/9839925821731”)
{

metafields(first:1) { nodes {id ownerType value key type
definition {name metafields(first:2) {nodes {id namespace value }}}} }
category{ fullName }}}

This returns

{
“data”: { “product”: { “metafields”: { “nodes”: [
{ “id”: “gid://shopify/Metafield/40439661953315”, “ownerType”: “PRODUCT”, “value”: “["gid://shopify/Metaobject/74067444003"]”,
“key”: “color-pattern”, “type”: “list.metaobject_reference”,
“definition”: {
“name”: “Color”,
“metafields”: {
“nodes”: [
{
“id”: “gid://shopify/Metafield/40331134435619”,
“namespace”: “shopify”,
“value”: “["gid://shopify/Metaobject/74067444003"]”
},
{
“id”: “gid://shopify/Metafield/40331219960099”,
“namespace”: “shopify”,
“value”: “["gid://shopify/Metaobject/124484387107"]”
}]}}}]},
“category”: {
“fullName”: “Business & Industrial > Signage > Digital Signs”
}}},

But I cannot find a way to associate a label with the value returned?

Please let me know what I am missing.