API to create a product issue with meta fields

Topic summary

A developer is encountering issues when creating products via API—specifically, metafields are not being set correctly.

Problem Identified:

  • The user is likely using an incorrect namespace for the ispattern metafield
  • Using global as the namespace may not match the actual metafield definition

Suggested Solutions:

  • Check the metafield’s definition in the Admin UI by clicking the text field, which should reveal the correct namespace
  • Use the metafieldDefinitions GraphQL query to retrieve accurate namespace and key information:
    metafieldDefinitions(first: 100, ownerType: PRODUCT) {
      nodes {
        name
        namespace
        key
      }
    }
    

Additional Guidance:

  • Standard metafield definitions are auto-configured and cannot be edited
  • Only custom metafield definitions can be modified
  • For further API-related questions, the developer resources and Technical Q&A community board were recommended

Status: The issue remains unresolved pending verification of the correct namespace.

Summarized with AI on November 23. AI used: claude-sonnet-4-5-20250929.

Hey [email removed]iamarsibragimov,

Great question. If you favor working with metafields in the admin over the API or are cross-referencing how this will look in the admin - we offer a detailed guide in our help docs working with Metafields here. The screenshot shared in your last post is the metafields definition available through the admin.

There is also a dedicated section in our docs on editing a definition through the admin that includes a few insights, such as follows:

You can only edit custom metafield definitions. Standard metafield definitions are automatically configured for you and they can’t be edited.

For any other questions or concerns around using the admin features available, don’t hesitate to connect with Shopify Support here or consider posting in the Technical Q&A community board here.

If you are looking for additional insights into working with metafields using the API, after reviewing our extensive developer resources we’d suggest bringing additional questions back to this community board.

  • Cheers!